diff --git a/Libs/swig/dataset.py b/Libs/swig/dataset.py index 7a98c133..f16039ce 100644 --- a/Libs/swig/dataset.py +++ b/Libs/swig/dataset.py @@ -384,7 +384,7 @@ def pick_quality_from_size(size, dtype_str, q_max, base_elems_q1=2): # Assert(quality<=0) temp_qual=quality bit_length=len(self.getBitmask().toString())-1 - if temp_qual!=0: + if size!=None: quality = pick_quality_from_size(size, self.getField().dtype.toString(), bit_length) temp_qual=quality if temp_qual<=0: @@ -880,3 +880,4 @@ def read(self, logic_box=None, x=None, y=None, z=None, u=None,v=None, field_name elif type(z) is not tuple: data = data[0,:,:] return data + diff --git a/Libs/swig/setup.py b/Libs/swig/setup.py index 96ec5c0f..7dced713 100644 --- a/Libs/swig/setup.py +++ b/Libs/swig/setup.py @@ -7,7 +7,7 @@ pass # the following line can be replaced automatically by `NewTag` so be careful not to change its format -PROJECT_VERSION="2.2.142" +PROJECT_VERSION="2.2.146" # I can override by env variable if "PROJECT_VERSION" in os.environ: @@ -33,8 +33,8 @@ def DoSetup(): shutil.rmtree('./dist', ignore_errors=True) shutil.rmtree('./.git', ignore_errors=True) shutil.rmtree('./tmp', ignore_errors=True) - shutil.rmtree('./{}.egg-info'.format("OpenVisus"), ignore_errors=True) - shutil.rmtree('./{}.egg-info'.format("OpenVisusNoGui"), ignore_errors=True) + shutil.rmtree('./openvisus.egg-info'.format(""), ignore_errors=True) + shutil.rmtree('./openvisusnogui.egg-info'.format(""), ignore_errors=True) files=[] for dirpath, __dirnames__, filenames in os.walk("."): for it in filenames: @@ -46,11 +46,11 @@ def DoSetup(): # special name for no-gui # see https://github.com/opencv/opencv-python/blob/master/setup.py - package_name="OpenVisus" + package_name="openvisus" # special case no gui if not os.path.isfile(os.path.join(this_dir,"QT_VERSION")): - package_name="OpenVisusNoGui" + package_name="openvisusnogui" # dependency on numpy removed otherwise I have problems with conda which downgrade numpy for unknown reasons setuptools.setup(