Here, we assume that Docker is already installed and can access the GPU. If you did not install Docker yet, please refer to the complete instructions below.
git clone --recursive https://github.com/cg-tuwien/StatMC.git
cd StatMC/
sudo docker build -t statmc -f ./docker/Dockerfile . --network=host
sudo docker run -d -i -t --name statmc -v .:/StatMC --gpus all --network=host statmc
sudo docker exec -it statmc bash
./docker/install-dependencies-container.sh
./scripts/_build.sh
./scripts/_download-scenes.sh
./scripts/1-staircase.sh
-
If not already done, check out our repository:
git clone --recursive https://github.com/cg-tuwien/StatMC.git cd StatMC/
Important: Make sure all shell scripts inside the
scripts/
directory have UNIX line endings (\n
). On Windows, Git might convert them automatically to Windows-style line endings (\r\n
) which will result in errors when executed with bash inside the container. -
Optional: if not already installed, install the NVIDIA driver and CUDA on the host:
sudo ./scripts/_install-dependencies.sh
If you reboot, make sure to go back into the
StatMC/
directory afterwards. -
Optional: if not already installed, install Docker and the NVIDIA Container Toolkit on the host:
./docker/install_docker.sh ./docker/install_nvidia_container_toolkit.sh
-
Create the container:
sudo docker build -t statmc -f ./docker/Dockerfile . --network=host
-
Start the container in detached mode:
sudo docker run -d -i -t --name statmc -v .:/StatMC --gpus all --network=host statmc
This enables the GPU for the container and mounts the current (
StatMC
) directory (as a persistent volume) at/StatMC
inside the container. -
If not already done, make the shell scripts for Docker executable:
chmod +x ./docker/install-dependencies-container.sh
-
Open an interactive shell inside the container:
sudo docker exec -it statmc bash
Inside the interactive shell:
-
Install dependencies inside the container, compile the sources, and download scenes:
./docker/install-dependencies-container.sh ./scripts/_build.sh ./scripts/_download-scenes.sh
-
Compute the first result from the paper.
./scripts/1-staircase.sh
-