Upload folder using huggingface_hub
Browse files
README.md
CHANGED
@@ -13,13 +13,28 @@ This model is a custom implementation of **ResNetYoloV1** from the ```vision_mod
|
|
13 |
Please look in the config file for more information about the model architecture.
|
14 |
|
15 |
## **Usage**
|
16 |
-
To load the model, you can use the following code snippet:
|
17 |
|
18 |
```python
|
|
|
19 |
from vision_models_playground.utility.hub import load_vmp_model_from_hub
|
20 |
|
21 |
|
22 |
model = load_vmp_model_from_hub("Akriel/ResNetYoloV1")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
```
|
24 |
|
25 |
## **Metrics**
|
|
|
13 |
Please look in the config file for more information about the model architecture.
|
14 |
|
15 |
## **Usage**
|
16 |
+
To load the torch model, you can use the following code snippet:
|
17 |
|
18 |
```python
|
19 |
+
import torch
|
20 |
from vision_models_playground.utility.hub import load_vmp_model_from_hub
|
21 |
|
22 |
|
23 |
model = load_vmp_model_from_hub("Akriel/ResNetYoloV1")
|
24 |
+
|
25 |
+
x = torch.randn(...)
|
26 |
+
y = model(x) # y will be of type torch.Tensor
|
27 |
+
```
|
28 |
+
|
29 |
+
To load the pipeline that includes the model, you can use the following code snippet:
|
30 |
+
|
31 |
+
```python
|
32 |
+
from vision_models_playground.utility.hub import load_vmp_pipeline_from_hub
|
33 |
+
|
34 |
+
pipeline = load_vmp_pipeline_from_hub("Akriel/ResNetYoloV1")
|
35 |
+
|
36 |
+
x = raw_data # raw_data will be of type pipeline.input_type
|
37 |
+
y = pipeline(x) # y will be of type pipeline.output_type
|
38 |
```
|
39 |
|
40 |
## **Metrics**
|