Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dry weather flow map geometry is reversed #127

Open
leendertvanwolfswinkel opened this issue Oct 22, 2024 · 5 comments
Open

Dry weather flow map geometry is reversed #127

leendertvanwolfswinkel opened this issue Oct 22, 2024 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@leendertvanwolfswinkel
Copy link

The dry weather flow map is a line from the connection_node.geom to the dry_weather_flow.geom, but is should be the other way around.

@leendertvanwolfswinkel leendertvanwolfswinkel added the bug Something isn't working label Oct 22, 2024
@margrietpalm
Copy link
Contributor

margrietpalm commented Nov 21, 2024

@leendertvanwolfswinkel Should this only be swapped for the dry weather flow map or also for the surface map?

Yes, also for surface_map

@margrietpalm margrietpalm self-assigned this Nov 26, 2024
@margrietpalm
Copy link
Contributor

@leendertvanwolfswinkel can you double check this? Because I run the following command to make these lines:

    query = f"""
        UPDATE {basename}_map AS map
        SET geom = (
            SELECT MakeLine(PointOnSurface(obj.geom), vcn.the_geom)
            FROM {basename} obj
            JOIN v2_connection_nodes vcn ON map.connection_node_id = vcn.id
            WHERE obj.id = map.{basename}_id
        );        
    """

Which I'd assume makes a line from the PointOnSurface to the connection node

@leendertvanwolfswinkel
Copy link
Author

LGTM

@margrietpalm
Copy link
Contributor

@leendertvanwolfswinkel does the sqlite look good or the result? Because this sqlite is already in the currently released schema.

@leendertvanwolfswinkel
Copy link
Author

@margrietpalm I migrated a spatialite with threedi-schema 0.228.2, but unfortunately the geometry is still wrong. It is a line from the connection node to the dry_weather_flow polygon. It should be the other way around. This is odd, because the SQL statement you shared in the comment above should in my view result in a correct geometry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants