dpi-upscaler-checker
Check image DPI and intelligently upscale low-resolution images using super-resolution
Best use case
dpi-upscaler-checker is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Check image DPI and intelligently upscale low-resolution images using super-resolution
Teams using dpi-upscaler-checker should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/dpi-upscaler-checker/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How dpi-upscaler-checker Compares
| Feature / Agent | dpi-upscaler-checker | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Check image DPI and intelligently upscale low-resolution images using super-resolution
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Marketing
Discover AI agents for marketing workflows, from SEO and content production to campaign research, outreach, and analytics.
AI Agents for Startups
Explore AI agent skills for startup validation, product research, growth experiments, documentation, and fast execution with small teams.
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
SKILL.md Source
# DPI Upscaler & Checker
Check if images meet 300 DPI printing standards, and intelligently restore blurry low-resolution images using AI super-resolution technology.
## Features
- **DPI Detection**: Read and verify image DPI information
- **Intelligent Analysis**: Calculate actual print size and pixel density
- **Super-Resolution Restoration**: Use Real-ESRGAN algorithm to enhance image clarity
- **Batch Processing**: Support single image and batch folder processing
- **Format Support**: JPG, PNG, TIFF, BMP, WebP
## Use Cases
- Academic paper figure DPI checking
- Print image quality pre-inspection
- Low-resolution material restoration
- Document scan enhancement
## Usage
### Check Single Image DPI
```bash
python scripts/main.py check --input image.jpg
```
### Batch Check Folder
```bash
python scripts/main.py check --input ./images/ --output report.json
```
### Super-Resolution Restoration
```bash
python scripts/main.py upscale --input image.jpg --output upscaled.jpg --scale 4
```
### Batch Fix Low DPI Images
```bash
python scripts/main.py upscale --input ./images/ --output ./output/ --min-dpi 300 --scale 2
```
## Parameters
### Check Command
| Parameter | Type | Default | Required | Description |
|-----------|------|---------|----------|-------------|
| `--input` | string | - | Yes | Input image path or folder |
| `--output` | string | stdout | No | Output report path |
| `--target-dpi` | int | 300 | No | Target DPI threshold |
### Upscale Command
| Parameter | Type | Default | Required | Description |
|-----------|------|---------|----------|-------------|
| `--input` | string | - | Yes | Input image path or folder |
| `--output` | string | - | Yes | Output path |
| `--scale` | int | 2 | No | Scale factor (2/3/4) |
| `--min-dpi` | int | - | No | Only process images below this DPI |
| `--denoise` | int | 0 | No | Denoise level (0-3) |
| `--face-enhance` | flag | false | No | Enable face enhancement |
## Output Description
### DPI Check Report
```json
{
"file": "image.jpg",
"dpi": [72, 72],
"width_px": 1920,
"height_px": 1080,
"print_width_cm": 67.7,
"print_height_cm": 38.1,
"meets_300dpi": false,
"recommended_scale": 4.17
}
```
### Restored Image
- Automatically saved as `<original_filename>_upscaled.<extension>`
- Preserves original EXIF information
- Sets DPI to 300
## Dependencies
- Python >= 3.8
- Pillow >= 9.0.0
- opencv-python >= 4.5.0
- numpy >= 1.21.0
- realesrgan (optional, for best results)
## Algorithm Description
### DPI Calculation
```
Actual DPI = Pixel dimensions / Physical dimensions
Print size (cm) = Pixel count / DPI * 2.54
```
### Super-Resolution
- Default use of Real-ESRGAN model
- Support lightweight bicubic interpolation fallback
- Intelligent model selection (general/anime/face)
## Notes
1. Input image DPI information may be inaccurate; actual pixel calculation shall prevail
2. Super-resolution cannot create non-existent information; extremely blurry images have limited improvement
3. Large file processing requires more memory
4. GPU acceleration requires CUDA environment (optional)
## Risk Assessment
| Risk Indicator | Assessment | Level |
|----------------|------------|-------|
| Code Execution | Python/R scripts executed locally | Medium |
| Network Access | No external API calls | Low |
| File System Access | Read input files, write output files | Medium |
| Instruction Tampering | Standard prompt guidelines | Low |
| Data Exposure | Output files saved to workspace | Low |
## Security Checklist
- [ ] No hardcoded credentials or API keys
- [ ] No unauthorized file system access (../)
- [ ] Output does not expose sensitive information
- [ ] Prompt injection protections in place
- [ ] Input file paths validated (no ../ traversal)
- [ ] Output directory restricted to workspace
- [ ] Script execution in sandboxed environment
- [ ] Error messages sanitized (no stack traces exposed)
- [ ] Dependencies audited
## Prerequisites
```bash
# Python dependencies
pip install -r requirements.txt
```
## Evaluation Criteria
### Success Metrics
- [ ] Successfully executes main functionality
- [ ] Output meets quality standards
- [ ] Handles edge cases gracefully
- [ ] Performance is acceptable
### Test Cases
1. **Basic Functionality**: Standard input → Expected output
2. **Edge Case**: Invalid input → Graceful error handling
3. **Performance**: Large dataset → Acceptable processing time
## Lifecycle Status
- **Current Stage**: Draft
- **Next Review Date**: 2026-03-06
- **Known Issues**: None
- **Planned Improvements**:
- Performance optimization
- Additional feature supportRelated Skills
time-checker
Check accurate current time, date, and timezone information for any location worldwide using time.is. Use when the user asks "what time is it in X", "current time in Y", or needs to verify timezone offsets.
hna-666-flight-checker
查询海南航空 666Plus 权益可往返航班,自动遍历指定目的地
SKILL: stock-checker
## Description
minimax-plan-checker
获取 MiniMax 平台的套餐信息,包括套餐名称、额度、当前使用情况。当用户询问 MiniMax 套餐、额度使用情况、API 调用量、计费信息时使用此技能。
vibe-coding-checker
描述一个功能或项目,AI 快速评估用 Cursor/Windsurf/Bolt 等 AI 编程工具能否独立实现, 给出可行性判断、推荐工具、拆解路径和风险提示。
gold-price-checker
国内金价查询工具。用于查询黄金实时价格、银行金条价格、金店零售价、国际金价和黄金未来趋势分析。当用户询问金价、黄金价格、今日金价、金店价格、银行金条、国际金价、伦敦金、黄金走势或未来趋势时触发此技能。
weather-checker
Get current weather information for any city
hollow-validation-checker
Helps detect hollow validation in AI agent skills — identifies fake tests that always pass without actually verifying behavior, like validation commands that just run echo 'ok' or console.log('passed').
grammar-checker-ama
Grammar checking tool for AMA style medical writing
figure-reference-checker
Check figure references in manuscripts
drug-interaction-checker
Check for drug-drug interactions between multiple medications. Trigger when user asks about medication compatibility, "can I take X with Y", drug interactions, contraindications, or safety of combining pharmaceuticals.
conflict-of-interest-checker
Check for co-authorship conflicts between authors and suggested reviewers