Hani Park
commited on
Commit
·
78c2e74
1
Parent(s):
44547ee
Modify usage
Browse files
README.md
CHANGED
|
@@ -84,10 +84,24 @@ First, from the command line install the `datasets` library
|
|
| 84 |
then, from within python load the datasets library.
|
| 85 |
|
| 86 |
>>> import datasets
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 87 |
|
| 88 |
Now load one of the 'ChAFF' datasets, e.g.,
|
| 89 |
|
| 90 |
>>> dataset = datasets.load_dataset("maomlab/ChAFF", name = "default", data_files = "data/Absorbance.csv", split = "train", features = features)
|
| 91 |
|
|
|
|
| 92 |
You can modify "data/Absorbance.csv" based on your interest (e.g., "data/Reactivity.csv").
|
| 93 |
The default is split = "train" as we did not split the datasets.
|
|
|
|
| 84 |
then, from within python load the datasets library.
|
| 85 |
|
| 86 |
>>> import datasets
|
| 87 |
+
>>> from datasets import load_dataset, Features, Value
|
| 88 |
+
|
| 89 |
+
Specifiy column types to prevent pyarrow error.
|
| 90 |
+
```python
|
| 91 |
+
features = Features({
|
| 92 |
+
"Type": Value("string"),
|
| 93 |
+
"DatasetName": Value("string"),
|
| 94 |
+
"AID": Value("int64"),
|
| 95 |
+
"ID": Value("string"),
|
| 96 |
+
"IDType": Value("string"),
|
| 97 |
+
"SMILES": Value("string")
|
| 98 |
+
})
|
| 99 |
+
```
|
| 100 |
|
| 101 |
Now load one of the 'ChAFF' datasets, e.g.,
|
| 102 |
|
| 103 |
>>> dataset = datasets.load_dataset("maomlab/ChAFF", name = "default", data_files = "data/Absorbance.csv", split = "train", features = features)
|
| 104 |
|
| 105 |
+
|
| 106 |
You can modify "data/Absorbance.csv" based on your interest (e.g., "data/Reactivity.csv").
|
| 107 |
The default is split = "train" as we did not split the datasets.
|