Skip to content

Commit 1b00735

Browse files
authored
fix(cli): multithread warp (#2744)
OSGeo/gdal#7478
1 parent 1051328 commit 1b00735

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

packages/cli/src/cog/__tests__/cog.test.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,9 @@ o.spec('cog', () => {
5959
'TILING_SCHEME=GoogleMapsCompatible',
6060
'-co',
6161
'NUM_THREADS=ALL_CPUS',
62+
'--config',
63+
'GDAL_NUM_THREADS',
64+
'ALL_CPUS',
6265
'-co',
6366
'BIGTIFF=YES',
6467
'-co',

packages/cli/src/gdal/gdal.cog.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,10 @@ export class GdalCogBuilder {
9292
// Max CPU POWER
9393
'-co',
9494
'NUM_THREADS=ALL_CPUS',
95+
// in GDAL 3.7.x NUM_THREADS will also set GDAL_NUM_THREADS
96+
'--config',
97+
'GDAL_NUM_THREADS',
98+
'ALL_CPUS',
9599
// Force big tiff the extra few bytes savings of using little tiffs does not affect us
96100
'-co',
97101
'BIGTIFF=YES',

0 commit comments

Comments
 (0)