Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Re: batch processing on bulk layer
#1
Hi all,

I expect performing bulk/batch editing a group of negative-images (say for example 40 negative-images) running following commands on GIMP
Colors -> Auto -> White Balance
and then
Colors -> Linear Invert

A folk on another thread advised me to do it through layer;
1. Create a new layer
2. Copy 40 negative-images on new layer
3. Perform editing one negative-image, then the rest negative-images would be automatically edited simultaneously.

I have 2 GIMP versions:-
GIMP 2.10.18
Ubuntu 20.04 desktop
G'MIC-Qt (Filter plugin)
Goat-Exercise

GIMP 2.10.30
Ubuntu 22.04 desktop VM (VirtualBox)
Python-Fu (Filter plugin)
Scipt-Fu

I have no previous experience on this technique and on making some search online I found following threads;

Bulk layer edits with GIMP
https://astroroad.com.au/processing/bulk...with-gimp/

GIMP batch processing
https://www.educba.com/gimp-batch-processing/

GIMP Batch Mode (it needs a script)
https://www.gimp.org/tutorials/Basic_Batch/

HOW TO BATCH EDIT PHOTOS USING GIMP AND BIMP (+ HOW TO INSTALL)
https://daviesmediadesign.com/project/ho...o-install/

BIMP. Batch Image Manipulation Plugin for GIMP.
Addicted to GIMP?
https://alessandrofrancesconi.it/projects/bimp/
BIMP 2.6 (download from source)
https://github.com/alessandrofrancesconi...s/tag/v2.6

Please advise which document/thread shall I follow?

Thanks

Regards
Reply
#2
If all in layers, I would use Filters ➤ G'MIC ➤ Colors ➤ Auto balance(there are other filters in G'MIC), then as "Input Layer" ➤ All, then use one of the Ofnut's script to export each layer as image
Reply
#3
(06-10-2022, 05:11 AM)PixLab Wrote: If all in layers, I would use Filters ➤ G'MIC ➤ Colors ➤ Auto balance(there are other filters in G'MIC), then as "Input Layer" ➤ All, then use one of the Ofnut's script to export each layer as image
Thanks for your advice.

How to create the new layer ?
Layer -> New Layer  (no response)
Layer -> New from Visible
Layer -> New Layer Group

Which of them shall I select ?

Whether after having created a new layer, copy all negative-images on it with "Drag & Drop".  Afterwards execute the commands ?

Please advise.  Thanks

Regards
Reply
#4
Quote: I expect performing bulk/batch editing a group of negative-images (say for example 40 negative-images) running following commands on GIMP
Colors -> Auto -> White Balance
and then
Colors -> Linear Invert

A folk on another thread advised me to do it through layer;
1. Create a new layer
2. Copy 40 negative-images on new layer
3. Perform editing one negative-image, then the rest negative-images would be automatically edited simultaneously.

I do wish 'folk' would try out advice before giving it.

When it comes to Colors -> Auto -> White Balance Each Image is assessed individually. Even a border will make a difference. It is very unlikely that 40 combined images will process correctly. Applying Auto White Balance to your two negatives one with white BG the other with black BG. Neither correct. https://i.imgur.com/gE7UYV5.jpg
Reply
#5
Sorry to mislead you, you cannot use any of the colour menu items that you need once they are in a group.

Smile
Reply
#6
(06-12-2022, 06:59 AM)sallyanne Wrote: Sorry to mislead you, you cannot use any of the colour menu items that you need once they are in a group.
Hi,

Never mind.  We are here helping each others.  That was your good intent.

Regards

Hi all,

Is there anyway to run batch process on GIMP alone, without plugin, such as BIMP, G'MIC etc ?

Thanks

Regards
Reply
#7
Quote:Is there anyway to run batch process on GIMP alone, without plugin, such as BIMP, G'MIC etc ?

Of course it is possible.

You have already referenced https://www.gimp.org/tutorials/Basic_Batch/ more that once. That is using script-fu to create a script. An alternative is you to create a python plugin and this method comes originally from an Ofnuts post. https://ntcore.com/?p=509

The bottom line. Can you write either script-fu or python ?

You can't ? then use BIMP and G'mic
Reply
#8
(06-12-2022, 12:50 PM)rich2005 Wrote:
Quote:Is there anyway to run batch process on GIMP alone, without plugin, such as BIMP, G'MIC etc ?

Of course it is possible.

You have already referenced https://www.gimp.org/tutorials/Basic_Batch/ more that once. That is using script-fu to create a script. An alternative is you to create a python plugin and this method comes originally from an Ofnuts post. https://ntcore.com/?p=509

The bottom line. Can you write either script-fu or python ?

You can't ? then use BIMP and G'mic
No.  But I'm willing to learn something new to me.

