Skip to main content

Package to support simplified application of machine learning models to datasets in materials science

Project description

PyPI Tests Tests NSF-1931306

Foundry-ML simplifies the discovery and usage of ML-ready datasets in materials science and chemistry providing a simple API to access even complex datasets.

  • Load ML-ready data with just a few lines of code
  • Work with datasets in local or cloud environments.
  • Publish your own datasets with Foundry to promote community usage
  • (in progress) Run published ML models without hassle

Learn more and see our available datasets on Foundry-ML.org

Documentation

Information on how to install and use Foundry is available in our documentation here.

DLHub documentation for model publication and running information can be found here.

Quick Start

Install Foundry-ML via command line with: pip install foundry_ml

You can use the following code to import and instantiate Foundry-ML, then load a dataset.

from foundry import Foundry
f = Foundry(index="mdf")


f = f.load("10.18126/e73h-3w6n", globus=True)

If running this code in a notebook, a table of metadata for the dataset will appear:

metadata

We can use the data with f.load_data() and specifying splits such as train for different segments of the dataset, then use matplotlib to visualize it.

res = f.load_data()

imgs = res['train']['input']['imgs']
desc = res['train']['input']['metadata']
coords = res['train']['target']['coords']

n_images = 3
offset = 150
key_list = list(res['train']['input']['imgs'].keys())[0+offset:n_images+offset]

fig, axs = plt.subplots(1, n_images, figsize=(20,20))
for i in range(n_images):
    axs[i].imshow(imgs[key_list[i]])
    axs[i].scatter(coords[key_list[i]][:,0], coords[key_list[i]][:,1], s = 20, c = 'r', alpha=0.5)
Screen Shot 2022-10-20 at 2 22 43 PM

See full examples

Primary Support

This work was supported by the National Science Foundation under NSF Award Number: 1931306 "Collaborative Research: Framework: Machine Learning Materials Innovation Infrastructure".

Other Support

Foundry-ML brings together many components in the materials data ecosystem. Including MAST-ML, the Data and Learning Hub for Science (DLHub), and the Materials Data Facility (MDF).

MAST-ML

This work was supported by the National Science Foundation (NSF) SI2 award No. 1148011 and DMREF award number DMR-1332851

The Data and Learning Hub for Science (DLHub)

This material is based upon work supported by Laboratory Directed Research and Development (LDRD) funding from Argonne National Laboratory, provided by the Director, Office of Science, of the U.S. Department of Energy under Contract No. DE-AC02-06CH11357. https://www.dlhub.org

The Materials Data Facility

This work was performed under financial assistance award 70NANB14H012 from U.S. Department of Commerce, National Institute of Standards and Technology as part of the Center for Hierarchical Material Design (CHiMaD). This work was performed under the following financial assistance award 70NANB19H005 from U.S. Department of Commerce, National Institute of Standards and Technology as part of the Center for Hierarchical Materials Design (CHiMaD). This work was also supported by the National Science Foundation as part of the Midwest Big Data Hub under NSF Award Number: 1636950 "BD Spokes: SPOKE: MIDWEST: Collaborative: Integrative Materials Design (IMaD): Leverage, Innovate, and Disseminate". https://www.materialsdatafacility.org

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

foundry_ml-0.5.1.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

foundry_ml-0.5.1-py3-none-any.whl (19.7 kB view details)

Uploaded Python 3

File details

Details for the file foundry_ml-0.5.1.tar.gz.

File metadata

  • Download URL: foundry_ml-0.5.1.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.1

File hashes

Hashes for foundry_ml-0.5.1.tar.gz
Algorithm Hash digest
SHA256 a3792eb7e5194ddbba06916befe8ace325c916924ff7142eaddc35f5a6f33af3
MD5 4482a7521c2951d32d82b144b53d6c55
BLAKE2b-256 ee6023df0de130b909a2e1b7d0a31a43b46e6ef9674aa4b2e448cefaffcdb59d

See more details on using hashes here.

File details

Details for the file foundry_ml-0.5.1-py3-none-any.whl.

File metadata

  • Download URL: foundry_ml-0.5.1-py3-none-any.whl
  • Upload date:
  • Size: 19.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.1

File hashes

Hashes for foundry_ml-0.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9306487c51633c3fe826346d18aa3bb793b9bee6964f2bf087d8382c8fd0665e
MD5 aea73f86bd204cba639d03b6ad2ecff4
BLAKE2b-256 cd5af1d2556c3b7c8391368c79004655e079e089d26cec3cb84f4cc7a8eb95cd

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page