Skip to content

Mappedin Parser

agent/parsers/mappedin.py — handles Vicinity, Mirvac, and international Mappedin-powered malls.

Input

Directory containing sniffed Mappedin API responses:

  • public_1_polygon_*.json — vertexes for all polygons
  • public_1_map_*.json — floor definitions with georef control points
  • public_1_location_*.json — store names, amenity locations with semantic names

Coordinate Transform

Mappedin provides 3+ georef control points per floor (map.georeference[]). Each maps a pixel-space (x, y) to a real-world (lat, lng). The parser builds an affine transform (GeorefTransform.from_control_points()) and applies it to all coordinates, producing WGS84 [lng, lat] output.

Layer Classification

Polygon layers map to feature types:

LayerFeature TypeCategory
Polygon, Anchor, Kiosk, etc.unitshop
Seating Areaunitservice
Washroom / Washroomsamenitytoilet
Connection / Connectionsamenityescalator
Entrance / Entrancesamenityexit
Amenities IconsSkipped
Floor, Wall, Void, etc.Skipped

Amenity Classification from Locations

The public_1_location_*.json file is the authoritative source of amenity classification. When a location of type "amenities" links to a polygon via its polygons[] array, the location's name overrides the layer-based classification.

24+ name patterns in AMENITY_NAME_PATTERNS (case-insensitive substring, ordered most-specific first):

PatternCategory
escalator, escalatorsescalator
elevator, elevators, liftselevator
staircase, stairsstairs
parent with pramparking
parents room, family roomparents_room
restroom, washroom, toilettoilet
atmatm
ev charging, charging stationev_charging
accessible parking, car parkparking
uber, rideshare, drop-offrideshare
taxitaxi
bus, shuttlebus
valetvalet
concierge, visitor loungeconcierge
guest services, directoryinfo

Unmatched amenity names are logged as warnings.

Store Name Index

Store/tenant locations (type: "store" or type: "tenant") are indexed by polygon ID. When a unit polygon's ID matches a location's polygons[].id, the store name becomes the feature's label.

Note: Some Mappedin tenants (e.g. Philippines malls) miscategorize stores as type: "amenities". The parser handles this correctly — unmatched amenity names fall through to the name index as store labels.

Output

ParserResult with:

  • floors[] — each with features[] (ParsedFeature), bbox, georef
  • has_georef — true if any floor has geographic coordinates
  • warnings[] — unmapped amenity names, missing files, etc.