Skip to content

Commit

Permalink
update schema
Browse files Browse the repository at this point in the history
  • Loading branch information
fekad committed Oct 15, 2024
1 parent d5cff0a commit 8d2e214
Show file tree
Hide file tree
Showing 28 changed files with 60 additions and 82 deletions.
2 changes: 1 addition & 1 deletion notebooks/arise.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"name": "SOAP"
}
],
"systems": [
"applications": [
{
"name": "Grain boundaries"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/atomic-features.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"name": ""
}
],
"systems": [
"applications": [
{
"name": "Atoms"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/clustering-tutorial.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "HDBSCAN"
}
],
"systems": [
"applications": [
{
"name": "Synthetic data"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/cmlkit.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "Symmetry functions"
}
],
"systems": [
"applications": [
{
"name": "Transparent conducting oxides"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/co2-sgd-tutorial.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"name": "Decision tree"
}
],
"systems": [
"applications": [
{
"name": "CO2 activation"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/compressed-sensing.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"name": "Atomic features"
}
],
"systems": [
"applications": [
{
"name": "Octet binaries"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/convolutional-nn.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"name": "Attentive response map"
}
],
"systems": [
"applications": [
{
"name": "Images"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/decision-tree.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"name": "Atomic features"
}
],
"systems": [
"applications": [
{
"name": "Images"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/descriptor-role.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"name": "Atomic features"
}
],
"systems": [
"applications": [
{
"name": "Octet binaries"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/domain-of-applicability.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"name": "n-gram"
}
],
"systems": [
"applications": [
{
"name": "Transparent conducting oxides"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/dos-similarity-search.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"name": "Fingerprint"
}
],
"systems": [
"applications": [
{
"name": "Binaries"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/error-estimates.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"name": "Linear least-squares regression"
}
],
"systems": [
"applications": [
{
"name": "Binaries"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/exploratory-analysis.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"name": "MDS"
}
],
"systems": [
"applications": [
{
"name": "Octet binaries"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/gap-si-surface.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "Gaussian approximation potentials (GAP)"
}
],
"systems": [
"applications": [
{
"name": "Silicon"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/grain-boundaries.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "Gaussian mixture"
}
],
"systems": [
"applications": [
{
"name": "Iron"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/hierarchical-sisso.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"name": "Atomic features"
}
],
"systems": [
"applications": [
{
"name": "Bulk properties"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/kaggle-competition.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "n-gram"
}
],
"systems": [
"applications": [
{
"name": "Transparent conducting oxides"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/krr4mat.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"name": "SOAP"
}
],
"systems": [
"applications": [
{
"name": "Transparent conducting oxides"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/nn-regression.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"name": "Atomic features"
}
],
"systems": [
"applications": [
{
"name": "Inorganic compounds"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/perovskite-tolerance-factor.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"name": "Atomic features"
}
],
"systems": [
"applications": [
{
"name": "Perovskites"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/query-nomad-archive.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "Random forest"
}
],
"systems": [
"applications": [
{
"name": "Ternaries"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"name": "Decision tree"
}
],
"systems": [
"applications": [
{
"name": "Heterogeneous catalysis"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/sgd-propylene-oxidation-hte.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"name": "Subgroup discovery"
}
],
"systems": [
"applications": [
{
"name": "Heterogeneous catalysis"
}
Expand Down
2 changes: 1 addition & 1 deletion notebooks/soap-atomic-charges.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"name": "SOAP"
}
],
"systems": [
"applications": [
{
"name": "GDB molecular database"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/tcmi.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"name": "TCMI"
}
],
"systems": [
"applications": [
{
"name": "Synthetic data"
},
Expand Down
2 changes: 1 addition & 1 deletion notebooks/tetradymite-PRM2020.archive.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"name": "SISSO"
}
],
"systems": [
"applications": [
{
"name": "Tetradymites"
},
Expand Down
4 changes: 2 additions & 2 deletions notebooks/tutorial_stats.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": 12,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -354,7 +354,7 @@
"\n",
" 'category': map_categories[tutorial['labels']['category'][0]],\n",
" 'methods': [ {'name': v } for v in tutorial['labels']['ai_methods'] ],\n",
" 'application': [ {'name': v } for v in tutorial['labels']['application_system'] ],\n",
" 'applications': [ {'name': v } for v in tutorial['labels']['application_system'] ],\n",
" 'platform': 'Python'\n",
" }\n",
"\n",
Expand Down
86 changes: 32 additions & 54 deletions src/nomad_aitoolkit/apps/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@
from nomad.config import _plugins
from nomad.config.models.plugins import AppEntryPoint
from nomad.config.models.ui import (
AlignEnum,
App,
BreakpointEnum,
Column,
Columns,
Dashboard,
FilterMenu,
FilterMenus,
Expand All @@ -15,7 +13,6 @@
Format,
Layout,
ModeEnum,
RowActions,
RowActionURL,
RowDetails,
Rows,
Expand Down Expand Up @@ -60,42 +57,26 @@
# exclude=['*#nomad.datamodel.metainfo.eln.BasicEln'],
),
filters_locked=filters_locked,
columns=Columns(
include=[
'entry_id',
'entry_type',
'authors',
'data.name#nomad_aitoolkit.schema.AIToolkitNotebook',
'data.category#nomad_aitoolkit.schema.AIToolkitNotebook',
'data.platform#nomad_aitoolkit.schema.AIToolkitNotebook',
'data.date#nomad_aitoolkit.schema.AIToolkitNotebook',
],
selected=[
'data.name#nomad_aitoolkit.schema.AIToolkitNotebook',
'authors',
'data.category#nomad_aitoolkit.schema.AIToolkitNotebook',
'data.date#nomad_aitoolkit.schema.AIToolkitNotebook',
],
options={
'entry_id': Column(),
'entry_type': Column(label='Entry type', align=AlignEnum.LEFT),
'authors': Column(label='Authors', align=AlignEnum.LEFT),
'data.name#nomad_aitoolkit.schema.AIToolkitNotebook': Column(
label='Name', align=AlignEnum.LEFT
),
'data.category#nomad_aitoolkit.schema.AIToolkitNotebook': Column(
label='Category'
),
'data.platform#nomad_aitoolkit.schema.AIToolkitNotebook': Column(
label='Platform', align=AlignEnum.LEFT
),
'data.date#nomad_aitoolkit.schema.AIToolkitNotebook': Column(
label='Last update',
align=AlignEnum.LEFT,
format=Format(mode=ModeEnum.DATE),
),
},
),
columns=[
Column(
quantity='data.name#nomad_aitoolkit.schema.AIToolkitNotebook',
selected=True,
),
Column(
quantity='data.category#nomad_aitoolkit.schema.AIToolkitNotebook',
selected=True,
),
Column(
quantity='data.date#nomad_aitoolkit.schema.AIToolkitNotebook',
label='Upload time',
selected=True,
format=Format(mode=ModeEnum.DATE),
),
Column(quantity='entry_id'),
Column(quantity='entry_type'),
Column(quantity='authors'),
Column(quantity='data.platform#nomad_aitoolkit.schema.AIToolkitNotebook'),
],
filter_menus=FilterMenus(
options={
'custom_quantities': FilterMenu(
Expand Down Expand Up @@ -148,21 +129,18 @@
]
),
rows=Rows(
actions=RowActions(
enabled=True,
options={
'launch': RowActionURL(
type='url',
path="data.references[?kind=='hub'].uri",
description='Launch Jupyter notebook',
),
'repository': RowActionURL(
type='downloadurl',
path="data.references[?kind=='repository'].uri",
description='Link to the repository',
),
},
),
actions=[
RowActionURL(
path="data.references[?kind=='repository'].uri",
description='Go to the repository',
icon='file_download',
),
RowActionURL(
path="data.references[?kind=='hub'].uri",
description='Launch Jupyter notebook',
icon='launch',
),
],
details=RowDetails(enabled=True),
selection=RowSelection(enabled=True),
),
Expand Down

0 comments on commit 8d2e214

Please sign in to comment.