Skip to content
Back to skills

Image Ai

ASecurity

"Use ImageAI 3.x PyTorch computer-vision workflows for

  • 247 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 8, 2026
datapythonbashapibackend

Works with

  • api

Security analysis

A96/100
  • mediumInstalls packages at runtime which could introduce malicious dependencies

Pro scans all 20 files and shows the line behind each finding

Scanned September 8, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill image-ai --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Image Ai?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Image Ai
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-image-ai/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-image-ai)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: image-ai
description: "Use ImageAI 3.x PyTorch computer-vision workflows for
  classification, object detection, video detection, and custom training."
disable-model-invocation: true
metadata:
  disco-role: operating
license: MIT
---

# ImageAI Repo Skill

Use this repo skill when a task involves the ImageAI Python package (`imageai`), especially ImageAI 3.x PyTorch workflows for simple computer-vision applications.

## Start here

1. Confirm the user is using ImageAI 3.x / PyTorch assets (`.pt` or `.pth`). TensorFlow/Keras `.h5` models are legacy ImageAI 2.x artifacts and are not accepted by the current package path.
2. Confirm local model weights, images/videos, datasets, and JSON config files exist. This skill does not bundle pretrained weights or download assets.
3. Choose the closest sub-skill route below.
4. For environment uncertainty, run the bundled smoke checker before loading large weights:

```bash
python scripts/check_imageai_env.py
python scripts/check_imageai_env.py --require-cuda
```

## Route by task

| User task | Read |
| --- | --- |
| Classify a still image with ImageNet weights | [classification-workflows](sub-skills/classification-workflows/SKILL.md) |
| Run custom image classification from a trained `.pt`/`.pth` model and classes JSON | [classification-workflows](sub-skills/classification-workflows/SKILL.md) |
| Detect COCO objects in a still image with RetinaNet, YOLOv3, or TinyYOLOv3 | [object-detection-workflows](sub-skills/object-detection-workflows/SKILL.md) |
| Run custom YOLO/TinyYOLO still-image detection from a trained model and detection JSON | [object-detection-workflows](sub-skills/object-detection-workflows/SKILL.md) |
| Detect objects in videos, camera feeds, or live streams | [video-detection-workflows](sub-skills/video-detection-workflows/SKILL.md) |
| Add per-frame, per-second, per-minute, or whole-video analysis callbacks | [video-detection-workflows](sub-skills/video-detection-workflows/SKILL.md) |
| Prepare datasets, convert Pascal VOC to YOLO, validate layouts, or start custom training | [custom-training-and-data](sub-skills/custom-training-and-data/SKILL.md) |
| Resolve install, backend, or model-asset confusion | [installation and model assets](references/installation-and-model-assets.md) and [troubleshooting](references/troubleshooting.md) |

## Package and install essentials

ImageAI 3.x uses PyTorch. A typical CPU-oriented setup follows the package docs and requirements:

```bash
pip install imageai
pip install cython "pillow>=7.0.0" "numpy>=1.18.1" "opencv-python>=4.1.2" \
  "torch>=1.9.0" "torchvision>=0.10.0" tqdm scipy matplotlib mock
```

Use a PyTorch CUDA wheel only when the runtime has compatible NVIDIA drivers and the task needs acceleration. CUDA is helpful for video and real training, but CPU is enough for import/API checks and small validation helpers. See [installation and model assets](references/installation-and-model-assets.md) for dependency variants, model-weight expectations, and legacy TensorFlow notes.

## Minimal import/API check

```python
from imageai.Classification import ImageClassification
from imageai.Detection import ObjectDetection, VideoObjectDetection
from imageai.Classification.Custom import ClassificationModelTrainer, CustomImageClassification
from imageai.Detection.Custom import DetectionModelTrainer, CustomObjectDetection, CustomVideoObjectDetection

for cls in [
    ImageClassification, ObjectDetection, VideoObjectDetection,
    ClassificationModelTrainer, CustomImageClassification,
    DetectionModelTrainer, CustomObjectDetection, CustomVideoObjectDetection,
]:
    cls()
```

If this fails, do not proceed to weight loading. Use the root troubleshooting reference first.

## Shared operating rules

- Always choose the model-type setter that matches the weight architecture. Filenames are hints, not proof.
- Current ImageAI 3.x model files must be `.pt` or `.pth`; `.h5` triggers a TensorFlow-legacy error.
- Call `useCPU()` before `loadModel()` when forcing CPU.
- Load large weights once and reuse the detector/classifier object for repeated images or frames.
- Treat pretrained weights, custom models, JSON mappings, datasets, videos, and camera streams as caller-supplied assets.
- Do not run full video detection or training as a quick smoke test unless the user supplies bounded assets and compute expectations.

## Provenance and routing metadata

- [repo-provenance.md](references/repo-provenance.md) records the source snapshot and evidence paths used to create this skill.
- [repo-routing-metadata.json](references/repo-routing-metadata.json) records managed repo-skills-router placement for import tooling.

Files in this skill

  • SKILL.md4.6 KB
  • references/installation-and-model-assets.md4.6 KB
  • references/repo-provenance.md2.1 KB
  • references/repo-routing-metadata.json415 B
  • references/troubleshooting.md4.9 KB
  • scripts/check_imageai_env.py5 KB
  • sub-skills/classification-workflows/SKILL.md3.3 KB
  • sub-skills/classification-workflows/references/api-reference.md9.6 KB
  • sub-skills/classification-workflows/references/troubleshooting.md7.1 KB
  • sub-skills/classification-workflows/references/workflows.md7.7 KB
  • sub-skills/classification-workflows/scripts/classify_image.py9.6 KB
  • sub-skills/custom-training-and-data/SKILL.md3.8 KB
  • sub-skills/custom-training-and-data/references/data-formats.md4.8 KB
  • sub-skills/custom-training-and-data/references/training-workflows.md8 KB
  • sub-skills/custom-training-and-data/references/troubleshooting.md8.2 KB
  • sub-skills/custom-training-and-data/scripts/pascal_voc_to_yolo.py13.7 KB
  • sub-skills/custom-training-and-data/scripts/validate_imageai_dataset.py13.2 KB
  • sub-skills/object-detection-workflows/SKILL.md3.3 KB
  • sub-skills/object-detection-workflows/references/api-reference.md7.9 KB
  • sub-skills/object-detection-workflows/references/coco-object-classes.md3.6 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.