pytron-web/views/html/upload_html.pug

63 lines
3.5 KiB
Plaintext
Raw Normal View History

2019-03-28 16:16:51 +01:00
extends base_html
2019-03-27 16:02:53 +01:00
2019-03-22 10:56:49 +01:00
block content
section.section
.container
.columns.is-centered
2019-03-27 16:02:53 +01:00
.column.is-6.is-desktop
2019-03-22 10:56:49 +01:00
form(action="upload-target", method="POST", encType="multipart/form-data")
.field
label.label Name
2019-03-27 16:02:53 +01:00
p.content.has-text-justified
| This name will be the name you will see on
| the leaderboard. It also corresponds to the
| name of the module your AI will be on the
| server.
p.content.has-text-justified
2019-03-27 16:47:58 +01:00
| You can use an already existing name to
2019-03-27 16:02:53 +01:00
| replace it with a new version of your AI.
2019-03-22 10:56:49 +01:00
input.input(type="text", name="name", placeholder="Name of your AI")
2019-03-27 18:33:41 +01:00
.fielg
label.label Password
p.content.has-text-justified
| This password will allow you to update your
| AI. If the name you specify is not used,
| this password can be anything you want. If
| the name you specify already exists, you need
| to enter the password you entered when you
| uploaded the AI the first time.
input.input(type="password", name="password", placeholder="Password")
2019-03-22 10:56:49 +01:00
.field
2019-03-27 16:02:53 +01:00
label.label Archive
p.content.has-text-justified
| The archive to upload needs to contain a file
| named <code>ai.py</code> which must contain a
| class named <code>Ai</code> which must contain
| a constructor that takes no arguments (other
| than self or optional arguments).
p.content.has-text-justified
| It may also contain more files, such as
| binary files with neural network weights, or
| such as other python modules.
2019-03-27 17:06:10 +01:00
p.content.has-text-justified
| Please, use as few modules as possible. The
| server won't have pygame or matplotlib, so
| importing those kind of modules in your AI
| will crash the script.
2019-03-27 16:02:53 +01:00
p.content.has-text-justified
| Please note that this archive must not
| contain a directory, it must only contain the
| files.
2019-03-22 10:56:49 +01:00
.file.has-name
label.file-label
input.file-input(type="file", name="archive")
span.file-cta
span.file-icon
i.fas.fa-upload
span.file-label Choose a file…
span.file-name
2019-03-27 16:02:53 +01:00
.field
input.button.is-link(type="submit", value="Submit")
2019-03-22 10:56:49 +01:00