Upto - 4 Megapixels, 10sec per image sampling { Hi - Res }
Post 🤗: https://huggingface.co/posts/prithivMLmods/508581844814759
Endpoint Creation Step by Step: 🧵
-> Sign up to { api.bfl.ml } & get your api's: https://api.bfl.ml/auth/profile
-> File Structure:
flux_image_generation/
├── .env
├── generate_image.py
└── requirements.txt
-> Step 0: Add Your API Key to an Environment File { .env }
BFL_API_KEY=your_actual_api_key_here
-> Step 1: Install Required Libraries { requirements.txt }
requests
python-dotenv
-> Step 2: Setup the Python Script
{ generate_image.py} - https://github.com/PRITHIVSAKTHIUR/Flux-API/blob/main/generate_image.py
-> Step3: Install the requirements & Run the Script
pip install -r requirements.txt
python generate_image.py
-> Polling: The script polls the API every 0.5 seconds until the image generation result is ready. That's it the script also checks for a successful response after submitting the request.
For more visit:
🔺for script: https://github.com/PRITHIVSAKTHIUR/Flux-API/tree/main
🔺bfl doc: https://docs.bfl.ml/quick_start/gen_image/#__tabbed_1_2
Endpoints for image generation: 🧵
-> /flux-pro-1.1-ultra -> /flux-pro-1.1 -> /flux-pro -> /flux-dev
Each ID has 50 free credits available for use, based on the cost per image sample generated by the model.
. . . @prithivMLmods 🤗