Analyze the disk image stack

[1]:
import astro3d
from astro3d import image_stack

Read the image stack

We again need to set the printer-specific settings and the directory of the slides:

[2]:
stack = image_stack.IStack(
    astro3d.get_output('slices_pluto_color3'),
    dpi_x=600, dpi_y=300, dz=27e-4,
)

Plots

Show the distribution of materials

[26]:
f, ax = stack.show_counts()
../../_images/3Dprinting_4_color_disk_2_link_11_0.png

Show a histogram of the columns that are not fully transparent

[27]:
f, ax = stack.show_histogram()
../../_images/3Dprinting_4_color_disk_2_link_13_0.png

Show fully transparent pixels and the density distribution.

[28]:
f, ax = stack.show_transparency_estimate()
../../_images/3Dprinting_4_color_disk_2_link_15_0.png

Top view

[29]:
stack.show_top_view(bg=[255] * 3)
[29]:
(<Figure size 640x480 with 1 Axes>, <AxesSubplot:>)
../../_images/3Dprinting_4_color_disk_2_link_17_1.png

Careful: this takes around 10 minutes

[30]:
#%%time
#f, ax = stack.three_views()
#f.savefig('perspectives.pdf', transparent=True, bbox_inches='tight', dpi=300)