RajatMalviya commited on
Commit
b88bbe1
·
verified ·
1 Parent(s): ee14801

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -43,7 +43,7 @@ async def analyze_food_image(
43
  img = Image.open(io.BytesIO(image_bytes))
44
 
45
  # Load the generative model
46
- model = genai.GenerativeModel("gemini-1.5-flash") # Optimized for real-time image processing
47
 
48
  # Define prompts based on analysis type
49
  prompts = {
@@ -245,7 +245,7 @@ async def analyze_food_image_original(file: UploadFile = File()):
245
  img = Image.open(io.BytesIO(image_bytes))
246
 
247
  # Load the generative model
248
- model = genai.GenerativeModel("gemini-1.5-flash") # Optimized for real-time image processing
249
 
250
  # Updated structured JSON prompt
251
  prompt = """
 
43
  img = Image.open(io.BytesIO(image_bytes))
44
 
45
  # Load the generative model
46
+ model = genai.GenerativeModel("gemini-2.0-flash") # Optimized for real-time image processing
47
 
48
  # Define prompts based on analysis type
49
  prompts = {
 
245
  img = Image.open(io.BytesIO(image_bytes))
246
 
247
  # Load the generative model
248
+ model = genai.GenerativeModel("gemini-2.0-flash") # Optimized for real-time image processing
249
 
250
  # Updated structured JSON prompt
251
  prompt = """