diff --git a/monai/transforms/utility/array.py b/monai/transforms/utility/array.py index ef2a714a25..f9b81865e0 100644 --- a/monai/transforms/utility/array.py +++ b/monai/transforms/utility/array.py @@ -681,7 +681,7 @@ def __call__( if self.data_type if data_type is None else data_type: lines.append(f"Type: {type(img)} {img.dtype if hasattr(img, 'dtype') else None}") if self.data_shape if data_shape is None else data_shape: - lines.append(f"Shape: {img.shape}") + lines.append(f"Shape: {img.shape if hasattr(img, 'shape') else None}") if self.value_range if value_range is None else value_range: if isinstance(img, np.ndarray): lines.append(f"Value range: ({np.min(img)}, {np.max(img)})") diff --git a/runtests.sh b/runtests.sh index 01f58088ec..f71bc4c9ff 100755 --- a/runtests.sh +++ b/runtests.sh @@ -544,7 +544,7 @@ then if ! is_pip_installed pylint then echo "Pip installing pylint ..." - ${cmdPrefix}${PY_EXE} -m pip install pylint>2.16 + ${cmdPrefix}${PY_EXE} -m pip install "pylint>2.16,!=3.0.0" fi ${cmdPrefix}${PY_EXE} -m pylint --version