swastikbansal commited on
Commit
fef9a8e
·
verified ·
1 Parent(s): d910a07

Disabled customdata endpoint

Browse files
Files changed (1) hide show
  1. app.py +15 -16
app.py CHANGED
@@ -230,22 +230,21 @@ trainer = Trainer(hands,pose)
230
  def home():
231
  return f"<h1>Signify API</h1>"
232
 
233
- @app.route('/customTrain', methods= ["POST"])
234
- def custom_model():
235
- """
236
- Trigger custom training (POST)
237
- Always returns a valid Flask response to avoid None being returned.
238
- """
239
- pass
240
- # try:
241
- # status = trainer.run_training()
242
- # if status:
243
- # print("Model training completed")
244
- # return jsonify({"status": "success", "message": "Custom model training completed and switched"}), 200
245
- # else:
246
- # return jsonify({"status": "failed", "message": "Custom training did not complete successfully"}), 500
247
- # except Exception as e:
248
- # return jsonify({"status": "error", "message": f"Error training model: {str(e)}"}), 500
249
 
250
  @app.route('/switchModel', methods=['POST', 'GET'])
251
  def switch_model():
 
230
  def home():
231
  return f"<h1>Signify API</h1>"
232
 
233
+ # @app.route('/customTrain', methods= ["POST"])
234
+ # def custom_model():
235
+ # """
236
+ # Trigger custom training (POST)
237
+ # Always returns a valid Flask response to avoid None being returned.
238
+ # """
239
+ # try:
240
+ # status = trainer.run_training()
241
+ # if status:
242
+ # print("Model training completed")
243
+ # return jsonify({"status": "success", "message": "Custom model training completed and switched"}), 200
244
+ # else:
245
+ # return jsonify({"status": "failed", "message": "Custom training did not complete successfully"}), 500
246
+ # except Exception as e:
247
+ # return jsonify({"status": "error", "message": f"Error training model: {str(e)}"}), 500
 
248
 
249
  @app.route('/switchModel', methods=['POST', 'GET'])
250
  def switch_model():