fiedl / hole-ice-scripts

Example scripts for the hole-ice extension of clsim in the IceCube simulation framework.
0 stars 0 forks source link

Try icetray docker setup #2

Open fiedl opened 2 years ago

fiedl commented 2 years ago

There is an icetray docker image.

https://hub.docker.com/r/icecube/icetray https://github.com/wipacrepo/docker-icecube-icetray

Would this work here?

fiedl commented 2 years ago

I'm trying a minimal docker-compose configuration.

[2022-08-10 18:47:24] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ 251cfb6
▶ cat docker-compose.yml
version: "3.9"
services:
  icetray:
    image: "icecube/icetray:icetray-main-devel"
[2022-08-10 18:44:11] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master 251cfb6
▶ docker-compose run icetray bash

I've found the icetray build in /usr/local/icetray, the $I3_TESTDATA in /opt/i3-data/i3-test-data.

[2022-08-11 14:35:36] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ 251cfb6
▶ docker-compose run icetray bash
root@66bf8aca83a8:~# env |grep I3_
I3_DATA=/opt/i3-data
I3_SHELL=exec
I3_SRC=/usr/local/icetray
I3_BUILD=/usr/local/icetray
I3_TESTDATA=/opt/i3-data/i3-test-data
fiedl commented 2 years ago

From there, one can use:

[2022-08-11 16:32:28] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ e6cc5e9
▶ docker-compose run icetray icetray-inspect clsim

[2022-08-11 16:32:28] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ e6cc5e9
▶ docker-compose run icetray scripts/generate_photons.py

[2022-08-11 16:32:28] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ e6cc5e9
▶ docker-compose run icetray dataio-shovel data/generated_photons.i3
fiedl commented 2 years ago

Can one use opencl from within docker?

https://linuxhandbook.com/setup-opencl-linux-docker/