Skip to content

Commit

Permalink
Alexandria add download bash script (#281)
Browse files Browse the repository at this point in the history
* bash script to download dataset

* download dataset updated

* exclude download of index.html

* try-cath exceptions in alexandria example fixed

* formatting fixed

* natoms count fixed

* fix json files

---------

Co-authored-by: Massimiliano Lupo Pasini <mlupopa@login10.frontier.olcf.ornl.gov>
Co-authored-by: Massimiliano Lupo Pasini <mlupopa@andes-login1.olcf.ornl.gov>
Co-authored-by: Jong Choi <choij@ornl.gov>
  • Loading branch information
4 people authored Nov 6, 2024
1 parent d1fb63d commit 42b1a68
Show file tree
Hide file tree
Showing 4 changed files with 205 additions and 119 deletions.
128 changes: 74 additions & 54 deletions examples/alexandria/alexandria_energy.json
Original file line number Diff line number Diff line change
@@ -1,58 +1,78 @@
{
"Verbosity": {
"level": 2
},
"NeuralNetwork": {
"Architecture": {
"model_type": "EGNN",
"equivariance": true,
"radius": 5.0,
"max_neighbours": 100000,
"num_gaussians": 50,
"envelope_exponent": 5,
"int_emb_size": 64,
"basis_emb_size": 8,
"out_emb_size": 128,
"num_after_skip": 2,
"num_before_skip": 1,
"num_radial": 6,
"num_spherical": 7,
"num_filters": 126,
"edge_features": ["length"],
"hidden_dim": 50,
"num_conv_layers": 3,
"output_heads": {
"graph":{
"num_sharedlayers": 2,
"dim_sharedlayers": 50,
"num_headlayers": 2,
"dim_headlayers": [50,25]
}
},
"task_weights": [1.0]
},
"Variables_of_interest": {
"input_node_features": [0, 1, 2, 3],
"output_names": ["energy"],
"output_index": [0],
"output_dim": [1],
"type": ["graph"]
},
"Training": {
"num_epoch": 50,
"perc_train": 0.8,
"loss_function_type": "mae",
"batch_size": 32,
"continue": 0,
"Optimizer": {
"type": "AdamW",
"learning_rate": 1e-3
}
"Verbosity": {
"level": 2
},
"NeuralNetwork": {
"Architecture": {
"model_type": "EGNN",
"equivariance": true,
"radius": 5,
"max_neighbours": 100000,
"num_gaussians": 50,
"envelope_exponent": 5,
"int_emb_size": 64,
"basis_emb_size": 8,
"out_emb_size": 128,
"num_after_skip": 2,
"num_before_skip": 1,
"num_radial": 6,
"num_spherical": 7,
"num_filters": 126,
"edge_features": [
"length"
],
"hidden_dim": 50,
"num_conv_layers": 3,
"output_heads": {
"graph": {
"num_sharedlayers": 2,
"dim_sharedlayers": 50,
"num_headlayers": 2,
"dim_headlayers": [
50,
25
]
}
},
"task_weights": [
1
]
},
"Variables_of_interest": {
"input_node_features": [
0,
1,
2,
3
],
"output_names": [
"energy"
],
"output_index": [
0
],
"output_dim": [
1
],
"type": [
"graph"
]
},
"Visualization": {
"plot_init_solution": true,
"plot_hist_solution": false,
"create_plots": true
"Training": {
"num_epoch": 50,
"perc_train": 0.8,
"loss_function_type": "mae",
"batch_size": 32,
"continue": 0,
"Optimizer": {
"type": "AdamW",
"learning_rate": 0.001
}
}
}
},
"Visualization": {
"plot_init_solution": true,
"plot_hist_solution": false,
"create_plots": true
}
}
128 changes: 74 additions & 54 deletions examples/alexandria/alexandria_forces.json
Original file line number Diff line number Diff line change
@@ -1,58 +1,78 @@
{
"Verbosity": {
"level": 2
},
"NeuralNetwork": {
"Architecture": {
"model_type": "EGNN",
"equivariance": true,
"radius": 5.0,
"max_neighbours": 100000,
"num_gaussians": 50,
"envelope_exponent": 5,
"int_emb_size": 64,
"basis_emb_size": 8,
"out_emb_size": 128,
"num_after_skip": 2,
"num_before_skip": 1,
"num_radial": 6,
"num_spherical": 7,
"num_filters": 126,
"edge_features": ["length"],
"hidden_dim": 50,
"num_conv_layers": 3,
"output_heads": {
"node": {
"num_headlayers": 2,
"dim_headlayers": [200,200],
"type": "mlp"
}
},
"task_weights": [1.0]
},
"Variables_of_interest": {
"input_node_features": [0, 1, 2, 3],
"output_names": ["forces"],
"output_index": [2],
"output_dim": [3],
"type": ["node"]
},
"Training": {
"num_epoch": 50,
"EarlyStopping": true,
"perc_train": 0.9,
"loss_function_type": "mae",
"batch_size": 32,
"continue": 0,
"Optimizer": {
"type": "AdamW",
"learning_rate": 1e-3
}
"Verbosity": {
"level": 2
},
"NeuralNetwork": {
"Architecture": {
"model_type": "EGNN",
"equivariance": true,
"radius": 5,
"max_neighbours": 100000,
"num_gaussians": 50,
"envelope_exponent": 5,
"int_emb_size": 64,
"basis_emb_size": 8,
"out_emb_size": 128,
"num_after_skip": 2,
"num_before_skip": 1,
"num_radial": 6,
"num_spherical": 7,
"num_filters": 126,
"edge_features": [
"length"
],
"hidden_dim": 50,
"num_conv_layers": 3,
"output_heads": {
"node": {
"num_headlayers": 2,
"dim_headlayers": [
200,
200
],
"type": "mlp"
}
},
"task_weights": [
1
]
},
"Variables_of_interest": {
"input_node_features": [
0,
1,
2,
3
],
"output_names": [
"forces"
],
"output_index": [
2
],
"output_dim": [
3
],
"type": [
"node"
]
},
"Visualization": {
"plot_init_solution": true,
"plot_hist_solution": false,
"create_plots": true
"Training": {
"num_epoch": 50,
"EarlyStopping": true,
"perc_train": 0.9,
"loss_function_type": "mae",
"batch_size": 32,
"continue": 0,
"Optimizer": {
"type": "AdamW",
"learning_rate": 0.001
}
}
}
},
"Visualization": {
"plot_init_solution": true,
"plot_hist_solution": false,
"create_plots": true
}
}
25 changes: 25 additions & 0 deletions examples/alexandria/download_dataset.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/bin/bash

# URL to download from
URL="https://alexandria.icams.rub.de/data/"

# Directory where files will be saved
OUTPUT_DIR="./dataset/compressed_data"

# Create output directory if it doesn't exist
mkdir -p "$OUTPUT_DIR"

# Use wget to recursively download all files and directories
wget --recursive \
--no-parent \
--continue \
--no-clobber \
--convert-links \
--cut-dirs=1 \
--no-check-certificate \
--reject-regex="(/older/|/geo_opt_paths/)" \
--reject "*index.html*" \
--directory-prefix="$OUTPUT_DIR" \
"$URL"

echo "Download complete. All files saved to $OUTPUT_DIR."
Loading

0 comments on commit 42b1a68

Please sign in to comment.