Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RCv0.3 #44

Merged
merged 44 commits into from
May 23, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
3111ca7
Adding bounding circles to meshes and polygons to do collision check …
carterbox Nov 13, 2016
ba183a1
Moving beamintersect functions to the acquisition module because beam…
carterbox Nov 13, 2016
30a3bdd
Changed the raster_scan and angle_scan functions such that they retur…
carterbox Nov 13, 2016
cdb8f43
BUG: test_geometry was failing because import beamcirc and beampoly w…
carterbox Jan 11, 2017
a25e9c2
Integrating new `polytope` rotation functions with `Polygon` and `Bea…
carterbox Jan 11, 2017
f2e6ab1
Merge branch 'master' into polytope
carterbox Jan 12, 2017
0e4b9a8
Bumped some debugging print statements to the logger.
carterbox Jan 12, 2017
e2f1fbd
BUG: Probe did not properly translate beam.
carterbox Jan 21, 2017
26c1bea
MAINT: Update calls to polytope translation and rotation because of A…
carterbox Jan 21, 2017
03341ce
TST: Add benchmark test for sinogram computation of triangle and circle.
carterbox Jan 22, 2017
545d321
ENH: Update geometry.contains() functions
carterbox Mar 18, 2017
40d310f
TST: Add tests for geometry.contains()
carterbox Mar 19, 2017
6183542
ENH: Add __repr__ to geometry module
carterbox Mar 17, 2017
259fac9
API: Combine Phantom and Feature classes
carterbox Mar 15, 2017
3152098
ENH: Add XDesignDefault for internal testing of XDesign
carterbox Apr 14, 2017
de9d792
BUG: Made entities self-containing
carterbox May 2, 2017
e71bce9
PEP8: Removing line overflow and renaming ambiguous variables
carterbox May 2, 2017
ffe73f3
API: Remove Ellipse and Superellipse from public API
carterbox May 2, 2017
0b0ca48
BUG: Fix rotation for DefaultPhantom
carterbox May 2, 2017
d4d41fc
BUG: Fix plot_phantom_color_map by using float massatten
carterbox May 2, 2017
776ac2a
API: Moved phantom save and load functions out to module
carterbox May 3, 2017
598d6aa
TST: Convert material tests for new save and load
carterbox May 3, 2017
3e5afcb
Merge branch 'polytope' into dev
carterbox May 3, 2017
a926f64
Merge branch 'tree-phantom' into dev
carterbox May 3, 2017
cc3b439
API: Make metrics compatible new hierarchical phantom
carterbox May 3, 2017
0fee299
DOC: Rephase doc strings and add deprecation warnings
carterbox May 3, 2017
b37be8a
Merge branch 'tree-phantom' into dev
carterbox May 3, 2017
6093d71
TST: Remove Feature from sinogram_test
carterbox May 3, 2017
f0290d8
BUG: Remove redundant function definitions left over from merge
carterbox May 4, 2017
19a57e1
ENH: Add __repr__ to Beam and Probe
carterbox Mar 17, 2017
fd66220
TST: Add logger.debug statement
carterbox May 4, 2017
2cd929f
DOC: Improve documentation for algorithm module.
carterbox Jan 25, 2017
0e11040
DOC: Improve docstrings for acquistion module.
carterbox Jan 25, 2017
1de3bdb
DOC: Remove traces of `Feature` class from docs
carterbox May 4, 2017
fb0e42d
REF: Replace hstack and vstack with concatenate and stack
carterbox May 4, 2017
74f6c67
API: Add Probe to things returned by sinogram, angleogram
carterbox May 4, 2017
b23d2a3
DOC: Updating demonstrations to use `sinogram`
carterbox May 5, 2017
9254d8f
REL: Add polytope to requirements
carterbox May 7, 2017
2259cef
DOC: Update documentation
carterbox May 17, 2017
28b1b49
DOC: Make doc index more informative
carterbox May 17, 2017
47d1a44
DOC: Run notebooks automatically for doc page
carterbox May 17, 2017
092cbf3
DOC: Clean up mock modules for readthedocs build
carterbox May 17, 2017
ff28b81
Merge pull request #47 from tomography/sphinxnb
carterbox May 18, 2017
7597008
REL: Bump version to 0.3
carterbox May 23, 2017
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
354 changes: 0 additions & 354 deletions docs/demos/FullReferenceMetrics.ipynb

This file was deleted.

439 changes: 0 additions & 439 deletions docs/demos/NoReferenceMetrics.ipynb

This file was deleted.

241 changes: 0 additions & 241 deletions docs/demos/Shepp.ipynb

This file was deleted.

276 changes: 0 additions & 276 deletions docs/demos/StandardPatterns.ipynb

This file was deleted.

5 changes: 3 additions & 2 deletions docs/source/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ API

api/xdesign.acquisition
api/xdesign.algorithms
api/xdesign.feature
api/xdesign.geometry
api/xdesign.constants
api/xdesign.formats
api/xdesign.material
api/xdesign.metrics
api/xdesign.phantom
Expand All @@ -17,4 +18,4 @@ API
.. automodule:: xdesign
:members:
:undoc-members:
:show-inheritance:
:show-inheritance:
28 changes: 15 additions & 13 deletions docs/source/api/xdesign.acquisition.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,22 @@
==========================

.. automodule:: xdesign.acquisition
:members:
:show-inheritance:
:undoc-members:
:synopsis: Defines objects related to collection and organization of probe data.
:members:
:show-inheritance:
:undoc-members:

.. rubric:: **Functions:**
.. rubric:: **Classes:**

.. autosummary::
.. autosummary::

Beam
Probe
sinogram
angleogram
raster_scan
angle_scan
Beam
Probe

.. moduleauthor:: Doga Gursoy <[email protected]>
.. rubric:: **Functions:**

.. autosummary::

sinogram
angleogram
raster_scan
angle_scan
5 changes: 1 addition & 4 deletions docs/source/api/xdesign.algorithms.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,13 @@
:members:
:show-inheritance:
:undoc-members:
:synopsis: Defines methods for reconstructing data from the :mod:`.acquisition` module.

.. rubric:: **Functions:**

.. autosummary::

reconstruct
art
sirt
mlem
stream

.. moduleauthor:: Doga Gursoy <[email protected]>
update_progress
4 changes: 4 additions & 0 deletions docs/source/api/xdesign.constants.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
:mod:`xdesign.constants`
========================

.. automodule:: xdesign.constants
16 changes: 0 additions & 16 deletions docs/source/api/xdesign.feature.rst

This file was deleted.

11 changes: 11 additions & 0 deletions docs/source/api/xdesign.formats.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
:mod:`xdesign.formats`
======================

.. automodule:: xdesign.formats
:members:
:show-inheritance:
:undoc-members:

.. rubric:: **Functions:**

.. autosummary::
16 changes: 6 additions & 10 deletions docs/source/api/xdesign.geometry.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@
=======================

.. automodule:: xdesign.geometry
:members:
:show-inheritance:
:inherited-members:
:undoc-members:
:synopsis: Defines geometric objects for the purpose of supporting :class:`.Feature` definition and calculating intersections for the :mod:`.acquisition` module.
:members:
:show-inheritance:
:inherited-members:

.. rubric:: **Classes:**
.. rubric:: **Classes:**

.. autosummary::

.. autosummary::
Entity
Point
Circle
Expand All @@ -20,6 +19,3 @@
Square
Polygon
Mesh

.. moduleauthor:: Doga Gursoy <[email protected]>
.. moduleauthor:: Daniel J Ching <[email protected]>
6 changes: 2 additions & 4 deletions docs/source/api/xdesign.material.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
:members:
:show-inheritance:
:undoc-members:
:synopsis: Defines objects which auto-generate a parameterized :class:`.Phantom`.

.. rubric:: **Functions:**
.. rubric:: **Classes:**

.. autosummary::

Material
XDesignDefault
HyperbolicConcentric
DynamicRange
DogaCircles
Expand All @@ -25,5 +25,3 @@
SoftBiomaterial
Electronics
FiberComposite

.. moduleauthor:: Daniel J Ching <[email protected]>
20 changes: 11 additions & 9 deletions docs/source/api/xdesign.metrics.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,23 @@
:members:
:show-inheritance:
:undoc-members:
:synopsis: Objects and methods for computing the quality of reconstructions.

.. rubric:: **Functions:**
.. rubric:: **Classes:**

.. autosummary::

ImageQuality
probability_mask
compute_quality

.. rubric:: **Functions:**

.. autosummary::

compute_PCC
compute_likeness
compute_background_ttest
compute_mtf
compute_mtf_siemens
compute_nps
compute_neq

.. moduleauthor:: Daniel J Ching <[email protected]>
compute_mtf_ffst
compute_mtf_lwkj
compute_nps_ffst
compute_neq_d
compute_quality
5 changes: 1 addition & 4 deletions docs/source/api/xdesign.phantom.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,9 @@
:members:
:show-inheritance:
:undoc-members:
:synopsis: Defines an object for organizing :class:`.Feature`.

.. rubric:: **Functions:**
.. rubric:: **Classes:**

.. autosummary::

Phantom

.. moduleauthor:: Daniel J Ching <[email protected]>
4 changes: 0 additions & 4 deletions docs/source/api/xdesign.plot.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
:members:
:show-inheritance:
:undoc-members:
:synopsis: Contains functions for visualizing :class:`.Phantom` and :class:`.ImageQuality` metrics.

.. rubric:: **Functions:**

Expand All @@ -14,13 +13,10 @@
sidebyside
discrete_phantom
plot_phantom
plot_feature
plot_mesh
plot_polygon
plot_curve
plot_metrics
plot_mtf
plot_nps
plot_neq

.. moduleauthor:: Daniel J Ching <[email protected]>
6 changes: 3 additions & 3 deletions docs/source/bibtex/cite.bib
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@Article{ching:17,
author = "Ching, Daniel J. and G{\"{u}}rsoy, Do{\v{g}}a",
title = "{{\it XDesign}: an open-source software package for designing X-ray imaging phantoms and experiments}",
@Article{ching:17,
author = "Ching, Daniel J. and G{\"{u}}rsoy, Do{\v{g}}a",
title = "{XDesign: an open-source software package for designing X-ray imaging phantoms and experiments}",
journal = "Journal of Synchrotron Radiation",
year = "2017",
volume = "24",
Expand Down
9 changes: 9 additions & 0 deletions docs/source/bibtex/refs.bib
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,15 @@ @article{Sufian:15
year = {2015}
}

@inproceedings{loebich2007digital,
title={Digital camera resolution measurement using sinusoidal Siemens stars},
author={Loebich, Christian and Wueller, Dietmar and Klingen, Bruno and Jaeger, Anke},
booktitle={Electronic Imaging 2007},
pages={65020N--65020N},
year={2007},
organization={International Society for Optics and Photonics}
}

@article{Bergamaschi:fv5047,
author = "Bergamaschi, Antoine and Medjoubi, Kadda and Messaoudi, C{\'{e}}dric and Marco, Sergio and Somogyi, Andrea",
title = "{{\it MMX-I}: data-processing software for multimodal X-ray imaging and tomography}",
Expand Down
63 changes: 24 additions & 39 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

import sys
import os
from unittest.mock import MagicMock

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
Expand All @@ -23,7 +24,7 @@
# -- General configuration ------------------------------------------------

# If your documentation needs a minimal Sphinx version, state it here.
#needs_sphinx = '1.0'
# needs_sphinx = '1.0'

# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
Expand All @@ -40,6 +41,8 @@
'sphinx.ext.viewcode',
'sphinx.ext.napoleon',
'sphinxcontrib.bibtex',
'nbsphinx',
'IPython.sphinxext.ipython_console_highlighting',
]

# Napoleon settings
Expand All @@ -63,7 +66,7 @@
source_suffix = '.rst'

# The encoding of source files.
#source_encoding = 'utf-8-sig'
# source_encoding = 'utf-8-sig'

# The master toctree document.
master_doc = 'index'
Expand All @@ -79,7 +82,7 @@
#
# The short X.Y version.
# The full version, including alpha/beta/rc tags.
release = '0.1'
release = '0.3'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand All @@ -96,7 +99,7 @@

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
exclude_patterns = []
exclude_patterns = ['_build', '**.ipynb_checkpoints']

# The reST default role (used for this markup: `text`) to use for all
# documents.
Expand Down Expand Up @@ -168,7 +171,7 @@
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
# html_static_path = ['_static']

# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied
Expand Down Expand Up @@ -315,42 +318,24 @@
# texinfo_no_detailmenu = False

# Example configuration for intersphinx: refer to the Python standard library.
intersphinx_mapping = {'https://docs.python.org/': None}
intersphinx_mapping = {'https://docs.python.org/3': None}

# picked from http://read-the-docs.readthedocs.org/en/latest/faq.html
class Mock(object):

__all__ = []
# picked from http://read-the-docs.readthedocs.org/en/latest/faq.html
class Mock(MagicMock):
@classmethod
def __getattr__(cls, name):
return MagicMock()

def __init__(self, *args, **kwargs):
pass

def __call__(self, *args, **kwargs):
return Mock()
MOCK_MODULES = ['numpy',
'matplotlib', 'matplotlib.pyplot', 'matplotlib.patches',
'matplotlib.path', 'matplotlib.patheffects', 'matplotlib.axis',
'polytope',
'cached_property',
'scipy', 'scipy.stats', 'scipy.ndimage', 'scipy.spatial',
'cycler',
'phasepack',
]

@classmethod
def __getattr__(cls, name):
return Mock()
def __mul__(self, other):
return Mock()
def __rmul__(self, other):
return Mock()
def __pow__(self, other):
return Mock()
def __div__(self, other):
return Mock()
def __add__(self, other):
return Mock()
def __radd__(self, other):
return Mock()

MOCK_MODULES = [
'cached_property', 'cycler', 'intertools',
'matplotlib', 'matplotlib.pyplot', 'matplotlib.patches',
'matplotlib.path', 'matplotlib.patheffects', 'matplotlib.axis',
'math', 'numpy', 'numbers', 'phasepack', 'polytope',
'scipy', 'scipy.stats', 'scipy.ndimage', 'scipy.spatial',
]

for mod_name in MOCK_MODULES:
sys.modules[mod_name] = Mock()
sys.modules.update((mod_name, Mock()) for mod_name in MOCK_MODULES)
Loading