Author Topic: marker reference import one column python  (Read 1536 times)

  • Newbie
  • *
  • Posts: 1
    • View Profile
marker reference import one column python
« on: July 25, 2022, 02:05:07 PM »

I am running an RTK drone survey script in python and getting large error numbers on the markers when I import them (4m+). Any idea how to include accuracy info of markers into the importReference() function?

Marker example:
n,   x,   y,   z,   accu
target 116,   462824.203,   100642.111,   3.822,   0.02



  • Hero Member
  • *****
  • Posts: 1350
    • View Profile
Re: marker reference import one column python
« Reply #1 on: July 26, 2022, 05:33:52 PM »

maybe you should look at p.43 API reference manula and columns parameter of importReference
importReference(path='', format=ReferenceFormatCSV, columns='', delimiter='', group_delimiters=False,
skip_rows=0[, items ][, crs ], ignore_labels=False, create_markers=False,
threshold=0.1, shutter_lag=0[, progress ])
Import reference data from the specified file.
• path (string) – Path to the file with reference data.
• format (ReferenceFormat) – File format.
• columns (string) – Column order in csv format (n - label, o - enabled flag, x/y/z - coordinates,
X/Y/Z - coordinate accuracy, a/b/c - rotation angles, A/B/C - rotation angle accuracy,
[] - group of multiple values, | - column separator within group).
Best Regards,
Paul Pelletier,

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14965
    • View Profile
Re: marker reference import one column python
« Reply #2 on: July 28, 2022, 12:19:52 PM »
Hello rpr1g08,

For such input you should use the following:
Code: [Select]
chunk.importReference(path, format = Metashape.ReferenceFormatCSV, columns='nxyz[XYZ]', delimiter=',')In this case the last column in the file will be used as same accuracy for X, Y and Z.

Also make sure that either comma or tab is used as a delimiter, not both simultaneously.
Best regards,
Alexey Pasumansky,
Agisoft LLC