Forum

Author Topic: Camera.open(path) causes the program to crash  (Read 1835 times)

shirofukurou

  • Newbie
  • *
  • Posts: 6
    • View Profile
Camera.open(path) causes the program to crash
« on: May 12, 2017, 12:34:18 PM »
I have a script that was working nicely under 1.2.6 but completely crashes PhotoScan under 1.3.1. No error messages and no warning so I'm guessing this is a bug somewhere (otherwise I'd just get a python error and I'm used to that). I've narrowed down the crash to this line:

camera.open(image_path)

camera comes from camera = chunk.addCamera() and looks to be properly initialised. If image_path doesn't point to a valid image I get an error in camera.open as expected. But if image_path is valid then I get the crash.

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14847
    • View Profile
Re: Camera.open(path) causes the program to crash
« Reply #1 on: May 12, 2017, 12:48:39 PM »
Hello shirofukurou,

I think it's related to the fact that no sensor is defined for the camera.

I can suggest to add new images using .addPhotos() option.
Best regards,
Alexey Pasumansky,
Agisoft LLC