Commit 252fd0ce authored by Edward Andò's avatar Edward Andò
Browse files

Merge branch 'master' into splitImage

parents 4cf652b5 c4e67847
......@@ -15,6 +15,7 @@ build:
test:
stage: test
script:
- pip install -r requirements.txt
- pip install -r requirements-dev.txt
- python setup.py install
- python setup.py test
......@@ -33,6 +34,7 @@ pages:
GIT_SUBMODULE_STRATEGY: normal
stage: pages
script:
- pip install -r requirements.txt
- pip install -r requirements-dev.txt
- python setup.py install
- python setup.py build_sphinx
......
......@@ -66,6 +66,9 @@ Changelog
+-----------------+------------+--------------------------------------------------------------------------------------------------------------------------------------+
| Version | Date | Notes |
+=================+============+======================================================================================================================================+
| 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 |
......
......@@ -4,44 +4,66 @@ DIC package
Submodules
----------
DIC.DICToolkit module
---------------------
.. automodule:: DIC.DICToolkit
:members:
:undoc-members:
:show-inheritance:
DIC.DICToolkit module
---------------------
.. automodule:: DIC.DICToolkit
:members:
:undoc-members:
:show-inheritance:
DIC.DICtoolkit module
---------------------
.. automodule:: DIC.DICtoolkit
:members:
:undoc-members:
:show-inheritance:
DIC.correlate module
--------------------
.. automodule:: DIC.correlate
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
DIC.correlateGM module
----------------------
.. automodule:: DIC.correlateGM
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
DIC.deform module
-----------------
.. automodule:: DIC.deform
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
DIC.grid module
---------------
.. automodule:: DIC.grid
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: DIC
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
{% extends "!layout.html" %}
{% block menu %}
{{ super() }}
<a href="/spam/py-modindex.html">Module Index</a>
{% endblock %}
......@@ -4,30 +4,26 @@ deformation package
Submodules
----------
deformation.deformationFunction module
--------------------------------------
.. automodule:: deformation.deformationFunction
:members:
:undoc-members:
:show-inheritance:
deformation.deformationField module
--------------------------------------
-----------------------------------
.. automodule:: deformation.deformationField
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
deformation.deformationFunction module
--------------------------------------
.. automodule:: deformation.deformationFunction
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: deformation
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -8,23 +8,22 @@ excursions.elkc module
----------------------
.. automodule:: excursions.elkc
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
excursions.randomFields module
------------------------------
.. automodule:: excursions.randomFields
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: excursions
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -4,27 +4,42 @@ filters package
Submodules
----------
filters.filtersToolkit module
-----------------------------
.. automodule:: filters.filtersToolkit
:members:
:undoc-members:
:show-inheritance:
filters.filtersToolkit module
-----------------------------
.. automodule:: filters.filtersToolkit
:members:
:undoc-members:
:show-inheritance:
filters.morphologicalOperations module
--------------------------------------
.. automodule:: filters.morphologicalOperations
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
filters.movingFilters module
----------------------------
.. automodule:: filters.movingFilters
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: filters
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -5,50 +5,49 @@ Submodules
----------
helpers.histogramTools module
--------------------------------
-----------------------------
.. automodule:: helpers.histogramTools
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
helpers.imageManipulation module
--------------------------------
.. automodule:: helpers.imageManipulation
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
helpers.optionsParser module
----------------------------
.. automodule:: helpers.optionsParser
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
helpers.tsvio module
--------------------
.. automodule:: helpers.tsvio
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
helpers.vtkio module
--------------------
.. automodule:: helpers.vtkio
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: helpers
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -8,15 +8,38 @@ kalisphera.kalisphera module
----------------------------
.. automodule:: kalisphera.kalisphera
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
kalisphera.kalispheraToolkit module
-----------------------------------
.. automodule:: kalisphera.kalispheraToolkit
:members:
:undoc-members:
:show-inheritance:
kalisphera.kalispheraToolkit module
-----------------------------------
.. automodule:: kalisphera.kalispheraToolkit
:members:
:undoc-members:
:show-inheritance:
kalisphera.spheroid module
--------------------------
.. automodule:: kalisphera.spheroid
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: kalisphera
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -8,31 +8,46 @@ label.ITKwatershed module
-------------------------
.. automodule:: label.ITKwatershed
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
label.contacts module
---------------------
.. automodule:: label.contacts
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
label.label module
------------------
.. automodule:: label.label
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
label.labelToolkit module
-------------------------
.. automodule:: label.labelToolkit
:members:
:undoc-members:
:show-inheritance:
label.labelToolkit module
-------------------------
.. automodule:: label.labelToolkit
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: label
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -8,31 +8,46 @@ measurements.covariance module
------------------------------
.. automodule:: measurements.covariance
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
measurements.globalDescriptors module
-------------------------------------
.. automodule:: measurements.globalDescriptors
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
measurements.measurementsToolkit module
---------------------------------------
.. automodule:: measurements.measurementsToolkit
:members:
:undoc-members:
:show-inheritance:
measurements.measurementsToolkit module
---------------------------------------
.. automodule:: measurements.measurementsToolkit
:members:
:undoc-members:
:show-inheritance:
measurements.porosityField module
---------------------------------
.. automodule:: measurements.porosityField
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: measurements
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -4,35 +4,50 @@ mesh package
Submodules
----------
mesh.meshToolkit module
-----------------------
.. automodule:: mesh.meshToolkit
:members:
:undoc-members:
:show-inheritance:
mesh.meshToolkit module
-----------------------
.. automodule:: mesh.meshToolkit
:members:
:undoc-members:
:show-inheritance:
mesh.projection module
----------------------
.. automodule:: mesh.projection
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
mesh.structured module
----------------------
.. automodule:: mesh.structured
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
mesh.unstructured module
------------------------
.. automodule:: mesh.unstructured
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: mesh
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -8,47 +8,46 @@ plotting.greyLevelHistogram module
----------------------------------
.. automodule:: plotting.greyLevelHistogram
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
plotting.multivariateGaussians module
-------------------------------------
.. automodule:: plotting.multivariateGaussians
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
plotting.orientationPlotter module
----------------------------------
.. automodule:: plotting.orientationPlotter
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
plotting.particleSizeDistribution module
----------------------------------------
.. automodule:: plotting.particleSizeDistribution
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
plotting.tetrahedraPlotter module
---------------------------------
.. automodule:: plotting.tetrahedraPlotter
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
Module contents
---------------
.. automodule:: plotting
:members:
:undoc-members:
:show-inheritance:
:members:
:undoc-members:
:show-inheritance:
......@@ -125,6 +125,7 @@ For this reason the threshold is made on the image after the application of a va
Please note that it's also possible to use the variance filter in scipy through the *generic* interface as follows::
import scipy
standardDev = numpy.sqrt(scipy.ndimage.generic_filter(im.astype(float), numpy.var, footprint=structEl))
but it's more than 100 times slower!
......@@ -140,8 +141,8 @@ Then the aggregates are dilated 2 times in order to retrieve their original size
# now aggregates are dilated 2 times
for i in range(2):
aggregates = sfilters.binaryDilation(aggregates)
aggregates = spam.filters.binaryDilation(aggregates)
plt.imshow(aggregates[aggregates.shape[0]//2], cmap="Greys"); plt.title("Horizontal slice of the identified aggregates"); plt.show()
.. figure:: images/tutorial/06-projection/aggregates.png
......@@ -157,7 +158,7 @@ An array with all the phases can now be created where the value of each voxel wi
# mortar -> 1
# pores -> 2
# aggregates -> 3
phases = numpy.ones_like(im).astype('<u1')*sfilters.binaryErosion(mask)
phases = numpy.ones_like(im).astype('<u1')*spam.filters.binaryErosion(mask)
phases[pores==1] = 2
phases[aggregates==1] = 3
......@@ -217,7 +218,7 @@ Step 2.2: Create the Finite Element Mesh
For the projection we need an unstructured 3D mesh made of 4-node tetrahedra.
At this stage we have to consider the physical dimensions to the FE mesh.
We use the module `mesh.unstructured` which is a wrapper of `pygmsh` and `meshio` to create the needed `.msh` file
We use the module `mesh.unstructured` which is a wrapper of `meshio` to create the needed `.msh` file
and a vtk for visualisation::
# specimen dimensions in mm
......@@ -229,10 +230,10 @@ and a vtk for visualisation::
# create the gmsh file needed for the projection
points, connectivity = spam.mesh.createCylinder(centre, radius, height, lcar, gmshFile="cylinder")