Datasets:
Sara Hantgan
commited on
Commit
·
f054c93
1
Parent(s):
9b69ef4
Added proper dataset loader, data folder, and README for Hugging Face dataset compatibility
Browse files- 5ht_ki_prediction.py +36 -0
- README.md +18 -12
- data/KiDatabase.csv +3 -0
5ht_ki_prediction.py
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from datasets import DatasetInfo, GeneratorBasedBuilder, SplitGenerator, Split, Value, Features
|
| 2 |
+
import datasets
|
| 3 |
+
import csv
|
| 4 |
+
|
| 5 |
+
class FiveHTKiPrediction(datasets.GeneratorBasedBuilder):
|
| 6 |
+
VERSION = datasets.Version("1.0.0")
|
| 7 |
+
|
| 8 |
+
def _info(self):
|
| 9 |
+
return DatasetInfo(
|
| 10 |
+
description="Curated dataset of serotonin receptor Ki values from PDSP Ki Database.",
|
| 11 |
+
features=Features({
|
| 12 |
+
"smiles": Value("string"),
|
| 13 |
+
"ki": Value("float"),
|
| 14 |
+
"receptor": Value("string"),
|
| 15 |
+
"source": Value("string"),
|
| 16 |
+
}),
|
| 17 |
+
supervised_keys=None,
|
| 18 |
+
)
|
| 19 |
+
|
| 20 |
+
def _split_generators(self, dl_manager):
|
| 21 |
+
data_path = dl_manager.download_and_extract("data/KiDatabase.csv")
|
| 22 |
+
return [SplitGenerator(name=Split.TRAIN, gen_kwargs={"filepath": data_path})]
|
| 23 |
+
|
| 24 |
+
def _generate_examples(self, filepath):
|
| 25 |
+
with open(filepath, encoding="utf-8") as f:
|
| 26 |
+
reader = csv.DictReader(f)
|
| 27 |
+
for idx, row in enumerate(reader):
|
| 28 |
+
try:
|
| 29 |
+
yield idx, {
|
| 30 |
+
"smiles": row["SMILES"].strip(),
|
| 31 |
+
"ki": float(row["ki Val"]) if row["ki Val"] else None,
|
| 32 |
+
"receptor": row["Name"].strip(),
|
| 33 |
+
"source": row["source"].strip(),
|
| 34 |
+
}
|
| 35 |
+
except Exception:
|
| 36 |
+
continue
|
README.md
CHANGED
|
@@ -1,16 +1,22 @@
|
|
| 1 |
---
|
|
|
|
|
|
|
| 2 |
language:
|
| 3 |
-
- en
|
|
|
|
| 4 |
tags:
|
| 5 |
-
- bioactivity
|
| 6 |
-
- cheminformatics
|
| 7 |
-
- regression
|
| 8 |
-
- serotonin
|
| 9 |
-
- binding-affinity
|
| 10 |
-
pretty_name: 5-HT Ki Prediction Dataset
|
| 11 |
size_categories:
|
| 12 |
-
-
|
|
|
|
|
|
|
|
|
|
| 13 |
---
|
|
|
|
| 14 |
# Serotonin Receptor (5-HT) Binding Affinity Prediction Dataset
|
| 15 |
|
| 16 |
This dataset was curated from the PDSP Ki Database to support training machine learning models that predict binding affinity (Ki in nM) of ligands to serotonin (5-HT) receptors.
|
|
@@ -32,15 +38,15 @@ This dataset was curated from the PDSP Ki Database to support training machine l
|
|
| 32 |
|
| 33 |
### 📈 Model Performance
|
| 34 |
|
| 35 |
-
- **R² Score**:
|
| 36 |
-
- **RMSE**:
|
| 37 |
|
| 38 |
## Source
|
| 39 |
|
| 40 |
- PDSP Ki Database: https://pdsp.unc.edu/databases/kidb.php
|
| 41 |
|
| 42 |
-
##
|
| 43 |
|
| 44 |
Sara Hantgan
|
| 45 |
University of Michigan | BIOINF 595 Final Project
|
| 46 |
-
Winter 2025
|
|
|
|
| 1 |
---
|
| 2 |
+
datasets:
|
| 3 |
+
- sarahantgan/5HT_Ki_Prediction
|
| 4 |
language:
|
| 5 |
+
- en
|
| 6 |
+
license: cc-by-4.0
|
| 7 |
tags:
|
| 8 |
+
- bioactivity
|
| 9 |
+
- cheminformatics
|
| 10 |
+
- regression
|
| 11 |
+
- serotonin
|
| 12 |
+
- binding-affinity
|
|
|
|
| 13 |
size_categories:
|
| 14 |
+
- 100-1K
|
| 15 |
+
task_categories:
|
| 16 |
+
- regression
|
| 17 |
+
pretty_name: 5-HT Ki Prediction Dataset
|
| 18 |
---
|
| 19 |
+
|
| 20 |
# Serotonin Receptor (5-HT) Binding Affinity Prediction Dataset
|
| 21 |
|
| 22 |
This dataset was curated from the PDSP Ki Database to support training machine learning models that predict binding affinity (Ki in nM) of ligands to serotonin (5-HT) receptors.
|
|
|
|
| 38 |
|
| 39 |
### 📈 Model Performance
|
| 40 |
|
| 41 |
+
- **R² Score**: `your_R2_here`
|
| 42 |
+
- **RMSE**: `your_RMSE_here` nM
|
| 43 |
|
| 44 |
## Source
|
| 45 |
|
| 46 |
- PDSP Ki Database: https://pdsp.unc.edu/databases/kidb.php
|
| 47 |
|
| 48 |
+
## Project by
|
| 49 |
|
| 50 |
Sara Hantgan
|
| 51 |
University of Michigan | BIOINF 595 Final Project
|
| 52 |
+
Winter 2025
|
data/KiDatabase.csv
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:93a15227e00534bed1d6e6bc777af679b66eb8180c797fbb18248df4602aeefe
|
| 3 |
+
size 23869637
|