Skip to content

Commit 90f64db

Browse files
committed
update load parameters
1 parent 3549d8c commit 90f64db

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

torch_molecule/datasets/load_hf_dataset.py

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ def load_broad6k(
231231
local_dir : str, optional
232232
Path where the data should be saved, by default "torchmol_data"
233233
target_cols : List[str], optional
234-
List of target column names, by default ["ABCB1", "ABL1", "ADRA1D", "ADRA2B", "ADRB2", "CA12", "CA2", "CA9", "CACNA1H", "CDK2", "CHRM1", "CHRM3", "CHRM4", "CNR1", "CYP1A2", "CYP2C19", "CYP2C9", "CYP2D6", "CYP3A4", "DRD2", "DRD3", "DRD4", "EGFR", "ESR1", "FLT1", "HRH1", "HTR1A", "HTR2A", "HTR2B", "HTR2C", "HTR6", "KCNH2", "KDR", "LCK", "MCL1", "OPRK1", "PPARG", "PTGS1", "SIGMAR1", "SLC6A2", "SLC6A4"]
234+
List of target column names, by default all tasks
235235
return_local_data_path : bool, optional
236236
Whether to return the local data path, by default False
237237
@@ -261,7 +261,7 @@ def load_broad6k(
261261

262262
def load_toxcast(
263263
local_dir: str = "torchmol_data",
264-
target_cols: Optional[List[str]] = None,
264+
target_cols: List[str] = TOXCAST_TASKS,
265265
return_local_data_path: bool = False,
266266
):
267267
"""
@@ -274,7 +274,7 @@ def load_toxcast(
274274
local_dir : str, optional
275275
Path where the data should be saved, by default "torchmol_data"
276276
target_cols : List[str], optional
277-
List of target column names, by default None (i.e., all tasks)
277+
List of target column names, by default all tasks
278278
return_local_data_path : bool, optional
279279
Whether to return the local data path, by default False
280280
@@ -289,9 +289,6 @@ def load_toxcast(
289289
- property_numpy: 2D numpy array with properties (rows=molecules, cols=targets)
290290
- local_data_path: Path where the data is saved
291291
"""
292-
if target_cols is None:
293-
target_cols = TOXCAST_TASKS.copy()
294-
295292
smiles_list, property_numpy, local_data_path = _load_from_hf(
296293
repo_id="liuganghuggingface/toxcast",
297294
filename="toxcast_data.csv.gz",
@@ -308,7 +305,7 @@ def load_toxcast(
308305

309306
def load_admet(
310307
local_dir: str = "torchmol_data",
311-
target_cols: Optional[List[str]] = None,
308+
target_cols: List[str] = ["AMES","BBB_Martins","Bioavailability_Ma","CYP1A2_Veith","CYP2C19_Veith","CYP2C9_Substrate_CarbonMangels","CYP2C9_Veith","CYP2D6_Substrate_CarbonMangels","CYP2D6_Veith","CYP3A4_Substrate_CarbonMangels","CYP3A4_Veith","Caco2_Wang","Carcinogens_Lagunin","Clearance_Hepatocyte_AZ","Clearance_Microsome_AZ","ClinTox","DILI","HIA_Hou","Half_Life_Obach","HydrationFreeEnergy_FreeSolv","LD50_Zhu","Lipophilicity_AstraZeneca","NR-AR-LBD","NR-AR","NR-AhR","NR-Aromatase","NR-ER-LBD","NR-ER","NR-PPAR-gamma","PAMPA_NCATS","PPBR_AZ","Pgp_Broccatelli","SR-ARE","SR-ATAD5","SR-HSE","SR-MMP","SR-p53","Skin_Reaction","Solubility_AqSolDB","VDss_Lombardo","hERG"],
312309
return_local_data_path: bool = False,
313310
):
314311
"""
@@ -321,7 +318,7 @@ def load_admet(
321318
local_dir : str, optional
322319
Path where the data should be saved, by default "torchmol_data"
323320
target_cols : List[str], optional
324-
List of target column names, by default None (i.e., all tasks)
321+
List of target column names, by default all tasks
325322
return_local_data_path : bool, optional
326323
Whether to return the local data path, by default False
327324
@@ -336,9 +333,6 @@ def load_admet(
336333
- property_numpy: 2D numpy array with properties (rows=molecules, cols=targets)
337334
- local_data_path: Path where the data is saved
338335
"""
339-
if target_cols is None:
340-
target_cols = ["AMES","BBB_Martins","Bioavailability_Ma","CYP1A2_Veith","CYP2C19_Veith","CYP2C9_Substrate_CarbonMangels","CYP2C9_Veith","CYP2D6_Substrate_CarbonMangels","CYP2D6_Veith","CYP3A4_Substrate_CarbonMangels","CYP3A4_Veith","Caco2_Wang","Carcinogens_Lagunin","Clearance_Hepatocyte_AZ","Clearance_Microsome_AZ","ClinTox","DILI","HIA_Hou","Half_Life_Obach","HydrationFreeEnergy_FreeSolv","LD50_Zhu","Lipophilicity_AstraZeneca","NR-AR-LBD","NR-AR","NR-AhR","NR-Aromatase","NR-ER-LBD","NR-ER","NR-PPAR-gamma","PAMPA_NCATS","PPBR_AZ","Pgp_Broccatelli","SR-ARE","SR-ATAD5","SR-HSE","SR-MMP","SR-p53","Skin_Reaction","Solubility_AqSolDB","VDss_Lombardo","hERG"]
341-
342336
smiles_list, property_numpy, local_data_path = _load_from_hf(
343337
repo_id="liuganghuggingface/admet",
344338
filename="admet.csv",

0 commit comments

Comments
 (0)