diff --git a/cpp/open3d/ml/paddle/misc/VoxelPoolingOpKernel.cpp b/cpp/open3d/ml/paddle/misc/VoxelPoolingOpKernel.cpp index 230a459e340..a70e05281d7 100644 --- a/cpp/open3d/ml/paddle/misc/VoxelPoolingOpKernel.cpp +++ b/cpp/open3d/ml/paddle/misc/VoxelPoolingOpKernel.cpp @@ -16,7 +16,7 @@ namespace { template class OutputAllocator { public: - OutputAllocator(paddle::Place place) : place(place) {} + explicit OutputAllocator(paddle::Place place) : place(place) {} void AllocPooledPositions(TReal** ptr, size_t num) { if (num != 0) { diff --git a/python/open3d/ml/paddle/python/layers/convolutions.py b/python/open3d/ml/paddle/python/layers/convolutions.py index 4773de30135..8c63f5fae4c 100644 --- a/python/open3d/ml/paddle/python/layers/convolutions.py +++ b/python/open3d/ml/paddle/python/layers/convolutions.py @@ -272,12 +272,6 @@ def forward(self, queries=out_positions, radius=radius, hash_table=fixed_radius_search_hash_table) - if return_distances: - if self.radius_search_metric == 'L2': - neighbors_distance_normalized = self.nns.neighbors_distance / ( - radius * radius) - else: # L1 - neighbors_distance_normalized = self.nns.neighbors_distance / radius elif len(extents.shape) == 1: radii = 0.5 * extents @@ -291,6 +285,11 @@ def forward(self, if self.window_function is None: neighbors_importance = paddle.empty((0,), dtype=paddle.float32) else: + if self.radius_search_metric == 'L2': + neighbors_distance_normalized = self.nns.neighbors_distance / ( + radius * radius) + else: # L1 + neighbors_distance_normalized = self.nns.neighbors_distance / radius neighbors_importance = self.window_function( neighbors_distance_normalized) diff --git a/util/ci_utils.sh b/util/ci_utils.sh index 6ccaf0922ad..1e4817aabd2 100644 --- a/util/ci_utils.sh +++ b/util/ci_utils.sh @@ -96,7 +96,7 @@ install_python_dependencies() { if [ "$BUILD_PADDLE_OPS" == "ON" ]; then # ML/requirements-torch.txt if [[ "$OSTYPE" == "linux-gnu"* ]]; then python -m pip uninstall paddlepaddle paddlepaddle-gpu -y - python -m pip install --pre $PADDLE_GLNX -i $PADDLE_GLNX_PIP_INDEX + python -m pip install --pre "$PADDLE_GLNX" -i "$PADDLE_GLNX_PIP_INDEX" else echo "unknown OS $OSTYPE" exit 1 diff --git a/util/run_python_unittest.sh b/util/run_python_unittest.sh deleted file mode 100755 index 8a44295d647..00000000000 --- a/util/run_python_unittest.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/usr/bin/env bash -set -euo pipefail - -PWD="$(cd $(dirname $0); pwd)" -OPEN3D_ROOT="${PWD}/../" - -# Get build scripts and control environment variables -# shellcheck source=ci_utils.sh -source "${PWD}/ci_utils.sh" - -# # Run on CPU versions -echo "Try importing Open3D CPU Python package" -cpu_wheel_path=$(ls ${OPEN3D_ROOT}/build/lib/python_package/pip_package/open3d_cpu*.whl) -test_wheel $cpu_wheel_path -echo "Running Open3D CPU Python tests..." -run_python_tests -echo - -if nvidia-smi >/dev/null 2>&1; then - # Run on GPU versions - echo "Try importing Open3D GPU Python package" - gpu_wheel_path=$(ls ${OPEN3D_ROOT}/build/lib/python_package/pip_package/open3d*.whl | grep -v $cpu_wheel_path) - test_wheel $gpu_wheel_path - echo "Running Open3D GPU Python tests..." - run_python_tests - echo -fi