Reworked CSS (#103)

Recklessly merging, YOLO.
This commit is contained in:
Luecx authored and GitHub committed 2022-11-22 03:13:40 -05:00
1 parent d577d18eb5
commit e8fcc6a787
20 files changed
+1280 -937

No files matched your search

+9 -277
View File
@@ -1,295 +1,27 @@
body { html, body, header {
font-family: "Courier Prime"; height: 100%;
font-size: 18px; line-height: 1.5rem;
background: #303030; font-weight: 400;
} }
a:link, a:visited, a:hover, a:active {
text-decoration: none;
color: #FFFFFF;
}
#sidebar {
float: left;
margin: 16px;
margin-top: 60px;
}
#sidebar ul {
list-style-type: none;
padding: 0px 18px;
}
#sidebar li a {
color: #A2A2A2;
font-size: 15px;
}
#sidebar .header {
font-size: 15px;
color: #00AF00;
}
#content {
float: left;
margin-top: 0;
color: #EAEAEA;
}
#content label {
width: 128px;
padding-right: 10px;
text-align: right;
display: inline-block;
color: #A2A2A2;
font-size: 14px;
}
#content input, #content select {
background-color: #BBBBBB;
color: #000000;
padding: 10px;
margin: 1px 0px;
width: 320px;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
}
#content button {
padding: 8px 0px;
margin: 2px 0px;
display: inline-block;
vertical-align: middle;
width: 290px;
background-color: #777777;
color: black;
border: none;
border-radius: 16px;
cursor: pointer;
font-weight: bold;
}
#content button:hover {
background-color: #00AF00;
}
#content input[type=submit] {
background-color: #00AF00;
color: #000000;
border: none;
border-radius: 16px;
cursor: pointer;
width: 100%;
font-weight: bold;
}
#content input:read-only {
font-weight: bold;
}
#content input:-moz-read-only {
font-weight: bold;
}
#content #configuration {
float: left;
margin-top: 20px;
}
#content #actions {
margin-left: 32px;
float: right;
}
#content #actions h4 {
color: #A2A2A2;
font-size: 15px;
font-weight: bold;
}
#content #actions .anchorbutton {
color: #000000;
padding: 8px 8px;
margin: 0px 8px;
border-radius: 16px;
font-weight: bold;
text-align: center;
display: inline-block;
width: 25%;
}
#content #actions .anchorbutton a:hover {
background-color: #00AF00;
}
#content #actions #approvebutton {
background-color: #9DF779;
}
#content #actions #stopbutton {
background-color: #EEF788;
}
#content #actions #restartbutton {
background-color: #EEF788;
}
#content #actions #deletebutton {
background-color: #FA8E8E;
}
#content #actions .deadbutton {
background-color: #808080;
pointer-events: none;
}
#content #actions input {
width: 260px;
}
#content #actions input[type=submit] {
width: 100%;
}
#content .left-align {
text-align: left;
}
#content tr:hover {
background-color: #666666;
}
#content th {
color: #00AF00;
font-size: 16px;
font-weight: 100;
padding: 7px 12px 5px 12px;
background-color: #000000;
}
#content td {
padding: 7px 12px 5px 12px;
}
#content .numeric {
text-align: right;
}
#content tr {
background-color: #202020;
}
#content .table-spacer th {
background: #303030;
height: 16px;
}
#content .statblock { #content .statblock {
line-height: 70%;
color: black; color: black;
background-color: #CCCCCC; background-color: #CCCCCC;
border-radius: 4px; font-family: Courier, serif;
font-family: "Courier New";
} }
#content .green { #content .green {
background-color: #9DF779 background-color: #6bd26b
/*background: linear-gradient(to bottom, #75bb76 0%, #44EB44 100%);*/
} }
#content .yellow { #content .yellow {
background-color: #EEF788 background-color: #EEF788
} }
#content .red { #content .red {
/*background: linear-gradient(to bottom, #FA8E8E 0%, #da7474 100%);*/
background-color: #FA8E8E background-color: #FA8E8E
} }
#content #results {
display: inline-block;
width: inherit;
}
#content table {
line-height: 96%;
}
#content .textcenter {
text-align: center;
}
#content strong {
font-size: 14px;
font-weight: bold;
}
#content a:not(.TitleLink) {
font-weight: 100;
color: #8BBAD6;
}
#content a.redlink {
color: #FF4D4D;
}
#content a.unstarred {
color: #808080;
}
#content h1, h2, h3 {
color: #a7a7a7;
text-align: center;
}
#content #pagebrowse {
text-align: center;
margin: 16px 0px 16px 0px;
}
#content .page {
text-align: center;
display: inline-block;
padding: 8px 0px;
width: 5%;
background-color: #1A1A1A;
border-radius: 8px;
}
#content .page:hover {
background-color: #00AF00;
}
#error {
background-color: #EE7676;
padding: 8px;
text-align: center;
}
#content form h3 {
margin-left: 110px;
margin-bottom: 2px;
font-size: 16px;
font-weight: normal;
color: #00AF00;
}
#content h4 a {
font-size: 18px;
}
#content form .settings-column {
float: left;
padding-bottom: 16px;
}
#content #test-mode-buttons button {
width: 49.8%;
}
#content #test-mode-buttons .left-floated {
float: left;
}
#content #test-mode-buttons .right-floated {
float: right;
}
+69 -37
View File
@@ -33,6 +33,7 @@ def oneDigitPrecision(value):
except: except:
return value return value
def twoDigitPrecision(value): def twoDigitPrecision(value):
try: try:
value = round(value, 2) value = round(value, 2)
@@ -44,52 +45,71 @@ def twoDigitPrecision(value):
except: except:
return value return value
def gitDiffLink(test):
def gitDiffLink(test):
if type(test) != OpenBench.models.Test: if type(test) != OpenBench.models.Test:
dev = test['dev']['source'] dev = test['dev']['source']
base = test['base']['source'] base = test['base']['source']
devsha = test['dev']['sha'] devsha = test['dev']['sha']
basesha = test['base']['sha'] basesha = test['base']['sha']
else: else:
dev = test.dev.source dev = test.dev.source
base = test.base.source base = test.base.source
devsha = test.dev.sha devsha = test.dev.sha
basesha = test.base.sha basesha = test.base.sha
repo = OpenBench.utils.pathjoin(*dev.split('/')[:-2]) repo = OpenBench.utils.pathjoin(*dev.split('/')[:-2])
return OpenBench.utils.pathjoin(repo, 'compare', return OpenBench.utils.pathjoin(repo, 'compare',
'{0}...{1}'.format(basesha[:8], devsha[:8])) '{0}...{1}'.format(basesha[:8], devsha[:8]))
def shortStatBlock(test): def shortStatBlock(test):
if test.test_mode == "SPRT": if test.test_mode == "SPRT":
currentllr = twoDigitPrecision(test.currentllr) currentllr = twoDigitPrecision(test.currentllr)
lowerllr = twoDigitPrecision(test.lowerllr) lowerllr = twoDigitPrecision(test.lowerllr)
upperllr = twoDigitPrecision(test.upperllr) upperllr = twoDigitPrecision(test.upperllr)
elolower = twoDigitPrecision(test.elolower) elolower = twoDigitPrecision(test.elolower)
eloupper = twoDigitPrecision(test.eloupper) eloupper = twoDigitPrecision(test.eloupper)
llrbounds = '({}, {}) '.format(lowerllr, upperllr) llrbounds = '({}, {}) '.format(lowerllr, upperllr)
return 'LLR: {0} {1}[{2}, {3}]\n'.format(currentllr, llrbounds, elolower, eloupper) \ return 'LLR: {0} {1}[{2}, {3}]\n'.format(currentllr, llrbounds, elolower, eloupper) \
+ 'Games: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws) + 'Games: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws)
if test.test_mode == "GAMES": if test.test_mode == "GAMES":
lower, elo, upper = OpenBench.stats.ELO(test.wins, test.losses, test.draws) lower, elo, upper = OpenBench.stats.ELO(test.wins, test.losses, test.draws)
error = max(upper - elo, elo - lower) error = max(upper - elo, elo - lower)
elo = twoDigitPrecision(elo) elo = twoDigitPrecision(elo)
error = twoDigitPrecision(error) error = twoDigitPrecision(error)
return 'Elo: {0} +- {1} (95%) [N={2}]\n'.format(elo, error, test.max_games) \ return 'Elo: {0} +- {1} (95%) [N={2}]\n'.format(elo, error, test.max_games) \
+ 'Games: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws) + 'Games: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws)
def shortBoldBlock(test):
if test.test_mode == "SPRT":
currentllr = twoDigitPrecision(test.currentllr)
lowerllr = twoDigitPrecision(test.lowerllr)
upperllr = twoDigitPrecision(test.upperllr)
elolower = twoDigitPrecision(test.elolower)
eloupper = twoDigitPrecision(test.eloupper)
llrbounds = '({}, {}) '.format(lowerllr, upperllr)
return 'LLR: {0}'.format(currentllr)
if test.test_mode == "GAMES":
lower, elo, upper = OpenBench.stats.ELO(test.wins, test.losses, test.draws)
error = max(upper - elo, elo - lower)
elo = twoDigitPrecision(elo)
error = twoDigitPrecision(error)
return 'Elo: {0} +- {1}'.format(elo, error, test.max_games)
def longStatBlock(test): def longStatBlock(test):
tokens = test.devoptions.split(' ') tokens = test.devoptions.split(' ')
threads = tokens[0].split('=')[1] threads = tokens[0].split('=')[1]
hash = tokens[1].split('=')[1] hash = tokens[1].split('=')[1]
@@ -97,73 +117,85 @@ def longStatBlock(test):
lower, elo, upper = OpenBench.stats.ELO(test.wins, test.losses, test.draws) lower, elo, upper = OpenBench.stats.ELO(test.wins, test.losses, test.draws)
error = max(upper - elo, elo - lower) error = max(upper - elo, elo - lower)
elo = twoDigitPrecision(elo) elo = twoDigitPrecision(elo)
error = twoDigitPrecision(error) error = twoDigitPrecision(error)
if test.test_mode == 'SPRT': if test.test_mode == 'SPRT':
lowerllr = twoDigitPrecision(test.lowerllr)
lowerllr = twoDigitPrecision(test.lowerllr)
currentllr = twoDigitPrecision(test.currentllr) currentllr = twoDigitPrecision(test.currentllr)
upperllr = twoDigitPrecision(test.upperllr) upperllr = twoDigitPrecision(test.upperllr)
elolower = twoDigitPrecision(test.elolower) elolower = twoDigitPrecision(test.elolower)
eloupper = twoDigitPrecision(test.eloupper) eloupper = twoDigitPrecision(test.eloupper)
return 'ELO | {0} +- {1} (95%)\n'.format(elo, error) \ return 'ELO | {0} +- {1} (95%)\n'.format(elo, error) \
+ 'SPRT | {0}s Threads={1} Hash={2}MB\n'.format(test.timecontrol, threads, hash) \ + 'SPRT | {0}s Threads={1} Hash={2}MB\n'.format(test.timecontrol, threads, hash) \
+ 'LLR | {0} ({1}, {2}) [{3}, {4}]\n'.format(currentllr, lowerllr, upperllr, elolower, eloupper) \ + 'LLR | {0} ({1}, {2}) [{3}, {4}]\n'.format(currentllr, lowerllr, upperllr, elolower, eloupper) \
+ 'GAMES | N: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws) + 'GAMES | N: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws)
if test.test_mode == 'GAMES': if test.test_mode == 'GAMES':
return 'ELO | {0} +- {1} (95%)\n'.format(elo, error) \ return 'ELO | {0} +- {1} (95%)\n'.format(elo, error) \
+ 'CONF | {0}s Threads={1} Hash={2}MB\n'.format(test.timecontrol, threads, hash) \ + 'CONF | {0}s Threads={1} Hash={2}MB\n'.format(test.timecontrol, threads, hash) \
+ 'GAMES | N: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws) + 'GAMES | N: {0} W: {1} L: {2} D: {3}'.format(test.games, test.wins, test.losses, test.draws)
def testResultColour(test): def testResultColour(test):
if test.passed: return 'green' if test.passed: return 'green'
if test.failed: if test.failed:
if test.wins >= test.losses: return 'yellow' if test.wins >= test.losses: return 'yellow'
return 'red' return 'red'
return '' return ''
def sumAttributes(iterable, attribute): def sumAttributes(iterable, attribute):
try: return sum([getattr(f, attribute) for f in iterable]) try:
except: return 0 return sum([getattr(f, attribute) for f in iterable])
except:
return 0
def insertCommas(value): def insertCommas(value):
return '{:,}'.format(int(value)) return '{:,}'.format(int(value))
def prettyName(name): def prettyName(name):
if re.search('[0-9a-fA-F]{40}', name): if re.search('[0-9a-fA-F]{40}', name):
return name[:16].upper() return name[:16].upper()
return name return name
def prettyDevName(test): def prettyDevName(test):
if test.dev.name == test.base.name and test.devnetname != '': if test.dev.name == test.base.name and test.devnetname != '':
try: return OpenBench.models.Network.objects.get(sha256=test.devnetwork).name try:
except: return test.devnetname # File has since been deleted ? return OpenBench.models.Network.objects.get(sha256=test.devnetwork).name
except:
return test.devnetname # File has since been deleted ?
return prettyName(test.dev.name) return prettyName(test.dev.name)
def testIsFRC(test): def testIsFRC(test):
return "FRC" in test.bookname.upper() or "960" in test.bookname.upper() return "FRC" in test.bookname.upper() or "960" in test.bookname.upper()
def resolveNetworkURL(sha256): def resolveNetworkURL(sha256):
if OpenBench.models.Network.objects.filter(sha256=sha256): if OpenBench.models.Network.objects.filter(sha256=sha256):
return '/networks/download/{0}'.format(sha256) return '/networks/download/{0}'.format(sha256)
return sha256 # Legacy Networks return sha256 # Legacy Networks
def testIdToPrettyName(test_id): def testIdToPrettyName(test_id):
return prettyName(OpenBench.models.Test.objects.get(id=test_id).dev.name) return prettyName(OpenBench.models.Test.objects.get(id=test_id).dev.name)
def testIdToTimeControl(test_id): def testIdToTimeControl(test_id):
return OpenBench.models.Test.objects.get(id=test_id).timecontrol return OpenBench.models.Test.objects.get(id=test_id).timecontrol
register = django.template.Library() register = django.template.Library()
register.filter('oneDigitPrecision', oneDigitPrecision) register.filter('oneDigitPrecision', oneDigitPrecision)
register.filter('twoDigitPrecision', twoDigitPrecision) register.filter('twoDigitPrecision', twoDigitPrecision)
register.filter('gitDiffLink', gitDiffLink) register.filter('gitDiffLink', gitDiffLink)
register.filter('shortStatBlock', shortStatBlock) register.filter('shortStatBlock', shortStatBlock)
register.filter('shortBoldBlock', shortBoldBlock)
register.filter('longStatBlock', longStatBlock) register.filter('longStatBlock', longStatBlock)
register.filter('testResultColour', testResultColour) register.filter('testResultColour', testResultColour)
register.filter('sumAttributes', sumAttributes) register.filter('sumAttributes', sumAttributes)
+1 -1
View File
@@ -93,7 +93,7 @@ def getMachineStatus(username=None):
if username != None: if username != None:
machines = machines.filter(user__username=username) machines = machines.filter(user__username=username)
return ": {0} Machines / ".format(len(machines)) + \ return "{0} Machines / ".format(len(machines)) + \
"{0} Threads / ".format(sum([f.threads for f in machines])) + \ "{0} Threads / ".format(sum([f.threads for f in machines])) + \
"{0} MNPS ".format(round(sum([f.threads * f.mnps for f in machines]), 2)) "{0} MNPS ".format(round(sum([f.threads * f.mnps for f in machines]), 2))
+1 -1
View File
@@ -379,7 +379,7 @@ def machines(request):
# # # #
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
data = {'machines' : OpenBench.utils.getRecentMachines()} data = {'machines' : OpenBench.utils.getRecentMachines(10080)}
return render(request, 'machines.html', data) return render(request, 'machines.html', data)
+45 -10
View File
@@ -1,13 +1,48 @@
<div id="pagebrowse"> <div class="d-flex justify-content-center mb-5" id="pagebrowse">
{% if paging.prev != paging.next %} {% if paging.prev != paging.next %}
<a class="page" href="/{{paging.url}}/{{paging.prev}}">&lt;--</a>
{% for page in paging.pages %} <nav aria-label="Page navigation">
{% if page != "..." %} <ul class="pagination">
<a class="page" href="/{{paging.url}}/{{page}}">{{page}}</a> <li class="page-item"><a class="page-link" href="/{{paging.url}}/{{paging.prev}}"><i class="fa-solid fa-arrow-left"></i></a></li>
{% else %} {% for page in paging.pages %}
<a class="page"> {{page}} </a>
{% endif %} {% if page == paging.page %}
{% endfor %} <li class="page-item"><a class="page-link bg-light" href="/{{paging.url}}/{{page}}">{{page}}</a></li>
<a class="page" href="/{{paging.url}}/{{paging.next}}">--&gt;</a> {% elif page != "..." %}
<li class="page-item"><a class="page-link" href="/{{paging.url}}/{{page}}">{{page}}</a></li>
{% else %}
<li class="page-item"><a class="page-link" href="#">{{page}}</a></li>
{% endif %}
{% endfor %}
<li class="page-item"><a class="page-link" href="/{{paging.url}}/{{paging.next}}"><i class="fa-solid fa-arrow-right"></i></a></li>
</ul>
</nav>
{% endif %} {% endif %}
{# {% if paging.prev != paging.next %}#}
{# <a class="page" href="/{{paging.url}}/{{paging.prev}}">&lt;--</a>#}
{# {% for page in paging.pages %}#}
{# {% if page != "..." %}#}
{# <a class="page" href="/{{paging.url}}/{{page}}">{{page}}</a>#}
{# {% else %}#}
{# <a class="page"> {{page}} </a>#}
{# {% endif %}#}
{# {% endfor %}#}
{# <a class="page" href="/{{paging.url}}/{{paging.next}}">--&gt;</a>#}
{# {% endif %}#}
{##}
{# {% if paging.prev != paging.next %}#}
{# <a class="page" href="/{{paging.url}}/{{paging.prev}}">&lt;--</a>#}
{# {% for page in paging.pages %}#}
{# {% if page != "..." %}#}
{# <a class="page" href="/{{paging.url}}/{{page}}">{{page}}</a>#}
{# {% else %}#}
{# <a class="page"> {{page}} </a>#}
{# {% endif %}#}
{# {% endfor %}#}
{# <a class="page" href="/{{paging.url}}/{{paging.next}}">--&gt;</a>#}
{# {% endif %}#}
</div> </div>
+41 -10
View File
@@ -1,11 +1,42 @@
{% load mytags %} {% load mytags %}
<tr> <tr class="w-100" onclick="location.href='/test/{{ test.id }}'">
<td><a href="/user/{{test.author}}">{{test.author|capfirst|slice:":6"}}</a></td> <td>
<td>{{test.engine}}</td> <a class="text-left btn btn-primary-outline btn-block btn-link text-decoration-none " href="/user/{{ test.author }}" role="button">
{% if test.error %} <td><a href="/test/{{test.id}}"><span style="color: red">[x]</span> {{test|prettyDevName}}</a></td> {{ test.author|capfirst|slice:":6" }}
{% elif test|testIsFRC %} <td><a href="/test/{{test.id}}">{{test|prettyDevName}}<span style="color: green">[FRC]</span></a></td> </a>
{% else %} <td><a href="/test/{{test.id}}">{{test|prettyDevName}}</a></td> {% endif %} </td>
<td class="textcenter"><a href="{{test|gitDiffLink}}">diff</a></td> <td class="text-left text-truncate"><a class="text-left btn btn-primary-outline btn-block"
<td>{{test.timecontrol}}</td> role="button">{{ test.engine }}</a></td>
<td class='statblock {{test|testResultColour}}'><strong>{{test|shortStatBlock|linebreaksbr}}</strong></td> {% if test.error %}
</tr> <td class="text-left text-truncate"><a class="text-left btn btn-outline-danger btn-block text-danger"
href="/test/{{ test.id }}"
role="button"><span>[x]</span> {{ test|prettyDevName }}</a></td>
{% elif test|testIsFRC %}
<td class="text-left text-truncate"><a class="text-left btn btn-primary-outline btn-block"
href="/test/{{ test.id }}" role="button">{{ test|prettyDevName }}<span
style="color: green">[FRC]</span></a></td>
{% else %}
<td class="text-left text-truncate"><a class="text-left btn btn-primary-outline btn-block"
href="/test/{{ test.id }}" role="button">{{ test|prettyDevName }}</a>
</td> {% endif %}
<td class="text-center"><a class="btn btn-primary-outline btn-link btn-block text-decoration-none" href="{{ test|gitDiffLink }}" role="button">diff</a>
</td>
<td class="text-center"><a class="btn btn-primary-outline btn-block" role="button">{{ test.timecontrol }}</a></td>
{# <td class="align-middle statblock {{ test|testResultColour }}">#}
{# <label style="font-size: 0.8rem; line-height:1.1rem" class="align-middle align-text-bottom text-monospace px-0">#}
{# <div class="row">#}
{# <div class="col-12 ">{{ test|shortStatBlock|linebreaksbr }}</div>#}
{# </div>#}
{# </label>#}
{# </td>#}
<td style="font-size: 0.8rem; line-height:1.2rem; border-radius:7px;"
class='text-monospace statblock {{ test|testResultColour }}'>
<div class="px-2 row h-100 mh-100 py-0">
{# <!-- <div class="col-4 align-self-center text-center"><h6><strong>{{ test|shortBoldBlock|linebreaksbr }}</strong></h6></div> -->#}
<div class="col-12 ">{{ test|shortStatBlock|linebreaksbr }}</div>
</div>
</td>
</tr>
+148 -87
View File
@@ -2,104 +2,165 @@
<html lang="en"> <html lang="en">
{% load static %} {% load static %}
<head> <head>
<link rel="stylesheet" href="{% static 'style.css' %}"> <link rel="icon" type="image/svg+xml" href="{% static 'logo.svg' %}">
<link rel="icon" type="image/svg+xml" href="{% static 'logo.svg' %}"> <link href='https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.0/css/all.min.css' rel='stylesheet'>
<link href='https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css ' rel='stylesheet'> <link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,200;0,400;1,100&amp;display=swap"
<link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,200;0,400;1,100&amp;display=swap" rel="stylesheet"> rel="stylesheet">
<link rel="preconnect" href="https://fonts.gstatic.com"> <link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Courier+Prime&display=swap" rel="stylesheet"> <link href="https://fonts.googleapis.com/css2?family=Courier+Prime&display=swap" rel="stylesheet">
<title>OpenBench</title> <!-- Bootstrap CSS -->
<script> {# <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.3.1/dist/css/bootstrap.min.css"#}
{% block scripts %} {# integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">#}
{% endblock %}
document.addEventListener('DOMContentLoaded', function() {
var timestamps = document.getElementsByClassName('timestamp'); <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"
integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo"
crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/popper.js@1.14.7/dist/umd/popper.min.js"
integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1"
crossorigin="anonymous"></script>
{# <script src="https://cdn.jsdelivr.net/npm/bootstrap@4.3.1/dist/js/bootstrap.min.js"#}
{# integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM"#}
{# crossorigin="anonymous"></script>#}
var options = { <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet">
year : 'numeric', month : '2-digit', <link href="https://cdn.jsdelivr.net/npm/bootstrap-dark-5@1.1.3/dist/css/bootstrap-nightfall.min.css"
day : '2-digit', hour : '2-digit', rel="stylesheet" media="(prefers-color-scheme: dark)">
minute : '2-digit', second : '2-digit',
hour12 : false,
};
for (var i = 0; i < timestamps.length; i++) { <link rel="stylesheet" href="{% static 'style.css' %}">
var date = new Date(1000 * timestamps[i].innerHTML);
timestamps[i].innerHTML = date.toLocaleString(undefined, options);
}
}, false); <title>OpenBench</title>
</script> <script>
</head> {% block scripts %}
{% endblock %}
<body> document.addEventListener('DOMContentLoaded', function () {
<!-- Views may return an error message --> var timestamps = document.getElementsByClassName('timestamp');
{% if error %}
<div id="error"> var options = {
<pre>{{error}}</pre> year: 'numeric', month: '2-digit',
day: '2-digit', hour: '2-digit',
minute: '2-digit', second: '2-digit',
hour12: false,
};
for (var i = 0; i < timestamps.length; i++) {
var date = new Date(1000 * timestamps[i].innerHTML);
timestamps[i].innerHTML = date.toLocaleString(undefined, options);
}
}, false);
</script>
</head>
<body class="container-fluid p-0 w-100 h-100 bg-body">
<!-- Views may return an error message -->
{% if error %}
<div id="error">
<pre>{{ error }}</pre>
</div>
{% endif %}
<nav class="navbar navbar-expand-lg navbar-light bg-dark sticky-top">
<div class="container container-xxl" style="max-width: 1540px;">
<a class="navbar-brand w-100" href="#">
<h2><i class="fa-solid fa-chess-knight fa-1x"></i> OpenBench Testing Framework</h2>
</a>
</div>
</nav>
<div class="">
<div class="container container-xxl" style="max-width: 1540px;">
<div class="row h-100">
<div class="col-12 col-md-3 col-xl-2 h-75 pt-5">
<label class="mb-2" style="color:green;"><strong>Admin<br></strong></label>
<ul class="list-unstyled font-weight-normal pb-2 w-100">
{% if user.is_authenticated %}
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="/logout/"><i class="fa-solid fa-right-from-bracket fa-fw"></i> Logout</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="/profile/"><i class="fa-solid fa-user fa-fw"></i> Profile</a></li>
{% else %}
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="/login"><i class="fa-solid fa-right-to-bracket fa-fw"></i> Login</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="/register"><i class="fa-solid fa-registered fa-fw"></i> Register</a></li>
{% endif %}
</ul>
<hr>
<label class="mb-2" style="color:green;"><strong>Tests<br></strong></label>
<ul class="list-unstyled font-weight-normal pb-2">
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/index"><i
class="fa-solid fa-house fa-fw"></i> Index</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/greens"><i
class="fa-solid fa-heart fa-fw"></i> Greens</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/search"><i
class="fa-solid fa-magnifying-glass fa-fw"></i> Search</a></li>
</ul>
<hr>
<label class="mb-2" style="color:green;"><strong>Actions<br></strong></label>
<ul class="list-unstyled font-weight-normal pb-2">
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/newTest"><i
class="fa-solid fa-plus fa-fw"></i> Create Test</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="/networks/upload"><i class="fa-solid fa-upload fa-fw"></i> Upload Network</a></li>
</ul>
<hr>
<label class="mb-2" style="color:green;"><strong>Info<br></strong></label>
<ul class="list-unstyled font-weight-normal pb-2">
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/users"><i
class="fa-solid fa-users fa-fw"></i> Users</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/events"><i
class="fa-solid fa-circle-exclamation fa-fw"></i> Events</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/machines"><i
class="fa-solid fa-microchip fa-fw"></i> Machines</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light" href="/networks"><i
class="fa-solid fa-circle-nodes fa-fw"></i> Networks</a></li>
</ul>
<hr>
<label class="mb-2" style="color:green;"><strong>Support<br></strong></label>
<ul class="list-unstyled font-weight-normal pb-2">
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="{{ config.framework }}"><i class="fa-brands fa-github fa-fw"></i> OpenBench</a></li>
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="https://discord.gg/9MVg7fBTpM"><i class="fa-brands fa-discord fa-fw"></i> Discord</a></li>
</ul>
<hr>
<label class="mb-2" style="color:green;"><strong>Engines<br></strong></label>
<ul class="list-unstyled font-weight-normal pb-2">
{% for engine, data in config.engines.items|dictsort:"0.lower" %}
<li><a class="w-100 rounded border-0 btn btn-outline-dark text-start text-light"
href="{{ data.source }}">{{ engine }}</a></li>
{% endfor %}
</ul>
</div>
<div class="col-12 col-md-9 col-xl-10 pt-5">
<div class="w-100 mb-5" id="content">
{% block content %}
{% endblock %}
</div>
</div> </div>
{% endif %}
<div id="sidebar">
<ul>
<li class="header">Admin</li>
{% if user.is_authenticated %}
<li><a href="/logout/">Logout</a></li>
<li><a href="/profile/">Profile</a></li>
{% else %}
<li><a href="/login">Login</a></li>
<li><a href="/register">Register</a></li>
{% endif %}
</ul>
<ul>
<li class="header">Tests</li>
<li><a href="/index">Index</a></li>
<li><a href="/greens">Greens</a></li>
<li><a href="/search">Search</a></li>
</ul>
<ul>
<li class="header">Actions</li>
<li><a href="/newTest">Create Test</a></li>
<li><a href="/networks/upload">Upload Net</a></li>
</ul>
<ul>
<li class="header">Info</li>
<li><a href="/users">Users</a></li>
<li><a href="/events">Events</a></li>
<li><a href="/machines">Machines</a></li>
<li><a href="/networks">Networks</a></li>
</ul>
<ul>
<li class="header">Support</li>
<li><a href="{{config.framework}}">OpenBench</a></li>
<li><a href="https://discord.gg/9MVg7fBTpM">Discord</a></li>
</ul>
<ul>
<li class="header">Engines</li>
{% for engine, data in config.engines.items|dictsort:"0.lower" %}
<li><a href="{{data.source}}">{{engine}}</a></li>
{% endfor %}
</ul>
</div> </div>
</div>
</div>
</body>
<div id="content">
<h2> <a class="TitleLink" href="/">OpenBench Testing Framework</a></h2>
{% block content %}
{% endblock %}
</div>
</body>
</html> </html>
+107 -57
View File
@@ -2,79 +2,129 @@
<html lang="en"> <html lang="en">
{% load static %} {% load static %}
<head> <head>
<link rel="stylesheet" href="{% static 'style.css' %}"> <link rel="stylesheet" href="{% static 'style.css' %}">
<link rel="icon" type="image/svg+xml" href="{% static 'logo.svg' %}"> <link rel="icon" type="image/svg+xml" href="{% static 'logo.svg' %}">
<link rel="preconnect" href="https://fonts.gstatic.com"> <link href='https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.0/css/all.min.css' rel='stylesheet'>
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:ital@0;1&display=swap" rel="stylesheet"> <link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,200;0,400;1,100&amp;display=swap"
rel="stylesheet">
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Courier+Prime&display=swap" rel="stylesheet">
<title> Ethereal 13.75 (NNUE) </title> <!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.3.1/dist/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
<style>
body { <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"
background: #202020; integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo"
transform: scale(1.05); crossorigin="anonymous"></script>
} <script src="https://cdn.jsdelivr.net/npm/popper.js@1.14.7/dist/umd/popper.min.js"
integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1"
crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.3.1/dist/js/bootstrap.min.js"
integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM"
crossorigin="anonymous"></script>
#content { <link rel="preconnect" href="https://fonts.gstatic.com">
font-family: "Open Sans", sans-serif; <link href="https://fonts.googleapis.com/css2?family=Open+Sans:ital@0;1&display=swap" rel="stylesheet">
}
#content h1 { <title> Ethereal 13.75 (NNUE) </title>
font-size: 64px;
font-weight: bold;
margin: 20px 0px;
color: #00AF00;
font-style: italic;
}
#content p { <style>
font-size: 16px; body, html, :root {
margin: 16px 100px; height: 100%;
text-align: justify }
} </style>
</head>
#content #buyethereal { <body class="w-100 h-100">
font-size: 32px; <div class="container-fluid h-100">
display: block; <div class="container h-100" style="max-width: 1500px">
border-radius: 8px; <div class="min-vh-100 d-flex align-items-center">
color: black; <div class="jumbotron container align-items-center text-center">
font-weight: bold; {# <img class="w-100 mw-100" src="https://github.com/AndyGrant/Ethereal/blob/master/logo.png?raw=true">#}
background: #00AF00; <h1 class="mb-5"> <strong>Ethereal 13.75</strong> </h1>
text-align: center;
margin-top: 20px;
line-height: 64px;
border-color: black;
margin: 0px 100px;
}
</style> <p> Ethereal 13.75 (NNUE) has been released. Since 13.50, a large number of changes have been made to
</head> improve the search, time management, and NNUE architecture and training methods. Ethereal has
received multiple iterations of NNUE updates since 13.50, finally arriving at a pair of newly
trained Networks that are larger, but still faster than previous Networks. These Networks are
trained using the sum total of training data built up since 13.00.</p>
<body> <p> Ethereal 13.75 (NNUE) once again includes two NNUE Networks for evaluation. These Networks continue
<div id="content"> Ethereal's long standing legacy of original work. These Networks are not trained on, nor duplicated
from the works of any other Computer Chess team. With it, Ethereal continues to refine new ideas and
techniques, allowing older processors to outperform NNUE implementations found in other engines,
while still harnessing the full power of the AVX/AVX2 instruction sets for CPUs with support. </p>
<h1> Ethereal 13.75 </h1> <p> Additionally, Ethereal 13.00 was the first engine to offer a secondary Network trained exclusively
for Fischer Random Chess (FRC). Ethereal 13.75 once again provides a secondary Network, updated with
all of the improvements found between releases. This Network outperforms the standard Network by
significant margins in FRC play, showcasing a creative style by Ethereal, not reliant on Opening
Theory.</p>
<p> Ethereal 13.75 (NNUE) has been released. Since 13.50, a large number of changes have been made to improve the search, time management, and NNUE architecture and training methods. Ethereal has received multiple iterations of NNUE updates since 13.50, finally arriving at a pair of newly trained Networks that are larger, but still faster than previous Networks. These Networks are trained using the sum total of training data built up since 13.00.</p> <p> The commercial NNUE version requires a CPU with the SSSE3 instruction set (which almost all CPUs
have), and will not run on systems lacking these instructions. AVX/AVX2 have become ubiquitous in
modern processor design, and are necessary to capitalize on the full strength of Neural Network
technology. If you are unsure if your system is supported, please reach out to me via email at <a>andrew@grantnet.us</a>
for assistance. </p>
<p> Ethereal 13.75 (NNUE) once again includes two NNUE Networks for evaluation. These Networks continue Ethereal's long standing legacy of original work. These Networks are not trained on, nor duplicated from the works of any other Computer Chess team. With it, Ethereal continues to refine new ideas and techniques, allowing older processors to outperform NNUE implementations found in other engines, while still harnessing the full power of the AVX/AVX2 instruction sets for CPUs with support. </p> <p><a href="https://stripe.com">Stripe</a> will verify your payment of $40 USD. Afterwards, you will
receive an email from <a>andrew@grantnet.us</a> or <a>andrewgrantethereal@gmail.com</a> within 24
hours containing a download link for the Standard/Fischer NNUE Networks, as well as the binary or
executable files for Windows and Linux. You should select the binary matching your Operating System.
Users with Intel CPUs containing BMI2 support (Also known as PEXT), should use the pext binary for
optimal performance. AMD CPU users should use the popcnt binary, unless they have a 5XXX series
Ryzen. AVX2 binaries will be the fastest, followed by AVX, and finally SSSE3. You should use the
fastest your CPU allows. </p>
<p> Additionally, Ethereal 13.00 was the first engine to offer a secondary Network trained exclusively for Fischer Random Chess (FRC). Ethereal 13.75 once again provides a secondary Network, updated with all of the improvements found between releases. This Network outperforms the standard Network by significant margins in FRC play, showcasing a creative style by Ethereal, not reliant on Opening Theory.</p> <p> If you purchased Ethereal 13.00, or 13.25, or 13.50, you should have received an email containing
updates to 13.75 free of charge. If you did not, and the email cannot be found in your spam folder,
please reach out to me via <a>andrew@grantnet.us</a> or <a>andrewgrantethereal@gmail.com.</p>
<p> The commercial NNUE version requires a CPU with the SSSE3 instruction set (which almost all CPUs have), and will not run on systems lacking these instructions. AVX/AVX2 have become ubiquitous in modern processor design, and are necessary to capitalize on the full strength of Neural Network technology. If you are unsure if your system is supported, please reach out to me via email at <a>andrew@grantnet.us</a> for assistance. </p> <br>
<p> <a href="https://stripe.com">Stripe</a> will verify your payment of $40 USD. Afterwards, you will receive an email from <a>andrew@grantnet.us</a> or <a>andrewgrantethereal@gmail.com</a> within 24 hours containing a download link for the Standard/Fischer NNUE Networks, as well as the binary or executable files for Windows and Linux. You should select the binary matching your Operating System. Users with Intel CPUs containing BMI2 support (Also known as PEXT), should use the pext binary for optimal performance. AMD CPU users should use the popcnt binary, unless they have a 5XXX series Ryzen. AVX2 binaries will be the fastest, followed by AVX, and finally SSSE3. You should use the fastest your CPU allows. </p> {# <button class="btn btn-primary" id="buyethereal" href="https://buy.stripe.com/aEU7wz19x7EGbJeaEG"> Buy#}
{# Ethereal 13.75 (NNUE)#}
<p> If you purchased Ethereal 13.00, or 13.25, or 13.50, you should have received an email containing updates to 13.75 free of charge. If you did not, and the email cannot be found in your spam folder, please reach out to me via <a>andrew@grantnet.us</a> or <a>andrewgrantethereal@gmail.com.</p> {# <span class="position-absolute top-0 start-100 translate-middle badge rounded-pill bg-danger">#}
{# Special Offer!#}
<br> {# </span>#}
{# </button>#}
<a id="buyethereal" href="https://buy.stripe.com/aEU7wz19x7EGbJeaEG"> Buy Ethereal 13.75 (NNUE) </a> <button type="button" class="btn btn-primary position-relative" id="buyethereal" href="https://buy.stripe.com/aEU7wz19x7EGbJeaEG">
Buy Ethereal 13.75 (NNUE)
<span class="position-absolute top-0 start-100 translate-middle badge rounded-pill bg-danger">
Christmas Offer
</span>
</button>
</div>
</div> </div>
</body> </div>
</div>
{# <div id="content">#}
{##}
{# <h1> Ethereal 13.75 </h1>#}
{##}
{# <p> Ethereal 13.75 (NNUE) has been released. Since 13.50, a large number of changes have been made to improve the search, time management, and NNUE architecture and training methods. Ethereal has received multiple iterations of NNUE updates since 13.50, finally arriving at a pair of newly trained Networks that are larger, but still faster than previous Networks. These Networks are trained using the sum total of training data built up since 13.00.</p>#}
{##}
{# <p> Ethereal 13.75 (NNUE) once again includes two NNUE Networks for evaluation. These Networks continue Ethereal's long standing legacy of original work. These Networks are not trained on, nor duplicated from the works of any other Computer Chess team. With it, Ethereal continues to refine new ideas and techniques, allowing older processors to outperform NNUE implementations found in other engines, while still harnessing the full power of the AVX/AVX2 instruction sets for CPUs with support. </p>#}
{##}
{# <p> Additionally, Ethereal 13.00 was the first engine to offer a secondary Network trained exclusively for Fischer Random Chess (FRC). Ethereal 13.75 once again provides a secondary Network, updated with all of the improvements found between releases. This Network outperforms the standard Network by significant margins in FRC play, showcasing a creative style by Ethereal, not reliant on Opening Theory.</p>#}
{##}
{# <p> The commercial NNUE version requires a CPU with the SSSE3 instruction set (which almost all CPUs have), and will not run on systems lacking these instructions. AVX/AVX2 have become ubiquitous in modern processor design, and are necessary to capitalize on the full strength of Neural Network technology. If you are unsure if your system is supported, please reach out to me via email at <a>andrew@grantnet.us</a> for assistance. </p>#}
{##}
{# <p> <a href="https://stripe.com">Stripe</a> will verify your payment of $40 USD. Afterwards, you will receive an email from <a>andrew@grantnet.us</a> or <a>andrewgrantethereal@gmail.com</a> within 24 hours containing a download link for the Standard/Fischer NNUE Networks, as well as the binary or executable files for Windows and Linux. You should select the binary matching your Operating System. Users with Intel CPUs containing BMI2 support (Also known as PEXT), should use the pext binary for optimal performance. AMD CPU users should use the popcnt binary, unless they have a 5XXX series Ryzen. AVX2 binaries will be the fastest, followed by AVX, and finally SSSE3. You should use the fastest your CPU allows. </p>#}
{##}
{# <p> If you purchased Ethereal 13.00, or 13.25, or 13.50, you should have received an email containing updates to 13.75 free of charge. If you did not, and the email cannot be found in your spam folder, please reach out to me via <a>andrew@grantnet.us</a> or <a>andrewgrantethereal@gmail.com.</p>#}
{##}
{# <br>#}
{##}
{# <a id="buyethereal" href="https://buy.stripe.com/aEU7wz19x7EGbJeaEG"> Buy Ethereal 13.75 (NNUE) </a>#}
{# </div>#}
</body>
</html> </html>
+40 -17
View File
@@ -4,31 +4,54 @@
{% block content %} {% block content %}
<table> <table class="table table-striped table-sm table-hover">
<thead class="bg-black">
<tr> <tr>
<th>Date</th> <th style="color:green">Date</th>
<th>User</th> <th style="color:green">User</th>
<th>Test</th> <th style="color:green">Test</th>
<th>Worker</th> <th style="color:green">Worker</th>
<th>TC</th> <th style="color:green">TC</th>
<th>Summary</th> <th style="color:green">Summary</th>
<th>Logs</th> <th style="color:green">Logs</th>
</tr> </tr>
</thead>
{% for event in events %} {% for event in events %}
<tr> <tr>
<td class="timestamp">{{event.created|date:'U'}}</td> <td class="timestamp">
<td>{{event.author|capfirst}}</td> {{ event.created|date:'U' }}
<td><a href="/test/{{event.test_id}}">{{event.test_id|testIdToPrettyName}}</a></td> </td>
<td>{% if event.machine_id %} {{event.machine_id}} {% endif %}</td> <td>
<td>{{event.test_id|testIdToTimeControl}}</td> {{ event.author|capfirst }}
<td>{{event.summary}}</td> </td>
<td>{% if event.log_file %}<a href='/event/{{event.id}}'>View</a>{% endif %}</td> <td>
<a class="text-decoration-none" href="/test/{{ event.test_id }}">
{{ event.test_id|testIdToPrettyName }}
</a>
</td>
<td>
{% if event.machine_id %}
{{ event.machine_id }}
{% endif %}
</td>
<td>
{{ event.test_id|testIdToTimeControl }}
</td>
<td>
{{ event.summary }}
</td>
<td>
{% if event.log_file %}
<a href='/event/{{ event.id }}'>
<i class="fa fa-download"></i>
</a>
{% endif %}
</td>
</tr> </tr>
{% endfor %} {% endfor %}
<table> </table>
{% include "OpenBench/Blocks/pagebrowser.html" %} {% include "OpenBench/Blocks/pagebrowser.html" %}
+59 -19
View File
@@ -2,37 +2,77 @@
{% block content %} {% block content %}
<table class="datatable"> {% if paging.page == 1 %}
{% if pending %}
<!-- Only show Pending tests for the front page of the Index --> <div class="align-self-center w-100 text-center mt-4 bg-black font-weight-bold mb-0 py-2 rounded-top" style="color:green;">
{% if paging.page == 1 %} <h5>
Pending
<!-- Currently Pending tests (Waiting to be approved) --> </h5>
{% if pending %} </div>
<tr><th colspan='6'>Pending</th></tr> <table class="table table-sm table-hover table-striped datatable">
<thead class="bg-black">
<tr>
<th class="px-3" style="width:10%; color:green;" scope="col">Author</th>
<th class="px-3" style="width:10%; color:green;" scope="col">Engine</th>
<th class="px-3" style=" color:green;" scope="col">Name</th>
<th class="px-3 text-center" style="width: 5%; color:green;" scope="col"><i class="fa-brands fa-github"></i></th>
<th class="px-3 text-center" style="width:12%; color:green;" scope="col">TC <i class="fa-solid fa-clock"></i></th>
<th class="px-3" style=" color:green;" scope="col">Result</th>
</tr>
</thead>
{% for test in pending %} {% for test in pending %}
{% include "OpenBench/Blocks/testsummary.html" %} {% include "OpenBench/Blocks/testsummary.html" %}
{% endfor %} {% endfor %}
<tr class="table-spacer"><th></th></tr> <tr class="table-spacer">
{% endif %} <th></th>
</tr>
</table>
{% endif %}
<!-- Currently Running tests (Waiting to be completed) --> {% if active %}
{% if active %} <div class="align-self-center w-100 text-center mt-4 bg-black font-weight-bold mb-0 py-2 rounded-top" style="color:green;">
<tr><th colspan='6'>Active {{status}}</th></tr> <h5>
Active {{ status }}
</h5>
</div>
<table class="table table-sm table-hover table-striped datatable" style="table-layout: fixed">
<thead class="bg-black">
<tr>
<th class="px-3" style="width:10%; color:green;" scope="col">Author</th>
<th class="px-3" style="width:10%; color:green;" scope="col">Engine</th>
<th class="px-3" style=" color:green;" scope="col">Name</th>
<th class="px-3 text-center" style="width: 5%; color:green;" scope="col"><i class="fa-brands fa-github"></i></th>
<th class="px-3 text-center" style="width:12%; color:green;" scope="col">TC <i class="fa-solid fa-clock"></i></th>
<th class="px-3" style=" color:green;" scope="col">Result</th>
</tr>
</thead>
{% for test in active %} {% for test in active %}
{% include "OpenBench/Blocks/testsummary.html" %} {% include "OpenBench/Blocks/testsummary.html" %}
{% endfor %} {% endfor %}
<tr class="table-spacer"><th></th></tr> </table>
{% endif %}
{% endif %} {% endif %}
{% endif %}
<!-- Tests which have already finished -->
<tr><th colspan='6'>Finished</th></tr> <div class="align-self-center w-100 text-center mt-4 bg-black font-weight-bold mb-0 py-2 rounded-top" style="color:green;">
<h5>
Finished
</h5>
</div>
<table class="mw-100 table table-sm table-hover table-striped datatable" style="table-layout: fixed">
<thead class="bg-black">
<tr>
<th class="px-3" style="width:10%; color:green;" scope="col">Author</th>
<th class="px-3" style="width:10%; color:green;" scope="col">Engine</th>
<th class="px-3" style=" color:green;" scope="col">Name</th>
<th class="px-3 text-center" style="width: 5%; color:green;" scope="col"><i class="fa-brands fa-github"></i></th>
<th class="px-3 text-center" style="width:12%; color:green;" scope="col">TC <i class="fa-solid fa-clock"></i></th>
<th class="px-3" style=" color:green;" scope="col">Result</th>
</tr>
</thead>
{% for test in completed %} {% for test in completed %}
{% include "OpenBench/Blocks/testsummary.html" %} {% include "OpenBench/Blocks/testsummary.html" %}
{% endfor %} {% endfor %}
</table> </table>
{% include "OpenBench/Blocks/pagebrowser.html" %} {% include "OpenBench/Blocks/pagebrowser.html" %}
+15 -3
View File
@@ -4,9 +4,21 @@
<form method="POST" action="/login/"> <form method="POST" action="/login/">
{% csrf_token %} {% csrf_token %}
<label type="text">Username</label> <input type="text" name="username"><br> <div class="form-group">
<label type="text">Password</label> <input type="password" name="password"><br> <div class="row">
<input type="submit" name="submit" value="Login"> <div class="col-12 col-xl-6">
<label for="login-username-input">Username</label>
<input class="form-control" id="login-username-input" type="text" name="username" placeholder="Your Username"><br>
</div>
<div class="col-12 col-xl-6">
<label for="login-password-input">Password</label>
<input class="form-control" id="login-username-input" type="password" name="password" placeholder="Your Password"><br>
</div>
</div>
<input class="btn btn-primary" type="submit" name="submit" value="Login">
</div>
{# <label type="text">Username</label> <input type="text" name="username"><br>#}
{# <label type="text">Password</label> <input type="password" name="password"><br>#}
</form> </form>
{% endblock %} {% endblock %}
+17 -17
View File
@@ -4,27 +4,27 @@
{% block content %} {% block content %}
<table> <table class="table table-striped table-sm table-hover">
<thead class="bg-black">
<tr> <tr>
<th>#</th> <th style="color:green;">#</th>
<th>User</th> <th style="color:green;">User</th>
<th>System</th> <th style="color:green;">System</th>
<th>Updated</th> <th style="color:green;">Updated</th>
<th>Workload</th> <th style="color:green;">Workload</th>
<th>Threads</th> <th style="color:green;">Threads</th>
<th>MNPS</th> <th style="color:green;">MNPS</th>
</tr> </tr>
</thead>
{% for machine in machines %} {% for machine in machines %}
<tr> <tr>
<td class="numeric">{{machine.id}}</td> <td class="numeric">{{ machine.id }}</td>
<td>{{machine.user.username|capfirst}}</td> <td>{{ machine.user.username|capfirst }}</td>
<td>{{machine.osname|truncatewords:1|slice:":-2"}}</td> <td>{{ machine.osname|truncatewords:1|slice:":-2" }}</td>
<td class="timestamp">{{machine.updated|date:'U'}}</td> <td class="timestamp">{{ machine.updated|date:'U' }}</td>
<td> <a href="/test/{{machine.workload.id}}">{{machine.workload.dev.name|prettyName}}</a></td> <td><a href="/test/{{ machine.workload.id }}">{{ machine.workload.dev.name|prettyName }}</a></td>
<td class="numeric">{{machine.threads}}</td> <td class="numeric">{{ machine.threads }}</td>
<td class="numeric">{{machine.mnps|twoDigitPrecision}}</td> <td class="numeric">{{ machine.mnps|twoDigitPrecision }}</td>
</tr> </tr>
{% endfor %} {% endfor %}
+12 -10
View File
@@ -55,16 +55,18 @@
{% block content %} {% block content %}
<table id="network-table"> <table class="table table-striped table-hover table-sm" id="network-table">
<tr> <thead class="bg-black">
<th onclick=sort_networks("default")></th> <tr>
<th onclick=sort_networks("engine")>Engine</th> <th style="color:green" onclick=sort_networks("default")></th>
<th onclick=sort_networks("author")>Uploader</th> <th style="color:green" onclick=sort_networks("engine")>Engine</th>
<th onclick=sort_networks("name")>Name</th> <th style="color:green" onclick=sort_networks("author")>Uploader</th>
<th onclick=sort_networks("hash")>Hash</th> <th style="color:green" onclick=sort_networks("name")>Name</th>
<th></th> <th style="color:green" onclick=sort_networks("hash")>Hash</th>
</tr> <th></th>
</tr>
</thead>
{% for network in networks %} {% for network in networks %}
<tr> <tr>
@@ -82,7 +84,7 @@
<td>{{network.sha256}}</td> <td>{{network.sha256}}</td>
<td><a class="redlink" onclick="return confirm('YOU ARE DELETING THIS NETWORK FILE FOREVER')" href="/networks/delete/{{network.sha256}}"> <td><a class="redlink" onclick="return confirm('YOU ARE DELETING THIS NETWORK FILE FOREVER')" href="/networks/delete/{{network.sha256}}">
<i class="fas fa-minus-circle"></i></a></td> <i class="fas fa-trash"></i></a></td>
</tr> </tr>
{% endfor %} {% endfor %}
+314 -177
View File
@@ -3,179 +3,184 @@
{% block scripts %} {% block scripts %}
var Configurations = { var Configurations = {
{% for name, data in config.engines.items %} {% for name, data in config.engines.items %}
'{{name}}' : { '{{ name }}' : {
'base' : "{{data.base}}", 'base' : "{{ data.base }}",
'book' : "{{data.book}}", 'book' : "{{ data.book }}",
'bounds' : "{{data.bounds}}", 'bounds' : "{{ data.bounds }}",
}, },
{% endfor %} {% endfor %}
}; };
var TestModes = { var TestModes = {
{% for name, data in config.engines.items %} {% for name, data in config.engines.items %}
'{{name}}' : [ '{{ name }}' : [
{% for mode in data.testmodes %} {% for mode in data.testmodes %}
{ {
{% for key, value in mode.items %} {% for key, value in mode.items %}
'{{key}}' : '{{value}}', '{{ key }}' : '{{ value }}',
{% endfor %} {% endfor %}
}, },
{% endfor %}
],
{% endfor %} {% endfor %}
],
{% endfor %}
}; };
var Networks = [ var Networks = [
{% for network in networks %} {% for network in networks %}
{ {
"name" : "{{network.name}}", "name" : "{{ network.name }}",
"sha256" : "{{network.sha256}}", "sha256" : "{{ network.sha256 }}",
"engine" : "{{network.engine}}", "engine" : "{{ network.engine }}",
"default" : "{{network.default}}", "default" : "{{ network.default }}",
}, },
{% endfor %} {% endfor %}
]; ];
function set_test_type(type) { function set_test_type(type) {
//// When the test mode is set or changed, run this. //// When the test mode is set or changed, run this.
//// Sets the bounds, confidence intervals, and max games fields. //// Sets the bounds, confidence intervals, and max games fields.
var selectA = document.getElementById("test_mode"); var selectA = document.getElementById("test_mode");
var mode = selectA.options[selectA.selectedIndex].value; var mode = selectA.options[selectA.selectedIndex].value;
var selectB = document.getElementById("enginename"); var selectB = document.getElementById("enginename");
var engine = selectB.options[selectB.selectedIndex].value; var engine = selectB.options[selectB.selectedIndex].value;
if (mode == "SPRT") { if (mode == "SPRT") {
document.getElementById("test_bounds").value = Configurations[engine]["bounds"] document.getElementById("test_bounds").value = Configurations[engine]["bounds"]
document.getElementById("test_confidence").value = "{{config.tests.confidence}}"; document.getElementById("test_confidence").value = "{{ config.tests.confidence }}";
document.getElementById("test_max_games").value = "N/A"; document.getElementById("test_max_games").value = "N/A";
} }
if (mode == "GAMES") { if (mode == "GAMES") {
document.getElementById("test_bounds").value = "N/A"; document.getElementById("test_bounds").value = "N/A";
document.getElementById("test_confidence").value = "N/A"; document.getElementById("test_confidence").value = "N/A";
document.getElementById("test_max_games").value = "{{config.tests.max_games}}"; document.getElementById("test_max_games").value = "{{ config.tests.max_games }}";
} }
} }
function set_test_mode(mode_idx) { function set_test_mode(mode_idx) {
//// Sets any of the possible following options: //// Sets any of the possible following options:
//// Threads, Hash, Book, time Control, Test Mode, Bounds, Games //// Threads, Hash, Book, time Control, Test Mode, Bounds, Games
var selection = document.getElementById("enginename"); var selection = document.getElementById("enginename");
var engine = selection.options[selection.selectedIndex].value; var engine = selection.options[selection.selectedIndex].value;
var mode = TestModes[engine][mode_idx]; var mode = TestModes[engine][mode_idx];
if (mode["th"] != null && mode["hash"] != null) { if (mode["th"] != null && mode["hash"] != null) {
var threads = mode["th"]; var hash = mode["hash"]; var threads = mode["th"]; var hash = mode["hash"];
document.getElementById("devoptions").value = "Threads=" + threads + " Hash=" + hash; document.getElementById("devoptions").value = "Threads=" + threads + " Hash=" + hash;
document.getElementById("baseoptions").value = "Threads=" + threads + " Hash=" + hash; document.getElementById("baseoptions").value = "Threads=" + threads + " Hash=" + hash;
} }
if (mode["book"] != null) { if (mode["book"] != null) {
document.getElementById("bookname").value = mode["book"] document.getElementById("bookname").value = mode["book"]
} }
if (mode["tc"] != null) { if (mode["tc"] != null) {
document.getElementById("timecontrol").value = mode["tc"];; document.getElementById("timecontrol").value = mode["tc"];;
} }
if (mode["bounds"] != null) { if (mode["bounds"] != null) {
document.getElementById("test_mode").value = "SPRT"; set_test_type(); document.getElementById("test_mode").value = "SPRT"; set_test_type();
document.getElementById("test_bounds").value = mode["bounds"]; document.getElementById("test_bounds").value = mode["bounds"];
} }
if (mode["games"] != null) { if (mode["games"] != null) {
document.getElementById("test_mode").value = "GAMES"; set_test_type(); document.getElementById("test_mode").value = "GAMES"; set_test_type();
document.getElementById("test_max_games").value = mode["games"]; document.getElementById("test_max_games").value = mode["games"];
} }
// Default back when not specified // Default back when not specified
if (mode["bounds"] == null && mode["games"] == null) { if (mode["bounds"] == null && mode["games"] == null) {
document.getElementById("test_mode").value = "SPRT"; set_test_type(); document.getElementById("test_mode").value = "SPRT"; set_test_type();
} }
if (mode["book"] == null) { if (mode["book"] == null) {
document.getElementById("bookname").value = Configurations[engine]["book"]; document.getElementById("bookname").value = Configurations[engine]["book"];
} }
} }
function set_engine(engine) { function set_engine(engine) {
//// Creates a button to setup test modes, as specififed in the Engine's //// Creates a button to setup test modes, as specififed in the Engine's
//// entry in config.py. Also sets the opening book, and default base branch //// entry in config.py. Also sets the opening book, and default base branch
//// based on the same config entry. Finally, creates a list of all uploaded //// based on the same config entry. Finally, creates a list of all uploaded
//// Network files that can be selected. The default Network is set as such, //// Network files that can be selected. The default Network is set as such,
//// if it exists. In all cases, a blank Network is included in the options. //// if it exists. In all cases, a blank Network is included in the options.
document.getElementById("enginename").value = engine; document.getElementById("enginename").value = engine;
var button_div = document.getElementById("test-mode-buttons"); var button_div = document.getElementById("test-mode-buttons");
while (button_div.hasChildNodes()) button_div.removeChild(button_div.lastChild); while (button_div.hasChildNodes()) button_div.removeChild(button_div.lastChild);
for (let i in TestModes[engine]) { for (let i in TestModes[engine]) {
const btn = document.createElement('button') const btn = document.createElement('button')
btn.innerHTML = TestModes[engine][i]["id"]; btn.innerHTML = TestModes[engine][i]["id"];
btn.onclick = function() { set_test_mode(i); }; btn.onclick = function(e) {
btn.class = (i % 2) ? "left-floated" : "right-floated"; set_test_mode(i);
button_div.append(btn); console.log(i);
} e.preventDefault();}
;
btn.classList.add('btn');
btn.classList.add('btn-secondary', 'mr-1');
button_div.append(btn);
}
var devnet = document.getElementById("devnetwork"); var devnet = document.getElementById("devnetwork");
var basenet = document.getElementById("basenetwork"); var basenet = document.getElementById("basenetwork");
var hasdefault = false; var hasdefault = false;
while (devnet.length) devnet.remove(0); while (devnet.length) devnet.remove(0);
while (basenet.length) basenet.remove(0); while (basenet.length) basenet.remove(0);
for (const network of Networks) { for (const network of Networks) {
if (network.engine !== engine) continue; if (network.engine !== engine) continue;
var devopt = document.createElement("option"); var devopt = document.createElement("option");
var baseopt = document.createElement("option"); var baseopt = document.createElement("option");
devopt.text = baseopt.text = network.name; devopt.text = baseopt.text = network.name;
devopt.value = baseopt.value = network.sha256; devopt.value = baseopt.value = network.sha256;
devopt.selected = network.default == "True"; devopt.selected = network.default == "True";
baseopt.selected = network.default == "True"; baseopt.selected = network.default == "True";
devnet.add(devopt); basenet.add(baseopt); devnet.add(devopt); basenet.add(baseopt);
hasdefault = (hasdefault || (network.default == "True")); hasdefault = (hasdefault || (network.default == "True"));
} }
{ {
var devopt = document.createElement("option"); var devopt = document.createElement("option");
var baseopt = document.createElement("option"); var baseopt = document.createElement("option");
devopt.text = baseopt.text = "None"; devopt.text = baseopt.text = "None";
devopt.value = baseopt.value = ""; devopt.value = baseopt.value = "";
devopt.selected = (hasdefault == false); devnet.add(devopt); devopt.selected = (hasdefault == false); devnet.add(devopt);
baseopt.selected = (hasdefault == false); basenet.add(baseopt); baseopt.selected = (hasdefault == false); basenet.add(baseopt);
} }
var base_branch = document.getElementById("basebranch"); var base_branch = document.getElementById("basebranch");
base_branch.value = Configurations[engine]["base"]; base_branch.value = Configurations[engine]["base"];
var book_selection = document.getElementById("bookname"); var book_selection = document.getElementById("bookname");
book_selection.value = Configurations[engine]["book"]; book_selection.value = Configurations[engine]["book"];
} }
document.addEventListener( document.addEventListener(
'DOMContentLoaded', function () { 'DOMContentLoaded', function () {
set_test_type(); set_test_type();
set_engine("{{profile.engine}}"); set_engine("{{ profile.engine }}");
set_test_mode(0); set_test_mode(0);
}, false }, false
); );
{% endblock %} {% endblock %}
@@ -184,73 +189,205 @@
<form method="POST" action="/newTest/"> <form method="POST" action="/newTest/">
{% csrf_token %} {% csrf_token %}
<div class="settings-column">
<h3> Engine </h3> <div class="row">
<label> Engine </label> <select id="enginename" name="enginename" onchange="set_engine(value);"> <div class="col-12 col-xl-6">
{% for engine in config.engines %} <div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
<option value="{{engine}}">{{engine}}</option> {# <h3>Engine</h3>#}
{% endfor %} <div class="form">
</select><br> <div class="row">
<label> Source </label> <input value="{{profile.repo}}" name="source"><br> <div class="col-3 pb-2 d-flex align-items-center">
<span for="enginename">Engine</span>
</div>
<div class="col-9 mb-2">
<select class="form-control form-select" id="enginename" name="enginename"
onchange="set_engine(value);">
{% for engine in config.engines %}
<option value="{{ engine }}">{{ engine }}</option>
{% endfor %}
</select>
</div>
<div class="col-3 d-flex align-items-center">
<label for="enginesource">Source</label>
</div>
<div class="col-9">
<input class="form-control" id="enginesource" value="{{ profile.repo }}"
name="source">
</div>
</div>
</div>
</div>
<div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
{# <h3>Dev Settings</h3>#}
<div class="form row">
<div class="col-3 pb-2 d-flex align-items-center">
<label for="devbench"> Dev Bench </label>
</div>
<div class="col-9 mb-2">
<input id="devbench" class="form-control"
name="devbench">
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="devbranch"> Dev Branch </label>
</div>
<div class="col-9 mb-2">
<input id="devbranch" class="form-control"
name="devbranch" autofocus>
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="devoptions"> Dev Options </label>
</div>
<div class="col-9 mb-2">
<input id="devoptions"
class="form-control"
name="devoptions">
</div>
<div class="col-3 d-flex align-items-center">
<label for="devnetwork"> Dev Network </label></div>
<div class="col-9">
<select id="devnetwork"
class="form-control form-select"
name="devnetwork"></select>
</div>
</div>
</div>
<div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
{# <h3>Base Settings</h3>#}
<div class="form row">
<div class="col-3 pb-2 d-flex align-items-center">
<label for="basebench"> Base Bench </label>
</div>
<div class="col-9 mb-2">
<input id="basebench" class="form-control" name="basebench">
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="basebranch"> Base Branch </label>
</div>
<div class="col-9 mb-2">
<input id="basebranch" class="form-control" name="basebranch">
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="baseoptions"> Base Options </label>
</div>
<div class="col-9 mb-2">
<input id="baseoptions"
class="form-control" name="baseoptions">
</div>
<div class="col-3 d-flex align-items-center">
<label for="basenetwork"> Base Network </label>
</div>
<div class="col-9">
<select id="basenetwork" class="form-control form-select" name="basenetwork"></select>
</div>
</div>
</div>
</div>
<div class="col-12 col-xl-6">
<div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
<div class="form row">
<div class="col-3 pb-2 d-flex align-items-center">
<label for="test_mode"> Test Mode </label>
</div>
<div class="col-9 mb-2">
<select id="test_mode" class="form-control form-select" onchange='set_test_type()'
name="test_mode">
<option selected value="SPRT"> SPRT</option>
<option value="GAMES"> Fixed Games</option>
</select>
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="test_bounds"> Bounds </label>
</div>
<div class="col-9 mb-2">
<input class="form-control" id="test_bounds"
name="bounds">
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="test_confidence"> Confidence </label>
</div>
<div class="col-9 mb-2">
<input class="form-control" id="test_confidence" name="confidence">
</div>
<div class="col-3 d-flex align-items-center">
<label for="test_max_games"> Max Games </label>
</div>
<div class="col-9">
<input class="form-control" id="test_max_games" name="max_games">
</div>
<h3> Dev Settings </h3> </div>
<label> Dev Bench </label> <input name="devbench"><br>
<label> Dev Branch </label> <input name="devbranch" autofocus><br>
<label> Dev Options </label> <input id="devoptions" name="devoptions"><br>
<label> Dev Network </label> <select id="devnetwork" name="devnetwork"></select><br>
<h3> Base Settings </h3>
<label> Base Bench </label> <input name="basebench"><br>
<label> Base Branch </label> <input id="basebranch" name="basebranch"><br>
<label> Base Options </label> <input id="baseoptions" name="baseoptions"><br>
<label> Base Network </label> <select id="basenetwork" name="basenetwork"></select><br>
</div>
<div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
<div class="form row">
<div class="col-3 pb-2 d-flex align-items-center">
<label for="priority"> Priority </label>
</div>
<div class="col-9 mb-2">
<input id="priority" class="form-control" value="0" name="priority">
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="throughput"> Throughput </label>
</div>
<div class="col-9 mb-2">
<input id="throughput" class="form-control" value="1000" name="throughput">
</div>
<div class="col-3 pb-2 d-flex align-items-center">
<label for="syzygy_adj"> Syzygy ADJ </label>
</div>
<div class="col-9 mb-2">
<select id="syzygy_adj" class="form-control form-select" name="syzygy_adj">
<option selected value="OPTIONAL"> Optional</option>
<option value="REQUIRED"> Required</option>
<option value="DISABLED"> Disabled</option>
</select>
</div>
<div class="col-3 d-flex align-items-center">
<label for="syzygy_wdl"> Syzygy WDL </label>
</div>
<div class="col-9">
<select id="syzygy_wdl" class="form-control form-select" name="syzygy_wdl">
<option value="OPTIONAL"> Optional</option>
<option value="REQUIRED"> Required</option>
<option selected value="DISABLED"> Disabled</option>
</select>
</div>
</div>
</div>
<div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
{# <h3>Game Settings</h3>#}
<div class="form row">
<div class="col-3 pb-2 d-flex align-items-center">
<label for="bookname">Book</label>
</div>
<div class="col-9 mb-2">
<select class="form-control form-select" id="bookname" name="bookname">
{% for name, data in config.books.items %}
<option value="{{ name }}">{{ name }}</option>
{% endfor %}
</select>
</div>
<div class="col-3 d-flex align-items-center">
<label for="timecontrol">Time</label>
</div>
<div class="col-9">
<input class="form-control" id="timecontrol" name="timecontrol">
</div>
</div>
</div>
</div>
</div> </div>
<div class="settings-column"> <div class="mb-3" id="test-mode-buttons">
<!-- Generated based on the selected Engine -->
<h3> Game Settings </h3>
<label> Book </label> <select id="bookname" name="bookname">
{% for name, data in config.books.items %}
<option value="{{name}}">{{name}}</option>
{% endfor %}
</select><br>
<label> Time </label> <input id="timecontrol" name="timecontrol"><br>
<h3> Test Settings </h3>
<label> Test Mode </label> <select onchange='set_test_type()' id="test_mode" name="test_mode">
<option selected value="SPRT"> SPRT </option>
<option value="GAMES"> Fixed Games </option>
</select><br>
<label> Bounds </label> <input id="test_bounds" name="bounds"><br>
<label> Confidence </label> <input id="test_confidence" name="confidence"><br>
<label> Max Games </label> <input id="test_max_games" name="max_games"><br>
<h3> General Settings </h3>
<label> Priority </label> <input value="0" name="priority"><br>
<label> Throughput </label> <input value="1000" id="throughput", name="throughput"><br>
<label> Syzygy ADJ </label> <select name="syzygy_adj">
<option selected value="OPTIONAL"> Optional </option>
<option value="REQUIRED"> Required </option>
<option value="DISABLED"> Disabled </option>
</select><br>
<label> Syzygy WDL </label> <select name="syzygy_wdl">
<option value="OPTIONAL"> Optional </option>
<option value="REQUIRED"> Required </option>
<option selected value="DISABLED"> Disabled </option>
</select><br>
</div> </div>
<input class="btn btn-primary" type="submit" name="submit" value="Create Engine Test">
<br><input type="submit" name="submit" value="Create Engine Test">
</form> </form>
<div id="test-mode-buttons">
<!-- Generated based on the selected Engine -->
</div>
{% endblock %} {% endblock %}
+48 -23
View File
@@ -4,30 +4,55 @@
<form method="POST" action="/profile/"> <form method="POST" action="/profile/">
{% csrf_token %} {% csrf_token %}
<div class="form-group">
<div class="row">
<div class="col-12 col-xl-6">
<label for="profile-username-input">Username</label>
<input class="form-control" id="profile-username-input" disabled readonly
value="{{ profile.user.username }}"><br>
</div>
<div class="col-12 col-xl-6">
<label for="profile-email-input">Email</label>
<input class="form-control" id="profile-email-input" name="email" placeholder="name@example.com"
value="{{ profile.user.email }}"><br>
</div>
<div class="col-12 col-xl-6">
<label for="profile-password-1-input">New Password</label>
<input class="form-control" id="profile-password-1-input" type="password" autocomplete="off" name="password1" placeholder="New password"><br>
</div>
<div class="col-12 col-xl-6">
<label for="profile-password-2-input">New Password</label>
<input class="form-control" id="profile-password-2-input" type="password" autocomplete="off" name="password2" placeholder="Repeat your password"><br>
</div>
<div class="col-12 col-xl-6">
<label for="profile-repo-input">Source Repository</label>
<input class="form-control" id="profile-repo-input" name="repo" value="{{ profile.repo }}"><br>
{# <div class="input-group">#}
{# <span class="input-group-text">https://github.com/</span>#}
{# </div>#}
</div>
<div class="col-12 col-xl-6">
<label for="engine">Engine</label>
<select id="engine" name="engine" class="form-control form-select mb-4"
aria-label="Default select example">
{% for engine in config.engines %}
{% if profile.engine == engine %}
<option selected value="{{ engine }}">{{ engine }}</option>
{% else %}
<option value="{{ engine }}">{{ engine }}</option>
{% endif %}
{% endfor %}
{% if not profile.engine %}
<option selected value=""></option>
{% endif %}
</select>
</div>
<div class="col-12 mt-2">
<input class="btn btn-primary" type="submit" value="Update Profile">
</div>
</div>
<!-- Profile information. Everything may be changed but the Username --> </div>
<label>Username</label><input readonly value="{{profile.user.username}}"><br>
<label>Email</label><input value="{{profile.user.email}}" name="email"><br>
<label>Source Repo</label><input value="{{profile.repo}}" name="repo"><br>
<label>New Password</label><input type="password" name="password1"><br>
<label>New Password</label><input type="password" name="password2"><br>
<!-- User's have a default engine. Select the default, otherwise show an empty line -->
<label>Engine</label> <select id="engine" name="engine">
{% for engine in config.engines %}
{% if profile.engine == engine %}
<option selected value="{{engine}}">{{engine}}</option>
{% else %}
<option value="{{engine}}">{{engine}}</option>
{% endif %}
{% endfor %}
{% if not profile.engine %}
<option selected value=""></option>
{% endif %}
</select><br>
<input type="submit" value="Update Profile">
</form> </form>
{% endblock %} {% endblock %}
+18 -5
View File
@@ -4,11 +4,24 @@
<form id="registerForm" method="POST" action="/register/"> <form id="registerForm" method="POST" action="/register/">
{% csrf_token %} {% csrf_token %}
<label>Username</label> <input name="username"><br> <form>
<label>Password</label> <input type="password" name="password1"><br> <div class="row">
<label>Password</label> <input type="password" name="password2"><br> <div class="col-6">
<label>Email </label> <input name="email"><br> <label for="username">Username</label> <input class="form-control" id="username" name="username"><br>
<input type="submit" name="submit" value="Create User"> </div>
<div class="col-6">
<label for="email">Email </label> <input class="form-control" id="email" name="email"><br>
</div>
<div class="col-6">
<label for="password1">Password</label> <input class="form-control" type="password" id="password1" name="password1" autocomplete="off"><br>
</div>
<div class="col-6">
<label for="password2">Password</label> <input class="form-control" type="password" id="password2" name="password2" autocomplete="off"><br>
</div>
</div>
</form>
<input class="btn btn-primary" type="submit" name="submit" value="Create User">
</form> </form>
{% endblock %} {% endblock %}
+97 -50
View File
@@ -3,15 +3,15 @@
{% block scripts %} {% block scripts %}
function set_default_engine() { function set_default_engine() {
{% if profile.engine %} {% if profile.engine %}
document.getElementById("engine").value = "{{profile.engine}}"; document.getElementById("engine").value = "{{ profile.engine }}";
{% endif %} {% endif %}
} }
document.addEventListener( document.addEventListener(
'DOMContentLoaded', function () { 'DOMContentLoaded', function () {
set_default_engine(); set_default_engine();
}, false }, false
); );
{% endblock %} {% endblock %}
@@ -22,55 +22,102 @@
<form method="POST" action="/search/"> <form method="POST" action="/search/">
{% csrf_token %} {% csrf_token %}
{# <h2>Search for a test</h2>#}
<div class="form-group">
<div class="row">
<div class="col-12">
<div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
<div class="row">
<div class="col-12 col-xl-6 mb-2">
<label for="search-keywords-input">Keywords</label>
<input id="search-keywords-input" class="form-control" name="keywords">
</div>
<div class="col-12 col-xl-6 mb-2">
<label for="search-author-input">Author</label>
<input id="search-author-input" class="form-control" name="author">
</div>
<div class="col-12">
<label for="engine">Engine</label>
<select id="engine" class="form-control form-select" name="engine">
<option selected value="">ALL</option>
{% for name, data in config.engines.items %}
<option value="{{ name }}">{{ name }}</option>
{% endfor %}
</select>
</div>
</div>
</div>
</div>
<label> Keywords </label> <input name="keywords"><br> <div class="col-12">
<label> Author </label> <input name="author"><br> <div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
<div class="row">
<label> Engine </label> <div class="col-12 col-md-4 mb-2">
<select id="engine" name="engine"> <label for="search-show-greens-select"> Show Greens </label>
<option selected value="">ALL</option> <select id="search-show-greens-select" class="form-control form-select"
{% for name, data in config.engines.items %} name="showgreens">
<option value="{{name}}">{{name}}</option> <option selected value="True">True</option>
{% endfor %} <option value="False">False</option>
</select><br> </select>
</div>
<label> Show Greens </label> <div class="col-12 col-md-4 mb-2">
<select name="showgreens"> <label for="search-show-yellows-select"> Show Yellows </label>
<option selected value="True">True</option> <select id="search-show-yellows-select" class="form-control form-select"
<option value="False">False</option> name="showyellows">
</select><br> <option selected value="True">True</option>
<option value="False">False</option>
<label> Show Yellows </label> </select>
<select name="showyellows"> </div>
<option selected value="True">True</option> <div class="col-12 col-md-4 mb-2">
<option value="False">False</option> <label for="search-show-reds-select"> Show Reds </label>
</select><br> <select id="search-show-reds-select" class="form-control form-select"
name="showreds">
<label> Show Reds </label> <option selected value="True">True</option>
<select name="showreds"> <option value="False">False</option>
<option selected value="True">True</option> </select>
<option value="False">False</option> </div>
</select><br> <div class="col-12 col-md-6 mb-2">
<label for="search-show-stopped-select"> Show Stopped </label>
<label> Show Stopped </label> <select id="search-show-stopped-select" class="form-control form-select"
<select name="showunfinished"> name="showunfinished">
<option value="True">True</option> <option selected value="True">True</option>
<option selected value="False">False</option> <option value="False">False</option>
</select><br> </select>
</div>
<label> Show Deleted </label> <div class="col-12 col-md-6 mb-2">
<select name="showdeleted"> <label for="search-show-deleted-select"> Show Deleted </label>
<option value="True">True</option> <select id="search-show-deleted-select" class="form-control form-select"
<option selected value="False">False</option> name="showdeleted">
</select><br> <option selected value="True">True</option>
<option value="False">False</option>
<input type="submit" name="submit" value="Search Tests"> </select>
</div>
</div>
</div>
</div>
<div class="col-12">
<input class="btn btn-primary" type="submit" name="submit" value="Search Tests">
</div>
</div>
</div>
</form> </form>
{% endif %} {% endif %}
<table class="datatable"> <table class="table table-hover table-sm table-striped datatable" style="table-layout: fixed">
<thead class="bg-black rounded-top">
{% if tests != empty %}
<tr>
<th class="px-3" style="width:10%; color:green;" scope="col">Author</th>
<th class="px-3" style="width:10%; color:green;" scope="col">Engine</th>
<th class="px-3" style=" color:green;" scope="col">Name</th>
<th class="px-3 text-center" style="width: 5%; color:green;" scope="col"><i class="fa-brands fa-github"></i></th>
<th class="px-3 text-center" style="width:12%; color:green;" scope="col">TC <i class="fa-solid fa-clock"></i></th>
<th class="px-3" style=" color:green;" scope="col">Result</th>
</tr>
{% endif %}
</thead>
{% for test in tests %} {% for test in tests %}
{% include "OpenBench/Blocks/testsummary.html" %} {% include "OpenBench/Blocks/testsummary.html" %}
{% endfor %} {% endfor %}
+180 -102
View File
@@ -3,104 +3,180 @@
{% load mytags %} {% load mytags %}
{% block style %} {% block style %}
{% load static %} {% load static %}
{% endblock %} {% endblock %}
{% block content %} {% block content %}
<div id="configuration"> <div id="configuration">
<table class="datatable left-align"> <!-- Dev vs Base [Git Diff Link] -->
<tr><th>Author</th><td>{{test.author|capfirst}}</td></tr> <h4 class="mb-4"><a href="{{ test|gitDiffLink }}">
<tr><th>Creation</th><td class="timestamp">{{test.creation|date:'U'}}</td></tr> {{ test.dev.name|prettyName }} vs {{ test.base.name|prettyName }}
<tr><th>Engine</th><td>{{test.engine}}</td></tr> </a></h4>
<tr><th>Dev Branch</th><td>{{test.dev.name|prettyName}}</td></tr> <div class="row">
<tr><th>Dev Bench</th><td>{{test.dev.bench}}</td></tr>
<tr><th>Dev Options</th><td>{{test.devoptions}}</td></tr>
<tr><th>Dev Sha</th><td>{{test.dev.sha}}</td></tr>
{% if test.devnetwork %}
<tr>
<th>Dev Network</th>
<td><a href="{{test.devnetwork|resolveNetworkURL}}">{{test.devnetname}}</td>
</tr>
{% endif %}
<tr><th>Base Branch</th><td>{{test.base.name|prettyName}}</td></tr>
<tr><th>Base Bench</th><td>{{test.base.bench}}</td></tr>
<tr><th>Base Options</th><td>{{test.baseoptions}}</td></tr>
<tr><th>Base Sha</th><td>{{test.base.sha}}</td></tr>
{% if test.basenetwork %}
<tr>
<th>Base Network</th>
<td><a href="{{test.basenetwork|resolveNetworkURL}}">{{test.basenetname}}</td>
</tr>
{% endif %}
<tr><th>Source Repo</th><td><a href="{{test.source}}">{{test.source}}</a></td></tr>
<tr><th>Opening Book</th><td><a href="{{config.framework}}/raw/master/Books/">{{test.bookname}}</a></td></tr>
<tr><th>Syzygy ADJ</th><td>{{test.syzygy_adj}}</td></tr> <div class="col-12 col-xl-6">
<tr><th>Syzygy WDL</th><td>{{test.syzygy_wdl}}</td></tr> <table class="datatable table table-sm left-align">
</table> <tr>
<th>Author</th>
<td>{{ test.author|capfirst }}</td>
</tr>
<tr>
<th>Creation</th>
<td class="timestamp">{{ test.creation|date:'U' }}</td>
</tr>
<tr>
<th>Engine</th>
<td>{{ test.engine }}</td>
</tr>
<tr>
<th>Dev Branch</th>
<td>{{ test.dev.name|prettyName }}</td>
</tr>
<tr>
<th>Dev Bench</th>
<td>{{ test.dev.bench }}</td>
</tr>
<tr>
<th>Dev Options</th>
<td>{{ test.devoptions }}</td>
</tr>
<tr>
<th>Dev Sha</th>
<td>{{ test.dev.sha }}</td>
</tr>
{% if test.devnetwork %}
<tr>
<th>Dev Network</th>
<td><a href="{{ test.devnetwork|resolveNetworkURL }}">{{ test.devnetname }}</a></td>
</tr>
{% endif %}
<tr>
<th>Base Branch</th>
<td>{{ test.base.name|prettyName }}</td>
</tr>
<tr>
<th>Base Bench</th>
<td>{{ test.base.bench }}</td>
</tr>
<tr>
<th>Base Options</th>
<td>{{ test.baseoptions }}</td>
</tr>
<tr>
<th>Base Sha</th>
<td>{{ test.base.sha }}</td>
</tr>
{% if test.basenetwork %}
<tr>
<th>Base Network</th>
<td><a href="{{ test.basenetwork|resolveNetworkURL }}">{{ test.basenetname }}</a></td>
</tr>
{% endif %}
<tr>
<th>Source Repo</th>
<td><a href="{{ test.source }}">{{ test.source }}</a></td>
</tr>
<tr>
<th>Opening Book</th>
<td><a href="{{ config.framework }}/raw/master/Books/">{{ test.bookname }}</a></td>
</tr>
<tr>
<th>Syzygy ADJ</th>
<td>{{ test.syzygy_adj }}</td>
</tr>
<tr>
<th>Syzygy WDL</th>
<td>{{ test.syzygy_wdl }}</td>
</tr>
</table>
</div>
<div class="col-12 col-xl-6">
<div class="row">
<div class="col-3">
<!-- Approve Button: For Admins, or Cross-approvers -->
{% if not test.approved and profile.approver and profile.user.username != test.author %}
<a class="btn btn-success w-100" id="approvebutton" href="/test/{{ test.id }}/APPROVE" role="button">Approve</a>
{% elif not test.approved and request.user.is_superuser %}
<a class="btn btn-success w-100" id="approvebutton" href="/test/{{ test.id }}/APPROVE" role="button">Approve</a>
{% else %}
<a class="btn btn-secondary w-100 disabled"role="button">Approve</a>
{% endif %}
</div>
<div class="col-3">
<!-- Restart Button: For Approvers or Test Authors of finished tests -->
{% if test.finished and profile.approver %}
<a class="btn btn-primary w-100" id="stopbutton" href="/test/{{ test.id }}/RESTART" role="button">Restart</a>
{% elif test.finished and profile.user.username == test.author %}
<a class="btn btn-primary w-100" id="stopbutton" href="/test/{{ test.id }}/RESTART" role="button">Restart</a>
{% elif test.finished %}
<a class="btn btn-secondary w-100" role="button">Restart</a>
{% else %}
<a class="btn btn-secondary w-100 disabled " role="button">Restart</a>
{% endif %}
</div>
<div class="col-3">
<!-- Stop Button: For Approvers or Test Authors of active tests -->
{% if not test.finished and profile.approver %}
<a class="btn btn-danger w-100" id="restartbutton" href="/test/{{ test.id }}/STOP" role="button">Stop</a>
{% elif not test.finished %}
<a class="btn btn-primary w-100 disabled" role="button">Stop</a>
{% else %}
<a class="btn btn-secondary w-100 disabled" role="button">Stop</a>
{% endif %}
</div>
<div class="col-3">
<!-- Delete Button: For Approvers or Test Authors -->
{% if profile.approver or profile.user.username == test.author %}
<a class="btn btn-danger w-100" id="deletebutton" href="/test/{{ test.id }}/DELETE" role="button">Delete</a>
{% else %}
<a class="btn btn-secondary w-100 disabled" role="button">Delete</a>
{% endif %}
</div>
</div>
<!-- Elo, (SPRT/LRR if SPRT, otherwise CONF), Games -->
<pre class="mt-3">{{ test|longStatBlock|linebreaksbr }}</pre>
<!-- Forum to modify the Priority or Throughput -->
<form method="POST" action="/test/{{ test.id }}/MODIFY">
{% csrf_token %}
<div class="form row">
<div class="col-3">
<label>Priority</label>
</div>
<div class="col-9 mb-2">
<input class="form-control" value="{{ test.priority }}" name="priority" id="priority">
</div>
<div class="col-3">
<label>Throughput</label>
</div>
<div class="col-9 mb-2">
<input class="form-control" value="{{ test.throughput }}" name="throughput" id="throughput">
</div>
</div>
<!-- Edit Button: For Approvers or Test Authors -->
{% if profile.approver or profile.user.username == test.author %}
<input class="btn btn-primary" type="submit" name="submit" value="Modify">
{% else %}
<input class="btn btn-primary" disabled type="submit" name="submit" value="Modify">
{% endif %}
</form>
</div>
</div>
</div> </div>
<div id="actions"> <div id="actions">
<!-- Dev vs Base [Git Diff Link] -->
<h4><a href="{{test|gitDiffLink}}">
{{test.dev.name|prettyName}} vs {{test.base.name|prettyName}}
</a></h4>
<!-- Approve Button: For Admins, or Cross-approvers -->
{% if not test.approved and profile.approver and profile.user.username != test.author %}
<a class="anchorbutton" id="approvebutton" href="/test/{{test.id}}/APPROVE">Approve</a>
{% elif not test.approved and request.user.is_superuser %}
<a class="anchorbutton" id="approvebutton" href="/test/{{test.id}}/APPROVE">Approve</a>
{% else %}
<a class="anchorbutton deadbutton">Approve</a>
{% endif %}
<!-- Restart Button: For Approvers or Test Authors of finished tests -->
{% if test.finished and profile.approver %}
<a class="anchorbutton" id="stopbutton" href="/test/{{test.id}}/RESTART">Restart</a>
{% elif test.finished and profile.user.username == test.author %}
<a class="anchorbutton" id="stopbutton" href="/test/{{test.id}}/RESTART">Restart</a>
{% elif test.finished %}
<a class="anchorbutton deadbutton">Restart</a>
{% endif %}
<!-- Stop Button: For Approvers or Test Authors of active tests -->
{% if not test.finished and profile.approver %}
<a class="anchorbutton" id="restartbutton" href="/test/{{test.id}}/STOP">Stop</a>
{% elif not test.finished and profile.user.username == test.author %}
<a class="anchorbutton" id="restartbutton" href="/test/{{test.id}}/STOP">Stop</a>
{% elif not test.finished %}
<a class="anchorbutton deadbutton">Stop</a>
{% endif %}
<!-- Delete Button: For Approvers or Test Authors -->
{% if profile.approver or profile.user.username == test.author %}
<a class="anchorbutton" id="deletebutton" href="/test/{{test.id}}/DELETE">Delete</a>
{% else %}
<a class="anchorbutton deadbutton">Delete</a>
{% endif %}
<!-- Elo, (SPRT/LRR if SPRT, otherwise CONF), Games -->
<pre>{{test|longStatBlock|linebreaksbr}}</pre>
<!-- Forum to modify the Priority or Throughput -->
<form method="POST" action="/test/{{test.id}}/MODIFY">
{% csrf_token %}
<label>Priority</label><input value="{{test.priority}}" name="priority"><br>
<label>Throughput</label><input value="{{test.throughput}}" name="throughput"><br>
<!-- Edit Button: For Approvers or Test Authors -->
{% if profile.approver or profile.user.username == test.author %}
<input type="submit" name="submit" value="Modify">
{% else %}
<input class="deadbutton" type="submit" name="submit" value="Modify">
{% endif %}
</form>
</div> </div>
@@ -108,10 +184,11 @@
<div id="results"> <div id="results">
<table class="datatable"> <table class="table table-sm table-striped table-hover datatable">
<thead>
<tr> <tr>
<th>#</th> <th>Machine ID #</th>
<th>User</th> <th>User</th>
<th>OS</th> <th>OS</th>
<th>Updated</th> <th>Updated</th>
@@ -122,22 +199,23 @@
<th style="width: 60px">Time</th> <th style="width: 60px">Time</th>
<th style="width: 60px">Crash</th> <th style="width: 60px">Crash</th>
</tr> </tr>
</thead>
<tbody>
{% for result in results %} {% for result in results %}
<tr> <tr>
<td>{{result.machine.id}}</td> <td>{{ result.machine.id }}</td>
<td>{{result.machine.user.username|capfirst|slice:"6"}}</td> <td>{{ result.machine.user.username|capfirst|slice:"6" }}</td>
<td>{{result.machine.osname|truncatewords:1|slice:":-2"}}</td> <td>{{ result.machine.osname|truncatewords:1|slice:":-2" }}</td>
<td class="timestamp">{{result.updated|date:'U'}}</td> <td class="timestamp">{{ result.updated|date:'U' }}</td>
<td class="numeric">{{result.games}}</td> <td class="numeric">{{ result.games }}</td>
<td class="numeric">{{result.wins}}</td> <td class="numeric">{{ result.wins }}</td>
<td class="numeric">{{result.losses}}</td> <td class="numeric">{{ result.losses }}</td>
<td class="numeric">{{result.draws}}</td> <td class="numeric">{{ result.draws }}</td>
<td class="numeric">{{result.timeloss}}</td> <td class="numeric">{{ result.timeloss }}</td>
<td class="numeric">{{result.crashes}}</td> <td class="numeric">{{ result.crashes }}</td>
</tr> </tr>
{% endfor %} {% endfor %}
</tbody>
</table> </table>
</div> </div>
+34 -13
View File
@@ -3,22 +3,43 @@
{% block content %} {% block content %}
<form method="post" enctype="multipart/form-data"> <form method="post" enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
<label>Name</label><input name="name"><br> <div class="form">
<label>Weights</label><input name="netfile" type="file"><br>
<label>Engine</label> <select id="engine" name="engine"> <div class="row mb-2">
{% for engine in config.engines %} <div class="col-12">
{% if engine == profile.engine %} <div class="container-fluid py-3 px-2 mb-4 border rounded bg-dark">
<option selected value="{{engine}}">{{engine}}</option> <div class="row">
{% else %} <div class="col-6">
<option value="{{engine}}">{{engine}}</option> <label for="name" class="form-label">Name</label>
{% endif %} <input class="form-control" id="name" name="name"><br>
{% endfor %} </div>
</select><br> <div class="col-6">
<label for="engine" class="form-label">Name</label>
<select class="form-control" id="engine" name="engine">
{% for engine in config.engines %}
{% if engine == profile.engine %}
<option selected value="{{ engine }}">{{ engine }}</option>
{% else %}
<option value="{{ engine }}">{{ engine }}</option>
{% endif %}
{% endfor %}
</select>
</div>
<div class="col-12">
<label for="netfile" class="form-label">Netfile</label>
<input class="form-control" type="file" id="netfile" name="netfile">
</div>
</div>
</div>
</div>
<input type="submit" value="Upload"> </div>
</div>
<input class="btn btn-primary" type="submit" value="Upload">
<form> <form>
{% endblock %} {% endblock %}
+25 -21
View File
@@ -4,35 +4,39 @@
{% block content %} {% block content %}
<table> <table class="table table-hover table-sm table-hover table-striped">
<thead class="bg-black">
<tr> <tr>
<th>Username</th> <th style="color: green" class="px-2">Username</th>
<th>Games</th> <th style="color: green; text-align: center">Games</th>
<th>Tests</th> <th style="color: green; text-align: center">Tests</th>
<th>Engine</th> <th style="color: green">Engine</th>
<th>Default Repository</th> <th style="color: green">Default Repository</th>
</tr> </tr>
</thead>
<thead class="bg-black">
<tr style="font-weight: bold"> <tr style="font-weight: bold">
<th>{{profiles|length}}</th> <th style="color: green"></th>
<th>{{profiles|sumAttributes:"games"|insertCommas}}</th> <th style="color: green; text-align: right">{{ profiles|sumAttributes:"games"|insertCommas }}</th>
<th>{{profiles|sumAttributes:"tests"|insertCommas}}</th> <th style="color: green; text-align: right">{{ profiles|sumAttributes:"tests"|insertCommas }}</th>
<th></th><th></th> <th style="color: green"></th>
<th style="color: green"></th>
</tr> </tr>
</thead>
{% for profile in profiles %} {% for profile in profiles %}
{% if profile.enabled %} {% if profile.enabled %}
{% if profile.games or profile.tests %} {% if profile.games or profile.tests %}
<tr> <tr onclick="window.location='/user/{{ profile.user.username }}'">
<td><a href="/user/{{profile.user.username}}">{{profile.user.username|capfirst}}</a></td> <td><a class="text-decoration-none text-white px-2" href="/user/{{ profile.user.username }}">{{ profile.user.username|capfirst }}</a></td>
<td style="text-align: right">{{profile.games|insertCommas}}</td> <td style="text-align: right">{{ profile.games|insertCommas }}</td>
<td style="text-align: right">{{profile.tests|insertCommas}}</td> <td style="text-align: right">{{ profile.tests|insertCommas }}</td>
<td>{{profile.engine}}</td> <td>{{ profile.engine }}</td>
<td><a href="{{profile.repo}}">{{profile.repo}}</a></td> <td><a href="{{ profile.repo }}">{{ profile.repo }}</a></td>
</tr> </tr>
{% endif %}
{% endif %} {% endif %}
{% endif %}
{% endfor %} {% endfor %}
</table> </table>