Forum

Author Topic: Writing log to file  (Read 2149 times)

Gildas Allaz

  • Newbie
  • *
  • Posts: 2
    • View Profile
Writing log to file
« on: April 25, 2018, 12:36:12 PM »
Hello,

Do you have an example of use of the function "log_enable" to save log in a file ?

It's a new option of the version 1.4.2.

Thank you for your help.

Gildas

Gildas Allaz

  • Newbie
  • *
  • Posts: 2
    • View Profile
Writing log to file
« Reply #1 on: April 25, 2018, 12:36:48 PM »
Hello,
Do you have an example of use of the function "log_enable" to save log in a file ?
It's a new option of the version 1.4.2.
Thank you for your help.
Gildas

paulm

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: Writing log to file
« Reply #2 on: May 30, 2018, 12:51:08 PM »
I would be interested in this as well. Setting log_enable to True and setting a file name in log_path doesn't seem to be enough. And is there an API call to add log messages to the application log from a user script? E.g. app.log("....")

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14847
    • View Profile
Re: Writing log to file
« Reply #3 on: June 11, 2018, 08:23:16 PM »
Hello Gildas,

If you need to redirect the terminal output from the OS console to the file you can use the common OS tools. For example:
Code: [Select]
photoscan.exe -r script.py > D:/log.txt
Best regards,
Alexey Pasumansky,
Agisoft LLC