Skip to content
Snippets Groups Projects
Commit b5eed67e authored by Simon Wittl's avatar Simon Wittl
Browse files

updated tigre example

parent c9d91768
No related branches found
No related tags found
No related merge requests found
![test](https://mygit.th-deg.de/roboct/robo_quality/gitlab-profile/-/raw/main/resources/rq_controller.svg?inline=false)
![test](https://mygit.th-deg.de/roboct/robo_quality/gitlab-profile/-/raw/main/resources/rq_controller_450.png?inline=false)
# RoboQualityController
......
......@@ -12,7 +12,7 @@ import matplotlib.pyplot as plt
# This script assumes that the service nodes a started with the rq_wokflow/launch/tigre_artist_launch.py file.
# !!!
NUMBER_OF_PROJECTION = 100
NUMBER_OF_PROJECTION = 80
FOD_MM = 1000.
FDD_MM = 2000.
......@@ -37,16 +37,18 @@ def main():
# Move source / dtector and aquire projections
for i in range(NUMBER_OF_PROJECTION):
rotation = Rotation.from_euler('Z', angles[i], False)
scan_pose = projection.look_at(rotation.apply(source), rotation.apply(detector), np.array([0, 0, -1]))
scan_pose = projection.look_at(rotation.apply(source) + (np.random.random(3) - 0.5) * 30,
rotation.apply(detector) + (np.random.random(3) - 0.5) * 30,
np.array([0, 0, -1]))
projection_stack.append(workflow.aquire_projection(scan_pose))
# Define reconstruction area and call reconstruction client
roi = PyRegionOfIntrest(np.zeros((1, 3)), np.ones((1, 3)) * 120., resolution_mm=np.array([0.5, 0.5, 0.5]))
volume = workflow.get_volume(projection_stack, roi)
roi = PyRegionOfIntrest(center_points_mm=np.array([0., 0., 0.]),
dimensions_mm=np.array([120., 120., 120.]),
resolution_mm=np.array([0.5, 0.5, 0.5]))
# visualize middle slice
plt.imshow(volume.array[:, volume.shape[1] // 2, :])
plt.show()
workflow.reconstruction.set_reconstruction_algorithm_name('ossart') # ossart / fdk
volume = workflow.get_volume(projection_stack, roi)
if __name__ == '__main__':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment