Commit 9a46c6eb authored by Markus Scheidgen's avatar Markus Scheidgen
Browse files

Merge branch 'v0.5.3' into 'master'

v0.5.3

See merge request !56
parents e6bbf192 ccb3a4fa
Pipeline #54362 passed with stage
in 23 seconds
......@@ -76,6 +76,7 @@ Open [http://localhost:8888/html/setup.html](http://localhost:8888/html/setup.ht
your browser.
## Change log
Omitted versions are plain bugfix releases with only minor changes and fixes.
### v0.5.2
- allows to download large files over longer time period
......
Subproject commit a824f0f72303bb8e39c8ae7ee710210edc287331
Subproject commit 7863212e4bde3443fae8fbb57caf3b0d95fb28f3
......@@ -77,16 +77,47 @@ def query_uploads(ctx, uploads):
@uploads.command(help='List selected uploads')
@click.argument('UPLOADS', nargs=-1)
@click.option('-c', '--calculations', is_flag=True, help='Show details about calculations.')
@click.option('--ids', is_flag=True, help='Only show a list of ids.')
@click.option('--json', is_flag=True, help='Output a JSON array of ids.')
@click.pass_context
def ls(ctx, uploads):
def ls(ctx, uploads, calculations, ids, json):
_, uploads = query_uploads(ctx, uploads)
def row(upload):
row = [
upload.upload_id,
upload.name,
upload.user_id,
upload.process_status,
upload.tasks_status,
upload.published]
if calculations:
row += [
upload.total_calcs,
upload.failed_calcs,
upload.total_calcs - upload.processed_calcs]
return row
headers = ['id', 'name', 'user', 'process', 'tasks', 'published']
if calculations:
headers += ['calcs', 'failed', 'processing']
if ids:
for upload in uploads:
print(upload.upload_id)
return
if json:
print('[%s]' % ','.join(['"%s"' % upload.upload_id for upload in uploads]))
return
print('%d uploads selected, showing no more than first 10' % uploads.count())
print(tabulate(
[
[upload.upload_id, upload.name, upload.user_id, upload.process_status, upload.published]
for upload in uploads[:10]],
headers=['id', 'name', 'user', 'status', 'published']))
[row(upload) for upload in uploads[:10]],
headers=headers))
@uploads.command(help='Change the owner of the upload and all its calcs.')
......
......@@ -200,7 +200,7 @@ def bar_plot(client, retrieve, metric1, metric2=None, title=None):
@client.command(help='Generate various matplotlib charts')
@click.option('--errors', is_flag=True, help='Two charts with relative and absolute parser/normalizer errors per code.')
@click.option('--x-axis', type=str, help='Aggregation used for x-axis, values are "code" and "time".')
@click.option('--y-axis', multiple=True, type=str, help='Metrics used for y-axis, values are "entries", "energies", "users".')
@click.option('--y-axis', multiple=True, type=str, help='Metrics used for y-axis, values are "entries", "energies", "calculations", "users".')
@click.option('--cumulate', is_flag=True, help='Cumulate over x-axis.')
@click.option('--title', type=str, help='Override chart title with given value.')
@click.option('--total', is_flag=True, help='Provide total sums of key metrics.')
......@@ -258,6 +258,11 @@ def statistics(errors, title, x_axis, y_axis, cumulate, total):
'total_energies',
label='total energy calculations',
cumulate=cumulate,
power=0.25 if not cumulate else 1, multiplier=1e-6, format='{x:,.1f}M'),
'calculations': Metric(
'calculations',
label='single configuration calculations',
cumulate=cumulate,
power=0.25 if not cumulate else 1, multiplier=1e-6, format='{x:,.1f}M')
}
......@@ -279,5 +284,5 @@ def statistics(errors, title, x_axis, y_axis, cumulate, total):
bar_plot(client, x_axis, *y_axis, title=title)
if total:
data = client.repo.search(per_page=1, owner='admin', metrics=['total_energies', 'users', 'datasets']).response().result
data = client.repo.search(per_page=1, owner='admin', metrics=['total_energies', 'calculations', 'users', 'datasets']).response().result
print(data.quantities['total'])
......@@ -30,7 +30,7 @@ def parse(
else:
parser_name = parser.__class__.__name__
assert parser is not None, 'there is not parser matching %s' % mainfile
assert parser is not None, 'there is no parser matching %s' % mainfile
logger = logger.bind(parser=parser.name) # type: ignore
logger.info('identified parser')
......
......@@ -193,7 +193,7 @@ client = NomadConfig(
url='http://localhost:8000/fairdi/nomad/latest/api'
)
version = '0.5.2'
version = '0.5.3'
commit = gitinfo.commit
release = 'devel'
domain = 'DFT'
......
......@@ -263,13 +263,10 @@ parsers = [
LegacyParser(
name='parsers/gaussian', code_name='Gaussian',
parser_class_name='gaussianparser.GaussianParser',
# This previous file matching string was too far down the line.
# r'\s*Cite this work as:'
# r'\s*Gaussian [0-9]+, Revision [A-Za-z0-9.]*,'
# r'\s\*\*\*\*\*\*\*\*\*\*\*\**'
# r'\s*Gaussian\s*([0-9]+):\s*([A-Za-z0-9-.]+)\s*([0-9][0-9]?\-[A-Z][a-z][a-z]\-[0-9]+)'
# r'\s*([0-9][0-9]?\-[A-Z][a-z][a-z]\-[0-9]+)')
mainfile_contents_re=r'Gaussian, Inc'),
mainfile_contents_re=(
r'\s*Cite this work as:'
r'\s*Gaussian [0-9]+, Revision [A-Za-z0-9\.]*,')
),
LegacyParser(
name='parsers/quantumespresso', code_name='Quantum Espresso',
parser_class_name='quantumespressoparser.QuantumEspressoParserPWSCF',
......
......@@ -6,6 +6,7 @@ proxy:
api:
disableReset: true
adminPasswordSecret: 'nomad-production-repository-password'
gui:
debug: true
......
apiVersion: v1
appVersion: "0.5.2"
appVersion: "0.5.3"
description: A Helm chart for Kubernetes that only runs nomad services and uses externally hosted databases.
name: nomad
version: 0.5.2
version: 0.5.3
......@@ -12,7 +12,7 @@ reqs = [str(ir.req) for ir in install_reqs if 'sphinxcontrib.httpdomain' not in
setup(
name='nomad',
version='0.5.2',
version='0.5.3',
description='The nomad@FAIRDI infrastructure python package',
py_modules=['nomad'],
install_requires=reqs,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment