Plotting#
- tigre.plotimg#
alias of
plotImg
- tigre.plotproj#
alias of
plotProj
- tigre.plotSinogram(proj, posV, show_plot=None)#
Show the sinogram of one detector row.
- Parameters:
proj (numpy.ndarray) – Projections, shape
(angle, v, u).posV (int) – Detector row, from 0 to
proj.shape[1] - 1.show_plot (bool, optional) – Call
plt.show(). Default: decided from the Matplotlib backend.
- tigre.plot_geometry(geo, angle=0)#
Draw the scanner geometry in 3D: source, detector and image.
Use it to check that the image sits inside the cone of rays and that offsets point the right way.
- Parameters:
geo (Geometry) – The scanner geometry.
angle (float, optional) – Rotation angle to draw it at, in radians. Default 0.
- tigre.plot_angles(angle_blocks, angle_index, savegif=None, show_plot=True, figsize=None, interval=500, draw_number=True, size_marker=None, angles_extended=True)#
Generate ordered subset angles animation :param angle_blocks: :type angle_blocks: List of subsets of extended (alpha, theta, psi) angles. :param angle_index: :type angle_index: List of subsets of indexes of angles. :param savegif: :type savegif: Specify file name to create a gif file. :param show_plot: :type show_plot: Set False not to display the plot. :param figsize: :type figsize: figsize to be passed to plt.figure() :param interval: :type interval: Animation interval of the frames in ms. :param draw_number: :type draw_number: Draw number in the plot. Default is True. :param size_marker: :type size_marker: Size of the angle marker. Default is None to use the default of plt.scatter(). :param angles_extended: :type angles_extended: If angles are not extended, set False. Default is True.