PhotographicMaterial512 β€” OMGSR-S on Stable Diffusion 2.1-base for Core ML

A Core ML conversion of OMGSR-S (You Only Need One Mid-timestep Guidance for Real-World Image Super-Resolution; code), a one-step diffusion restoration model, merged into Stable Diffusion 2.1-base.

The iOS app Still (ν•œμ»·) downloads it on demand. In the app's developer menu it can replace the default texture model for maximum quality, so the two can be compared. It restores skin, hair and fabric at the source resolution in 512 px tiles.

Generated detail is a prediction, not evidence of captured detail. Faces, glasses and text can change; the app holds the face's shape and the text it reads to the source.

Files

Path Purpose
MaterialEncoder.mlpackage/ VAE encoder with the OMGSR encoder adapter merged
MaterialDenoiser.mlpackage/ One-step UNet with the OMGSR adapter merged, 6-bit palettized
MaterialDecoder.mlpackage/ VAE decoder
manifest.json Size and SHA-256 of every file in the three packages
LICENSE-MODEL CreativeML Open RAIL++-M (governs this derivative of Stable Diffusion 2.1-base), including the use restrictions in Attachment A
LICENSE-OMGSR Apache License 2.0 of the OMGSR code and weights

Each stage is an ML Program for iOS 18 that takes input and returns output. The app runs the three stages one after another on 512 px tiles that overlap by at least 64 px, and releases each before loading the next. PhotographicMaterialRestorer.swift in the app shows the tiling.

Measured on iPhone 14 Pro (A16, iOS 18.4), Neural Engine, whole capture including decoding and PNG: 95.5 s for the first 4K frame (with the on-device check and compilation), then 9.9–67.0 s, 36.1 s on average over five captures.

Changes from the original weights

Notice of changes, as paragraph 4 of the CreativeML Open RAIL++-M License and section 4(b) of the Apache License 2.0 require:

  1. Merged the OMGSR-S LoRA adapters for the UNet and the VAE encoder, as published by the OMGSR authors, into Stable Diffusion 2.1-base. The official 2.1-base repository is no longer available, so the base weights come from the mirror Manojb/stable-diffusion-2-1-base at revision 0094d483a120f3f33dafbd187ea4aa60d10de75c, as suggested in OSEDiff issue 77. The app's repository records the SHA-256 of every source file.
  2. Fixed the empty-prompt text embedding and timestep 273 into the denoiser, removing the text encoder.
  3. Converted from PyTorch to three Core ML ML Programs (encoder, denoiser, decoder) with a fixed 512 px tile.
  4. Quantized the denoiser weights to 6 bits with k-means palettes. The encoder and decoder keep FP16 weights.

The conversion scripts are in the app's repository (MaterialStudy: fetch_omgsr.py, convert_omgsr.py, prepare_app_models.py).

License and use restrictions

This model is a Derivative of the Model Stable Diffusion 2.1-base and is distributed under the CreativeML Open RAIL++-M License (LICENSE-MODEL, copyright Β© 2022 Stability AI and contributors). By using it you agree to the use restrictions in Attachment A of that license. Anyone who redistributes it, or distributes a product that includes it, must pass these restrictions on as an enforceable provision and give users a copy of the license. The app Still does this in its terms of use, which people accept before the app uses this model.

The OMGSR code and weights are Β© their authors under the Apache License 2.0 (LICENSE-OMGSR), as the authors stated in OMGSR issue 9. This repository is not affiliated with or endorsed by Stability AI or the OMGSR authors. No warranty is given, including for claims arising from the training data of the original models. Evaluate this for your own use.

Citation

@misc{wu2025omgsrneedmidtimestepguidance,
  title={OMGSR: You Only Need One Mid-timestep Guidance for Real-World Image Super-Resolution},
  author={Zhiqiang Wu and Zhaomang Sun and Tong Zhou and Bingtao Fu and Ji Cong and Yitong Dong and Huaqi Zhang and Xuan Tang and Mingsong Chen and Xian Wei},
  year={2025},
  eprint={2508.08227},
  archivePrefix={arXiv},
  primaryClass={cs.CV},
  url={https://arxiv.org/abs/2508.08227}
}
Downloads last month
28
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for halfmoon-mind/still-material-restore

Quantized
(1)
this model

Paper for halfmoon-mind/still-material-restore