However when I input this file into the OpenStreetMap() function from Agents.jl (under the hood uses LightOSM from what I understand) I get a key error stating KeyError: key "way" not found. Any Idea what I am doing incorrectly?
using Agents: AbstractAgent, OpenStreetMapSpace, @agent,OSMAgent, ABM
@agent Zombie OSMAgent begin
infected::Bool
speed::Float64
end
map_path = "misc/data/guadeloupe-latest.osm"
model = ABM(
Zombie,
OpenStreetMapSpace(map_path);
properties = Dict(:dt => 1/60),
)
>>> ERROR: KeyError: key "way" not found
You may want to try converting your map to .json instead of .osm, if thatâs possible. Once youâve done this, you should (hopefully) be able to just create the OSM model via Agents.jl with the built-in functionality.
P.s.: Mind you, I havenât ever tested it like this. I just remember something about json being the preferred and fastest format for LightOSM. Personally, I normally just use the built-in overpass download function from LightOSM to get my map data.
Alright managed to sort it, Its was actually a problem with the filtering side of things. There were no highways in Guadeloupe, hence why it was giving a âkey âwayâ not found errorâ