Skip to main content

Australian Wildlife Conservancy's Wildlife detection and species classification inference tools

Project description

AWC Helpers

Wildlife detection and species classification inference tools combining MegaDetector with custom species classifiers.

Installation

1. Install PyTorch

Windows (with CUDA GPU):

pip install torch==2.9.1 --index-url https://download.pytorch.org/whl/cu128

Linux / Mac / CPU:

pip install torch==2.9.1

2. Install AWC Helpers

From PyPI:

pip install awc-helpers

From GitHub:

pip install git+https://github.com/Australian-Wildlife-Conservancy-AWC/awc_inference.git

Usage

from awc_helpers import DetectAndClassify

# Initialize the pipeline
pipeline = DetectAndClassify(
    detector_path="path/to/megadetector.pt",
    classifier_path="path/to/species_classifier.pth",
    label_names=["species_a", "species_b", "species_c"],
    detection_threshold=0.1,
    clas_threshold=0.5,
)

# Run inference on image paths
results = pipeline.predict(
    inp=["image1.jpg", "image2.jpg"],
    clas_bs=4
)

# Results format: [(identifier, bbox, label, confidence), ...]
for result in results:
    print(result)

License

This project is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License (CC BY-NC-SA 4.0).

Non-commercial use only. Derivative works must use the same license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

awc_helpers-0.1.2.tar.gz (10.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

awc_helpers-0.1.2-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file awc_helpers-0.1.2.tar.gz.

File metadata

  • Download URL: awc_helpers-0.1.2.tar.gz
  • Upload date:
  • Size: 10.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for awc_helpers-0.1.2.tar.gz
Algorithm Hash digest
SHA256 99fe3ac28d7e614f14d0c297cfc99a501052bd0089d518759d50cfca69a79803
MD5 ea7c48b3219da7e6f499970f59e62510
BLAKE2b-256 c7f29e6c62a089245e4b3333449b7a271b97218d1fdac353ec5ee74b7cee8aa7

See more details on using hashes here.

File details

Details for the file awc_helpers-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: awc_helpers-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 10.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for awc_helpers-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a2c5300e4179133621e00ed9a09f819bcedba22ac2e8c3b650da9fcc32e96cc1
MD5 6c1c9809d439e254d36f2060d6ea8691
BLAKE2b-256 4249af83985ddcc82ebe6261bc666d3d942bbf5b085b1f4795012cb6a8500d7a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page