Batch Image Editing Speed: Looking for answers

Hello, I have a server Runninng 4 Ten core Xeons and am using a GUI to run through command line for Raw Therapee via the batch image command seen here:

“C:\Program Files\RawTherapee\5.1\rawtherapee-cli.exe” -w -o “T:\Folder\bin\ProcessedFrames” -a"T:\Folder\bin\IntermediateFrames" -p “T:\Folder\bin\rawTherapee.pp3” -b8 -n -c “T:\Folder\bin\IntermediateFrames”

My Desktop (3770k) is currently getting around 40 frames (images) per minute whereas my Xeon based server is getting 1 Frame (image) per minute. I want to know if there is any reason as to why it is going so slow. I’d also like to know if there is any way to fix this issue.

First step is to run the lastest version, which is 5.2 :slight_smile:

I have done that.

You mean to say that you’re processing 40 raw files per minute? :astonished:

  1. Where is drive T:? Maybe the destination is the bottleneck.
  2. I’m not sure you used -a correctly - according to RawPedia a file or folder should follow, according to rawtherapee-cli --help it should not - one of them needs to be fixed by us.
  3. Using PNG will slow you down. Use uncompressed TIFF if you want speed.

rt is optimized for multiple cores, not for multiple cpus. It mostly uses dynamic scheduling which I expect to be the culprit for the slowness on your system.

Could you try the following commands before you start rt?

On Linux or on Windows when running rt in msys2 console

export OMP_NUM_THREADS=10
export GOMP_CPU_AFFINITY='0-9'

On Windows when running rt in cmd.exe

set OMP_NUM_THREADS=10
set GOMP_CPU_AFFINITY='0-9'

That binds rt to the 10 cores of your first cpu.
If rt runs faster with this settings we know that my assumption is true and we can think about how to allow static scheduling for systems with multiple cpus.

So those commands are done from a rawthreepee command window, and considering I use the -w tag (which forcefully keeps the window closed), I don’t see how exactly to implement this. I don’t see how exactly to implement this. Also, this prefix before my batch command does not work, “/start affinity 1” Windows says it can not find -w, is that intended

put them on separate lines in your script before the rawtherapee-cli.exe command.

I tried this and the program was either:

  1. too slow to even push out a frame in 2 min
  2. not working at all

I then went back to the original command

No Affinity Changes (Using Node0 Processor group 1 (20 cores / 40 total))
20 cores (2 cpu’s) = 25 frames per minute

I then manually set the affinity in task manager to 5 cores
5 cores (1/2 cpu) = 15 frames per minute

neither of them are running the cores past 6-10% usage

Considering you’re running on big iron, you should copy the files under test to a RAM disc, so we can rule out an I/O problem and come closer to what Ingo is suspecting and wants to get tested.

@AlexThurman

  1. We need more input. You wrote that you are using 4 ten-core xeons. Maybe there is only one xeon model with ten cores but we don’t have the time to search for this kind of information. You didn’t tell us which kind of raw files you processed in your tests. You didn’ tell us which processing you applied to the files.

  2. If you need speed, you need to build RT yourself. The packaged build is restricted to SSE2 usage. It’s easy to build RT even on Windows, just look here

  3. As I already wrote, RT isn’t optimized for multiple cpu systems. It’s optimized for multiple cores on one cpu machines. I’m really interested to optimize it also for multiple cpu machines, but I don’t have such a machine myself. That’s a point where you could help with tests.

Ingo

I will try that when I get the chance although the disks I am writing to are brand new sshd 2TB firecuda drives from segate,

  1. HP Proliant DL580 G7 4U Server 4x E7-4860 2.26ghz / 64GB ECC Memory / 4x 1200W

  2. The files are PNG format

  3. Here is the PP3 file config :

[Version]
AppVersion=4.2.0
Version=321

[General]
Rank=0
ColorLabel=0
InTrash=false

[Exposure]
Auto=false
Clip=0.02
Compensation=0
Brightness=0
Contrast=0
Saturation=5
Black=0
HighlightCompr=0
HighlightComprThreshold=33
ShadowCompr=50
CurveMode=Standard
CurveMode2=Standard
Curve=0;
Curve2=0;

