Forum

Author Topic: Is there a downscale or equivalent parameter for buildDem?  (Read 5857 times)

rkwik

  • Newbie
  • *
  • Posts: 10
    • View Profile
Is there a downscale or equivalent parameter for buildDem?
« on: October 06, 2023, 05:31:55 PM »
Howdy everyone,
I was reading the Metashape Python reference and couldn't find any info on a downscale or equivalent parameter for the buildDem function  :o . I am trying to match my Python script to the gui. Is there an equivalent?
Thanks in advance! - Robina


rkwik

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: Is there a downscale or equivalent parameter for buildDem?
« Reply #1 on: October 06, 2023, 09:27:02 PM »
I also noticed that buildDem does not have a filtering parameter. The software and python api seem so different

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 15177
    • View Profile
Re: Is there a downscale or equivalent parameter for buildDem?
« Reply #2 on: October 09, 2023, 11:58:25 AM »
Hello rkwik,

Quality parameter in the Batch process dialog is only considered, if you are using Depth Maps as a source data for the Build DEM operation. For other source options (like Point Cloud), the quality parameter value will be ignored.

The most common approaches for the DEM generation assume the following steps in Python:
1. Build Depth Maps (using desired downscale value) -> Build Point Cloud -> Classify Points (optionally) -> Build DEM using point cloud as a source.
2. Build Depth Maps (using desired downscale value) -> Build DEM using depth maps as a source.


Filtering parameter is also considered only for the depth maps generation.
Best regards,
Alexey Pasumansky,
Agisoft LLC

rkwik

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: Is there a downscale or equivalent parameter for buildDem?
« Reply #3 on: October 10, 2023, 06:41:05 PM »
Hi Alexey,

Thank you! That is helpful.

Robin

rkwik

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: Is there a downscale or equivalent parameter for buildDem?
« Reply #4 on: October 17, 2023, 06:25:11 PM »
I am also wondering if there is any way to see if the sun sensor was applied properly in the api? For example, if we can open the project that the api created, can we see anything in the gui that tells us this?
Here is the sun sensor code:
Thanks!


task = Metashape.Tasks.CalibrateReflectance()
task.use_reflectance_panels = True
task.use_sun_sensor = True
task.apply(chunk)
doc.save()

for sensor in chunk.sensors:
    sensor.normalize_sensitivity=True

chunk.locateReflectancePanels()
chunk.calibrateReflectance(use_reflectance_panels=True, use_sun_sensor=True)
doc.save()