Commit 24ab86c9 authored by Daniel Scheffler's avatar Daniel Scheffler

Merge branch 'bugfix/fix_singleprocessing' into 'master'

Fixed bug that caused to use multiprocessing.Pool if number of CPUs is set to 1.

See merge request !7
parents 70118ff8 529517a6
Pipeline #3805 passed with stages
in 10 minutes and 18 seconds
......@@ -917,7 +917,7 @@ class SensorMapGeometryTransformer3D(object):
band_idx=band
) for band in range(data.shape[2])]
if self.mp_alg == 'bands':
if self.opts['nprocs'] > 1 and self.mp_alg == 'bands':
with multiprocessing.Pool(self.opts['nprocs']) as pool:
result = pool.map(self._to_map_geometry_2D, args)
else:
......@@ -971,7 +971,7 @@ class SensorMapGeometryTransformer3D(object):
band_idx=band
) for band in range(data.shape[2])]
if self.mp_alg == 'bands':
if self.opts['nprocs'] > 1 and self.mp_alg == 'bands':
with multiprocessing.Pool(self.opts['nprocs']) as pool:
result = pool.map(self._to_sensor_geometry_2D, args)
else:
......
__version__ = '0.14.14'
__versionalias__ = '20190321_02'
__version__ = '0.14.15'
__versionalias__ = '20190322_01'
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment