Skip to main content

Software for the Practical Analysis of Materials

Project description

https://img.shields.io/badge/license-GPLv3-blue.svg https://gitlab.com/spam-project/spam/badges/master/pipeline.svg https://gitlab.com/spam-project/spam/badges/master/coverage.svg https://badge.fury.io/py/spam.svg https://joss.theoj.org/papers/10.21105/joss.02286/status.svg https://static.pepy.tech/badge/spam/month https://img.shields.io/static/v1?label=Chat&color=green&logo=matrix&style=social&message=join

Spam is a piece of Python software built upon NumPy and SciPy for the analysis and manipulation of 3D and 2D data sets in material science, be they from x-ray tomography, random fields or any other source.

A number of common functions are provided that are either lacking or slow in Numpy and Scipy, which are expected to be used by users within new python scripts. These functions are in the tools/ directory, and include tools to work with random fields, morphological operations, digital image correlation, and labelled images. Some of spam’s functions transparently call C/C++ functions for speed.

Some user-callable scipts are also provided – they are more complex pieces of code that combine a number of functions and which have a command-line interface. For the moment the scripts are 3 different image correlation techniques.

Please have a look at our online documentation for:

If you find bugs, need help, or want to talk to the developers, we use a element.io/matrix.org chat room for organisation, please join it here and come and talk to us – it is easy, there is a chat client that can run in your web broswer. All you need to do is choose a user name!

Changelog

Version

Date

Notes

Version 0.7.1.0

2024-03-06

Scripts are now called through python functions and are moved to src/spam/scripts

Version 0.7.0.1

2024-02-16

Remove R dependency for generating random fields in favor of gstools

Version 0.6.5.2

2024-01-24

Update returnStatus for the registration and local DIC differentiating image texture and transformation operator issues

Version 0.6.5.1

2023-12-04

Drop python 3.8 and update doc links

Version 0.6.5

2023-11-23

Revamp documentation

Version 0.6.4

2023-08-28

new returnPhiMaskCentre option in spam.DIC.register()

Version 0.6.3.2

2023-07-19

Fix inputs to spam-ereg, impose same-sized images in spam-reg

Version 0.6.3.1

2023-07-07

Revert inputs to spam-ereg, update links on pypi

Version 0.6.3

2023-07-06

Fixes masking in register(), move to pyproject.toml, and 2D imShowProgress and applyPhiPython

Version 0.6.2.1

2023-03-21

Imports in graphical tools fixed

Version 0.6.2

2023-03-17

Fixes to registration, pep8 and black the whole code, dev on global and projection

Version 0.6.1.3

2022-10-25

Fix for histogramTools, a number of library calls updated for deprecation warnings

Version 0.6.1.2

2022-09-22

Parallelised tetLabel, safety in spam-pixelSearch, -skp in spam-ldic

Version 0.6.1.1

2022-01-20

Registration subtraction option for spam-passPhiField (-regs)

Version 0.6.1

2021-10-29

New package spam.orientations and segmentations functions

Version 0.6.0.3

2021-07-08

Fixed -applyF check. Now registration guess is correctly applied to a set of points

Version 0.6.0.2

2021-06-23

Fixed spam-mmr-graphical and PyQt5 dependencies. New spam.plotting.plotSphericalHistogram renders a 3D orientation distribution!

Version 0.6.0.1

2021-05-20

Small fixes to spam-filterPhifield and spam-regularStrain

Version 0.6.0

2021-05-04

Massive rewrite of image correlation scripts, introduction of spam-pixelSearchPropagate, spam-filterPhiField, spam-passPhiField. The spam-pixelSearch is now separate from spam-ldic and spam-ddic, and works both in grid and labelled mode. Please check out new script documentation for a flowchart of how these should be used in series. Loads of scripts and quite a few functions are now multiprocess, and MPI parallelisation is completely dropped along with mpi4py. pygmsh dependency is also now dropped

Version 0.5.3.4

2021-03-19

Last version to support python 3.5. Update gradient option in spam-ldic, new function to generate pixelated spheroids: spam.kalisphera.makeBlurryNoisySpheroid()

Version 0.5.3.3

2020-11-27

spam-reg script, spam-ereg-discrete writing fix, spam-ldic update gradient option, implementation of Geers in 2D

Version 0.5.3.2

2020-10-27

spam-ereg-discrete mask option reinstated, many fixes for spam-ldic and registerMultiscale() for 2D images

Version 0.5.3.1

2020-10-23

spam-ereg-discrete make safer with slicePadded and moveGrains now renamed to moveLabels and proposed as function with erodeLabels

Version 0.5.3

2020-10-07

