Windows 10 installation problem

Hi, I installed and started to use CommonRoad on Ubuntu a while ago. However, when I tried to do the same on Windows 10 PC, I experienced an installation problem. What I have done so far is the following:

(1) create a new environment in my Anaconda Navigator called cmRd with Python 3.8.13;
(2) within the cmRd environment, in a windows command window, use

pip install commonroad-io commonroad-drivability-checker

This is where the problem occurred. The installation did not complete but produced errors. The log from the windows command window is the following (sorry, it is kind of long):

Building wheels for collected packages: commonroad-drivability-checker, polygon3
  Building wheel for commonroad-drivability-checker (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\ProgramData\Anaconda3\envs\cmRd\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Tong\\AppData\\Local\\Temp\\pip-install-jdzwspsk\\commonroad-drivability-checker_1f5efd72f4dd4e98b5d7dd24fdbc71f8\\setup.py'"'"'; __file__='"'"'C:\\Users\\Tong\\AppData\\Local\\Temp\\pip-install-jdzwspsk\\commonroad-drivability-checker_1f5efd72f4dd4e98b5d7dd24fdbc71f8\\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\Tong\AppData\Local\Temp\pip-wheel-bx87aoow'
       cwd: C:\Users\Tong\AppData\Local\Temp\pip-install-jdzwspsk\commonroad-drivability-checker_1f5efd72f4dd4e98b5d7dd24fdbc71f8\
  Complete output (111 lines):

The full log is even longer, for anyone interested in the full error log, it is provided here

I believe the prebuilt wheels don’t work for Windows at the moment. You should build the Drivability Checker on your own. Could you confirm this? @gerald_w

Hi Edmond, thank you for your insight. I can confirm that the basic commonroad-io tool installation using pip install commonroad-io is successful. For the driveability checker tool, I did the following trying to build it on my own:

  1. Following the guide from the installation doc (it has Linux and macOS manual build guides, but no dedicated Windows manual build guide).
  2. First I downloaded and installed eigen3.
  3. then I downloaded boost libraries (stable version 1.78), unzipped it, and placed it under C:\Program Files\boost\boost_1_78_0. I don’t know if I should build boost myself or not.
  4. I ran the following commands in the root folder of the CommonRoad Drivability Checker git submodule update --init, everything seems successful.
  5. I ran the following command with my conda environment activated pip3 install -r requirements.txt, everything seems successful.
  6. I ran the following command with my conda environment activated BUILD_JOBS=8 python setup.py build, error message 'BUILD_JOBS' is not recognized as an internal or external command .
  7. I removed BUILD_JOBS=8 and only used python setup.py build, the build started, but ended with error MSBUILD : error MSB1004: Specify the name of the target. Switch: --target. For the full error log, see here.

At this point I am stuck.

Hi nexthybrid,

currently we only offer the drivability checker as a (prebuilt) package on PyPi for Linux and MacOS. As far as I know, building from source directly on Windows doesn’t work (at least we have never tested that).

To run it on Windows, you can use “Windows Subsystem for Linux”. We have tested that previously and it worked for us. Also, other CommonRoad users have used this approach.

You can check out this thread with the instructions for this approach. Also in this thread another user has described how he successfully set CommonRoad up to run on Windows.

Hope this helps.

Best,
Gerald