Fixed minor typo and added multi GPU case
Browse filesVery nice implementation. You had a little typo in transformers"y" and I added the special case of using multiple GPUs and getting the specified error.
README.md
CHANGED
@@ -46,7 +46,7 @@ The following example demonstrates how to use the fine-tuned model for question
|
|
46 |
For now, you have to install a specific `transformers` fork, until the official PR will be merged.
|
47 |
|
48 |
```bash
|
49 |
-
> pip uninstall
|
50 |
> git clone https://github.com/bakrianoo/transformers.git
|
51 |
> cd transformers && git checkout feat-ModernBert-QnA-Support && pip install -e .
|
52 |
```
|
@@ -186,6 +186,12 @@ python run_qa.py \
|
|
186 |
--output_dir="/path/to/output/directory"
|
187 |
```
|
188 |
|
|
|
|
|
|
|
|
|
|
|
|
|
189 |
---
|
190 |
|
191 |
## Results 馃搳
|
|
|
46 |
For now, you have to install a specific `transformers` fork, until the official PR will be merged.
|
47 |
|
48 |
```bash
|
49 |
+
> pip uninstall transformers -y
|
50 |
> git clone https://github.com/bakrianoo/transformers.git
|
51 |
> cd transformers && git checkout feat-ModernBert-QnA-Support && pip install -e .
|
52 |
```
|
|
|
186 |
--output_dir="/path/to/output/directory"
|
187 |
```
|
188 |
|
189 |
+
If you have multiple GPUs and getting the error: `RuntimeError: Detected that you are using FX to symbolically trace a dynamo-optimized function` try this:
|
190 |
+
```bash
|
191 |
+
accelerate launch run_qa.py \
|
192 |
+
...other parameters
|
193 |
+
```
|
194 |
+
|
195 |
---
|
196 |
|
197 |
## Results 馃搳
|