- Home
- Skills
- Research & Analysis
- Image Sizes — Paste Width and Height, Get Ratio and Crop
Image Sizes — Paste Width and Height, Get Ratio and Crop
Paste one image per row with name, width and height; get the reduced aspect ratio, width ÷ height, shortfalls against your own minimums, and crop dimensions for a target ratio.
$5
Works with the AI Agents you already use
Image Sizes — Paste Width and Height, Get Ratio and Crop
Example session with this skill installed
python3 scripts/image_sizes.py examples/images.csv
- Read your context and instructions
- Compiled the image sizes
Image Sizes
Formula: reduced ratio = width/gcd : height/gcd; ratio = width ÷ height.
Shortfall = max(0, minimum − actual). Crop fits the target inside the source; integer division floors.
row | name | size | ratio | width/height | shortfall W×H | crop | status / note
1 | Hero banner | 1600×900 | 16:9 | 1.7778 | 400×100 | 1200×900 | ok
2 | Square icon | 1200×1200 | 1:1 | 1.0000 | 0×0 | 1200×1200 | ok
Unreadable dimension rows: 0
Connects securely to your tools. The creator never sees your data.
About this skill
Paste one image per row with a name, width, and height, and get a reduced aspect ratio, width ÷ height, optional shortfalls against your own minimum width and height, and crop dimensions for an optional target ratio. Minimum dimensions are supplied by you; this tool does not store marketplace requirements or judge image quality.
Input
CSV or TSV, one image per row, first row a header. Required columns: name, width, height. Optional columns: minimum_width, minimum_height, target_ratio (such as 4:3). Pixel counts accept correctly grouped thousands such as 1,200. Decimals, units such as px, combined entries such as 1200x800, and negative values are not interpreted; an unreadable width or height marks that row unreadable and is never replaced with zero. Input must be UTF-8 or UTF-16, at most 100,000 bytes and 2,000 data rows.
What you get
- Reduced ratio = width ÷ gcd : height ÷ gcd.
- Width ÷ height, shown to four places (half-up rounding).
- Shortfall = max(0, minimum − actual) for width and height; missing minimums show --.
- The largest crop of the target ratio that fits inside the image; the cropped side rounds down.
- Output as text, markdown, JSON, or CSV.
Run it
python3 scripts/image_sizes.py examples/images.csv (also --format markdown, json, csv). Requires Python 3.9+ and the standard library only. Tests: python3 -m unittest discover tests.
The tool calculates measurements only; it does not assess image quality, recommend a crop, or suggest how to photograph an image.
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Research & Analysis.
Minimum dimensions are supplied by you; no marketplace requirements are built in. Calculates measurements only; does not assess image quality or recommend a crop. Input limited to 100,000 bytes and 2,000 data rows; UTF-8 or UTF-16; decimals, units such as px, and combined entries such as 1200x800 are not interpreted.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 8 days ago
- Software
Python 3.9+