crowddynamics / crowddynamics

Continuous-time multi-agent crowd simulation engine implemented in Python using Numba and Numpy for performance.
https://jaantollander.com/post/how-to-implement-continuous-time-multi-agent-crowd-simulation/
MIT License
41 stars 9 forks source link

What exactly the enviroment is? #357

Open wdc63 opened 5 years ago

wdc63 commented 5 years ago

What python version should used? I tried from python 3.5.2, 3.5.4 and 3.7.3 on windows but none of them worked.

These two librarise can't meet requriment.txt: numpy must upgrade to 1.3.3+ to meet the pandas requirement. And Shapely could't find version shapely==1.5.17.post1 but 1.6.4.

In agent.py "from collections import Callable, Collection, Generator" there is no class named Collection in collections.abc under version of python 3.6 ,but I see the ductment used python3.5.

When I soved that.

The newest error seems to be a numba error:

PS C:\Users\Administrator> crowddynamics Traceback (most recent call last): File "C:\Python35\lib\site-packages\numba\pythonapi.py", line 1297, in serialize_object gv = self.module.__serialized[obj] KeyError: (<class 'RuntimeError'>, ('numba jitted function aborted due to unresolved symbol',))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "C:\Python35\Scripts\crowddynamics-script.py", line 9, in load_entry_point('crowddynamics==0+unknown', 'console_scripts', 'crowddynamics')() File "C:\Python35\lib\site-packages\pkg_resources__init.py", line 565, in load_entry_point return get_distribution(dist).load_entry_point(group, name) File "C:\Python35\lib\site-packages\pkg_resources__init.py", line 2631, in load_entry_point return ep.load() File "C:\Python35\lib\site-packages\pkg_resources__init__.py", line 2291, in load return self.resolve() File "C:\Python35\lib\site-packages\pkg_resources\init.py", line 2297, in resolve module = import__(self.module_name, fromlist=['name'], level=0) File "C:\Python35\lib\site-packages\crowddynamics-0+unknown-py3.5.egg\crowddynamics\cli.py", line 11, in from crowddynamics.simulation.multiagent import MultiAgentSimulation File "C:\Python35\lib\site-packages\crowddynamics-0+unknown-py3.5.egg\crowddynamics\simulation\multiagent.py", line 10, in from crowddynamics.simulation.agents import Agents File "C:\Python35\lib\site-packages\crowddynamics-0+unknown-py3.5.egg\crowddynamics\simulation\agents.py", line 15, in from crowddynamics.core.distance import distance_circles, \ File "C:\Python35\lib\site-packages\crowddynamics-0+unknown-py3.5.egg\crowddynamics\core\distance.py", line 13, in from crowddynamics.core.vector2D import length, rotate90, dot File "C:\Python35\lib\site-packages\crowddynamics-0+unknown-py3.5.egg\crowddynamics\core\vector2D.py", line 8, in @numba.vectorize([f8(f8)], cache=True) File "C:\Python35\lib\site-packages\numba\npyufunc\decorators.py", line 118, in wrap vec = Vectorize(func, **kws) File "C:\Python35\lib\site-packages\numba\npyufunc\decorators.py", line 38, in new return imp(func, identity=identity, cache=cache, targetoptions=kws) File "C:\Python35\lib\site-packages\numba\npyufunc\dufunc.py", line 89, in init self._install_cg() File "C:\Python35\lib\site-packages\numba\npyufunc\dufunc.py", line 275, in _install_cg targetctx = self._dispatcher.targetdescr.target_context File "C:\Python35\lib\site-packages\numba\npyufunc\ufuncbuilder.py", line 40, in target_context return cpu_target.target_context File "C:\Python35\lib\site-packages\numba\targets\registry.py", line 54, in target_context return self._toplevel_target_context File "C:\Python35\lib\site-packages\numba\utils.py", line 283, in get res = instance.dict[self.name] = self.func(instance) File "C:\Python35\lib\site-packages\numba\targets\registry.py", line 38, in _toplevel_target_context return cpu.CPUContext(self.typing_context) File "C:\Python35\lib\site-packages\numba\targets\base.py", line 240, in init__ self.init() File "C:\Python35\lib\site-packages\numba\targets\cpu.py", line 48, in init rtsys.initialize(self) File "C:\Python35\lib\site-packages\numba\runtime\nrt.py", line 35, in initialize self._library = nrtdynmod.compile_nrt_functions(ctx) File "C:\Python35\lib\site-packages\numba\runtime\nrtdynmod.py", line 199, in compile_nrt_functions ir_mod, library = create_nrt_module(ctx) File "C:\Python35\lib\site-packages\numba\runtime\nrtdynmod.py", line 189, in create_nrt_module _define_nrt_unresolved_abort(ctx, ir_mod) File "C:\Python35\lib\site-packages\numba\runtime\nrtdynmod.py", line 166, in _define_nrt_unresolved_abort ctx.call_conv.return_user_exc(builder, RuntimeError, (msg,)) File "C:\Python35\lib\site-packages\numba\targets\callconv.py", line 344, in return_user_exc struct_gv = pyapi.serialize_object(exc) File "C:\Python35\lib\site-packages\numba\pythonapi.py", line 1299, in serialize_object struct = self.serialize_uncached(obj) File "C:\Python35\lib\site-packages\numba\pythonapi.py", line 1282, in serialize_uncached arr = self.context.insert_unique_const(self.module, name, bdata) File "C:\Python35\lib\site-packages\numba\targets\base.py", line 401, in insert_unique_const gv = mod.get_global(name) File "C:\Python35\lib\site-packages\llvmlite\ir\module.py", line 138, in get_global return self.globals[name] KeyError: '.const.pickledata.2479669597384'

Hoping to get your help

jaantollander commented 5 years ago

Sorry about the late response. I haven't been working on this project for a while. I hope these instructions will help you:

To install the Conda environment:

Are you also trying to install crowddynamics-qtgui as well?