tf2_gnn/data/qm9_dataset.py
def load_data(self, path: RichPath, folds_to_load: Optional[Set[DataFold]] = None) -> None:
        """Load the data from disk."""
        if path is None:
            path = RichPath.create(self.default_data_directory())
        logger.info("Starting to load data.")

        # If we haven't defined what folds to load, load all:
        if folds_to_load is None:
            folds_to_load = {DataFold.TRAIN, DataFold.VALIDATION, DataFold.TEST}

        if DataFold.TRAIN in folds_to_load:
            self._loaded_data[DataFold.TRAIN] = self.__load_data(path.join("train.jsonl.gz"))
            logger.debug("Done loading training data.")
        if DataFold.VALIDATION in folds_to_load:
            self._loaded_data[DataFold.VALIDATION] = self.__load_data(path.join("valid.jsonl.gz"))
            logger.debug("Done loading validation data.")
        if DataFold.TEST in folds_to_load:
            self._loaded_data[DataFold.TEST] = self.__load_data(path.join("test.jsonl.gz"))
            logger.debug("Done loading test data.")
Load the data from disk.
Load the data from disk.
Load the data from disk .
def load_data(self, path: RichPath, folds_to_load: Optional[Set[DataFold]] = None) -> None:
        if path is None:
            path = RichPath.create(self.default_data_directory())
        logger.info("Starting to load data.")
        if folds_to_load is None:
            folds_to_load = {DataFold.TRAIN, DataFold.VALIDATION, DataFold.TEST}
        if DataFold.TRAIN in folds_to_load:
            self._loaded_data[DataFold.TRAIN] = self.__load_data(path.join("train.jsonl.gz"))
            logger.debug("Done loading training data.")
        if DataFold.VALIDATION in folds_to_load:
            self._loaded_data[DataFold.VALIDATION] = self.__load_data(path.join("valid.jsonl.gz"))
            logger.debug("Done loading validation data.")
        if DataFold.TEST in folds_to_load:
            self._loaded_data[DataFold.TEST] = self.__load_data(path.join("test.jsonl.gz"))
            logger.debug("Done loading test data.")
def load_data ( self , path : RichPath , folds_to_load : Optional [ Set [ DataFold ] ] = None ) -> None : if path is None : path = RichPath . create ( self . default_data_directory ( ) ) logger . info ( "Starting to load data." ) if folds_to_load is None : folds_to_load = { DataFold . TRAIN , DataFold . VALIDATION , DataFold . TEST } if DataFold . TRAIN in folds_to_load : self . _loaded_data [ DataFold . TRAIN ] = self . __load_data ( path . join ( "train.jsonl.gz" ) ) logger . debug ( "Done loading training data." ) if DataFold . VALIDATION in folds_to_load : self . _loaded_data [ DataFold . VALIDATION ] = self . __load_data ( path . join ( "valid.jsonl.gz" ) ) logger . debug ( "Done loading validation data." ) if DataFold . TEST in folds_to_load : self . _loaded_data [ DataFold . TEST ] = self . __load_data ( path . join ( "test.jsonl.gz" ) ) logger . debug ( "Done loading test data." )
Load the data from disk.
Load the data from disk .
"""Load the data from disk.""" # If we haven't defined what folds to load, load all:
self
path
RichPath
folds_to_load
Optional[Set[DataFold]]