a143e4f2f5ba50c530d156740f9b7023b603dc9b,deepchem/utils/save.py,,load_dataset_from_disk,#Any#,187
Before Change
train_dir = os.path.join(save_dir, "train_dir")
valid_dir = os.path.join(save_dir, "valid_dir")
test_dir = os.path.join(save_dir, "test_dir")
if os.path.exists(train_dir) and os.path.exists(valid_dir) and os.path.exists(
test_dir):
loaded = True
train = deepchem.data.DiskDataset(train_dir)
valid = deepchem.data.DiskDataset(valid_dir)
test = deepchem.data.DiskDataset(test_dir)
all_dataset = (train, valid, test)
with open(os.path.join(save_dir, "transformers.pkl"), "rb") as f:
transformers = pickle.load(f)
else:
loaded = False
all_dataset = None
transformers = []
return loaded, all_dataset, transformers
def save_dataset_to_disk(save_dir, train, valid, test, transformers):
After Change
train_dir = os.path.join(save_dir, "train_dir")
valid_dir = os.path.join(save_dir, "valid_dir")
test_dir = os.path.join(save_dir, "test_dir")
if not os.path.exists(train_dir) or not os.path.exists(valid_dir) or not os.path.exists(test_dir):
return False, None, list()
loaded = True
train = deepchem.data.DiskDataset(train_dir)
valid = deepchem.data.DiskDataset(valid_dir)
test = deepchem.data.DiskDataset(test_dir)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 8
Instances
Project Name: deepchem/deepchem
Commit Name: a143e4f2f5ba50c530d156740f9b7023b603dc9b
Time: 2018-01-02
Author: lilleswing@gmail.com
File Name: deepchem/utils/save.py
Class Name:
Method Name: load_dataset_from_disk
Project Name: vatlab/SoS
Commit Name: a1af2977c50399f58726182cd9481a6770c115ac
Time: 2017-03-30
Author: ben.bog@gmail.com
File Name: sos/sos_task.py
Class Name:
Method Name: check_task
Project Name: pantsbuild/pants
Commit Name: bc4a8fb3f07f6145649f02b06a1e5599aa28b36c
Time: 2020-10-21
Author: asher@asherfoa.com
File Name: src/python/pants/goal/aggregated_timings.py
Class Name: AggregatedTimings
Method Name: add_timing