I would forget python because unable to run it on Ubuntu 20.04

Whether following documents suffice for me learning script-fu?
Chapter 11.  Scripting the GIMP
http://uneex.ru/static/GimpDoc_EnRu/en/g...pting.html

In particular;
2.6. Image-Dependent Scripts
https://docs.gimp.org/2.10/en/image-inde...pt-fu.html

Re
GIMP Batch Mode
https://www.gimp.org/tutorials/Basic_Batch/

and
Batch image manipulation using Python and GIMP
https://ntcore.com/?p=509

Also I'm prepared to learn.  Does it need python?

If for example on GIMP
Colors -> Auto > White Balance
and then
Colors -> Linear Invert

What is GIMP Batch Mode ?
$ gimp ....

Thanks

Regards
Reply
#9
You have quoted this https://www.gimp.org/tutorials/Basic_Batch/ four  times Have you actually studied it ? It will not make you a scripting wizard but might get you started. Use it as a template.

   

...and you can get a simple script-fu

Code:
  (define (photonegative pattern)
  
  (let* ((filelist (cadr (file-glob pattern 1))))
    (while (not (null? filelist))
           (let* ((filename (car filelist))
                  (image (car (gimp-file-load RUN-NONINTERACTIVE filename filename)))
                  (drawable (car (gimp-image-get-active-layer image))))

             (gimp-drawable-levels-stretch drawable)
             (gimp-drawable-invert drawable TRUE)
             
             (gimp-file-save RUN-NONINTERACTIVE image drawable filename filename)
             (gimp-image-delete image))
           (set! filelist (cdr filelist)))))
           

Can you see the similarities ? One gimp procedure replaced by the two you require.

The information on using it is there as well. It tells you to run a command in the folder containing the images.
In a terminal
Code:
gimp -i -b '(photonegative  "*.jpeg" )' -b '(gimp-quit 0)'

...and that will apply the auto white balance and the invert-linear

example: https://i.imgur.com/TxXVJUs.mp4

...but if you want to do more than that, color corrections, then the commands you want are GEGL and not (easily) scriptable

Do not want to use BIMP ? I can have your 999 negatives processed before you have finished copying the script into your Gimp scripts folder.
Reply
#10
(06-12-2022, 06:20 PM)rich2005 Wrote: You have quoted this https://www.gimp.org/tutorials/Basic_Batch/  four  times Have you actually studied it ? It will not make you a scripting wizard but might get you started. Use it as a template.



...and you can get a simple script-fu

Code:
  (define (photonegative pattern)
  
  (let* ((filelist (cadr (file-glob pattern 1))))
    (while (not (null? filelist))
           (let* ((filename (car filelist))
                  (image (car (gimp-file-load RUN-NONINTERACTIVE filename filename)))
                  (drawable (car (gimp-image-get-active-layer image))))

             (gimp-drawable-levels-stretch drawable)
             (gimp-drawable-invert drawable TRUE)
             
             (gimp-file-save RUN-NONINTERACTIVE image drawable filename filename)
             (gimp-image-delete image))
           (set! filelist (cdr filelist)))))
           

Can you see the similarities ? One gimp procedure replaced by the two you require.

The information on using it is there as well. It tells you to run a command in the folder containing the images.
In a terminal
Code:
gimp -i -b '(photonegative  "*.jpeg" )' -b '(gimp-quit 0)'

...and that will apply the auto white balance and the invert-linear

example: https://i.imgur.com/TxXVJUs.mp4

...but if you want to do more than that, color corrections, then the commands you want are GEGL and not (easily) scriptable

Do not want to use BIMP ? I can have your 999 negatives processed before you have finished copying the script into your Gimp scripts folder.
Thanks for your advice.

Sorry.  It is difficult for me tracing data in another thread.

Now I have changed my decision, scanning past photos on smartphoto instead of their film negatives.  It'll save me lot of time. The quality of the digital photos is quite good.  No post-editing is required.  Please refers to attached photos captured by me in the past in Linz, Austria, no macros, only 1x1

The fixture is very simple.  The plastic clips are for indexing. Please refers to attached photo

Cropping can't be avoided.  Should I find those digital photos are of inferior quality then I'll scan their negatives.

Regards

Hi all,

I'm running remote desktop to shoot photos remotely.

My smartphone, Samsung Galaxy S9+, is connected to Ubuntu 20.04 desktop PC via an USB cable. It will charge the smartphone during capturing simultaneously.

I just remote-control the smartphone on Ubuntu 20.04 display and keyboard. After capturing, the digital file is immediately download to PC without saving on the smartphone.

This arrangement is very efficient without creating un-necessary motion to the smartphone during capturing because I don't need touching the screen of the smartphone.

Regards


Attached Files Thumbnail(s)
               
Reply


Forum Jump: