Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
@@ -37,19 +37,7 @@ pip install -e .
|
|
37 |
```
|
38 |
|
39 |
```python
|
40 |
-
|
41 |
-
from bigcode_eval.evaluator import Evaluator
|
42 |
|
43 |
-
|
44 |
-
task="text-generation",
|
45 |
-
model="d-matrix/CodeLlama-7b",
|
46 |
-
trust_remote_code=True,
|
47 |
-
)
|
48 |
-
|
49 |
-
# Transform the model with DMX
|
50 |
-
model = DmxModel.from_torch(pipe.model).to_basic_model() # Using BASIC configuration
|
51 |
-
|
52 |
-
evaluator = Evaluator(accelerator, model)
|
53 |
-
|
54 |
-
eval_results = evaluator.evaluate(task) # Assign desired task, i.e. "humaneval"
|
55 |
```
|
|
|
37 |
```
|
38 |
|
39 |
```python
|
40 |
+
# code_eval.py included in HF repofrom code_eval import evaluate_model
|
|
|
41 |
|
42 |
+
eval_results = evaluate_model("d-matrix/CodeLlama-7b", dmx_config="BASIC") # For BASIC configuration
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
43 |
```
|