tzrec/features/sequence_feature.py [273:300]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
            )
        else:
            raise ValueError(
                f"fg_mode: {self.fg_mode} is not supported without fg handler."
            )
        return parsed_feat

    def init_fg(self) -> None:
        """Init fg op."""
        cfgs = self.fg_json()
        is_rank_zero = os.environ.get("RANK", "0") == "0"
        if self._is_grouped_seq:
            # pyre-ignore [16]
            self._fg_op = pyfg.FeatureFactory.create(
                cfgs[0],
                self.sequence_name,
                self.sequence_delim,
                self.sequence_length,
                is_rank_zero,
            )
        else:
            # pyre-ignore [16]
            self._fg_op = pyfg.FeatureFactory.create(
                cfgs[0],
                is_rank_zero,
            )

    def fg_json(self) -> List[Dict[str, Any]]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



tzrec/features/sequence_feature.py [470:497]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                )
        else:
            raise ValueError(
                f"fg_mode: {self.fg_mode} is not supported without fg handler."
            )
        return parsed_feat

    def init_fg(self) -> None:
        """Init fg op."""
        cfgs = self.fg_json()
        is_rank_zero = os.environ.get("RANK", "0") == "0"
        if self._is_grouped_seq:
            # pyre-ignore [16]
            self._fg_op = pyfg.FeatureFactory.create(
                cfgs[0],
                self.sequence_name,
                self.sequence_delim,
                self.sequence_length,
                is_rank_zero,
            )
        else:
            # pyre-ignore [16]
            self._fg_op = pyfg.FeatureFactory.create(
                cfgs[0],
                is_rank_zero,
            )

    def fg_json(self) -> List[Dict[str, Any]]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



