Forum

Author Topic: type object 'Metashape.PointCloud' has no attribute 'Filter'  (Read 1112 times)

yowich

  • Newbie
  • *
  • Posts: 46
    • View Profile
type object 'Metashape.PointCloud' has no attribute 'Filter'
« on: February 13, 2023, 04:34:23 PM »
I'm running Python script for gradual selection in Metashape 2.0.0 but my codes give this error:

     f = Metashape.PointCloud.Filter()
AttributeError: type object 'Metashape.PointCloud' has no attribute 'Filter'
Error: type object 'Metashape.PointCloud' has no attribute 'Filter'

Has Filter attribute been removed or replaced in 2.0.0?

Paulo

  • Hero Member
  • *****
  • Posts: 1303
    • View Profile
Re: type object 'Metashape.PointCloud' has no attribute 'Filter'
« Reply #1 on: February 13, 2023, 05:05:52 PM »
Hello,

in 2.0, PointCloud class has been replaced by TiePoints class. I suggest you look at Python API reference manual where in Change Log chapter you have following:
Code: [Select]
• Renamed DataSource.PointCloudData enum value to DataSource.TiePointsData
• Renamed DataSource.DenseCloudData enum value to DataSource.PointCloudData
• Renamed PointCloud class to TiePoints
• Renamed DenseCloud class to PointCloud

Best Regards,
Paul Pelletier,
Surveyor

yowich

  • Newbie
  • *
  • Posts: 46
    • View Profile
Re: type object 'Metashape.PointCloud' has no attribute 'Filter'
« Reply #2 on: February 13, 2023, 06:57:13 PM »
Thank you very much! It has solved!