Update README.md
Browse files
README.md
CHANGED
|
@@ -118,72 +118,3 @@ print(f"\n✓ Repository downloaded to: {repo_path}")
|
|
| 118 |
# Construct path to the rossi_annotated_features parquet file
|
| 119 |
parquet_path = os.path.join(repo_path, "harbison_2004.parquet")
|
| 120 |
print(f"✓ Parquet file at: {parquet_path}")
|
| 121 |
-
➜ ~ cat /home/chase/Downloads/Harbison.2004.md
|
| 122 |
-
# Harbison 2004
|
| 123 |
-
|
| 124 |
-
This Dataset is a parsed version of the data provided by Richard A. Young's lab. To cite
|
| 125 |
-
this data, please use:
|
| 126 |
-
|
| 127 |
-
[Harbison CT, Gordon DB, Lee TI, Rinaldi NJ, Macisaac KD, Danford TW, Hannett NM, Tagne
|
| 128 |
-
JB, Reynolds DB, Yoo J, et al. 2004. Transcriptional regulatory code of a eukaryotic
|
| 129 |
-
genome. Nature 431:
|
| 130 |
-
99–104.doi:10.1038/nature02800](https://www.nature.com/articles/nature02800)
|
| 131 |
-
|
| 132 |
-
This repo provides 1 dataset:
|
| 133 |
-
|
| 134 |
-
- **harbison_2004**: ChIP-chip transcription factor binding data with environmental
|
| 135 |
-
conditions.
|
| 136 |
-
|
| 137 |
-
### `tfbpapi`
|
| 138 |
-
|
| 139 |
-
After [installing
|
| 140 |
-
tfbpapi](https://github.com/BrentLab/tfbpapi/?tab=readme-ov-file#installation), you can
|
| 141 |
-
adapt this [tutorial](https://brentlab.github.io/tfbpapi/tutorials/hfqueryapi_tutorial/)
|
| 142 |
-
in order to explore the contents of this repository.
|
| 143 |
-
|
| 144 |
-
### huggingface_cli/duckdb
|
| 145 |
-
|
| 146 |
-
You can retrieves and displays the file paths for each configuration of
|
| 147 |
-
the "BrentLab/harbison_2004" dataset from Hugging Face Hub.
|
| 148 |
-
|
| 149 |
-
```python
|
| 150 |
-
from huggingface_hub import ModelCard
|
| 151 |
-
from pprint import pprint
|
| 152 |
-
|
| 153 |
-
card = ModelCard.load("BrentLab/harbison_2004", repo_type="dataset")
|
| 154 |
-
|
| 155 |
-
# cast to dict
|
| 156 |
-
card_dict = card.data.to_dict()
|
| 157 |
-
|
| 158 |
-
# Get partition information
|
| 159 |
-
dataset_paths_dict = {d.get("config_name"): d.get("data_files")[0].get("path") for d in card_dict.get("configs")}
|
| 160 |
-
|
| 161 |
-
pprint(dataset_paths_dict)
|
| 162 |
-
```
|
| 163 |
-
|
| 164 |
-
If you wish to pull the entire repo, due to its size you may need to use an
|
| 165 |
-
[authentication token](https://huggingface.co/docs/hub/en/security-tokens).
|
| 166 |
-
If you do not have one, try omitting the token related code below and see if
|
| 167 |
-
it works. Else, create a token and provide it like so:
|
| 168 |
-
|
| 169 |
-
```python
|
| 170 |
-
from huggingface_hub import snapshot_download
|
| 171 |
-
import os
|
| 172 |
-
|
| 173 |
-
repo_id = "BrentLab/harbison_2004"
|
| 174 |
-
|
| 175 |
-
hf_token = os.getenv("HF_TOKEN")
|
| 176 |
-
|
| 177 |
-
# Download entire repo to local directory
|
| 178 |
-
repo_path = snapshot_download(
|
| 179 |
-
repo_id=repo_id,
|
| 180 |
-
repo_type="dataset",
|
| 181 |
-
token=hf_token
|
| 182 |
-
)
|
| 183 |
-
|
| 184 |
-
print(f"\n✓ Repository downloaded to: {repo_path}")
|
| 185 |
-
|
| 186 |
-
# Construct path to the rossi_annotated_features parquet file
|
| 187 |
-
parquet_path = os.path.join(repo_path, "harbison_2004.parquet")
|
| 188 |
-
print(f"✓ Parquet file at: {parquet_path}")
|
| 189 |
-
```
|
|
|
|
| 118 |
# Construct path to the rossi_annotated_features parquet file
|
| 119 |
parquet_path = os.path.join(repo_path, "harbison_2004.parquet")
|
| 120 |
print(f"✓ Parquet file at: {parquet_path}")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|