Skip to main content

Next-generation Open Source toolkit for low-level vision. Engineered for state-of-the-art performance in image and video restoration, including Super-Resolution, Denoising, Deblurring, and more.

Project description

GitHub Repo stars Downloads License Apache 2.0 PyPI version Python 3.10+ Discord

ClarityCore

[!!!WORK IN PROGRESS!!!]Easy and fast low-level vision for everyone


[!!!WORK IN PROGRESS!!!]Next-generation Open Source toolkit for low-level vision. Engineered for state-of-the-art performance in image and video pixel2pixel tasks, including Super-Resolution, Denoising, Deblurring, and more.

If you find ClarityCore useful, please consider giving it a star ⭐ and Join Discord!


Latest News 🚀

  • I am very busy at my current position. I want to continue this project in ~January
  • [2025/11] Major refactoring: unified dataset, preset system, Rich CLI
  • [2025/10] Project start

🚀 Quick Start

Installation

pip install claritycore

Or install from source:

git clone https://github.com/Bezdarnost/claritycore.git
cd claritycore
pip install -e .

Training

Train a 4x super-resolution model with one command:

# List available presets
claritycore list

# Train with a preset
claritycore train rrdbnetx4

# Train with custom settings
claritycore train rrdbnetx4 --steps 100000 --batch-size 8

Python API

from claritycore import AutoConfig, AutoModel, Trainer
from claritycore.data import Pixel2PixelDataset, DatasetConfig

# Create model
config = AutoConfig.from_name("rrdbnet", scale=4)
model = AutoModel.from_config(config)

# Create dataset
data_config = DatasetConfig(target_dir="data/HR", scale=4)
dataset = Pixel2PixelDataset(data_config)

# Train
trainer = Trainer(model, train_loader, optimizer, training_config)
trainer.train()

📦 Available Models

Model Task Parameters Scales
RRDBNet Super-Resolution 16.7M (full) / 1M (lite) 2×, 3×, 4×, 8×

See docs/models.md for detailed documentation.


📁 Dataset Structure

ClarityCore expects datasets in this structure:

datasets/DIV2K/
├── hr/           # Target (high-resolution) images
├── x2/           # Input images for 2x SR
├── x3/           # Input images for 3x SR
└── x4/           # Input images for 4x SR

The Pixel2PixelDataset automatically:

  • Detects filename suffix patterns (e.g., 0001x4.png)
  • Generates input images on-the-fly if no input directory exists
  • Supports flexible normalization ([0,1], [-1,1], or custom)

🛠️ CLI Reference

# Show help
claritycore --help

# List available training presets
claritycore list

# Train with preset
claritycore train <preset> [options]

# Examples
claritycore train rrdbnetx4                    # Full RRDBNet, 4x SR
claritycore train rrdbnet-litex4               # Lightweight variant
claritycore train rrdbnetx4 --steps 50000      # Custom steps
claritycore train rrdbnetx4 --batch-size 8     # Custom batch size

# Advanced training (full control)
claritycore train --model rrdbnet --scale 4 --data path/to/data

📊 Presets

Preset Model Scale Config Steps
rrdbnetx2 RRDBNet 64 feat, 23 blocks 400K
rrdbnetx4 RRDBNet 64 feat, 23 blocks 400K
rrdbnet-litex4 RRDBNet 32 feat, 6 blocks 200K

Run claritycore list for all available presets.

📖 Citation

If you use ClarityCore in your research, please cite:

@software{ClarityCore_2025,
  author = {Urumbekov, Aman},
  license = {Apache-2.0},
  title = {{ClarityCore}},
  url = {https://github.com/Bezdarnost/claritycore},
  year = {2025}
}

Urumbekov, A. (2025). ClarityCore: A toolkit for low-level vision. GitHub. https://github.com/bezdarnost/claritycore

⭐ Star History

Star History Chart


📄 License

Apache License 2.0. See LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

claritycore-0.0.5.tar.gz (394.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

claritycore-0.0.5-py3-none-any.whl (52.9 kB view details)

Uploaded Python 3

File details

Details for the file claritycore-0.0.5.tar.gz.

File metadata

  • Download URL: claritycore-0.0.5.tar.gz
  • Upload date:
  • Size: 394.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for claritycore-0.0.5.tar.gz
Algorithm Hash digest
SHA256 d09ad6f9dccd9dcf7f918ed4c64e5aea7d014c8efbbdfbad4480131735209954
MD5 f4e9be6aacb436eee4aaa19fa3d68aed
BLAKE2b-256 8a4a8e8ca8a7ebbf530ba6fbfae7e73d600359f8d2a8c82cebd06ff3d919c294

See more details on using hashes here.

Provenance

The following attestation bundles were made for claritycore-0.0.5.tar.gz:

Publisher: publish.yml on Bezdarnost/claritycore

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file claritycore-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: claritycore-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 52.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for claritycore-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 70a683103c8e7eeafb888b1501e59329254f3e61e9fad4654d15da1178ad1a76
MD5 55216d3b471f58db347f6f484edcd71a
BLAKE2b-256 28f7cfb1101f0e84f97ebfb7dd21790c125c37a26ee45c028574f951b502df6d

See more details on using hashes here.

Provenance

The following attestation bundles were made for claritycore-0.0.5-py3-none-any.whl:

Publisher: publish.yml on Bezdarnost/claritycore

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page