xdesign.material

Functions:

Material(formula, density) Placeholder for class which uses NIST data to automatically calculate material properties based on beam energy.
HyperbolicConcentric([min_width, exponent]) Generates a series of cocentric alternating black and white circles whose radii are changing at a parabolic rate.
DynamicRange([steps, jitter, shape]) Generates a phantom of randomly placed circles for determining dynamic range.
DogaCircles([n_sizes, size_ratio, n_shuffles]) Rows of increasingly smaller circles.
SlantedSquares([count, angle, gap]) Generates a collection of slanted squares.
UnitCircle([radius, mass_atten]) Generates a phantom with a single circle in its center.
Soil([porosity]) Generates a phantom with structure similar to soil.
WetCircles()
SiemensStar([n_sectors, center, radius]) Generates a Siemens star.
Foam([size_range, gap, porosity]) Generates a phantom with structure similar to foam.
Metal([shape])
SoftBiomaterial([shape])
Electronics([shape])
FiberComposite([shape])
class xdesign.material.Material(formula, density)[source]

Bases: object

Placeholder for class which uses NIST data to automatically calculate material properties based on beam energy.

atom_concentration

Number of atoms per unit volume [1/cm^3].

atomic_form_factor

Measure of the scattering amplitude of a wave by an isolated atom. Read from NIST database [Unitless].

compton_cross_section

Compton cross-section of the electron [cm^2].

compton_scattering

X-ray attenuation due to the Compton scattering [1/cm].

electron_density

Electron density [e/cm^3].

linear_attenuation

Total x-ray attenuation [1/cm].

mass_ratio()[source]
number_of_elements()[source]
photoelectric_absorption

X-ray attenuation due to the photoelectric effect [1/cm].

photoelectric_cross_section
reduced_energy_ratio

Energy ratio of the incident x-ray and the electron energy [Unitless].

refractive_index
class xdesign.material.HyperbolicConcentric(min_width=0.1, exponent=0.5)[source]

Bases: xdesign.phantom.Phantom

Generates a series of cocentric alternating black and white circles whose radii are changing at a parabolic rate. These line spacings cover a range of scales and can be used to estimate the Modulation Transfer Function. The radii change according to this function: r(n) = r0*(n+1)^k.

radii

list

The list of radii of the circles

widths

list

The list of the widths of the bands

class xdesign.material.DynamicRange(steps=10, jitter=True, shape=u'square')[source]

Bases: xdesign.phantom.Phantom

Generates a phantom of randomly placed circles for determining dynamic range.

Parameters:
  • steps (scalar, optional) – The orders of magnitude (base 2) that the colors of the circles cover.
  • jitter (bool, optional) – True : circles are placed in a jittered grid False : circles are randomly placed
  • shape (string, optional)
class xdesign.material.DogaCircles(n_sizes=5, size_ratio=0.5, n_shuffles=5)[source]

Bases: xdesign.phantom.Phantom

Rows of increasingly smaller circles. Initally arranged in an ordered Latin square, the inital arrangement can be randomly shuffled.

radii

ndarray

radii of circles

x

ndarray

x position of circles

y

ndarray

y position of circles

class xdesign.material.SlantedSquares(count=10, angle=0.08726646259972222, gap=0)[source]

Bases: xdesign.phantom.Phantom

Generates a collection of slanted squares. Squares are arranged in concentric circles such that the space between squares is at least gap. The size of the squares is adaptive such that they all remain within the unit circle.

angle

scalar

the angle of slant in radians

count

scalar

the total number of squares

gap

scalar

the minimum space between squares

side_length

scalar

the size of the squares

squares_per_level

list

the number of squares at each level

radius_per_level

list

the radius at each level

n_levels

scalar

the number of levels

class xdesign.material.UnitCircle(radius=0.5, mass_atten=1)[source]

Bases: xdesign.phantom.Phantom

Generates a phantom with a single circle in its center.

class xdesign.material.Soil(porosity=0.412)[source]

Bases: xdesign.phantom.Phantom

Generates a phantom with structure similar to soil.

References

Schlüter, S., Sheppard, A., Brown, K., & Wildenschild, D. (2014). Image processing of multiphase images obtained via X‐ray microtomography: a review. Water Resources Research, 50(4), 3615-3639.

class xdesign.material.WetCircles[source]

Bases: xdesign.phantom.Phantom

class xdesign.material.SiemensStar(n_sectors=4, center=<xdesign.geometry.Point object>, radius=0.5)[source]

Bases: xdesign.phantom.Phantom

Generates a Siemens star.

ratio

scalar

The spatial frequency times the proportional radius. e.g to get the frequency, f, divide this ratio by some fraction of the maximum radius: f = ratio/radius_fraction

class xdesign.material.Foam(size_range=[0.05, 0.01], gap=0, porosity=1)[source]

Bases: xdesign.phantom.Phantom

Generates a phantom with structure similar to foam.

class xdesign.material.Metal(shape=u'square')[source]

Bases: xdesign.phantom.Phantom

class xdesign.material.SoftBiomaterial(shape=u'square')[source]

Bases: xdesign.phantom.Phantom

class xdesign.material.Electronics(shape=u'square')[source]

Bases: xdesign.phantom.Phantom

class xdesign.material.FiberComposite(shape=u'square')[source]

Bases: xdesign.phantom.Phantom