[Frage] CSV point data export and filtering duplicates [Gelöst]

Schlagworte:
  • Csv
  • Points
  • Terrain
  • Re2
  • Duplicate
  • Filter

Hello everyone,
I am trying to make a script that exports 3D points of the face of selected 3D objects. The data needs to be in “re2” or similar, so AllPlan can read it as terrain points. I have done the script but it seems to export rows, column and index which, as far as I understand, makes the file unreadable by AllPlan. Any ideas on how to avoid this?

Edit: Also bonus points to anyone who suggest how to filter out duplicate points where X and Y are the same, but Z is different (lower Z is removed)?

In order to make the CSV readable by AllPlan I just added .re2 at the end of the file to change its format.
Also the script is a little wonky as it first needs to have save path selected, then clicked save again and then objects can be selected.

Kind regards,
Dobromir

Anhänge (1)

Typ: application/zip
377-mal heruntergeladen
Größe: 8,29 KiB

Lösung anzeigen Lösung verbergen

At Allplan help you can find the desired format (s. format_re2.png)
The edit the raw csv output with Notepadd++:

1. Remove the header row
2. remove first and second column
3. Replace ";" with ","
4. Add point code at end of each row

...then it works!

PS: The filtering of Points with equal Y/Y Coordinates you should better do before the export in visual scripting. Maybe you need a own scripted node for doing this. The comparation itself can be
a little bit time consuming, because you have to test each point against each other :-)

Anhänge (2)

Typ: image/png
45-mal heruntergeladen
Größe: 68,70 KiB
Typ: image/png
63-mal heruntergeladen
Größe: 154,74 KiB

At Allplan help you can find the desired format (s. format_re2.png)
The edit the raw csv output with Notepadd++:

1. Remove the header row
2. remove first and second column
3. Replace ";" with ","
4. Add point code at end of each row

...then it works!

PS: The filtering of Points with equal Y/Y Coordinates you should better do before the export in visual scripting. Maybe you need a own scripted node for doing this. The comparation itself can be
a little bit time consuming, because you have to test each point against each other :-)

Anhänge (2)

Typ: image/png
45-mal heruntergeladen
Größe: 68,70 KiB
Typ: image/png
63-mal heruntergeladen
Größe: 154,74 KiB