noshou commited on
Commit
c055453
·
verified ·
1 Parent(s): 918c0a5

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +16 -12
README.md CHANGED
@@ -31,17 +31,18 @@ size_categories:
31
  | File | Size | Description |
32
  |------|------|-------------|
33
  | `I(q)@L=50.h5` | ~66 GB | HDF5 database of I(q) curves and molecular data |
 
34
  | `xyz_coordinate_files.7z` | ~6.5 GB | Source XYZ geometry files for all molecule groups (LZMA2, max compression). Only needed to re-run the build pipeline from scratch. |
35
 
36
  ## Retrieving the dataset
37
 
38
  The HDF5 files are hosted on **[HuggingFace (noshou/iq_train_set)](https://huggingface.co/datasets/noshou/iq_train_set)** and **[Kaggle (noso0s0n/iql50)](https://www.kaggle.com/datasets/noso0s0n/iql50)**. The training code (ScatterNet model, preprocessing pipeline, baselines) lives in the **[noshou/APS360](https://github.com/noshou/APS360)** GitHub repository; the `Preprocess/` directory contains the encoding and data pipeline code.
39
 
40
- Download with the HuggingFace CLI (recommended - resumes interrupted downloads):
41
 
42
  ```bash
43
  pip install huggingface_hub
44
- huggingface-cli download noshou/iq_train_set "I(q)@L=50.h5" \
45
  --repo-type dataset --local-dir Preprocess/
46
  ```
47
 
@@ -49,15 +50,18 @@ Or in Python:
49
 
50
  ```python
51
  from huggingface_hub import hf_hub_download
52
- hf_hub_download(
53
- repo_id = "noshou/iq_train_set",
54
- filename = "I(q)@L=50.h5",
55
- repo_type = "dataset",
56
- local_dir = "Preprocess/",
57
- )
 
58
  ```
59
 
60
- Place the downloaded file at `Preprocess/I(q)@L=50.h5` (the path all pipeline scripts expect).
 
 
61
 
62
  ## Running training
63
 
@@ -72,13 +76,13 @@ python Train/train.py --config Train/train.yaml
72
  Key paths in `train.yaml`:
73
 
74
  ```yaml
75
- hdf5: Preprocess/I(q)@L=50.h5 # downloaded above
76
- db: Preprocess/iq_train_set # -> iq_train_set-ENCODING.sqlite3 (LFS)
77
  ```
78
 
79
  ### Kaggle (notebook)
80
 
81
- Open `Baselines/kaggle_baselines.ipynb`. Set `NOTEBOOK_NAME` to your Kaggle notebook slug at the top of the setup cell. The notebook clones the repo, installs dependencies, builds the encoding DB, and runs all baselines. The encoding DB build takes roughly 30 minutes on Kaggle hardware the first time; subsequent runs skip it automatically.
82
 
83
  ---
84
 
 
31
  | File | Size | Description |
32
  |------|------|-------------|
33
  | `I(q)@L=50.h5` | ~66 GB | HDF5 database of I(q) curves and molecular data |
34
+ | `iq_train_set-ENCODING.sqlite3` | ~860 MB | Encoding index: maps every molecule to its atom count and VOCAB indices, so the data pipeline never needs to scan the 66 GB HDF5 file during training |
35
  | `xyz_coordinate_files.7z` | ~6.5 GB | Source XYZ geometry files for all molecule groups (LZMA2, max compression). Only needed to re-run the build pipeline from scratch. |
36
 
37
  ## Retrieving the dataset
38
 
39
  The HDF5 files are hosted on **[HuggingFace (noshou/iq_train_set)](https://huggingface.co/datasets/noshou/iq_train_set)** and **[Kaggle (noso0s0n/iql50)](https://www.kaggle.com/datasets/noso0s0n/iql50)**. The training code (ScatterNet model, preprocessing pipeline, baselines) lives in the **[noshou/APS360](https://github.com/noshou/APS360)** GitHub repository; the `Preprocess/` directory contains the encoding and data pipeline code.
40
 
41
+ Download both the HDF5 file and the encoding DB with the HuggingFace CLI (recommended - resumes interrupted downloads):
42
 
43
  ```bash
44
  pip install huggingface_hub
45
+ hf download noshou/iq_train_set "I(q)@L=50.h5" "iq_train_set-ENCODING.sqlite3" \
46
  --repo-type dataset --local-dir Preprocess/
47
  ```
48
 
 
50
 
51
  ```python
52
  from huggingface_hub import hf_hub_download
53
+ for filename in ["I(q)@L=50.h5", "iq_train_set-ENCODING.sqlite3"]:
54
+ hf_hub_download(
55
+ repo_id = "noshou/iq_train_set",
56
+ filename = filename,
57
+ repo_type = "dataset",
58
+ local_dir = "Preprocess/",
59
+ )
60
  ```
61
 
62
+ Both files are also available on the **[Kaggle dataset](https://www.kaggle.com/datasets/noso0s0n/iql50)** and are mounted directly as notebook inputs when using `kaggle_train.ipynb` / `kaggle_baselines.ipynb` -- no download step needed there.
63
+
64
+ Place the downloaded files at `Preprocess/I(q)@L=50.h5` and `Preprocess/iq_train_set-ENCODING.sqlite3` (the paths all pipeline scripts expect).
65
 
66
  ## Running training
67
 
 
76
  Key paths in `train.yaml`:
77
 
78
  ```yaml
79
+ hdf5: Preprocess/I(q)@L=50.h5 # downloaded above
80
+ encodings_sqlite3_path: Preprocess/iq_train_set-ENCODING.sqlite3 # downloaded above
81
  ```
82
 
83
  ### Kaggle (notebook)
84
 
85
+ Open `Baselines/kaggle_baselines.ipynb`. Set `NOTEBOOK_NAME` to your Kaggle notebook slug at the top of the setup cell, and attach the [`noso0s0n/iql50`](https://www.kaggle.com/datasets/noso0s0n/iql50) dataset as a notebook input -- it provides both `I(q)@L=50.h5` and `iq_train_set-ENCODING.sqlite3` pre-mounted under `/kaggle/input/datasets/noso0s0n/iql50/`, no download or build step needed. The notebook clones the repo, installs dependencies, and runs all baselines.
86
 
87
  ---
88