Skip to main content

Multi-Modal Electron Microscopy Data Fusion for Spectral Maps

Project description

2D Multi-Modal Data Fusion for Electron Microscopy

License PyPI Python

Fused multi-modal electron microscopy, a combines elastic scattering (HAADF) and inelastic spectroscopic signals (EELS/EDX) to recover high signal-to-noise ratio chemical maps at nano- and atomic-resolution.

By linking simultaneously acquired modalities through regularized optimization, the method can reduce dose requirements by over one order of magnitude while substantially improving SNR for chemical maps.

Demo Screenshot

Installation

The package is available on PyPI:

pip install mapfusion

For local development, clone the repository and install in editable mode:

git clone https://github.com/jtschwar/Multi-Modal-2D-Data-Fusion.git --recursive
cd Multi-Modal-2D-Data-Fusion
pip install -e . 

Quick Start

from mapfusion import DataFusion

# Initialize fusion with list of elements
elements = ['Co', 'S', 'O']
fusion = DataFusion(elements)

# Load your chemical maps
# Provide as a dictionary where keys match your element list
# This helper function loads starter data from github
cobalt_map, sulfur_map, oxygen_map, haadf_im = fusion.load_edx_example()
chemical_maps = {
    'Co': cobalt_map,      # 2D numpy arrays
    'S': sulfur_map, 
    'O': oxygen_map
}
fusion.load_chemical_maps(chemical_maps)

# Load the simultaneously acquired HAADF image
fusion.load_haadf(haadf_im)  # 2D numpy array

# Run the fusion algorithm 
# We can adjust with regularization parameters
fusion.run(
    nIter=50, 
    lambdaEDS = 0.005, lambdaTV=0.1,
    plot_images=True, plot_convergence=True)

# Get results in dictionary format
results = fusion.get_results()
fused_cobalt = results['Co']
fused_sulfur = results['S']

Documentation

Refer to the comprehensive tutorial to learn how to adjust the hyperparameters.

Citation

If you use any of the data and source codes in your publications and/or presentations, we request that you cite our papers:

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

