Chirana/Diffusion_model
0
LuminaDiff: Low-Light Image Enhancement
LuminaDiff is a diffusion-based model for enhancing low-light images. It uses a custom U-Net architecture (PureDiffusionUNet) and a DiffusionEngine to recover details and correct lighting.
Project Structure
src/: Core source code (model, config, diffusion engine).weights/: Pre-trained model weights.infer.py: Main inference script (Guide & Stitch strategy).train.py: Training script.
Setup
- Install dependencies:
pip install -r requirements.txt- Ensure weights are in
weights/latest.pth.
Usage
Inference
To run the advanced inference (Guide & Stitch):
python infer.pyThis will process images in the test/ folder and save results to results_advanced/.
Docker
Build and run the container:
docker build -t lumina-diff .
docker run --rm -v $(pwd)/test:/app/test -v $(pwd)/results_advanced:/app/results_advanced lumina-diff