Author Topic: batch mask apply  (Read 3956 times)

Offline ritzelmut

  • Newcomer
  • Posts: 7
batch mask apply
« on: 2015 February 23 13:06:37 »
I didn't find any information about a technique to apply the same mask to a bulk of images, e.g. as a batch process. Is this possible in PI and if so, can someone experienced give me the necessary information how to do this.

Offline georg.viehoever

  • PTeam Member
  • PixInsight Jedi Master
  • ******
  • Posts: 2132
Re: batch mask apply
« Reply #1 on: 2015 February 23 13:27:03 »
Search for ImageContainer (to apply a process to a number of images) and ProcessContainer (for a sequence of Processes).
Georg
Georg (6 inch Newton, unmodified Canon EOS40D+80D, unguided EQ5 mount)

Offline ritzelmut

  • Newcomer
  • Posts: 7
Re: batch mask apply
« Reply #2 on: 2015 February 23 13:41:16 »
I'm a PI user since several years. Of course I'm experienced using Image container and Process container. Please tell me, which process I can place in the process container to apply a mask. I know 4 different ways to apply a mask at a image as a single process. None of them can be placed in a process container.
« Last Edit: 2015 February 23 15:03:21 by ritzelmut »

Offline gvanhau

  • PixInsight Old Hand
  • ****
  • Posts: 345
Re: batch mask apply
« Reply #3 on: 2015 February 23 13:41:55 »
Hello


One way to do it, is to apply the mask and process(es) to one image.
After that, you open history explorer and select the processes applied to the image and create a process container with them.

finally you  create a image container with the target images and apply(drop) it on to the recently created process container.

There is one restriction: the proceses have to modiffy the target images, not create new images (like debayer).

Regards
Geert
Geert Vanhauwaert

Offline ritzelmut

  • Newcomer
  • Posts: 7
Re: batch mask apply
« Reply #4 on: 2015 February 23 14:29:19 »
Hi Geert, thank you very much. This sounds good. Tomorrow I'll try it.
« Last Edit: 2015 February 23 15:03:50 by ritzelmut »

Offline ritzelmut

  • Newcomer
  • Posts: 7
Re: batch mask apply
« Reply #5 on: 2015 February 24 00:10:29 »
The idea with the History Explorer doesn't work, because applying a mask isn't saved by the History Explorer. Is there anyone with practice, not only ideas?

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: batch mask apply
« Reply #6 on: 2015 February 24 00:46:42 »
Normally, you process one of the images with the required mask, then create a new ProcessContainer icon from the History Explorer window. This icon has a reference to the mask(s) that you've used.

If you want to create a new ProcessContainer with masks from scratch, this requires a bit of a hack:

- Open or create your mask image. Set its identifier to "mask" (for example).

- Open ProcessContainer and add the process that you want to apply.

- Click the Edit Instance Source Code button on the control bar at the bottom.

- Type this at the bottom of the source code (create a new line by pressing Enter at the end of the code):

P.setMask( 0, "mask" );

This assigns "mask" to the first process instance in the ProcessContainer.

- Click the green check mark icon at the top of the code editor window to commit the changes.

- Create a ProcessContainer icon (blue triangle, etc.)

- Open ImageContainer and add the images that you want to process.

- Drop the ImageContainer instance to the ProcessContainer icon.

Let me know if this works.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline georg.viehoever

  • PTeam Member
  • PixInsight Jedi Master
  • ******
  • Posts: 2132
Re: batch mask apply
« Reply #7 on: 2015 February 24 01:12:47 »
Hi Ritzelmut,

The attached screenshot shows that the mask is recorded with the process in the History explorer. If you take the contents of the History Explorer, and drag it to the desktop, you will get a process container that also contains information about this mask. You can check this by selecting "Edit Instance Source Code" from the context menu. Apply this ProcessContainerInstance with an ImageContainer, you will get what you need (if I understand you correctly).

Georg
Georg (6 inch Newton, unmodified Canon EOS40D+80D, unguided EQ5 mount)

Offline ritzelmut

  • Newcomer
  • Posts: 7
Re: batch mask apply
« Reply #8 on: 2015 February 28 05:15:25 »
Hi Juan Conejero and Georg-Viehoefer,

thank you very much. This IS the solution and it works very well. With this method I'm able to do exactly what I've intented.