Author Topic: Could BatchPreProcessing Create Subdirectories for calibrated files?  (Read 3263 times)

Offline EorEquis

  • Member
  • *
  • Posts: 63
When BPP is told to Calibrate Only, it sticks all calibrated frames in the same "calibrated" subfolder.  When allowed to do registration, it creates a subfolder per filter under "registered", but does not do this for calibrated only frames.

Could this addition be made to the BPP script?

Offline EorEquis

  • Member
  • *
  • Posts: 63
Well...it's only been a year.   :D

Finally decided to rummage around and see if I could make this happen myself...turns out it was easy as pie.


Make the simple change(s) below, and next time you run BPP, it'll create a subfolder under "calibrated/light" named by the filter e.g. calibrated/light/Red.  This allows you to calibrate all your light sets at once, and keep the calibrated results nicely sorted by filter.

1. Open BatchPreprocessing-engine.js either in PI's script editor or your editor of choice

2. Find (in mine it's line 1647) :
Code: [Select]
IC.outputDirectory = File.existingDirectory( this.outputDirectory + "/calibrated/light" );
3. Change to :
Code: [Select]
IC.outputDirectory = File.existingDirectory( this.outputDirectory + "/calibrated/light/" + filter );
4. If you also wish to sort your calibrated flats by filter, find (in mine line 1633)
Code: [Select]
IC.outputDirectory = File.existingDirectory( this.outputDirectory + "/calibrated/flat" );
5. And change to :
Code: [Select]
IC.outputDirectory = File.existingDirectory( this.outputDirectory + "/calibrated/flat/" + filter );