Skip to content

masktrump19-sudo/flux

 
 

Repository files navigation

Flux Inference Project

🎓 SYSU Computer Vision Coursework

SYSU Hugging Face Weights Hugging Face Dataset Python Gradio

Efficient inference implementation for the Flux architecture.
Developed by Huang Yongqing for the CV course at Sun Yat-sen University.


📖 Project Overview

This repository contains the inference pipeline for the Flux model. It provides optimized scripts to run image generation tasks efficiently using local environments.

✨ Key Feature: The project supports both Gradio (Web UI) and Streamlit (Dashboard) for flexible demonstration.

📥 Model Weights & Dataset

1. Model Weights

Due to GitHub's file size limits, the model weights (.safetensors) are hosted on my Hugging Face Model repository.

👉 Download Weights here

2. Dataset (New!)

The full training and validation datasets (FLUX & SDXL) are hosted on my Hugging Face Dataset repository.

👉 Access Dataset here ---

Setup Instructions

After downloading weights, please organize the files in the checkpoints/ directory as follows:

checkpoints/ ├── flux1-dev.safetensors <-- Main Model (23.8GB) └── ae.safetensors <-- AutoEncoder (335MB) 

🚀 Getting Started

1. Environment Setup

Clone the repository and install dependencies:

# It is recommended to use conda or venv pip install -r requirements.txt

2. Run Inference

Choose your preferred interface style:

Interface Type Command Description
Gradio python demo_gr.py Interactive Web UI, suitable for quick testing.
Streamlit streamlit run demo_st.py Dashboard style, better for presentation.

📂 Project Structure

. ├── src/ # 🧠 Core implementation logic ├── assets/ # 🎨 Images and static assets ├── checkpoints/ # ⚖️ Model weights (Download from HF) ├── output/ # 🖼️ Generated results (Auto-created) ├── demo_gr.py # 🚀 Gradio startup script ├── demo_st.py # 🚀 Streamlit startup script └── requirements.txt # 📦 Dependency list

👤 Author

Huang Yongqing
Sun Yat-sen University (SYSU)
📧 huangyq296@mail2.sysu.edu.cn
🐙 @masktrump19-sudo

📜 Disclaimer

This project is for academic and educational purposes only. The Flux model architecture and weights are properties of their respective owners (Black Forest Labs).

About

Official inference repo for FLUX.1 models

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 100.0%