Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
160 commits
Select commit Hold shift + click to select a range
2efc63e
Initial sae code
awadell1 Oct 18, 2024
093f4f5
add nvtx
awadell1 Oct 20, 2024
244e3c2
perf: add multi-processing to HiddenStateDataModule
awadell1 Oct 21, 2024
2e165b4
wip: start enumerating possible features
awadell1 Oct 29, 2024
6099f61
Element and Regex features are working
awadell1 Oct 30, 2024
e7eb40d
first pass at using SMARTS to featurize
awadell1 Oct 31, 2024
a984e6a
wip: more sae pipeline
awadell1 Nov 19, 2024
5b359dc
wip: rework sae to inject coders into the model
awadell1 Mar 3, 2025
e3ec515
add more sae types
awadell1 Mar 7, 2025
9952cba
first pass at linear probe
awadell1 Mar 8, 2025
2c78388
initial run over linear probes
awadell1 Mar 10, 2025
c863e84
add analysis code for linear probes
awadell1 Mar 10, 2025
41f0134
add layerwise similarity and submission script
awadell1 Mar 10, 2025
760fdfb
wip: exploring design rules with MIST
awadell1 Mar 14, 2025
761e854
rework: refactor design rule plots
awadell1 Mar 14, 2025
db6a992
refactor: Move MistStyle into a proper package
awadell1 Mar 27, 2025
133d7c3
feat: better plots for design trends
awadell1 Mar 27, 2025
f3e09b5
add sat/unsat fats figure
awadell1 Apr 1, 2025
9dac883
rm unused code
awadell1 Apr 1, 2025
c70fa8e
tweak plots
awadell1 Apr 1, 2025
14affdc
fix spacing around degC
awadell1 Apr 1, 2025
a987e1a
tweak: plot sat fats as a spread
awadell1 Apr 1, 2025
6c4986e
restrict to omega-3 fatty acids
awadell1 Apr 1, 2025
c353968
feat: add tantext and token_embeddings figures
awadell1 Apr 7, 2025
30eadc7
fix units and quadrant
awadell1 Apr 10, 2025
03ea1ba
update plots per victor's comments
awadell1 Apr 10, 2025
7c02314
Merge branch 'master' into sae
awadell1 Apr 21, 2025
3b1a4ae
add linear probe submission and analysis scripts
awadell1 Apr 21, 2025
d80500f
Merge branch 'design' into sae
awadell1 Apr 21, 2025
952f53c
feat: construct dataset for lipinski linear probes
awadell1 Apr 22, 2025
a6ba97d
update linear probe sweep
awadell1 Apr 22, 2025
aa513aa
Merge remote-tracking branch 'origin/sae' into sae
awadell1 Apr 23, 2025
e314832
add BoxPlot config to style
awadell1 Apr 23, 2025
fba5965
don't track jld2 files
awadell1 Apr 23, 2025
8e62b97
update lipinski plots
awadell1 Apr 23, 2025
1dedb9d
update probe plots
awadell1 Apr 24, 2025
4a21b9a
Merge branch 'master' into sae
awadell1 Apr 24, 2025
574fa9f
add pandas and numpy to deps
awadell1 Apr 24, 2025
fa0d197
Merge branch 'master' into sae
awadell1 Apr 24, 2025
50dc9a6
fix formatting
awadell1 Apr 24, 2025
98a44c0
fix spelling
awadell1 Apr 24, 2025
9a7964b
feat update screening plots
awadell1 Jun 13, 2025
9727d58
add verification plots
awadell1 Jun 14, 2025
6319b11
move mol_surprise into electrolyte_fm
awadell1 Jun 17, 2025
fa2de78
Update figures for screening plots
awadell1 Jun 17, 2025
562c31e
Update and expand screening plots
awadell1 Jun 18, 2025
1f8d14c
add updates to screening
awadell1 Jun 24, 2025
4b430f6
Updated creativity figures
awadell1 Jun 28, 2025
db39a8c
Merge remote-tracking branch 'origin/master' into sae
awadell1 Jun 28, 2025
c31fa91
Update READMEs and probe plots
awadell1 Jul 2, 2025
f3ce150
Don't add SAE to model __init__.py
awadell1 Jul 2, 2025
41709eb
Add shebang to screening plots
awadell1 Jul 10, 2025
156ed14
rm unused code
awadell1 Jul 10, 2025
0ab6baf
Merge branch 'master' into screening
awadell1 Jul 10, 2025
dd1ec06
remove unused SAE codes
awadell1 Jul 13, 2025
1534609
fix pre-commit
awadell1 Jul 13, 2025
1bb4515
tweaks to screening figures
awadell1 Aug 11, 2025
6e830ae
Linearly calibrate models
awadell1 Aug 30, 2025
08c9dc1
Merge branch 'pubchem-3d' into stero
awadell1 Sep 1, 2025
13846c8
Add script for ingesting sterochemistry dataset
awadell1 Sep 1, 2025
6fd17c0
feat: support processing *.tar.gz files directly
awadell1 Sep 1, 2025
98a7f9e
feat: add process_clc_db
awadell1 Sep 1, 2025
411d13f
fix pre-commit issues
awadell1 Sep 1, 2025
f2fdb44
Merge branch 'sae' into stero
awadell1 Sep 1, 2025
2fcc8ce
Use latest smirk, update CI to reflect
awadell1 Sep 1, 2025
b0f8208
test: skip mds tests if missing cuda
awadell1 Sep 1, 2025
733f4c7
fix mds test errors
awadell1 Sep 1, 2025
5cf7e9a
testing: cut back on molnet tests
awadell1 Sep 1, 2025
f8657ce
fix: variance calculation
anoushka2000 Jul 22, 2025
63580e6
fix: progressive thawing works with configure model
anoushka2000 Sep 1, 2025
d25a731
feat: isotopes dataloader and config
anoushka2000 Sep 1, 2025
8f7e04d
tweak: normalize clc_db processing
awadell1 Sep 1, 2025
373f3f6
embedding coloured by decay type figure
anoushka2000 Sep 3, 2025
2e9049d
Merge pull request #129 from anoushka2000/stero
awadell1 Sep 3, 2025
8f7a7c0
Merge pull request #130 from anoushka2000/isotops
anoushka2000 Sep 3, 2025
fc3c9a2
Merge pull request #124 from anoushka2000/screening
awadell1 Sep 3, 2025
a0723d0
correct task head name
anoushka2000 Oct 1, 2025
12922cd
feat: return intermidiate params
anoushka2000 Oct 2, 2025
47aa991
add command for exporting mixture models
anoushka2000 Oct 2, 2025
8a1d0f8
export for mixture models
anoushka2000 Oct 2, 2025
3c412f7
fix: mixture export
anoushka2000 Oct 2, 2025
7f41411
Add script for ingesting sterochemistry dataset
awadell1 Sep 1, 2025
bbda2c3
feat: support processing *.tar.gz files directly
awadell1 Sep 1, 2025
886e141
feat: add process_clc_db
awadell1 Sep 1, 2025
470a801
Initial sae code
awadell1 Oct 18, 2024
4954665
add nvtx
awadell1 Oct 20, 2024
dce27ec
perf: add multi-processing to HiddenStateDataModule
awadell1 Oct 21, 2024
0878687
wip: start enumerating possible features
awadell1 Oct 29, 2024
5d1add4
Element and Regex features are working
awadell1 Oct 30, 2024
15a54a2
first pass at using SMARTS to featurize
awadell1 Oct 31, 2024
599fafe
wip: more sae pipeline
awadell1 Nov 19, 2024
c950191
wip: rework sae to inject coders into the model
awadell1 Mar 3, 2025
131d315
add more sae types
awadell1 Mar 7, 2025
5935b39
first pass at linear probe
awadell1 Mar 8, 2025
8046e1d
initial run over linear probes
awadell1 Mar 10, 2025
d8a655e
add analysis code for linear probes
awadell1 Mar 10, 2025
a0975df
add layerwise similarity and submission script
awadell1 Mar 10, 2025
f41d413
add linear probe submission and analysis scripts
awadell1 Apr 21, 2025
ecaa29e
wip: exploring design rules with MIST
awadell1 Mar 14, 2025
3284d97
rework: refactor design rule plots
awadell1 Mar 14, 2025
7fab304
refactor: Move MistStyle into a proper package
awadell1 Mar 27, 2025
4106659
feat: better plots for design trends
awadell1 Mar 27, 2025
3c3bf6f
add sat/unsat fats figure
awadell1 Apr 1, 2025
bcc4930
rm unused code
awadell1 Apr 1, 2025
5d6ff25
tweak plots
awadell1 Apr 1, 2025
c91bb04
update plots per victor's comments
awadell1 Apr 10, 2025
b88f3da
feat: construct dataset for lipinski linear probes
awadell1 Apr 22, 2025
cba9b6f
update linear probe sweep
awadell1 Apr 22, 2025
ba102a2
add BoxPlot config to style
awadell1 Apr 23, 2025
b95fab0
don't track jld2 files
awadell1 Apr 23, 2025
ebfe709
update lipinski plots
awadell1 Apr 23, 2025
1d6467a
update probe plots
awadell1 Apr 24, 2025
7bed0f5
add pandas and numpy to deps
awadell1 Apr 24, 2025
0ea2eae
fix formatting
awadell1 Apr 24, 2025
06b8ef2
fix spelling
awadell1 Apr 24, 2025
635657b
Update READMEs and probe plots
awadell1 Jul 2, 2025
b8a0dbc
Don't add SAE to model __init__.py
awadell1 Jul 2, 2025
946427f
rm unused code
awadell1 Jul 10, 2025
b4ab118
remove unused SAE codes
awadell1 Jul 13, 2025
5196bba
Use latest smirk, update CI to reflect
awadell1 Sep 1, 2025
4a3f863
test: skip mds tests if missing cuda
awadell1 Sep 1, 2025
b9393ff
fix mds test errors
awadell1 Sep 1, 2025
f6b98f5
testing: cut back on molnet tests
awadell1 Sep 1, 2025
3323846
tweak: normalize clc_db processing
awadell1 Sep 1, 2025
1e13a7f
fix: progressive thawing works with configure model
anoushka2000 Sep 1, 2025
ef561e7
feat: isotopes dataloader and config
anoushka2000 Sep 1, 2025
788a48a
embedding coloured by decay type figure
anoushka2000 Sep 3, 2025
e412ffb
feat update screening plots
awadell1 Jun 13, 2025
c58351c
add verification plots
awadell1 Jun 14, 2025
90586e9
move mol_surprise into electrolyte_fm
awadell1 Jun 17, 2025
022c335
Update figures for screening plots
awadell1 Jun 17, 2025
05a1873
Update and expand screening plots
awadell1 Jun 18, 2025
44523ed
add updates to screening
awadell1 Jun 24, 2025
6b07bd0
Updated creativity figures
awadell1 Jun 28, 2025
f4b5f55
Add shebang to screening plots
awadell1 Jul 10, 2025
75122de
fix pre-commit
awadell1 Jul 13, 2025
bdbeba7
tweaks to screening figures
awadell1 Aug 11, 2025
c62a54c
Linearly calibrate models
awadell1 Aug 30, 2025
49c0968
fix pre-commit issues
awadell1 Sep 1, 2025
c638b12
correct task head name
anoushka2000 Oct 1, 2025
1d24944
feat: return intermidiate params
anoushka2000 Oct 2, 2025
64b1fd3
add command for exporting mixture models
anoushka2000 Oct 2, 2025
aaa9115
export for mixture models
anoushka2000 Oct 2, 2025
0c36550
fix: mixture export
anoushka2000 Oct 2, 2025
868bdf9
rebase on mixture-splits are merge upstream
anoushka2000 Oct 4, 2025
e35c563
fix: precommit and spliter target distribution test
anoushka2000 Oct 4, 2025
b91e124
fix test_ckpt: lightining 2.5.5 cli automatically links matching para…
anoushka2000 Oct 4, 2025
ded218d
fix: merge conflict erased module level imports
anoushka2000 Oct 4, 2025
c97b932
fix: formatting
anoushka2000 Oct 4, 2025
3e9e2fa
increase spit test tolerance and disable wandb in CI
anoushka2000 Oct 4, 2025
9842289
splitter test tolerance
anoushka2000 Oct 4, 2025
de22433
python call for inference of conductivity model
anoushka2000 Oct 5, 2025
103ac74
feat: ternary plots
anoushka2000 Oct 6, 2025
af1cfba
feat: ternary plots for activation energy and excess Ea
anoushka2000 Oct 6, 2025
99b01a7
refactor: allow both mixture data modules (pre/post mixture-splits
anoushka2000 Oct 6, 2025
8f41a75
remove old mixture plotting code
anoushka2000 Oct 6, 2025
da0e352
increase dataset panel size
anoushka2000 Oct 9, 2025
c8fb927
excess Ea plot
anoushka2000 Oct 13, 2025
a535e8f
soap similarity plot
anoushka2000 Oct 13, 2025
8509c04
normalize similarity calculations, move calculation utils into Mixtur…
anoushka2000 Oct 14, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,9 @@ jobs:
enable-cache: true
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Install deploy key for BattModels/smirk
uses: webfactory/ssh-agent@dc588b651fe13675774614f8e6a936a468676387 #v0.9.0
with:
ssh-private-key: ${{ secrets.SMIRK_PRIVATE_KEY }}
- name: install project
run: uv sync --all-extras --dev
- name: pytest
run: uv run pytest
env:
WANDB_MODE: disabled
run: uv run pytest --durations=0
10 changes: 9 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,17 +28,25 @@ mist
Manifest.toml
LocalPreferences.toml
.CondaPkg/
*.jdl2

# Spack
.spack-env/
spack.lock

# Output files
*.json
*.tar.xz
*.tar.gz
*.tar
*.jsonl
*.jld2
*.bson
*.png
*.pdf
*.h5
*.csv
*.tar.xz
*.tar.gz
*.tar
*.jsonl
*.jld2
37 changes: 13 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ Benchmarking RoBERTa model pre-training on molecular datasets.

# Installation

The following provides installation instructions for the top-level package (`electrolyte_fm`), optional add-ons for our
various additional analysis and downstream applications (See `opt/`) may require additional configuration.

## Polaris

1. Install [rust](https://www.rust-lang.org/tools/install) and [uv](https://docs.astral.sh/uv/getting-started/installation/)
Expand All @@ -21,11 +24,18 @@ uv sync
```
## Artemis


Same as above except:
1. Skip loading conda (just use uv)
2. Ensure a module for CUDA@12.2 exists, may need to install with spack (make sure `buildable: True`)

## Apptainer

0. Install or load from a module [Apptainer](https://apptainer.org/)
1. Build the image `bash container/build.sh`, once build relocate the image `mv /tmp/mist.sif ./mist.sif`
2. Run training within the image `apptainer run --nv mist.sif python train.py ...`

> See `submit/dgx.j2` or `submit/delta.j2` for a more complete example of using the container

# Submitting Jobs

```shell
Expand All @@ -35,33 +45,12 @@ source ./activate # Activate Environment

See `submit/submit.py --help` for more info

## Building Apptainer Image

```shell
apptainer build --fakeroot \
--build-arg SSH_AUTH_SOCK=$SSH_AUTH_SOCK \
mist.sif mist.def
```

## Hackathon

Create a file `hack.yaml` and include it as an overlay to `submit.py` (i.e. `./submit/submit.py ... --data hack.yaml ...`).
Put the following in `hack.yaml`:
```yaml
queue: debug
account: GPU_Hack
nodes: 2
walltime: 1:0:0
train:
data.path: /grand/gpu_hack/FoundEnergy/realspace_v3_dev
```

# Development

## Pre-commit

We use [pre-commit](https://pre-commit.com) to preform various linting checks on the code. To enable:

1. Install poetry (See above)
2. Run pre-commit: `pre-commit`
3. Run before committing: `pre-commit install --allow-missing-config`
2. Run pre-commit: `uv run pre-commit`
3. Run before committing: `uv run pre-commit install --allow-missing-config`
4 changes: 2 additions & 2 deletions electrolyte_fm/data_modules/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from .molnet_dataset import MolNetDataModule
from .property_prediction_dataset import PropertyPredictionDataModule
from .tmqm_dataset import tmQMDataModule
from .roberta_dataset import RobertaDataSet
from .mixture_dataset import ComponentDataModule
from .tmqm_dataset import tmQMDataModule
from .mixture_dataset import ComponentDataModule, ComponentDataModuleFast
28 changes: 28 additions & 0 deletions electrolyte_fm/data_modules/isotope_dataset.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
from .property_prediction_dataset import PropertyPredictionDataModule
from .molnet_dataset import train_val_test_split
from datasets import Dataset, load_dataset
from pathlib import Path


class IsotopeDataModule(PropertyPredictionDataModule):
def __init__(self, path: str, **kwargs):
# Set default smi_column
self.path = path
assert Path(self.path).is_file()
super().__init__(**kwargs)

def prepare_data(self):
# Fetch data from the head node
self.dataset

def _get_dataset(self):
# Load the dataset
ds: Dataset = load_dataset(
"csv",
data_files=[self.path],
split="train",
keep_in_memory=False,
save_infos=False,
) # type: ignore

return train_val_test_split(ds)
Loading