A PyTorch implementation of the YOLOX object detection model based on the mmdetection implementation.
Project description
cjm-yolox-pytorch
Install
pip install cjm_yolox_pytorch
How to use
from cjm_yolox_pytorch.model import MODEL_TYPES, build_model
Select model type
model_type = MODEL_TYPES[0]
model_type
'yolox_tiny'
Build YOLOX model
import torch
yolox = build_model(model_type, 19)
test_inp = torch.randn(1, 3, 256, 256)
with torch.no_grad():
cls_scores, bbox_preds, objectness = yolox(test_inp)
print(f"cls_scores: {[cls_score.shape for cls_score in cls_scores]}")
print(f"bbox_preds: {[bbox_pred.shape for bbox_pred in bbox_preds]}")
print(f"objectness: {[objectness.shape for objectness in objectness]}")
cls_scores: [torch.Size([1, 19, 32, 32]), torch.Size([1, 19, 16, 16]), torch.Size([1, 19, 8, 8])]
bbox_preds: [torch.Size([1, 4, 32, 32]), torch.Size([1, 4, 16, 16]), torch.Size([1, 4, 8, 8])]
objectness: [torch.Size([1, 1, 32, 32]), torch.Size([1, 1, 16, 16]), torch.Size([1, 1, 8, 8])]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
cjm-yolox-pytorch-0.0.124.tar.gz
(21.9 kB
view hashes)
Built Distribution
Close
Hashes for cjm-yolox-pytorch-0.0.124.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a6262cc22bc1af641d7c231cc5939f13cb05799258ab0d2258b2a81779d7c129 |
|
MD5 | da6b2f1b8daeda0009b86785efc6db9f |
|
BLAKE2b-256 | 4a42fcd17bf580c640d9c34ae5f56b7cd4bb62ee6cf5dc474ce98c977d732e24 |
Close
Hashes for cjm_yolox_pytorch-0.0.124-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c26953b1d41036527b50a5d8848381302c5e5667acbd18c2dd131ae555e42218 |
|
MD5 | 50aafe621264a38aab12fbd8176921e1 |
|
BLAKE2b-256 | 9e08aeb2c6387249f6abae257027165b0830d5ca9fbe7fbf0982cf166894ce86 |