[HLRecovery]
Enabled=false
Method=Blend

[Channel Mixer]
Red=100;0;0;
Green=0;100;0;
Blue=0;0;100;

[Black & White]
Enabled=false
Method=Desaturation
Auto=false
ComplementaryColors=true
Setting=NormalContrast
Filter=None
MixerRed=43
MixerOrange=33
MixerYellow=33
MixerGreen=33
MixerCyan=33
MixerBlue=30
MixerMagenta=33
MixerPurple=33
GammaRed=0
GammaGreen=0
GammaBlue=0
Algorithm=SP
LuminanceCurve=0;
BeforeCurveMode=Standard
AfterCurveMode=Standard
BeforeCurve=0;
AfterCurve=0;

[Luminance Curve]
Brightness=0
Contrast=0
Chromaticity=0
AvoidColorShift=false
RedAndSkinTonesProtection=0
LCredsk=true
LCurve=0;
aCurve=0;
bCurve=0;
ccCurve=0;
chCurve=0;
lhCurve=0;
hhCurve=0;
LcCurve=0;
ClCurve=0;

[Sharpening]
Enabled=true
Method=usm
Radius=0.5
Amount=300
Threshold=20;80;2000;1200;
OnlyEdges=false
EdgedetectionRadius=2.5
EdgeTolerance=10000
HalocontrolEnabled=false
HalocontrolAmount=85
DeconvRadius=0.75
DeconvAmount=75
DeconvDamping=20
DeconvIterations=30

[Vibrance]
Enabled=false
Pastels=0
Saturated=0
PSThreshold=0;75;
ProtectSkins=false
AvoidColorShift=true
PastSatTog=true
SkinTonesCurve=0;

[SharpenEdge]
Enabled=true
Passes=1
Strength=30
ThreeChannels=false

[SharpenMicro]
Enabled=false
Matrix=false
Strength=20
Uniformity=50

[White Balance]
Setting=Camera
Temperature=6490
Green=1.002
Equal=1

[Color appearance]
Enabled=false
Degree=90
AutoDegree=true
Surround=Average
AdaptLum=16
Badpixsl=0
Model=RawT
Algorithm=JC
J-Light=0
Q-Bright=0
C-Chroma=0
S-Chroma=0
M-Chroma=0
J-Contrast=0
Q-Contrast=0
H-Hue=0
RSTProtection=0
AdaptScene=2000
AutoAdapscen=true
SurrSource=false
Gamut=true
Datacie=false
Tonecie=false
CurveMode=Lightness
CurveMode2=Lightness
CurveMode3=Chroma
Curve=0;
Curve2=0;
Curve3=0;

[Impulse Denoising]
Enabled=false
Threshold=50

[Defringing]
Enabled=false
Radius=2
Threshold=13
HueCurve=1;0.16666666699999999;0;0.34999999999999998;0.34999999999999998;0.34699999999999998;0;0.34999999999999998;0.34999999999999998;0.51366742600000004;0;0.34999999999999998;0.34999999999999998;0.66894457100000004;0;0.34999999999999998;0.34999999999999998;0.82877752459999998;0.97835991;0.34999999999999998;0.34999999999999998;0.99088838270000001;0;0.34999999999999998;0.34999999999999998;

[Directional Pyramid Denoising]
Enabled=true
Enhance=false
Median=false
Luma=100
Ldetail=50
Chroma=15
Method=RGB
SMethod=shal
MedMethod=soft
RGBMethod=soft
MethodMed=Lonly
Redchro=0
Bluechro=0
Gamma=1.7
Passes=1
LCurve=1;0.050000000000000003;0.14999999999999999;0.34999999999999998;0.34999999999999998;0.55000000000000004;0.040000000000000001;0.34999999999999998;0.34999999999999998;

[EPD]
Enabled=false
Strength=0.25
EdgeStopping=1.3999999999999999
Scale=1
ReweightingIterates=0

[Shadows & Highlights]
Enabled=false
HighQuality=false
Highlights=0
HighlightTonalWidth=80
Shadows=0
ShadowTonalWidth=80
LocalContrast=0
Radius=40

[Crop]
Enabled=false
X=0
Y=0
W=1350
H=1080
FixedRatio=false
Ratio=3:2
Orientation=Landscape
Guide=Rule of thirds

