Spaces:
Runtime error
Runtime error
Commit
·
847470e
1
Parent(s):
690feab
Update app.py
Browse files
app.py
CHANGED
@@ -201,21 +201,20 @@ def zip_and_upload_images(identifier: str, uploaded_files: List[BytesIO], image_
|
|
201 |
return s3_path
|
202 |
|
203 |
def train_model(model_inputs):
|
204 |
-
|
205 |
-
|
206 |
-
|
207 |
-
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
_ = requests.post(cli_args.train_endpoint_url, json=model_inputs)
|
219 |
|
220 |
|
221 |
def switch_ux_state(new_state: UxState):
|
|
|
201 |
return s3_path
|
202 |
|
203 |
def train_model(model_inputs):
|
204 |
+
logger.info("Skipping model training since --dry-run is enabled.")
|
205 |
+
logger.info(f"model_inputs: {model_inputs}")
|
206 |
+
st.markdown(str(model_inputs))
|
207 |
+
|
208 |
+
# if cli_args.train_endpoint_url is None:
|
209 |
+
# # Use banana backend
|
210 |
+
# api_key = "03cdd72e-5c04-4207-bd6a-fd5712c1740e"
|
211 |
+
# model_key = "1a3b4ce5-164f-4efb-9f4a-c2ad3a930d0b"
|
212 |
+
# st.markdown(str(model_inputs))
|
213 |
+
# print(model_inputs)
|
214 |
+
# _ = banana.run(api_key, model_key, model_inputs)
|
215 |
+
# else:
|
216 |
+
# # Send request directly to specified url
|
217 |
+
# _ = requests.post(cli_args.train_endpoint_url, json=model_inputs)
|
|
|
218 |
|
219 |
|
220 |
def switch_ux_state(new_state: UxState):
|