diff --git a/mace/calculators/foundations_models.py b/mace/calculators/foundations_models.py index b5e705d7..ae8385b0 100644 --- a/mace/calculators/foundations_models.py +++ b/mace/calculators/foundations_models.py @@ -26,10 +26,12 @@ def mace_mp( ) -> MACECalculator: """ Constructs a MACECalculator with a pretrained model based on the Materials Project (89 elements). - The model is released under the MIT license. + The model is released under the MIT license. See https://github.com/ACEsuit/mace-mp for all models. Note: If you are using this function, please cite the relevant paper for the Materials Project, any paper associated with the MACE model, and also the following: + - MACE-MP by Ilyes Batatia, Philipp Benner, Yuan Chiang, Alin M. Elena, + Dávid P. Kovács, Janosh Riebesell, et al., 2023, arXiv:2401.00096 - MACE-Universal by Yuan Chiang, 2023, Hugging Face, Revision e5ebd9b, DOI: 10.57967/hf/1202, URL: https://huggingface.co/cyrusyc/mace-universal - Matbench Discovery by Janosh Riebesell, Rhys EA Goodall, Philipp Benner, Yuan Chiang, @@ -57,9 +59,9 @@ def mace_mp( elif model in (None, "small", "medium", "large") or str(model).startswith("https:"): try: urls = dict( - small="https://tinyurl.com/2jmmb8b7?confirm=yTib", # 2023-12-10-mace-128-L0_energy_epoch-249.model - medium="https://tinyurl.com/y7uhwpje?confirm=yTib", # 2023-12-03-mace-128-L1_epoch-199.model - large="https://figshare.com/ndownloader/files/43117273", + small="http://tinyurl.com/46jrkm3v", # 2023-12-10-mace-128-L0_energy_epoch-249.model + medium="http://tinyurl.com/5yyxdm76", # 2023-12-03-mace-128-L1_epoch-199.model + large="http://tinyurl.com/5f5yavf3", # MACE_MPtrj_2022.9.model ) checkpoint_url = ( urls.get(model, urls["medium"]) @@ -78,10 +80,9 @@ def mace_mp( _, http_msg = urllib.request.urlretrieve( checkpoint_url, cached_model_path ) - # make sure download was successful - if "Content-Type: application/octet-stream" not in http_msg: + if "Content-Type: text/html" in http_msg: raise RuntimeError( - f"Model download failed, please check {checkpoint_url}" + f"Model download failed, please check the URL {checkpoint_url}" ) print(f"Cached MACE model to {cached_model_path}") model = cached_model_path