Hello stephan,
You need to use the following:
chunk = PhotoScan.app.document.chunk
dense_cloud = chunk.dense_cloud
dense_cloud.selectPointsByColor(color=[255,255,255], tolerance=99, channels='RGB')
dense_cloud.removeSelectedPoints()
PhotoScan.DenseCloud() - is a class, it's not related to the project contents.