-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue running pyvroom #85
Comments
Do you mind updating and reporting the version of Numpy? I suspect it is out of date? |
I have the same issue. Numpy version 1.26.0, pyvroom 1.13.3. Win 11, 64-bit. I'm using python 3.10.11. |
@jcoupey, please, can you help me with this issue specific to Win OS? |
There are two different errors here. Are you saying that you are getting the error equal to 3.7 or 3.8? |
Yes set_durations_matrix |
I can't reproduce so I'm not completly sure, but I suspect that the underlying data types are mismatching. I've made a experimental release for 1.13.4-dev1 which you can try out where I replace Let me know if that solves the issue. |
Can I install via pip? |
yes. |
Hmm, I'm getting still this: |
And @jonathf you can't reproduce on windows 11? Which python? I tried |
That is unfortunate. I don't have a windows machine. @nilsnolde, any chance you have time to try diagnose this issue? |
@jonathf on Ubuntu 20.04 or 22.04 it works with no issues. But we want to support Windows as well :-(. |
I’m currently taking a bit of distance to unpaid work for the rest of the year tbh. That is to say, you can contact me on [email protected] @jfulem if you want commercial support on this. At some point we’ll deal with this too, but that’s well into next year. |
Fwiw, the tests should probably run on windows as well. For FOSS it’s not counting towards GitHub limits @jonathf. OSX should mostly be fine when Linux is ok since the tool chains are so similar, but win is a very different STL. |
@nilsnolde OK, fair enough. I don't need commercial support. |
@nilsnolde, very understandable. Yeah, activating the tests for windows should be done. We chose against it when we started as I didn't want to use up vrooms entired budget, but that isn't as much of an issue anymore as the activity is now much lower. I'll get to that one of these days. |
Hi, I tried running the example code given in the documentation but encountered errors. Please let me know how to resolve this.
Find below the Python code I have used.
import vroom
problem_instance = vroom.Input()
problem_instance.set_durations_matrix(
profile="car",
matrix_input = [[0, 2104, 197, 1299],
[2103, 0, 2255, 3152],
[197, 2256, 0, 1102],
[1299, 3153, 1102, 0]],
)
problem_instance.add_vehicle([vroom.Vehicle(47, start=0, end=0),
vroom.Vehicle(48, start=2, end=2)])
problem_instance.add_job([vroom.Job(1414, location=0),
vroom.Job(1515, location=1),
vroom.Job(1616, location=2),
vroom.Job(1717, location=3)])
solution = problem_instance.solve(exploration_level=5, nb_threads=4)
print('Done')
I tried running the same code with different versions of Python.
Error with Python version 3.7.1
C:\Project\venvs\work_1\Scripts\python.exe C:\Project\practice_work\vrp_vroom\test.py
Traceback (most recent call last):
File "C:\Project\practice_work\vrp_vroom\test.py", line 1, in
import vroom
File "C:\Project\venvs\work_1\lib\site-packages\vroom_init_.py", line 14, in
from .input.input import Input
File "C:\Project\venvs\work_1\lib\site-packages\vroom\input\input.py", line 6, in
from numpy.typing import ArrayLike
ModuleNotFoundError: No module named 'numpy.typing'
Error with Python version 3.8.10:
C:\Project\venvs\work_2\Scripts\python.exe C:\Project\practice_work\vrp_vroom\test.py
Traceback (most recent call last):
File "C:\Project\practice_work\vrp_vroom\test.py", line 5, in
problem_instance.set_durations_matrix(
File "C:\Project\venvs\work_2\lib\site-packages\vroom\input\input.py", line 283, in set_durations_matrix
matrix_input = _vroom.Matrix(numpy.asarray(matrix_input, dtype="uint32"))
RuntimeError: Incompatible buffer format!
Operating system: Windows 10, 64-bit
The text was updated successfully, but these errors were encountered: