abstreet/docs/TODO_quality.md
2019-01-31 08:53:30 -08:00

4.2 KiB

TODO - Map quality

Geometry

  • try fixed pt again, for determinism purposes mostly

    • very different approaches

      • v1: keep f64 internally, but constantly drop small bits
        • we just want deterministic serialization really, so...
      • v2: try some rational number thing internally
    • retry integers for everything (probably all at once)

      • dont round too early... line intersection, dist to pt, kinematics
      • adjust epsilon values to match actual smallest difference, or start doing direct comparisons now
    • clamp distances first, not points? This one is working well!

      • note contains_pt needs to use 2 or 3 * epsilon, because of the error that may accumulate...
      • audit all EPSILON_DIST usages
      • make natively orderable
    • change internal pt2d representation to int. JUST get that working first.

      • then get rid of approx_eq, approx_dedupe
      • make sure dist_to at the tiniest case rounds up, too. maybe that needs to happen now.
      • make Pt2D natively orderable, hashable
      • can Pt2D::new() and x() and y() return something besides f64?
    • then work on proper SI types, with negative/positive cases handled carefully

    • also bounds?

    • cant get rid of the ccw intersection check... different answer in some cases that looks bad

  • underlying problems

    • bad polyline shifting remains
      • from the remaining cases, looks like we need to totally remove some tight points and retry
      • make polygons use the corrections too?
  • generalized_trim_back

    • breaks down when we have jagged lane endings due to polyline shift angle correction
    • sometimes a lane polyline hits the perpendicular of a trimmed road! where was this happening?
  • handle small roads again somehow?

    • VERY overeager... ate half of the map

      • can we capture snapshots of incremental changes?
        • save initial map at every step, be able to load raw + initial with a focus point
        • generic viewer should be easy... something that stores polygon and ID, wraps the quadtree, etc
      • try merging the shortest roads first
    • deal with loop roads

    • manually draw a picture of the weird intersection to see what would look reasonable. i think we need original road bands from deleted stuff to make decent polygons.

    • model U-turns

  • degenerate-2's should only have one crosswalk

    • then make them thinner
  • ped paths through sidewalk corners are totally broken

    • calculate the better paths first, then make the corner geometry from that?
  • car turns often clip sidewalk corners now

  • figure out what to do about yellow center lines

    • intersections on one-ways look weird
    • yellow and white lines intersect cars and turn icons and such
    • who should own drawing them?

More data

Low-priority geometry issues

More problems to fix

  • Disconnected map
    • Some lane-changing model needed to determine this
  • Impossible turns (from a far bus lane to a crazy left)

Release

  • publish the map data
  • stabilize the code except for sim