# cjm-yolox-pytorch
<!-- WARNING: THIS FILE WAS AUTOGENERATED! DO NOT EDIT! -->
## Install
``` sh
pip install cjm_yolox_pytorch
```
## How to use
``` python
import torch
from cjm_yolox_pytorch.model import MODEL_TYPES, build_model
```
**Select model type**
``` python
model_type = MODEL_TYPES[0]
model_type
```
'yolox_tiny'
**Build YOLOX model**
``` python
yolox = build_model(model_type, 19, pretrained=True)
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]}")
```
The file ./pretrained_checkpoints/yolox_tiny.pth already exists and overwrite is set to False.
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])]
Raw data
{
"_id": null,
"home_page": "https://github.com/cj-mills/cjm-yolox-pytorch",
"name": "cjm-yolox-pytorch",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": "",
"keywords": "nbdev jupyter notebook python torch",
"author": "cj-mills",
"author_email": "millscj.mills2@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/5d/f2/1b34e4cf859f43b60767bf75f8350f782c51c793a2c5b5f859a46b3885fa/cjm-yolox-pytorch-0.0.147.tar.gz",
"platform": null,
"description": "# cjm-yolox-pytorch\n\n<!-- WARNING: THIS FILE WAS AUTOGENERATED! DO NOT EDIT! -->\n\n## Install\n\n``` sh\npip install cjm_yolox_pytorch\n```\n\n## How to use\n\n``` python\nimport torch\nfrom cjm_yolox_pytorch.model import MODEL_TYPES, build_model\n```\n\n**Select model type**\n\n``` python\nmodel_type = MODEL_TYPES[0]\nmodel_type\n```\n\n 'yolox_tiny'\n\n**Build YOLOX model**\n\n``` python\nyolox = build_model(model_type, 19, pretrained=True)\n\ntest_inp = torch.randn(1, 3, 256, 256)\n\nwith torch.no_grad():\n cls_scores, bbox_preds, objectness = yolox(test_inp)\n \nprint(f\"cls_scores: {[cls_score.shape for cls_score in cls_scores]}\")\nprint(f\"bbox_preds: {[bbox_pred.shape for bbox_pred in bbox_preds]}\")\nprint(f\"objectness: {[objectness.shape for objectness in objectness]}\")\n```\n\n The file ./pretrained_checkpoints/yolox_tiny.pth already exists and overwrite is set to False.\n cls_scores: [torch.Size([1, 19, 32, 32]), torch.Size([1, 19, 16, 16]), torch.Size([1, 19, 8, 8])]\n bbox_preds: [torch.Size([1, 4, 32, 32]), torch.Size([1, 4, 16, 16]), torch.Size([1, 4, 8, 8])]\n objectness: [torch.Size([1, 1, 32, 32]), torch.Size([1, 1, 16, 16]), torch.Size([1, 1, 8, 8])]\n",
"bugtrack_url": null,
"license": "Apache Software License 2.0",
"summary": "A PyTorch implementation of the YOLOX object detection model based on the mmdetection implementation.",
"version": "0.0.147",
"project_urls": {
"Homepage": "https://github.com/cj-mills/cjm-yolox-pytorch"
},
"split_keywords": [
"nbdev",
"jupyter",
"notebook",
"python",
"torch"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "998d2116d2bd24ccac4bb0bab8b021cf5f6464f8e43da8aa59922d9dae500fde",
"md5": "449f92df6b4bf68c7dd5b81dc8629270",
"sha256": "4221b1a2f7c5f5c34e1eabcd0922e0d95e21175cfb29239663c80a42130968a4"
},
"downloads": -1,
"filename": "cjm_yolox_pytorch-0.0.147-py3-none-any.whl",
"has_sig": false,
"md5_digest": "449f92df6b4bf68c7dd5b81dc8629270",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 24765,
"upload_time": "2023-08-11T18:08:36",
"upload_time_iso_8601": "2023-08-11T18:08:36.736083Z",
"url": "https://files.pythonhosted.org/packages/99/8d/2116d2bd24ccac4bb0bab8b021cf5f6464f8e43da8aa59922d9dae500fde/cjm_yolox_pytorch-0.0.147-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "5df21b34e4cf859f43b60767bf75f8350f782c51c793a2c5b5f859a46b3885fa",
"md5": "03acdb8c5d3c4074aac2854daaf4966a",
"sha256": "9453a2d9208761ed0c26c8ddfab7b651c58278134eccef04efa90d6bcfe5ce1b"
},
"downloads": -1,
"filename": "cjm-yolox-pytorch-0.0.147.tar.gz",
"has_sig": false,
"md5_digest": "03acdb8c5d3c4074aac2854daaf4966a",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 23582,
"upload_time": "2023-08-11T18:08:38",
"upload_time_iso_8601": "2023-08-11T18:08:38.442771Z",
"url": "https://files.pythonhosted.org/packages/5d/f2/1b34e4cf859f43b60767bf75f8350f782c51c793a2c5b5f859a46b3885fa/cjm-yolox-pytorch-0.0.147.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-08-11 18:08:38",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "cj-mills",
"github_project": "cjm-yolox-pytorch",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "cjm-yolox-pytorch"
}