Improvements in edge cases in spam-ldic and spam-ddic, thanks to a helper function called spam.helpers.slicePadded(). New debug mode for spam-ddic as well as a graphical tool to manually align labels called spam-ereg-discrete

Version 0.5.2.1

2020-07-20

This is the version in the JOSS paper. Making python 3.8 package for PyPI, along with classifiers. Python 2.7 dropped

Version 0.5.2

2020-06-03

Big improvements in spam-mmr and spam-mmr-graphical, all TSVs im1->im2 and gradients always computed in im2

Version 0.5.1.5

2020-05-28

Don’t recompute Jacobian in register if not needed. Safety in pixel search

Version 0.5.1.4

2020-05-16

Fix spam-deformImageFromField, C++14

Version 0.5.1.3

2020-04-20

Fix spam-mmr and improvements to pixel search in spam-ddic

Version 0.5.1.2

2020-04-20

Fix and test for large initial guesses in register(), spam-mmr-graphical revived

Version 0.5.1.1

2020-04-08

Fix for running spam-ldic for pixel search

Version 0.5.1

2020-04-07

Fix for running spam-ddic with mpi, implementation of S. Brisard’s Directional Erosion

Version 0.5.0

2020-03-27

Big rename of scripts, functions, variables, parameters, with some backwards compatibility in TSV file reading. Some examples:

  • spam.correlate.lucasKanade -> spam.correlate.register

  • spam.helpers.readTSV -> spam.helpers.readCorrelationTSV

New framework for the calculation of strains, where the computation of F is separated from its decomposition. Output fields from correlation with prefixes “SubPix” and “SubPixel” become prefixless In TSV outputs from correlation the components like “F12” are now called “Fzy”

Version 0.4.3

2020-01-16

Various fixes to graphical clients (able to save TSV from spam-mmr-graphical and do a last, precise run with spam-mmr). Improvement to triangulation (now with CGAL alpha shapes) and discrete strain calculator (tested results)

Version 0.4.2

2019-09-25

spam-mmr-graphical now working, improvements in spam-mmr.

Version 0.4.1

2019-09-13

spam-mmr-graphical now working (c-python type error). Various bugfixes in clients. spam-ITKwatershed now accepts markers

Version 0.4.0

2019-07-18

c++ now bound with pybind11. New graphical script spam-mmr-graphical for multi-modal registration. New graphical script spam-ereg for eye (manual) registration. Python3 upgrade recommended for all users

Version 0.3.3.1

2019-05-27

Binning 2^31 fix, remove lines for immediate prints that are not py3 compatible First version with CGAL triangulation

Version 0.3.2.1

2019-05-14

Update pip documentation and changelog

Version 0.3.2

2019-04-30

Fix segfault with images larger than 2^31 voxels, and output both subtracted and original fields in spam-ldic

Version 0.3.1

2019-04-08

Fix a number of forgotten spam.DIC.transformationOperator functions

Version 0.3.0

2019-03-28

Consistent naming in DIC: Phi is 4x4 homogeneous deformation function and F is its internal 3x3 displacement gradient

Version 0.2.2.2

2019-03-21

First version on pip with complete dependencies. This version of spam runs fully in a venv with pip install spam

Version 0.2.2.1

2019-03-20

Pull in requirements.txt into setup.py automatically. This aligns the build from git with the build from pip.

Version 0.2.2

2019-02-21

Approximate python3 compatibility

Version 0.2.1

2019-02-18

Add PyPI documentation to pip in RST

Version 0.2.0

2019-02-18

Add PyPI documentation to README.rst to appear on pip. Note that the build status and coverage badges won’t appear until access to gitlab is opened

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

spam-0.7.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (7.5 MB view details)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

spam-0.7.1.0-cp312-cp312-macosx_12_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.12 macOS 12.0+ ARM64

spam-0.7.1.0-cp312-cp312-macosx_11_0_x86_64.whl (7.0 MB view details)

Uploaded CPython 3.12 macOS 11.0+ x86-64

