Skip to content

Commit 32ed170

Browse files
committed
add site/src/routes/paper/iclr-ml4mat/+page.md
extract common elements between paper and extended abstract (references, title, authors) to site/src/routes/paper/+layout.svelte
1 parent 705e0d0 commit 32ed170

File tree

7 files changed

+243
-104
lines changed

7 files changed

+243
-104
lines changed

scripts/make_api_docs.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
from matbench_discovery import ROOT, URLs
77

8-
# Update auto-generated API docs.
8+
"""Update auto-generated API docs viewable on the site's /api page."""
99

1010
out_path = f"{ROOT}/site/src/routes/api"
1111

@@ -20,13 +20,13 @@
2020
)
2121

2222
# Tweak lazydocs's markdown output:
23-
# - remove bold tags since they break inline code
24-
# - make badges linking to GitHub source code blue with flat style, add alt text
2523
for path in glob(f"{out_path}/*.md"):
2624
text = open(path).read()
2725

26+
# remove bold tags since they break inline code
2827
text = text.replace("<b>", "").replace("</b>", "")
2928

29+
# make badges linking to GitHub source code blue with flat style, add alt text
3030
text = text.replace(
3131
'src="https://img.shields.io/badge/-source-cccccc?style=flat-square"',
3232
'src="https://img.shields.io/badge/source-blue?style=flat" alt="source link"',

site/src/app.d.ts

+11
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,22 @@ declare module '*package.json' {
88
export default pkg
99
}
1010

11+
// model metadata files
1112
declare module '*metadata.yml' {
1213
const data: import('$lib').ModelMetadata
1314
export default data
1415
}
1516

17+
// paper metadata
18+
declare module '*frontmatter.yml' {
19+
const frontmatter: import('$lib').Frontmatter
20+
export = frontmatter
21+
}
22+
23+
declare module '*references.yaml' {
24+
export const references: import('$lib').Reference[]
25+
}
26+
1627
declare module '*element-counts.json' {
1728
const map: Record<string, number>
1829
export default map

site/src/lib/index.ts

+13
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,16 @@ export type Reference = {
7070
type: string
7171
ISSN?: string
7272
}
73+
74+
export type Frontmatter = {
75+
title: string
76+
subtitle?: string
77+
tags: string[]
78+
authors: {
79+
name: string
80+
affiliation: string
81+
orcid: string
82+
}[]
83+
affiliations: string[]
84+
date: string
85+
}

site/src/routes/paper/+layout.svelte

+66
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
<script lang="ts">
2+
import { References } from '$lib'
3+
import { affiliations, authors, date, subtitle, title } from './frontmatter.yml'
4+
import { references } from './references.yaml'
5+
</script>
6+
7+
<h1>{title}<br /><small>{subtitle}</small></h1>
8+
9+
<address>
10+
<span>
11+
{@html authors
12+
.map((author) => `${author.name}<sup>${author.affiliation}</sup>`)
13+
.join(`, `)}
14+
</span>
15+
<span>
16+
{@html affiliations.map((affil, idx) => `${idx + 1}. ${affil}`).join(`<br/>`)}
17+
</span>
18+
<span style="font-weight: lighter;">{date}</span>
19+
</address>
20+
21+
<div>
22+
<slot />
23+
</div>
24+
25+
<h2>References</h2>
26+
27+
<References {references} />
28+
29+
<style>
30+
address {
31+
text-align: center;
32+
}
33+
address span {
34+
margin: 1em;
35+
display: block;
36+
}
37+
div :global(summary) {
38+
font-weight: 300;
39+
}
40+
div :global(summary)::before {
41+
content: 'Abstract';
42+
font-weight: bold;
43+
font-size: larger;
44+
}
45+
/* references */
46+
div :global(sup.ref) {
47+
text-transform: capitalize;
48+
}
49+
/*auto-number HTML headings*/
50+
div :global(h2) {
51+
counter-increment: h2;
52+
counter-reset: h3, h4;
53+
}
54+
div :global(h2::before) {
55+
content: counter(h2);
56+
margin-right: 10pt;
57+
}
58+
div :global(h3) {
59+
counter-increment: h3;
60+
counter-reset: h4;
61+
}
62+
div :global(h3::before) {
63+
content: counter(h2) '.' counter(h3);
64+
margin-right: 10pt;
65+
}
66+
</style>

site/src/routes/paper/+page.md

+3-97
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,15 @@
1-
---
2-
title: Matbench Discovery
3-
subtitle: Can machine learning identify stable crystals given unrelaxed structures?
4-
tags:
5-
- Python
6-
- machine learning
7-
- materials science
8-
- materials discovery
9-
- benchmark
10-
- ensembles
11-
- uncertainty estimation
12-
authors:
13-
- name: Janosh Riebesell
14-
orcid: 0000-0001-5233-3462
15-
corresponding: true
16-
affiliation: 1, 2
17-
- name: Rhys Goodall
18-
orcid: 0000-0002-6589-1700
19-
affiliation: 1
20-
- name: Anubhav Jain
21-
orcid: 0000-0001-5893-9967
22-
affiliation: 2
23-
- name: Kristin Persson
24-
orcid: 0000-0003-2495-5509
25-
affiliation: 2
26-
- name: Alpha Lee
27-
orcid: 0000-0002-9616-3108
28-
affiliation: 1
29-
affiliations:
30-
- Cavendish Laboratory, University of Cambridge, UK
31-
- Lawrence Berkeley National Laboratory, Berkeley, USA
32-
date: Jan 31, 2023
33-
# To create a PDF from this markdown file, run:
34-
# ```sh
35-
# cd paper
36-
# pandoc path/to/this/file --output paper.pdf --citeproc
37-
# ```
38-
# Requires `brew install pandoc` on macOS. Not identical but similar output as the
39-
# artifact generated by the JOSS GitHub action
40-
# https://github.com/marketplace/actions/open-journals-pdf-generator
41-
---
42-
431
<script>
442
import MetricsTable from '$figs/metrics-table.svelte'
45-
import { references } from './references.yaml'
46-
import { References } from '$lib'
473
import CumulativeClfMetrics from '$figs/cumulative-clf-metrics.svelte'
484
import RollingMaeModels from '$figs/rolling-mae-vs-hull-dist-models.svelte'
495
import { browser } from '$app/environment'
506
</script>
517

52-
# {title}<br><small>{subtitle}</small>
53-
54-
<address>
55-
<span rel="author">
56-
{@html authors
57-
.map((author) => `${author.name}<sup>${author.affiliation}</sup>`)
58-
.join(`, `)}
59-
</span>
60-
<span data-rel="affiliation">
61-
{@html affiliations.map((affil, idx) => `${idx + 1}. ${affil}`).join(`<br/>`)}
62-
</span>
63-
<span style="font-weight: lighter;">{date}</span>
64-
</address>
8+
<summary>
659

66-
## Abstract
10+
We present a new machine learning (ML) benchmark for materials stability predictions named `Matbench Discovery`. A goal of this benchmark is to highlight the need to focus on metrics that directly measure their utility in prospective discovery campaigns as opposed to analyzing models based on predictive accuracy alone. Our benchmark consists of a task designed to closely simulate the deployment of ML energy models in a high-throughput search for stable inorganic crystals. We explore a wide variety of models covering multiple methodologies ranging from random forests to GNNs, and from one-shot predictors to iterative Bayesian optimizers and interatomic potential-based relaxers. We find M3GNet to achieve the highest F1 score of 0.58 and $R^2$ of 0.59 while MEGNet wins on discovery acceleration factor (DAF) with 2.94. Our results provide valuable insights for maintainers of high throughput materials databases to start using these models as triaging steps to more effectively allocate compute for DFT relaxations.
6711

68-
We present a new machine learning benchmark for materials stability predictions called **Matbench Discovery**. The primary goal of this benchmark is to evaluate the effectiveness of machine learning energy models at accelerating the search for inorganic crystals and to determine the optimal methodology for this task. Specifically, we aim to answer the question of whether density functional theory emulators like M3GNet or one-shot predictors like Wrenformer perform better. To make the results easily accessible, we provide an online leaderboard with interactive plots that allow for custom model comparisons and looking at a variety of performance metrics. New models are easily added to our leaderboard, allowing this benchmark to grow into the future. We also make our results easily reproducible by releasing all training and test scripts as well as WandB logs of all our experiments. We hope our results provide valuable insights that motivate researchers in the field of materials discovery and builders of high throughput databases to start using these models as triaging steps to more effectively allocate compute for DFT relaxations.
12+
</summary>
6913

7014
## Introduction
7115

@@ -195,41 +139,3 @@ M3GNet's performance appears to be particularly affected by poor performance on
195139
## Acknowledgements
196140

197141
JR acknowledges support from the German Academic Scholarship Foundation (Studienstiftung) and gracious hosting as a visiting affiliate in the groups of [KP](https://perssongroup.lbl.gov/people) and [AJ](https://hackingmaterials.lbl.gov).
198-
199-
## References
200-
201-
<References {references} />
202-
203-
<style>
204-
#abstract,
205-
#abstract + p {
206-
font-weight: 300;
207-
}
208-
address {
209-
text-align: center;
210-
}
211-
address span {
212-
margin: 1em;
213-
display: block;
214-
}
215-
/*auto-number HTML headings*/
216-
h2 {
217-
counter-increment: h2;
218-
counter-reset: h3, h4;
219-
}
220-
h2::before {
221-
content: counter(h2);
222-
margin-right: 10pt;
223-
}
224-
h3 {
225-
counter-increment: h3;
226-
counter-reset: h4;
227-
}
228-
h3::before {
229-
content: counter(h2) '.' counter(h3);
230-
margin-right: 10pt;
231-
}
232-
sup.ref {
233-
text-transform: capitalize;
234-
}
235-
</style>

0 commit comments

Comments
 (0)