mapfusion-0.9.1.tar.gz (1.6 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

mapfusion-0.9.1-cp312-cp312-win_amd64.whl (92.4 kB view details)

Uploaded CPython 3.12Windows x86-64

mapfusion-0.9.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (147.3 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

mapfusion-0.9.1-cp312-cp312-macosx_11_0_arm64.whl (99.4 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

mapfusion-0.9.1-cp311-cp311-win_amd64.whl (91.1 kB view details)

Uploaded CPython 3.11Windows x86-64

mapfusion-0.9.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (146.4 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

mapfusion-0.9.1-cp311-cp311-macosx_11_0_arm64.whl (98.5 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

mapfusion-0.9.1-cp310-cp310-win_amd64.whl (90.5 kB view details)

Uploaded CPython 3.10Windows x86-64

mapfusion-0.9.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (145.1 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

mapfusion-0.9.1-cp310-cp310-macosx_11_0_arm64.whl (97.2 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

mapfusion-0.9.1-cp39-cp39-win_amd64.whl (91.4 kB view details)

Uploaded CPython 3.9Windows x86-64

mapfusion-0.9.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (145.6 kB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

mapfusion-0.9.1-cp39-cp39-macosx_11_0_arm64.whl (97.3 kB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

mapfusion-0.9.1-cp38-cp38-win_amd64.whl (90.2 kB view details)

Uploaded CPython 3.8Windows x86-64

mapfusion-0.9.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (144.8 kB view details)

Uploaded CPython 3.8manylinux: glibc 2.17+ x86-64

mapfusion-0.9.1-cp38-cp38-macosx_11_0_arm64.whl (96.9 kB view details)

Uploaded CPython 3.8macOS 11.0+ ARM64

File details

Details for the file mapfusion-0.9.1.tar.gz.

File metadata

  • Download URL: mapfusion-0.9.1.tar.gz
  • Upload date:
  • Size: 1.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mapfusion-0.9.1.tar.gz
Algorithm Hash digest
SHA256 5f8339cf7bd8b361cc43449385ac919bb641ba4e233e3dfff42dc7e449f6273d
MD5 9a3b4fdbcab660c02cce1e2c42c9f8ba
BLAKE2b-256 d04fd349141190d76aeee38c10a8ee02d016c46deb412522edeafd324b62f0c8

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: mapfusion-0.9.1-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 92.4 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mapfusion-0.9.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 7dbba2278ed1b62a53393fdf385c2e69b7befd16f88bd6bb763f439b63a509b4
MD5 471cda66af1adddf64debc2beb4c73d3
BLAKE2b-256 90edec2b2157c2c96c8aa92b10cb989925794e3dd3791b9e5293ecc86644f595

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 573b7eac76a8bf88c22ca31ca5caf48647e8f58f17a68c3c2ab28e9f7cf48e86
MD5 84d05a409d95a78092082d8a2e0c77ef
BLAKE2b-256 4079cc9614bfb7a5b7338f795184092da396129b54f9dd53ed31d5d744d5727c

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 00bfe2b785aca50be6c2be62a63222096e29894dc2239601e9df1858d707a839
MD5 024a866f2d8cf7cb5cc7ab55229070cf
BLAKE2b-256 90cd64f4dd8ea74f2e061a02b4123952e8465da82465d676002b09983b9d87df

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: mapfusion-0.9.1-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 91.1 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mapfusion-0.9.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 1e689d9c716fc833d4f01a19ff805ba4cd6e36b3560d130ad69b68ccd4ca1ad5
MD5 eef1b4076e221ffcd8524bff856f34ae
BLAKE2b-256 2651a9825fe009354018d99e8bf933cb4bc9124dc3f7ada1ad644f0224d1c393

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e4c7930ffa751c0c990f7793145accf3f01be05138c1c8374d72a68ba3ec81f0
MD5 564b02e2567f0e7ae4e6e0baad52d15a
BLAKE2b-256 a718bae8ad4f98aaeb485b998e6725c56457ded7e582b09e17a49260cecec658

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 2b8a5ede51938ccb80b3357a49583d45780e847039fa3fb407ebba9cc2e7f23c
MD5 f445ac3ac5a67e0cfcf99cb0acb81a5a
BLAKE2b-256 4e1eaed8038be260bb758fa598561b6b3d9dbaa1de884d0d3d4054f6e283b4b5

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: mapfusion-0.9.1-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 90.5 kB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mapfusion-0.9.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 f015fd74fb25fbf83a5b60f339c287eaf8e77112bc3e33390e63f25168d752df
MD5 c073deb40570221c5f8165620ce253a7
BLAKE2b-256 ec0bba75e33fb6af8f64627d742af9ea6fd37bb0ba37b70715f1e772cc3fa61a

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 332d4cd53c3429d793935568d47a2de4b26e9538de5511af6f9ba49d179b634b
MD5 ffdac33afbc0d1ce7caa39f3a68870f0
BLAKE2b-256 5d636386518ed5b9b7d0e27e41c6d2c78e2a3cf8e8c59bc6c24eb8f9b1f5acd9

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f0ecc26d8d5cf15d9f979652b3e82839adad31c5e150e0ca0658b75dcf863236
MD5 62e145246794314337c42180c0559199
BLAKE2b-256 cc1e8dfdd5a5c6c0ffea2b835330852fc8d6db88ede3feb39196443654b2195c

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: mapfusion-0.9.1-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 91.4 kB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mapfusion-0.9.1-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 72d1b4a573e53ebb7a6713336377f597b78b7d81137a8a8811e797d166d66375
MD5 7047a6aa1c4a6a9cf8d611cce2be2814
BLAKE2b-256 6873bafce1c784e2617a218f6a6591bb225d0268083c43766ae05642bbcec7cc

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b32b8618c4610d600d1e624a2d50f5eea3dea9c4f8567b9c4f83d894f35df41d
MD5 fd8b0f4942cdba330847a6e5ce8c22e3
BLAKE2b-256 6d5d3c9e7d86be4890c561289fc3c058d74cdb5edde10e0f4cf63a042db35a36

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 9ed5f02c1355ea1239d7ad8a6c1576ef26df0d1852fd3bf3d60152d653d7972b
MD5 7e1ee6234ce803b032b3107f97ed91b0
BLAKE2b-256 6887e65aa2f676d52df8ce5c543bfa1223d7904e8694be1c685e7e904368bdab

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: mapfusion-0.9.1-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 90.2 kB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mapfusion-0.9.1-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 1e997985425ba38e195adae179c483a53a789752b98464ec2f142858913eea85
MD5 7d3199a4586e70c20307fff402f4f111
BLAKE2b-256 efb0b437ea6aa763b5d84b3a79f9b44a3d9ce6d262d4af02ec14b98122b683e6

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 6fccfa99a38c92315fca32ed268b774110a2b415714d60feb7ce4d2e622724c1
MD5 ba76d8bcfa93f68bce5ded8e5c6d566d
BLAKE2b-256 96f8a6b8a283739b003115ec438f0463133d1524ad857565fba17a78996d8779

See more details on using hashes here.

File details

Details for the file mapfusion-0.9.1-cp38-cp38-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for mapfusion-0.9.1-cp38-cp38-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 3626a06be78dc2d9f241bf67f27bd5902aed2dd73323ae5225c0aac8fc883b57
MD5 364ef086bb9cf7f0bb4c164efd5e4213
BLAKE2b-256 e6a4c4669191380c40528b4685357366f77d9c1838f4f2ad7ddc031bf05da602

See more details on using hashes here.

Supported by

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