Skip to content

Commit

Permalink
datasets
Browse files Browse the repository at this point in the history
  • Loading branch information
0x00b1 committed Jul 17, 2024
1 parent 96ec84a commit 02d6f02
Show file tree
Hide file tree
Showing 6 changed files with 123 additions and 29 deletions.
32 changes: 18 additions & 14 deletions src/beignet/datasets/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
from ._atom3d_res_dataset import ATOM3DRESDataset
from ._atom3d_rsr_dataset import ATOM3DRSRDataset
from ._atom3d_smp_dataset import ATOM3DSMPDataset
from ._bindingdb_dataset import BindingDBDataset
from ._bindingdb_ic50_dataset import BindingDBIC50Dataset
from ._bindingdb_kd_dataset import BindingDBKdDataset
from ._bindingdb_ki_dataset import BindingDBKiDataset
from ._broccatelli_p_glycoprotein_inhibition_dataset import (
BroccatelliPGlycoproteinInhibitionDataset,
)
Expand Down Expand Up @@ -98,26 +100,28 @@
from ._zinc_dataset import ZINCDataset

__all__ = [
"AqSolDBSolubilityDataset",
"AstraZenecaClearanceDataset",
"AstraZenecaLipophilicityDataset",
"AstraZenecaPlasmaProteinBindingRateDataset",
"ATOM3DDataset",
"ATOM3DMSPDataset",
"ATOM3DPPIDataset",
"ATOM3DPSRDataset",
"ATOM3DRESDataset",
"ATOM3DRSRDataset",
"ATOM3DSMPDataset",
"BindingDBDataset",
"AqSolDBSolubilityDataset",
"AstraZenecaClearanceDataset",
"AstraZenecaLipophilicityDataset",
"AstraZenecaPlasmaProteinBindingRateDataset",
"BindingDBIC50Dataset",
"BindingDBKdDataset",
"BindingDBKiDataset",
"BroccatelliPGlycoproteinInhibitionDataset",
"CarbonMangelsCytochromeP4502C9SubstrateDataset",
"CarbonMangelsCytochromeP4502D6SubstrateDataset",
"CarbonMangelsCytochromeP4503A4SubstrateDataset",
"ChEMBLDataset",
"ClinToxDataset",
"DataFrameDataset",
"DAVISDataset",
"DataFrameDataset",
"DisGeNETDataset",
"DrugCombDataset",
"FASTADataset",
Expand All @@ -130,46 +134,46 @@
"KIBADataset",
"LMDBDataset",
"LombardoVolumeOfDistributionAtSteadyStateDataset",
"MOSESDataset",
"MaBioavailabilityDataset",
"MartinsBloodBrainBarrierDataset",
"MOSESDataset",
"NCATSPAMPAPermeabilityDataset",
"ObachHalfLifeDataset",
"ParquetDataset",
"PDB70Dataset",
"PDBTrajectoryDataset",
"PDBbindDataset",
"ParquetDataset",
"QM7Dataset",
"QM7bDataset",
"QM8Dataset",
"QM9Dataset",
"REALDatabaseDataset",
"RandomEulerAngleDataset",
"RandomQuaternionDataset",
"RandomRotationDataset",
"RandomRotationMatrixDataset",
"RandomRotationVectorDataset",
"REALDatabaseDataset",
"SAbDabDataset",
"SKEMPIDataset",
"SequenceDataset",
"SizedSequenceDataset",
"SKEMPIDataset",
"SwissProtDataset",
"TDCDataset",
"Tox21Dataset",
"ToxCastDataset",
"TrajectoryDataset",
"TrEMBLDataset",
"TrajectoryDataset",
"USPTOReactionProductDataset",
"UniProtDataset",
"UniRef100Dataset",
"UniRef50Dataset",
"UniRef90Dataset",
"USPTOReactionProductDataset",
"VeithCytochromeP4501A2InhibitionDataset",
"VeithCytochromeP4502C19InhibitionDataset",
"VeithCytochromeP4502C9InhibitionDataset",
"VeithCytochromeP4502D6InhibitionDataset",
"VeithCytochromeP4503A4InhibitionDataset",
"WangEffectivePermeabilityDataset",
"ZhuAcuteToxicityLD50Dataset",
"ZINCDataset",
"ZhuAcuteToxicityLD50Dataset",
]
45 changes: 45 additions & 0 deletions src/beignet/datasets/_bindingdb_ic50_dataset.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
from pathlib import Path
from typing import Callable

