Thank you Alexey, it works perfectly!
The complete code:
def detect_fiducials():
doc =scan.app.document
for chk_sel in doc.chunks:
for sensor in chk_sel.sensors:
sensor.film_camera = True
if chk.enabled != True:
chk_sel.detectFiducials(generate_masks=True,generic_detector=True)
else:
chk_sel.detectFiducials(generate_masks=True, generic_detector=False, right_angle_detector=False,fiducials_position_corners=False,fiducials_position_sides=False)
I have two other questions:
Is it necessary to indicate the real size of the physical support of the scan (I have no idea...) or having the exact position of the fiducial marks is sufficient for resampling?
The detectFiducials algorithm detects systematically 8 fiducials marks (auto_0 to auto_7) that figurate in the table but the (auto_4,..., auto_7) marks are not present in the images. I manually delete the 4 last marks but I wonder if it's really necessary?
Best regards, and thanks again for your quick answer!