Update README.md
Browse files
README.md
CHANGED
@@ -9,71 +9,21 @@ tags:
|
|
9 |
datasets:
|
10 |
- nvidia-gpu-dataset
|
11 |
---
|
|
|
12 |
|
13 |
-
|
14 |
-
|
15 |
-
This project processes scraped data related to NVIDIA GPUs using a Dockerized Python environment. It runs scripts to scrape data (`webscraped.py`) and generate a summary report (`summary.py`).
|
16 |
-
|
17 |
-
## Pushing to Hugging Face
|
18 |
-
|
19 |
-
To push the dataset to Hugging Face, follow these steps:
|
20 |
-
|
21 |
-
1. **Install the Hugging Face Datasets library**:
|
22 |
-
```bash
|
23 |
-
pip install datasets
|
24 |
-
```
|
25 |
-
|
26 |
-
2. **Prepare your dataset**: Ensure your dataset is in a compatible format (e.g., JSON, CSV).
|
27 |
-
|
28 |
-
3. **Upload the dataset**:
|
29 |
-
Use the following command to upload your dataset:
|
30 |
-
```bash
|
31 |
-
huggingface-cli dataset create --dataset_name bniladridas/nvidia-gpu-dataset --path <path_to_your_dataset>
|
32 |
-
```
|
33 |
-
|
34 |
-
4. **Add metadata**: Optionally, you can add a dataset card to describe your dataset.
|
35 |
-
|
36 |
-
5. **Validate your dataset**: After uploading, check the Hugging Face website to ensure your dataset is correctly formatted and accessible.
|
37 |
-
|
38 |
-
For more detailed instructions, refer to the [Hugging Face documentation](https://huggingface.co/docs).
|
39 |
-
|
40 |
-
To push the dataset to Hugging Face, follow these steps:
|
41 |
-
|
42 |
-
1. **Install the Hugging Face Datasets library**:
|
43 |
-
```bash
|
44 |
-
pip install datasets
|
45 |
-
```
|
46 |
-
|
47 |
-
2. **Prepare your dataset**: Ensure your dataset is in a compatible format (e.g., JSON, CSV).
|
48 |
-
|
49 |
-
3. **Upload the dataset**:
|
50 |
-
Use the following command to upload your dataset:
|
51 |
-
```bash
|
52 |
-
huggingface-cli dataset create --dataset_name <your_dataset_name> --path <path_to_your_dataset>
|
53 |
-
```
|
54 |
-
|
55 |
-
4. **Add metadata**: Optionally, you can add a dataset card to describe your dataset.
|
56 |
-
|
57 |
-
5. **Validate your dataset**: After uploading, check the Hugging Face website to ensure your dataset is correctly formatted and accessible.
|
58 |
-
|
59 |
-
For more detailed instructions, refer to the [Hugging Face documentation](https://huggingface.co/docs).
|
60 |
-
|
61 |
-
|
62 |
-
This project processes scraped data related to NVIDIA GPUs using a Dockerized Python environment. It runs scripts to scrape data (`webscraped.py`) and generate a summary report (`summary.py`), outputting results like `nvidia_gpu_summary_report.csv`.
|
63 |
-
|
64 |
-
## Prerequisites
|
65 |
-
|
66 |
-
- [Docker](https://docs.docker.com/get-docker/) installed on your system.
|
67 |
-
- Basic familiarity with command-line tools.
|
68 |
|
69 |
-
|
70 |
|
71 |
-
|
72 |
|
73 |
-
|
|
|
|
|
74 |
|
75 |
-
|
76 |
|
|
|
77 |
```
|
78 |
nvidia_project/
|
79 |
├── Dockerfile
|
@@ -83,65 +33,71 @@ nvidia_project/
|
|
83 |
└── README.md
|
84 |
```
|
85 |
|
86 |
-
|
87 |
-
|
88 |
-
### 1. Build the Docker Image
|
89 |
-
|
90 |
-
Build the container image with all dependencies:
|
91 |
-
|
92 |
```bash
|
93 |
docker build -t nvidia_project .
|
94 |
```
|
95 |
|
96 |
-
### 2. Run
|
97 |
-
|
98 |
-
Launch the container to execute the scripts (`webscraped.py` followed by `summary.py`):
|
99 |
-
|
100 |
```bash
|
101 |
docker run --rm -it nvidia_project
|
102 |
```
|
|
|
|
|
103 |
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
### 3. Access the Output
|
108 |
-
|
109 |
-
Copy the generated report from the container to your local machine (adjust the path as needed):
|
110 |
-
|
111 |
```bash
|
112 |
-
docker cp $(docker ps -l -q):/app/nvidia_gpu_summary_report.csv /
|
113 |
```
|
114 |
-
|
115 |
Example:
|
116 |
-
|
117 |
```bash
|
118 |
docker cp $(docker ps -l -q):/app/nvidia_gpu_summary_report.csv /Users/niladridas/Desktop/nvidia_doc
|
119 |
```
|
120 |
|
121 |
-
##
|
|
|
122 |
|
123 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
124 |
|
125 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
126 |
```bash
|
127 |
docker run -it nvidia_project /bin/sh
|
128 |
```
|
129 |
-
|
130 |
```bash
|
131 |
ls -l /app
|
132 |
```
|
133 |
|
134 |
-
|
135 |
```bash
|
136 |
docker logs $(docker ps -l -q)
|
137 |
```
|
138 |
|
139 |
-
##
|
140 |
-
|
141 |
-
-
|
142 |
-
-
|
143 |
-
|
144 |
-
## Notes
|
145 |
-
|
146 |
-
- Ensure your `Dockerfile` is configured to copy `webscraped.py` and `summary.py` into `/app` and set the entrypoint to run them.
|
147 |
-
- Update the local path in the `docker cp` command to match your system.
|
|
|
9 |
datasets:
|
10 |
- nvidia-gpu-dataset
|
11 |
---
|
12 |
+
---
|
13 |
|
14 |
+
🚫 **Hands Off!** This dataset’s locked down—no downloading or messing with it unless you’re cleared. Regular Hugging Face users, this ain’t for you.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
|
16 |
+
# NVIDIA GPU Scraper
|
17 |
|
18 |
+
This project crunches NVIDIA GPU data in a slick Docker setup. It scrapes the web with `webscraped.py`, then whips up a tidy report with `summary.py`. Think CSV gold like `nvidia_gpu_summary_report.csv`.
|
19 |
|
20 |
+
## What You Need
|
21 |
+
- [Docker](https://docs.docker.com/get-docker/) on your machine.
|
22 |
+
- Basic command-line chops.
|
23 |
|
24 |
+
## Quick Start
|
25 |
|
26 |
+
### Project Layout
|
27 |
```
|
28 |
nvidia_project/
|
29 |
├── Dockerfile
|
|
|
33 |
└── README.md
|
34 |
```
|
35 |
|
36 |
+
### 1. Build It
|
37 |
+
Fire up the Docker image—all dependencies baked in, no virtualenv nonsense:
|
|
|
|
|
|
|
|
|
38 |
```bash
|
39 |
docker build -t nvidia_project .
|
40 |
```
|
41 |
|
42 |
+
### 2. Run It
|
43 |
+
Spin the container and let the scripts rip:
|
|
|
|
|
44 |
```bash
|
45 |
docker run --rm -it nvidia_project
|
46 |
```
|
47 |
+
- `--rm`: Cleans up after itself.
|
48 |
+
- `-it`: Keeps you in the loop with a terminal.
|
49 |
|
50 |
+
### 3. Grab the Goods
|
51 |
+
Snag the output CSV from the container:
|
|
|
|
|
|
|
|
|
|
|
52 |
```bash
|
53 |
+
docker cp $(docker ps -l -q):/app/nvidia_gpu_summary_report.csv /your/local/path
|
54 |
```
|
|
|
55 |
Example:
|
|
|
56 |
```bash
|
57 |
docker cp $(docker ps -l -q):/app/nvidia_gpu_summary_report.csv /Users/niladridas/Desktop/nvidia_doc
|
58 |
```
|
59 |
|
60 |
+
## Pushing to Hugging Face
|
61 |
+
Want it on Hugging Face? Here’s the drill:
|
62 |
|
63 |
+
1. **Get the Tools**:
|
64 |
+
```bash
|
65 |
+
pip install datasets
|
66 |
+
```
|
67 |
+
|
68 |
+
2. **Prep the Data**: Make sure it’s in JSON or CSV shape.
|
69 |
+
|
70 |
+
3. **Upload It**:
|
71 |
+
```bash
|
72 |
+
huggingface-cli dataset create --dataset_name bniladridas/nvidia-gpu-dataset --path /path/to/your/data
|
73 |
+
```
|
74 |
+
(Swap `bniladridas/nvidia-gpu-dataset` for your own dataset name if needed.)
|
75 |
+
|
76 |
+
4. **Spice It Up**: Add a dataset card with the juicy details.
|
77 |
|
78 |
+
5. **Check It**: Hit Hugging Face to confirm it’s live and legit.
|
79 |
+
|
80 |
+
More deets? Peek at the [Hugging Face docs](https://huggingface.co/docs).
|
81 |
+
|
82 |
+
## Debugging
|
83 |
+
Stuff breaking? Dive in:
|
84 |
+
|
85 |
+
- **Peek Inside**:
|
86 |
```bash
|
87 |
docker run -it nvidia_project /bin/sh
|
88 |
```
|
89 |
+
Scope out `/app` with:
|
90 |
```bash
|
91 |
ls -l /app
|
92 |
```
|
93 |
|
94 |
+
- **Read the Tea Leaves**:
|
95 |
```bash
|
96 |
docker logs $(docker ps -l -q)
|
97 |
```
|
98 |
|
99 |
+
## Pro Tips
|
100 |
+
- **Docker’s Your Friend**: No need to fuss with `source .venv/bin/activate`—it’s all contained.
|
101 |
+
- Keep it lean—let the container handle the heavy lifting.
|
102 |
+
- Double-check your `Dockerfile` copies `webscraped.py` and `summary.py` to `/app` and sets the entrypoint right.
|
103 |
+
- Tweak that `docker cp` path to wherever you want the CSV to land.
|
|
|
|
|
|
|
|