{"categories":[{"label":"Software Development","url":"https://skillfed.io/packages/category/software-development/2"},{"label":"Scientific/Engineering","url":"https://skillfed.io/packages/category/scientific-engineering"},{"label":"Artificial Intelligence","url":"https://skillfed.io/packages/category/scientific-engineering-artificial-intelligence/2"},{"label":"Image Recognition","url":"https://skillfed.io/packages/category/scientific-engineering-image-recognition"}],"enrichment":{"capability":"Profiles PyTorch models by counting Multiply-Accumulate Operations (MACs) and parameters in a single forward pass, with built-in rules for common layer types and support for custom counting rules.","skillfed_tags":["model-profiling","pytorch-tools","performance-analysis"],"use_cases":["Compare computational complexity of different neural network architectures before training to choose the most efficient design.","Estimate deployment requirements by profiling model MACs and parameters to predict inference latency and memory usage.","Analyze custom or third-party layer implementations by registering custom counting rules to understand their computational cost.","Profile models with variable input sizes using the stride parameter to estimate MACs across different spatial dimensions.","Convert raw operation counts into human-readable format using clever_format for reporting and documentation."],"what_it_does":"THOP is a PyTorch operation counter that measures model complexity by counting Multiply-Accumulate Operations and parameters. It runs a single forward pass through your model with example inputs and returns MAC and parameter counts, making it useful for comparing architecture efficiency before training or deployment. The package includes built-in counting rules for common layer types (convolutional, normalization, pooling, activation, linear, recurrent) and allows you to define custom counting rules for unsupported modules via forward hooks.\n\nThe package is lightweight and maintained by Ultralytics, with support for modern Python versions (3.8 through 3.14) across Linux, macOS, and Windows. It depends only on numpy and torch, keeping installation friction minimal. For image models, you can pass a stride parameter to estimate MACs from smaller stride-aligned profiles, or omit it for exact single-pass profiling. A helper function (clever_format) converts raw counts into human-readable notation.","worth_installing":"Yes. THOP is actively maintained, has no known vulnerabilities, installs with minimal friction (two common dependencies), and solves a concrete problem in model development. The AGPL-3.0 license is a consideration only if you plan to distribute proprietary modifications; for research, internal tools, or open-source projects, it poses no barrier. Install it if you need to profile PyTorch model efficiency."},"id":"ultralytics-thop","links":{"html":"https://skillfed.io/packages/ultralytics-thop","md":"https://skillfed.io/packages/ultralytics-thop.md","pypi":"https://pypi.org/project/ultralytics-thop/"},"maintenance":{"status":"active"},"meta":{"latest_release":"2026-07-30","license_spdx":null,"license_treatment":"agpl","name":"ultralytics-thop","python_support":"supports_current","summary":"Ultralytics THOP package for fast computation of PyTorch model FLOPs and parameters."},"popularity":{"monthly_downloads":6458146,"position":1907,"tier":"top_5000"},"security":{"n_vulnerabilities":0},"version":"2.1.6"}