from beignet.transforms import Transform

from ._tdc_dataset import TDCDataset


class BindingDBIC50Dataset(TDCDataset):
def __init__(
self,
root: str | Path,
*,
download: bool = False,
transform: Callable | Transform | None = None,
target_transform: Callable | Transform | None = None,
):
r"""
Parameters
----------
root : str | Path
Root directory of dataset.
download: bool
If `True`, downloads the dataset to the root directory. If dataset
already exists, it is not redownloaded. Default, `False`.
transform : Callable | Transform | None
Transforms the input.
target_transform : Callable | Transform | None
Transforms the target.
"""
super().__init__(
root=root,
download=download,
identifier=4291560,
suffix="csv",
checksum="md5:a6ca198002c335aa9a30248cf3795413",
x_keys=["X1", "X2"],
y_keys=["Y"],
transform=transform,
target_transform=target_transform,
)
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from ._tdc_dataset import TDCDataset


class BindingDBDataset(TDCDataset):
class BindingDBKdDataset(TDCDataset):
def __init__(
self,
root: str | Path,
Expand Down Expand Up @@ -35,11 +35,11 @@ def __init__(
super().__init__(
root=root,
download=download,
identifier=0,
suffix="",
checksum="",
x_keys=[""],
y_keys=[""],
identifier=4291555,
suffix="csv",
checksum="md5:728c9d39485cf9667c1567cc710fb6b6",
x_keys=["X1", "X2"],
y_keys=["Y"],
transform=transform,
target_transform=target_transform,
)
45 changes: 45 additions & 0 deletions src/beignet/datasets/_bindingdb_ki_dataset.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
from pathlib import Path
from typing import Callable

from beignet.transforms import Transform

from ._tdc_dataset import TDCDataset


class BindingDBKiDataset(TDCDataset):
def __init__(
self,
root: str | Path,
*,
download: bool = False,
transform: Callable | Transform | None = None,
target_transform: Callable | Transform | None = None,
):
r"""
Parameters
----------
root : str | Path
Root directory of dataset.
download: bool
If `True`, downloads the dataset to the root directory. If dataset
already exists, it is not redownloaded. Default, `False`.
transform : Callable | Transform | None
Transforms the input.
target_transform : Callable | Transform | None
Transforms the target.
"""
super().__init__(
root=root,
download=download,
identifier=4291556,
suffix="csv",
checksum="md5:187d6c8926c608e24f4469373811806d",
x_keys=["X1", "X2"],
y_keys=["Y"],
transform=transform,
target_transform=target_transform,
)
8 changes: 4 additions & 4 deletions src/beignet/datasets/_davis_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ def __init__(
super().__init__(
root=root,
download=download,
identifier=0,
suffix="",
identifier=5219748,
suffix="md5:6c7949b81aea69e9d816db88602d771e",
checksum="",
x_keys=[""],
y_keys=[""],
x_keys=["X1", "X2"],
y_keys=["Y"],
transform=transform,
target_transform=target_transform,
)
10 changes: 5 additions & 5 deletions src/beignet/datasets/_kiba_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ def __init__(
super().__init__(
root=root,
download=download,
identifier=0,
suffix="",
checksum="",
x_keys=[""],
y_keys=[""],
identifier=5255037,
suffix="tsv",
checksum="md5:2af3d738f320700bfc98b781fe354b64",
x_keys=["X1", "X2"],
y_keys=["Y"],
transform=transform,
target_transform=target_transform,
)

0 comments on commit 02d6f02

Please sign in to comment.