[Coarse Transformation]
Rotate=0
HorizontalFlip=false
VerticalFlip=false

[Common Properties for Transformations]
AutoFill=true

[Rotation]
Degree=0

[Distortion]
Amount=0

[LensProfile]
LCPFile=
UseDistortion=true
UseVignette=true
UseCA=false

[Perspective]
Horizontal=0
Vertical=0

[Gradient]
Enabled=false
Degree=0
Feather=25
Strength=0.59999999999999998
CenterX=0
CenterY=0

[PCVignette]
Enabled=false
Strength=0.59999999999999998
Feather=50
Roundness=50

[CACorrection]
Red=0
Blue=0

[Vignetting Correction]
Amount=0
Radius=50
Strength=1
CenterX=0
CenterY=0

[Resize]
Enabled=false
Scale=0.67000000000000004
AppliesTo=Cropped area
Method=Lanczos
DataSpecified=3
Width=900
Height=900

[Color Management]
InputProfile=(embedded)
ToneCurve=false
BlendCMSMatrix=false
DCPIlluminant=0
WorkingProfile=ProPhoto
OutputProfile=RT_sRGB
Gammafree=default
Freegamma=false
GammaValue=2.2200000000000002
GammaSlope=4.5

[Directional Pyramid Equalizer]
Enabled=false
Gamutlab=false
Mult0=1
Mult1=1
Mult2=1
Mult3=1
Mult4=1
Threshold=0.20000000000000001
Skinprotect=0
Hueskin=-5;25;170;120;

[HSV Equalizer]
HCurve=0;
SCurve=0;
VCurve=0;

[Film Simulation]
Enabled=false
ClutFilename=
Strength=100

[RGB Curves]
LumaMode=false
rCurve=0;
gCurve=0;
bCurve=0;

[ColorToning]
Enabled=false
Method=Lab
Lumamode=true
Twocolor=Std
Redlow=0
Greenlow=0
Bluelow=0
Satlow=0
Balance=0
Sathigh=0
Redmed=0
Greenmed=0
Bluemed=0
Redhigh=0
Greenhigh=0
Bluehigh=0
Autosat=true
OpacityCurve=1;0;0.29999999999999999;0.34999999999999998;0;0.25;0.80000000000000004;0.34999999999999998;0.34999999999999998;0.69999999999999996;0.80000000000000004;0.34999999999999998;0.34999999999999998;1;0.29999999999999999;0;0;
ColorCurve=1;0.050000000000000003;0.62;0.25;0.25;0.58499999999999996;0.11;0.25;0.25;
SatProtectionThreshold=0
SaturatedOpacity=0
Strength=50
HighlightsColorSaturation=60;80;
ShadowsColorSaturation=80;208;
ClCurve=3;0;0;0.34999999999999998;0.65000000000000002;1;1;
Cl2Curve=3;0;0;0.34999999999999998;0.65000000000000002;1;1;

[RAW]
DarkFrame=/szeva
DarkFrameAuto=false
FlatFieldFile=/szeva
FlatFieldAutoSelect=false
FlatFieldBlurRadius=32
FlatFieldBlurType=Area Flatfield
FlatFieldAutoClipControl=false
FlatFieldClipControl=false
CA=false
CARed=0
CABlue=0
HotPixelFilter=false
DeadPixelFilter=false
HotDeadPixelThresh=40
PreExposure=1
PrePreserv=0

[RAW Bayer]
Method=amaze
CcSteps=0
PreBlack0=0
PreBlack1=0
PreBlack2=0
PreBlack3=0
PreTwoGreen=true
LineDenoise=0
GreenEqThreshold=0
DCBIterations=2
DCBEnhance=false
LMMSEIterations=2

[RAW X-Trans]
Method=3-pass (best)
CcSteps=0
PreBlackRed=0
PreBlackGreen=0
PreBlackBlue=0

Also, I am more than happy to help in making the software optimized for Multi-Processor Systems, Whether that be testing different application versions or configurations.

Do you process png to png (load and save png format) ?

I ask because of this

Yes,

Though unrelated to the speed differences between your systems, save to png currently is a bottleneck. For that reason I’m trying to improve it.