spam-0.7.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (7.5 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

spam-0.7.1.0-cp311-cp311-macosx_12_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.11 macOS 12.0+ ARM64

spam-0.7.1.0-cp311-cp311-macosx_11_0_x86_64.whl (7.0 MB view details)

Uploaded CPython 3.11 macOS 11.0+ x86-64

spam-0.7.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (7.5 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

spam-0.7.1.0-cp310-cp310-macosx_12_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.10 macOS 12.0+ ARM64

spam-0.7.1.0-cp310-cp310-macosx_11_0_x86_64.whl (6.9 MB view details)

Uploaded CPython 3.10 macOS 11.0+ x86-64

spam-0.7.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (7.5 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

spam-0.7.1.0-cp39-cp39-macosx_12_0_arm64.whl (6.9 MB view details)

Uploaded CPython 3.9 macOS 12.0+ ARM64

spam-0.7.1.0-cp39-cp39-macosx_11_0_x86_64.whl (7.0 MB view details)

Uploaded CPython 3.9 macOS 11.0+ x86-64

File details

Details for the file spam-0.7.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1c0b29a603f033c6f345a4a92a0bca016df13aeca82e4bd215e3e05e81af707c
MD5 e6a095ac74e21893159de45e9252e4f2
BLAKE2b-256 854a690c45183edf332d3677977b0194208f9b046afac2c71261ecb91ab5a419

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp312-cp312-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp312-cp312-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 8195d94367788246f80486229f347bf2c584459d55d62bbae8f7a5503391ec78
MD5 7bd148ae952c7d1b31ce1ba1abbea4ca
BLAKE2b-256 cad7c2e98412dcf29e7e44f76d0709d0897ad611756a1fecfc32a514085ec434

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp312-cp312-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp312-cp312-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 90f7a0e5b7cd1ae3930d735b16c966d30cec74668dcd367c873c3cbd4e66810e
MD5 03a8942675dfc11767d60a2968b713e5
BLAKE2b-256 f006c369144524c9c0d584804aeeaabddf15f8cecc6cec5db5de39120cdb65a1

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 77daa5e285a06d67ab43d7424381af77afa9a72ba9a42ce399ea0f2704f7df29
MD5 80019cae40f41016903f086630082867
BLAKE2b-256 36411c9e261f9fc66df2e6920a81b69abc469501d3cffe42824868f307e8c880

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp311-cp311-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp311-cp311-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 6a421baa385ba132936c97b28c51a90ff76669b65bf63c9bf81e5dd2f28122eb
MD5 7b12d276784b6ea7d683db9d6407e10a
BLAKE2b-256 c8d1481f6c11466589fc51c7699061f0bb333dc0d940800eee8727f94a206b36

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp311-cp311-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp311-cp311-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 3387ef2b5f5e8c091c534012bad0b52a03594e59c82c60f374b62a52194feca9
MD5 3d58e03006568d4e6c7c4c82628ea317
BLAKE2b-256 8e548df37fd323b0c45b67aa60bf89b4be3076d03bba3a622002f82595d7d22d

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e6376ec2b437e5b37c7e8768b671432534619930e38df308c87b6a82031ade19
MD5 2b674a20cad1cce0d72a1e327cf97ec6
BLAKE2b-256 008be9694ceb140b10093e4dd445c9264843f9952661979641e391717bc08465

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp310-cp310-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp310-cp310-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 2de51212b32ebdd2facca3f336fd21f6a6046d7cf52c796e39552b102fbd4e1d
MD5 241f7ab934da8bad8f6f02bf905a7a53
BLAKE2b-256 43fd7451a9263ecfefa35b44b46b938b33cc91dff4c202dd43b94e75186222f2

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp310-cp310-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp310-cp310-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 4735ca2bfe17d2be997eb5a5aa7b051d4c6bdad2f6162ed8caf7bdc38840bc95
MD5 5f6136bcf3258ff93a3b3e5b181db63d
BLAKE2b-256 b060d560a2b9eaaae4fd13f08fb858fc2dad5663c39636735a78771f00a3b6ac

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0a6c60bedb9b0e47c1e808f5968e56e8c9e30e9c7ebe13c389f8a1a3fa488d41
MD5 10baf6d03c3d4acd4b0d1b217cee8477
BLAKE2b-256 4d8a909eed976cd4b26d69281d3ea7a8a06d6e5f194563b1653c284ff081805f

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp39-cp39-macosx_12_0_arm64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp39-cp39-macosx_12_0_arm64.whl
Algorithm Hash digest
SHA256 dad7ff619e638dd9a7e6f0ae4443182431f138ce2e28cf0de9949a216f102c3b
MD5 af10b6def04c1ef51472ff54d5cd7da1
BLAKE2b-256 e854577e6e1211138f05ce8e622ff9641fa5256fe22478b8281a4fd1ef8bf91c

See more details on using hashes here.

File details

Details for the file spam-0.7.1.0-cp39-cp39-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for spam-0.7.1.0-cp39-cp39-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 1b8d2fcf1d4a732b75c574bdc213bbb3b3719296961b62c504a081609946e133
MD5 694aaf6eae56bab10aef5de4e726e10c
BLAKE2b-256 6aefec96fc8eeb34edbf7090d876a28ac9cbd35492d88c21648d229dc613cef1

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