Composable sampling functions for diffusion models
Project description
Skrample 0.6.0
Composable sampling functions for diffusion models
Status
Production-tested on all popular diffusion models. The library has significantly matured since 0.5
Quickstart
Fastest way to jump in is examples. The classes and functions themselves have docstrings and type hints, so it's recommended to make liberal use of your IDE or python help()
Feature Flags
beta-schedule->scipy: For theBeta()schedule modifierbrownian-noise->torchsde: For theBrownian()noise generatorcdf-schedule->scipy: For theProbit()schedulediffusers-wrapper->torch: For thediffusersintegration modulepytorch->torch: For thepytorchmodulepytorch.noise: Custom generators
all: All of the abovedev: For runningtests/
Structured Samplers
These samplers are written inside-out to be compatible with Diffusers and similar frameworks
- Euler
- Stochastic
- DPM
- Order 1-3
- Stochastic
- Adams/IPNDM
- Order 1-9
- Stochastic
- UniP & UniPC
- Order 1-9
- Stochastic
- Custom predictor via other SkrampleSampler types
- SPC
- Basic fully customizable midpoint corrector
Functional Samplers
These samplers are written using closures similar to ksampler
- RKUltra
- Arbitrary Runge-Kutta solver
- Order 1-15, customizable through tableaux system
- Stochastic
- DynasauRK
- Procedural Runge-Kutta solver
- Order 2-4
- Stochastic
- RKMoire
- Experimental
- Embedded Runge-Kutta solver
- Order 2-6, customizable through tableaux system
Schedules
- Linear
- Flow-matching default
- Scaled
- Variance-preserving default
- ZSNR
Subschedules
Replaces sigmas on an existing schedule
- Karras
- Exponential
- Beta
- Probit
Schedule Modifiers
Modifies timestep spacing of a schedule
- FlowShift
- Hyper
- Sinner
Models
- Data / Sample / X-Pred
- Noise / Epsilon / Ε-Pred
- Velocity / V-Pred
- Flow / U-pred
Noise generators
- Random
- Brownian
- Offset
- Pyramid
Integrations
Diffusers
- Compatibile with DiffusionPipeline
- Import from config
- Sampler
- Schedule
- Predictor
- Structured sampler wrapper
- Functional sampler wrappers
- RKUltra
- DynasauRK
Implementations
quickdif
My diffusers cli quickdif has full support for all major Diffusers-compatible Skrample features, allowing extremely fine-grained customization.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file skrample-0.6.0.tar.gz.
File metadata
- Download URL: skrample-0.6.0.tar.gz
- Upload date:
- Size: 76.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a344fb2fde3a2cc0a4a728e3a0b80b72908dbe867bb348c5b28c78c657581483
|
|
| MD5 |
989f1c7ebf3158c74e358bc53225e5e9
|
|
| BLAKE2b-256 |
9ff77368a820d4494048969197f630d33e05e3f0fc48d35bb86190d2c2362503
|
File details
Details for the file skrample-0.6.0-py3-none-any.whl.
File metadata
- Download URL: skrample-0.6.0-py3-none-any.whl
- Upload date:
- Size: 81.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fc0e3207bd5cd35368aa21d136e7ae8525ddd92c3915ec4b7d3973a7f00a3510
|
|
| MD5 |
f6942e282ed1f30a3ea8683d7c394f25
|
|
| BLAKE2b-256 |
8d9fb5e7b2202153a4dcfedd27936f5ed96e5b9738d89674e6eb88d750832781
|