Unanswered
Hey, Trying To Figure Out How To Create An
Oh okay, my initial implementation was not far off:
` task = Task.init(project_name='VINZ', task_name=f'VINZ Retraining {datetime.now().strftime("%Y-%m-%d %H:%M:%S")}')
task.set_progress(0)
print("Training model...")
os.system(train_cmd)
print("✔️ Model trained!")
task.set_progress(75)
print("Converting model to ONNX...")
os.system(f"python export.py --weights {os.path.join(training_data_path, 'runs', 'train', 'yolov5s6_results', 'weights', 'best.pt')} --img 1280 --include onnx")
print("✔️ Model converted to ONNX!")
task.set_progress(100)
print("Exporting model to ClearML...")
output_model = OutputModel(
task=task,
framework='yolov5',
name='VINZ Model'
)
output_model.set_upload_destination(' ` ` ')
output_model.update_weights(os.path.join(training_data_path, 'runs', 'train', 'yolov5s6_results', 'weights', 'best.onnx'))
output_model.tags = [f'train-dataset-{continuous_learning_dataset_id[:8]}'] `
164 Views
0
Answers
2 years ago
one year ago