awabxnero commited on
Commit
06789ee
1 Parent(s): 004c03d

Update model.py

Browse files
Files changed (1) hide show
  1. model.py +1 -0
model.py CHANGED
@@ -4,6 +4,7 @@ import torch
4
  # Replace with your model path if it's not from the Hugging Face model hub
5
  # model_id = "https://api-inference.huggingface.co/models/awabxnero/imagen" # Your Hugging Face model repo
6
  pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-schnell")
 
7
  pipe = pipe.to("cuda") # Move model to GPU if available
8
 
9
  # Function to generate image from prompt
 
4
  # Replace with your model path if it's not from the Hugging Face model hub
5
  # model_id = "https://api-inference.huggingface.co/models/awabxnero/imagen" # Your Hugging Face model repo
6
  pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.1-schnell")
7
+
8
  pipe = pipe.to("cuda") # Move model to GPU if available
9
 
10
  # Function to generate image from prompt