meidachen / STPLS3D

🔥 Synthetic and real-world 2d/3d dataset for semantic and instance segmentation (BMVC 2022 Oral)
236 stars 20 forks source link

KPConv-STPLS3D- Data Problem #31

Closed zhangbaobao1027 closed 10 months ago

zhangbaobao1027 commented 1 year ago

first of all thanks. I use KPConv and STPLS3D dataset for training, When the training progresses to epoch130, an error will appear: 'It seems this dataset only containes empty input spheres'

Currently I skip these abnormal epochs, is it a data problem, and is there a better solution? part of the code:

        # Number collected
        n = input_inds.shape[0]

        # Safe check for empty spheres  
        if n < 2:
            failed_attempts += 1
            if failed_attempts > 100 * self.config.batch_num:
                # raise ValueError('It seems this dataset only containes empty input spheres')
                print('It seems this dataset only containes empty input spheres')
                return []
            t += [time.time()]
            t += [time.time()]
            continue

        # Collect labels and colors
        input_points = (points[input_inds] - center_point).astype(np.float32)
meidachen commented 11 months ago

@zhangbaobao1027 , Really sorry for the late reply, It seems like the point density and the sphere radius make it empty sometimes. I believe this should work fine, but just to make sure the density of the points and the radius are making sense.

zhangbaobao1027 commented 10 months ago

Thank you very much, it's real a data problem.