-
-
Notifications
You must be signed in to change notification settings - Fork 187
Description
Hi,
I'm testing gis/agents_and_networks but I faced an issue. I followed the readme. After executing the python3 -m pip install -r requirements.txt, the import mesa
print("Mesa version:", mesa.version) is Mesa version: 2.1.5 and the mesa-geo related to the requirements.txt is accurate: import mesa_geo
print("Mesa-Geo version:", mesa_geo.version), that means: Mesa-Geo version: 0.7.1.
Hi,
I'm testing the gis/agents_and_networks model, but I've encountered an issue. I followed the instructions in the README file, including executing python3 -m pip install -r requirements.txt.
When checking the versions, everything seems correct:
Mesa version: 2.1.5 (import mesa; print("Mesa version:", mesa.version))
Mesa-Geo version: 0.7.1 (import mesa_geo; print("Mesa-Geo version:", mesa_geo.version)).
However, when I attempt to run the command python3 scripts/run.py --campus ub, I get the following error message:
(mesa3_lite) parfait.atchade@Parfaits-MacBook-Pro agents_LLM_Mesa_Maps % python3 scripts/run.py --campus ub
Traceback (most recent call last):
File "/Users/parfait.atchade/Documents/agents_LLM_Mesa_Maps/scripts/run.py", line 58, in
server = mesa.visualization.ModularServer(
File "/Users/parfait.atchade/.pyenv/versions/3.9.6/lib/python3.9/site-packages/mesa_viz_tornado/ModularVisualization.py", line 354, in init
self.reset_model()
File "/Users/parfait.atchade/.pyenv/versions/3.9.6/lib/python3.9/site-packages/mesa_viz_tornado/ModularVisualization.py", line 381, in reset_model
self.model = self.model_cls(**model_params)
File "/Users/parfait.atchade/Documents/agents_LLM_Mesa_Maps/src/model/model.py", line 99, in init
self._load_buildings_from_file(buildings_file, crs=model_crs, campus=campus)
File "/Users/parfait.atchade/Documents/agents_LLM_Mesa_Maps/src/model/model.py", line 166, in _load_buildings_from_file
buildings = building_creator.from_GeoDataFrame(buildings_df)
File "/Users/parfait.atchade/.pyenv/versions/3.9.6/lib/python3.9/site-packages/mesa_geo/geoagent.py", line 197, in from_GeoDataFrame
new_agent = self.create_agent(geometry=geometry, unique_id=index)
File "/Users/parfait.atchade/.pyenv/versions/3.9.6/lib/python3.9/site-packages/mesa_geo/geoagent.py", line 156, in create_agent
new_agent = self.agent_class(
TypeError: init() got an unexpected keyword argument 'unique_id'
It seems to be an issue with how the unique_id argument is being passed. Could you give me any insights or guidance on how to resolve this?
Thank you for your support!
Best,