Forum

Author Topic: Interger Values correspondance for classMetashape.Accuracy  (Read 3896 times)

Courgax

  • Newbie
  • *
  • Posts: 3
    • View Profile
Interger Values correspondance for classMetashape.Accuracy
« on: April 19, 2019, 11:24:18 AM »
Hello!

As many users, I'm developing an script to automatically build a point cloud with different parameters.
(The twist is that I want to use CloudCompare in the loop  8))
I've find out that if I want to use parameter inside the matchPhotos command, it has to be an integer.
For exemple:
Code: [Select]
matchAccuracy=8
...
chunk.matchPhotos(accuracy = matchAccuracy, generic_preselection=True, reference_preselection=False)
...
Is interpreted as:
MatchPhotos: accuracy = Lowest, preselection = generic, keypoint limit = 40000, tiepoint limit = 4000, apply masks = 0, filter tie points = 0

But
Code: [Select]
matchAccuracy=5
...
chunk.matchPhotos(accuracy = matchAccuracy, generic_preselection=True, reference_preselection=False)
...
Becomes
MatchPhotos: accuracy = 5, preselection = generic, keypoint limit = 40000, tiepoint limit = 4000, apply masks = 0, filter tie points = 0

My question is:
Can I find the corresepondance somwhere? Is it giving me more possibilities than 'lowest, low, medium, hight, highest?
How does it work exactly? And is it the same for buildDepthMaps and other commands?

Thank you!

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 15595
    • View Profile
Re: Interger Values correspondance for classMetashape.Accuracy
« Reply #1 on: April 19, 2019, 12:43:11 PM »
Hello Courgax,

You can use corresponding enums instead of integer values, or convert them to int:

Code: [Select]
for item in Metashape.Accuracy.values.values():
    print(item, int(item))
Best regards,
Alexey Pasumansky,
Agisoft LLC

Courgax

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Interger Values correspondance for classMetashape.Accuracy
« Reply #2 on: April 19, 2019, 01:29:40 PM »
Working perfect thanks!

Quick results for those eventually interested:

2019-04-19 12:22:47 Metashape.Accuracy.MediumAccuracy 2
2019-04-19 12:22:47 Metashape.Accuracy.LowAccuracy 4
2019-04-19 12:22:47 Metashape.Accuracy.HighAccuracy 1
2019-04-19 12:22:47 Metashape.Accuracy.LowestAccuracy 8
2019-04-19 12:22:47 Metashape.Accuracy.HighestAccuracy 0

2019-04-19 12:23:52 Metashape.Quality.UltraQuality 1
2019-04-19 12:23:52 Metashape.Quality.LowestQuality 16
2019-04-19 12:23:52 Metashape.Quality.MediumQuality 4
2019-04-19 12:23:52 Metashape.Quality.HighQuality 2
2019-04-19 12:23:52 Metashape.Quality.LowQuality 8

2019-04-19 12:29:01 Metashape.FilterMode.NoFiltering 3
2019-04-19 12:29:01 Metashape.FilterMode.AggressiveFiltering 2
2019-04-19 12:29:01 Metashape.FilterMode.ModerateFiltering 1
2019-04-19 12:29:01 Metashape.FilterMode.MildFiltering 0