home.html 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. <!-- This is a Jinja2 Template that extends layout.html
  2. Implements a simple Bootstrap 5 form submission interface for YOLOv5 detection.
  3. -->
  4. {% extends "layout.html" %} {% block title %}
  5. <title>YOLOv5 Demo</title>
  6. {% endblock %} {% block content %}
  7. <div class="m-2">
  8. <h5>Upload image(s) and select a YOLOv5 model</h5>
  9. <hr />
  10. <form method="post" action="" enctype="multipart/form-data">
  11. <div class="my-2">
  12. <label for="file_list" class="form-label">Upload Images</label>
  13. <input
  14. class="form-control w-auto"
  15. type="file"
  16. name="file_list"
  17. id="file_list"
  18. multiple
  19. />
  20. </div>
  21. <div class="my-2">
  22. <div class="form-group">
  23. <label>Select YOLO Model</label>
  24. </div>
  25. <select class="form-select w-auto" name="model_name">
  26. {% for selection in model_selection_options %}
  27. <option value="{{ selection }}">{{ selection }}</option>
  28. {% endfor %}
  29. </select>
  30. </div>
  31. <div class="my-2">
  32. <label for="img_size_input" class="form-label"
  33. >Model Inference Size</label
  34. >
  35. <input
  36. type="text"
  37. class="form-control w-auto"
  38. id="img_size_input"
  39. name="img_size"
  40. value="1824"
  41. />
  42. </div>
  43. <div class="my-2">
  44. <input
  45. type="checkbox"
  46. id="multi_scale"
  47. name="multi_scale"
  48. />
  49. <label for="multi_scale" class="form-label">
  50. Multi-scale Inference
  51. </label>
  52. </div>
  53. <button class="btn btn-primary" type="submit">Submit</button>
  54. </form>
  55. </div>
  56. {% endblock %}