Skip to content

allGeoms and constructGeometries Don't Produce the Correct Schema #55

Open
@jbouffard

Description

@jbouffard

The OSMReader.allGeoms value is a DataFrame that is supposed to contain all of the Geometries from the source file; however, the geom column in the schema is of type Point instead of type Geometry

scala> reader.allGeoms.schema.printTreeString
root
 |-- _type: byte (nullable = false)
 |-- id: long (nullable = true)
 |-- geom: point (nullable = true)
 |-- tags: map (nullable = true)
 |    |-- key: string
 |    |-- value: string (valueContainsNull = true)
 |-- changeset: long (nullable = true)
 |-- updated: timestamp (nullable = true)
 |-- validUntil: timestamp (nullable = true)
 |-- visible: boolean (nullable = true)
 |-- version: integer (nullable = true)
 |-- minorVersion: integer (nullable = true)

Because OSMReader.allGeoms uses the same logic as ProcessOSM.constructGeometries, that means then that the latter method also has this issue.

This problem is most likely the result of the union that occurs, and one possible solution would be to reverse it. However, it's not clear what kind of performance impacts, if any, would occur.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions