Spaces:
Running
Running
hatmanstack
commited on
Commit
·
b551c1f
1
Parent(s):
a967c34
adjusted rate limit
Browse files- README.md +1 -0
- generate.py +1 -1
README.md
CHANGED
@@ -28,6 +28,7 @@ A Gradio application for advanced image generation using Amazon Nova Canvas, off
|
|
28 |
## Prerequisites
|
29 |
|
30 |
- AWS credentials configured (AmazonBedrockFullAccess)
|
|
|
31 |
- Boto3 Python library
|
32 |
- Gradio 5.6.0
|
33 |
|
|
|
28 |
## Prerequisites
|
29 |
|
30 |
- AWS credentials configured (AmazonBedrockFullAccess)
|
31 |
+
- HF Token for Input Image Check
|
32 |
- Boto3 Python library
|
33 |
- Gradio 5.6.0
|
34 |
|
generate.py
CHANGED
@@ -173,7 +173,7 @@ def check_rate_limit(body):
|
|
173 |
raise ImageError(rate_limit_message.format('Premium'))
|
174 |
rate_data['premium'].append(current_time)
|
175 |
else: # standard
|
176 |
-
if len(rate_data['standard']) >=
|
177 |
raise ImageError(rate_limit_message.format('Standard'))
|
178 |
rate_data['standard'].append(current_time)
|
179 |
|
|
|
173 |
raise ImageError(rate_limit_message.format('Premium'))
|
174 |
rate_data['premium'].append(current_time)
|
175 |
else: # standard
|
176 |
+
if len(rate_data['standard']) >= 6:
|
177 |
raise ImageError(rate_limit_message.format('Standard'))
|
178 |
rate_data['standard'].append(current_time)
|
179 |
|