From 0e1022d1073bdd92946e6d8bffc72848f3040c9d Mon Sep 17 00:00:00 2001 From: Shyue Ping Ong Date: Mon, 27 Nov 2023 13:00:08 -0800 Subject: [PATCH] Add other models. --- hubconf.py | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/hubconf.py b/hubconf.py index a99fd304..671b83ee 100644 --- a/hubconf.py +++ b/hubconf.py @@ -14,5 +14,32 @@ def m3gnet_universal_potential(version="MP-2021.2.8-DIRECT", **kwargs): version (str): Defaults to "MP-2021.2.8-DIRECT". Other versions available. **kwargs: Pass through to matgl.load_model. """ - # Call the model, load pretrained weights return matgl.load_model(f"M3GNet-{version}", **kwargs) + + +def m3gnet_formation_energy(**kwargs): + """M3GNet Formation Energy Model. + + Args: + version (str): Defaults to "MP-2018.6.1-EForm". Other versions available. + **kwargs: Pass through to matgl.load_model. + """ + return matgl.load_model("M3GNet-MP-2018.6.1-Eform", **kwargs) + + +def megnet_formation_energy(**kwargs): + """MEGNet Formation Energy Model. + + Args: + **kwargs: Pass through to matgl.load_model. + """ + return matgl.load_model("MEGNet-MP-2018.6.1-Eform", **kwargs) + + +def megnet_band_gap_mfi(**kwargs): + """MEGNet Multi-fidelity Band Gap Model. + + Args: + **kwargs: Pass through to matgl.load_model. + """ + return matgl.load_model("MEGNet-MP-2019.4.1-BandGap-mfi", **kwargs)