Skip to content
Back to skills

Sliced Inference

ASecurity

"Guide SAHI standard and sliced prediction APIs, CLI commands,

  • 247 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 9, 2026
toolspythongobashapibackend

Works with

  • cli
  • api

Security analysis

A100/100

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

Scanned September 9, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill sliced-inference --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Sliced Inference?

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

Security grade badge for Sliced Inference
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-sliced-inference/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-sliced-inference)

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: sliced-inference
description: "Guide SAHI standard and sliced prediction APIs, CLI commands,
  slicing choices, batching, exports, progress callbacks, and video
  visualization."
disable-model-invocation: true
metadata:
  disco-role: operating
license: MIT
---

# sliced-inference

Use this sub-skill when the task is to build or debug SAHI prediction calls: `AutoDetectionModel`, `get_prediction`, `get_sliced_prediction`, high-level `predict`, `predict-fiftyone`, `sahi predict`, folder or video inference, slicing parameters, progress reporting, batching, and prediction export routing.

Do not use it as the owner for detector-specific installation or weights. Route those questions to `../model-integrations/SKILL.md`. Route COCO conversion/evaluation to `../dataset-tools/SKILL.md`, postprocess backend internals to `../postprocess-backends/SKILL.md`, and result object serialization details to `../annotations-and-results/SKILL.md`.

## Start here

1. Choose the API surface in [CLI and Python workflows](references/cli-and-python.md):
   - `get_prediction` for one standard full-image call.
   - `get_sliced_prediction` for one image with tiles and optional standard+slice aggregation.
   - `predict` / `sahi predict` for files, folders, videos, and automatic exports.
   - `predict-fiftyone` for interactive FiftyOne review when that optional dependency is installed.
2. Choose the inference mode:
   - Standard only: disable sliced prediction.
   - Sliced only: disable standard prediction.
   - Standard+sliced: default for sliced workflows; useful when small and large objects both matter.
3. Tune `slice_height`, `slice_width`, overlap, batching, progress, and duplicate handling with [Slicing parameters](references/slicing-parameters.md).
4. If behavior is wrong, use [Troubleshooting](references/troubleshooting.md) before changing model code.
5. To validate that base SAHI prediction plumbing works without model weights or downloads, run the bundled [synthetic smoke script](scripts/sliced_prediction_smoke.py).

## Safe local smoke

From this sub-skill directory, run:

```bash
python scripts/sliced_prediction_smoke.py --mode sliced --slice-size 128 --batch-size 2
```

The smoke script constructs a deterministic in-memory `DetectionModel` subclass, creates a synthetic image, exercises the selected prediction path, asserts expected result structure, and prints success. It does not download weights, contact a network service, train a model, or write outputs by default.

## Boundaries and assumptions

- A real detector still needs a supported `model_type`, installed optional backend packages, and accessible local weights or model objects; this sub-skill only shows how those model objects are used by prediction APIs.
- Optional detector frameworks were not assumed to be installed or runtime-verified here.
- COCO result JSON export is covered only as prediction-output routing. Dataset conversion, slicing, evaluation, and error analysis belong to `../dataset-tools/SKILL.md`.
- NMS/NMM/GreedyNMM parameter placement is covered here; algorithm details and backend acceleration belong to `../postprocess-backends/SKILL.md`.

Files in this skill

  • SKILL.md3.1 KB
  • references/cli-and-python.md10.4 KB
  • references/slicing-parameters.md8.6 KB
  • references/troubleshooting.md9.6 KB
  • scripts/sliced_prediction_smoke.py10.8 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.