$npx skillfedfor your agent

sbi4onnx

A very simple script that only initializes the batch size of ONNX. Simple Batchsize Initialization for ONNX.

With conditionsPyPI Artificial IntelligenceReleased May 202482.7K downloads / moMIT LicensePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — sbi4onnx-1.0.7-py3-none-any.whl
v1.0.7 · released 2024-05-28 · Python >=3.6

Yes, if you need to modify ONNX batch dimensions and your models have straightforward graph structures. The tool is lightweight, dependency-free at runtime, and MIT-licensed. However, maintenance is dormant (last update 808 days ago), so expect no active bug fixes or feature development. Test thoroughly on your specific models first, as the tool explicitly does not handle complex Reshape or Gemm patterns—if your model fails, you may need to preprocess it with other tools or edit the ONNX file manually.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires onnx and onnx-graphsurgeon to be installed separately; tool may fail on models with complex Reshape operations or multiple undefined dimensions.
  • Low friction: pure Python wheel with no runtime dependencies.
  • Maintenance is dormant—last release was 808 days ago, though the repository remains active with recent commits as of 2024-05-28.

License · maintenance · safety

MIT License (permissive) — MIT License permits commercial and private use with minimal restrictions, making it safe to adopt in most projects.

last release 2024-05-28 (808 days) · last repo commit 2024-05-28 · 7 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 82,716 downloads/mo, #14,140 on PyPI

Verify before relying

pip install sbi4onnx

from sbi4onnx import initialize

onnx_graph = initialize(
  input_onnx_file_path="model.onnx",
  output_onnx_file_path="model_Nx224x224.onnx",
  initialization_character_string="N"
)
  • Whether the tool successfully handles all common ONNX model architectures or primarily works with simpler graph structures.
  • Performance impact of running onnxsim simplification on large models during batch size initialization.
  • Compatibility with recent ONNX opset versions beyond what the fact sheet indicates.
Same gist for agents: .md · .json

What it is and what it does

sbi4onnx is a lightweight command-line and Python tool for modifying ONNX neural network models to change their batch size dimension. It reads an ONNX file, replaces the batch dimension (typically the first dimension) with a string you specify—such as 'N' for a named dynamic dimension, '-1' for a wildcard, or any custom identifier—and writes the modified model to disk. The tool optionally runs ONNX simplification on the result to clean up redundant operations.

The package is designed for a narrow, specific task: preparing pre-trained models for inference frameworks that require explicit batch size handling. It is not a general ONNX manipulation library. The documentation warns that it may fail on models with complex internal structures, particularly those containing Reshape operations that already have undefined dimensions or Gemm layers with non-unit batch outputs. For such cases, the author recommends pre-processing with a companion tool (sam4onnx) to fix problematic dimensions first.

Use it for

  • Convert a fixed-batch ONNX model (e.g., batch size 1) to accept variable batch sizes for deployment.
  • Prepare ONNX models for TensorRT or other inference engines that require explicit batch dimension naming.
  • Batch-process multiple ONNX files to standardize their batch dimension representation before model serving.
  • Replace hardcoded batch dimensions with symbolic names for dynamic batching in production inference pipelines.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you need to modify ONNX batch dimensions and your models have straightforward graph structures.

The tool is lightweight, dependency-free at runtime, and MIT-licensed. However, maintenance is dormant (last update 808 days ago), so expect no active bug fixes or feature development. Test thoroughly on your specific models first, as the tool explicitly does not handle complex Reshape or Gemm patterns—if your model fails, you may need to preprocess it with other tools or edit the ONNX file manually.

Install

sbi4onnx on PyPI

Before you install

Low friction: pure Python wheel with no runtime dependencies. Maintenance is dormant—last release was 808 days ago, though the repository remains active with recent commits as of 2024-05-28.

Requires onnx and onnx-graphsurgeon to be installed separately; tool may fail on models with complex Reshape operations or multiple undefined dimensions.

License in practice

MIT License permits commercial and private use with minimal restrictions, making it safe to adopt in most projects.

Quickstart

pip install sbi4onnx

from sbi4onnx import initialize

onnx_graph = initialize(
  input_onnx_file_path="model.onnx",
  output_onnx_file_path="model_Nx224x224.onnx",
  initialization_character_string="N"
)

Verify before relying

  • Whether the tool successfully handles all common ONNX model architectures or primarily works with simpler graph structures.
  • Performance impact of running onnxsim simplification on large models during batch size initialization.
  • Compatibility with recent ONNX opset versions beyond what the fact sheet indicates.

Package facts

LicenseMIT License permissive
Python supportSupports the current Python release >=3.6
Install frictionLow. Pure-Python wheel
Runtime dependenciesNone
MaintenanceDormant 808 days since the last release
Last repo commit
First released
Downloads82,716 / month, #14,140 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14

Evidence: sbi4onnx-1.0.7-py3-none-any.whl

Tags

Capabilities
onnx batch size initializationmodify onnx model batch dimensiononnx dynamic batch sizeonnx model preprocessingbatch size converter onnxonnx graph modificationvariable batch onnx
Topics
onnx-toolsmodel-optimization

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “onnx batch size initialization”

  • sbi4onnxModifies ONNX model files to initialize or replace their batch size…
  • simple-onnx-processing-toolsA collection of command-line tools for transforming ONNX models:…
  • sio4onnxModifies the input and output shapes of ONNX model files, allowing…

Give your agent the search over MCP, or paste the wish link into any chat.

More Artificial Intelligence packages

litellm With conditions
PyPI · Artificial Intelligence · released Aug 2026

LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.

Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.

MITcompiled wheel
682.8Mdownloads / mo
huggingface-hub Worth it
PyPI · Artificial Intelligence · released Aug 2026

Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.

Install it if you work with Hugging Face Hub models or datasets.

Apache-2.0pure Python · 3.10.0+
442.4Mdownloads / mo
langchain Worth it
PyPI · Python Modules · released Aug 2026

LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.

MITpure Python
315.4Mdownloads / mo
hf-xet With conditions
PyPI · Artificial Intelligence · released Aug 2026

hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.

Apache-2.0compiled wheel · 3.8+
258.4Mdownloads / mo
tokenizers Worth it
PyPI · Artificial Intelligence · released Apr 2026

Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.

Apache-2.0compiled wheel · 3.10+
222.9Mdownloads / mo
transformers Worth it
PyPI · Artificial Intelligence · released Aug 2026

Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.

Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.

permissive licensepure Python · 3.10.0+
186.6Mdownloads / mo

See also soc4onnx · scc4onnx · sio4onnx · ssi4onnx · sng4onnx · sor4onnx · svs4onnx · sde4onnx · simple-onnx-processing-tools · lamindb_setup