Add rtmdet-tiny RTMW/RTMDet HF port
Browse files- README.md +3 -6
- config.json +1 -1
README.md
CHANGED
|
@@ -26,15 +26,12 @@ RTMDet is a family of real-time object detectors based on the CSPNeXt architectu
|
|
| 26 |
## Usage
|
| 27 |
|
| 28 |
```python
|
| 29 |
-
from transformers import AutoImageProcessor
|
| 30 |
from PIL import Image
|
| 31 |
import torch
|
| 32 |
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
config = RTMDetConfig.from_pretrained("akore/rtmdet-tiny", trust_remote_code=True)
|
| 37 |
-
model = RTMDetModel.from_pretrained("akore/rtmdet-tiny", trust_remote_code=True)
|
| 38 |
model.eval()
|
| 39 |
|
| 40 |
processor = AutoImageProcessor.from_pretrained("akore/rtmdet-tiny")
|
|
|
|
| 26 |
## Usage
|
| 27 |
|
| 28 |
```python
|
| 29 |
+
from transformers import AutoConfig, AutoModel, AutoImageProcessor
|
| 30 |
from PIL import Image
|
| 31 |
import torch
|
| 32 |
|
| 33 |
+
config = AutoConfig.from_pretrained("akore/rtmdet-tiny", trust_remote_code=True)
|
| 34 |
+
model = AutoModel.from_pretrained("akore/rtmdet-tiny", trust_remote_code=True)
|
|
|
|
|
|
|
|
|
|
| 35 |
model.eval()
|
| 36 |
|
| 37 |
processor = AutoImageProcessor.from_pretrained("akore/rtmdet-tiny")
|
config.json
CHANGED
|
@@ -36,6 +36,6 @@
|
|
| 36 |
"transformers_version": "5.2.0",
|
| 37 |
"auto_map": {
|
| 38 |
"AutoConfig": "configuration_rtmdet.RTMDetConfig",
|
| 39 |
-
"
|
| 40 |
}
|
| 41 |
}
|
|
|
|
| 36 |
"transformers_version": "5.2.0",
|
| 37 |
"auto_map": {
|
| 38 |
"AutoConfig": "configuration_rtmdet.RTMDetConfig",
|
| 39 |
+
"AutoModel": "modeling_rtmdet.RTMDetModel"
|
| 40 |
}
|
| 41 |
}
|