GithubHelp home page GithubHelp logo

hole-ice-scripts's People

Contributors

fiedl avatar

Watchers

 avatar  avatar

hole-ice-scripts's Issues

AttributeError: module 'icecube.phys_services' has no attribute 'I3SPRNGRandomService'

When running the propagation script in zeuthen (#9), the random-number generator is not found.

[2022-09-09 17:24:37] fiedl@kepler00 ~/icecube/hole-ice-scripts
▶ ~/icecube/icetray-build/env-shell.sh
▶ scripts/generate_photons.py
Traceback (most recent call last):
  File "scripts/generate_photons.py", line 63, in <module>
    main()
  File "scripts/generate_photons.py", line 16, in main
    random_number_generator = phys_services.I3SPRNGRandomService(
AttributeError: module 'icecube.phys_services' has no attribute 'I3SPRNGRandomService'

Originally posted by @fiedl in #9 (comment)

No matching OpenCL devices

After building icetray in zeuthen (#9), run the propagation script there:

[2022-09-09 17:50:55] fiedl@kepler00 ~/icecube/hole-ice-scripts
▶ ~/icecube/icetray-build/env-shell.sh
▶ scripts/generate_photons.py
▶ scripts/propagate_photons.py
FATAL (clsim): No matching OpenCL devices. Devices: Intel(R) Xeon(R) CPU E5-2660 0 @ 2.20GHz Selection: UseCPUs=False, UseGPUs=True, UseOnlyDeviceNumber=None.

Originally posted by @fiedl in #4 (comment)

Photonen mit Richtung generieren

In #6 (comment) sieht es so aus, als werden die Photonen in verschiedene Richtungen emittiert, obwohl ich einen schmalen Öffnungswinkel von 0.001 Grad angegeben habe.

[2022-09-07 23:20:27] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ 75cd293
▶ docker-compose run icetray scripts/generate_photons.py
▶ docker-compose run icetray scripts/propagate_photons.py

[2022-09-07 23:30:27] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ 75cd293
▶ source ~/py3/bin/activate && ~/icecube/icetray-build/env-shell.sh
▶ steamshovel data/propagated_photons.i3

Bildschirmfoto 2022-09-07 um 23 41 31

Prepare demo geometry

scenario including:

  • a DOM
  • a cable
  • drill hole
  • bubble column
  • several photons

requirements:

  • kernel code ➝ #12
  • passing parameters ➝ #15
  • cylinders with bottom and top
  • improve memory allocation
  • store more photon scatterings

No photons recorded by minimal propagation script

I have prepared minimal scripts to generate and propagate photons with clsim.

However, no photons are recorded.

[2022-08-10 11:16:50] fiedl@fiedl-mbp ~/icecube
▶ git clone [email protected]:fiedl/hole-ice-scripts.git

[2022-08-11 19:15:43] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ 1971bc1
▶ docker-compose run icetray scripts/generate_photons.py
▶ docker-compose run icetray scripts/propagate_photons.py
number of PhotonSeriesMap entries: 0

This is the clsim configuration from scripts/propagate_photons.py:

  tray.Add(
    clsim.I3CLSimMakePhotons,
    GCDFile = DETECTOR_GEOMETRY_FILE,
    UseCPUs = True,
    UseGPUs = False,
    UseI3PropagatorService = False,
    OutputMCTreeName = None,
    PhotonSeriesName = 'PhotonSeriesMap',
    MCPESeriesName = None,
    RandomService = tray.context['I3RandomService'],
    IceModelLocation = os.path.expandvars('$I3_SRC/ice-models/resources/models/ICEMODEL/spice_bfr-v2'),
    UseCascadeExtension = False,
    DisableTilt = False,
    DoNotParallelize = True,
    DOMOversizeFactor = 1.0,
    DOMEfficiency = 1.0,
    HoleIceParameterization = os.path.expandvars('$I3_SRC/ice-models/resources/models/ANGSENS/angsens/as.nominal'), # no hole-ice approximation
    UnWeightedPhotons = True,
    UnWeightedPhotonsScalingFactor = 1.0,
    StopDetectedPhotons = False,
    SaveAllPhotons = True,
    SaveAllPhotonsPrescale = 1.0,
    PhotonHistoryEntries = 10
  )

Script: Generate Photons

A minimal showcase would be:

  • Generate photons
  • Propagate these photons with clsim
  • Record the photon paths
  • Display the photon paths with steamshovel

Later, this can be extended to incorporate hole ice.

The first step would be to generate the photons to propagate.

Configure hole ice through `I3CLSimHoleIceCylinder`

ImportError: cannot import name 'I3CLSimOpenCLDevice' from 'icecube.clsim'

How to reproduce:

  1. Clone this repository
  2. Build icetray locally (#1)
  3. Start icetray env shell
  4. Run script scripts/propagate_photons.py locally:
[2022-09-08 00:12:29] fiedl@fiedl-mbp ~/icecube/hole-ice-scripts master ⚡ f823690
▶ source ~/py3/bin/activate && ~/icecube/icetray-build/env-shell.sh
▶ scripts/generate_photons.py
▶ scripts/propagate_photons.py
Traceback (most recent call last):
  File "/Users/fiedl/icecube/hole-ice-scripts/scripts/propagate_photons.py", line 92, in <module>
    main()
  File "/Users/fiedl/icecube/hole-ice-scripts/scripts/propagate_photons.py", line 28, in main
    tray.Add(
  File "/Users/fiedl/icecube/icetray-build/lib/I3Tray.py", line 107, in Add
    return method(_type, _name, **kwargs)
  File "/Users/fiedl/icecube/icetray-build/lib/I3Tray.py", line 224, in AddSegment
    return _segment(self, _name, **kwargs)
  File "/Users/fiedl/icecube/icetray-build/lib/icecube/clsim/traysegments/I3CLSimMakePhotons.py", line 302, in I3CLSimMakePhotons
    converters = setupPropagators(RandomService, clsimParams,
  File "/Users/fiedl/icecube/icetray-build/lib/icecube/clsim/traysegments/common.py", line 430, in setupPropagators
    openCLDevices = configureOpenCLDevices(
  File "/Users/fiedl/icecube/icetray-build/lib/icecube/clsim/traysegments/common.py", line 13, in configureOpenCLDevices
    from icecube.clsim import I3CLSimOpenCLDevice
ImportError: cannot import name 'I3CLSimOpenCLDevice' from 'icecube.clsim' (/Users/fiedl/icecube/icetray-build/lib/icecube/clsim/__init__.py)

This script does work when running in docker (#2), but fails when running locally (#1).

SSH into zeuthen

To connect to the zeuthen gpu machine for debugging requires

ssh warp-zeuthen.desy.de
ssh ice-wgs-gpu

How can I do this without entering my password? The server does not accept my ssh key.

Script: Propagate Photons

I'm trying to propagate some photons with clsim and visualize their path with steamshovel.

clsim does provide example scripts for that. However, they do fail when run against acurrent icetray build.

[2022-08-10 14:42:06] fiedl@faustaff-010-020-007-137 ~/icecube/icetray-build
▶ ./env-shell.sh

[2022-08-10 14:43:25] fiedl@faustaff-010-020-007-137 ~/icecube/icetray/clsim/resources/scripts/photonPaths main 6ce97c3a7
▶ ./generateTestFlashes.py --gcd ~/icecube/gcd/GeoCalibDetectorStatus_IC86.55697_corrected_V2.i3.gz
▶ ./applyCLSim.py -i test_flashes.i3
using input file test_flashes.i3
output dir is
output file is test_flashes_clsim.i3
storing I3Photons
FATAL (icetray): Module/service "I3XMLSummaryServiceFactory" not registered with I3_MODULE() or I3_SERVICE_FACTORY() (I3Factory.h:91 in FactoryFn I3Factory<I3ServiceFactory, boost::function<boost::shared_ptr<I3ServiceFactory> (const I3Context &)>>::Create(std::string) const [Product = I3ServiceFactory, FactoryFn = boost::function<boost::shared_ptr<I3ServiceFactory> (const I3Context &)>])
Traceback (most recent call last):
  File "/Users/fiedl/icecube/icetray/clsim/resources/scripts/photonPaths/./applyCLSim.py", line 114, in <module>
    tray.AddService("I3XMLSummaryServiceFactory","summary",
  File "/Users/fiedl/icecube/icetray-build/lib/I3Tray.py", line 176, in AddService
    super(I3Tray, self).AddService(_type, _name)
RuntimeError: Module/service "I3XMLSummaryServiceFactory" not registered with I3_MODULE() or I3_SERVICE_FACTORY() (in FactoryFn I3Factory<I3ServiceFactory, boost::function<boost::shared_ptr<I3ServiceFactory> (const I3Context &)>>::Create(std::string) const [Product = I3ServiceFactory, FactoryFn = boost::function<boost::shared_ptr<I3ServiceFactory> (const I3Context &)>])

Maybe, the example scripts are just outdated.

Fetch hole-ice kernel code from 2018

I'm trying to get the hole-ice code from 2018 working with current icetray.

The hole-ice code from 2018 consists of:

  • kernel code ➝ #12
  • clsim code to pass parameters to the kernel ➝ #15
  • clsim additions for direct detection
  • clsim additions for memory management
  • steamshovel patches and artists
  • example scripts

As a first step, fetch the kernel code from 2018 and try to apply it to current clsim.

Where is the previous code?

The clsim hole-ice code used in the 2018 thesis The Effect of Hole Ice on the Propagation and Detection of Light in IceCube (arxiv | pdf | latex | github) can be found in this fork of clsim: https://github.com/fiedl/clsim

To have a look at the git diff between the standard clsim of that time and the hole-ice clsim, open the diff on github:

https://github.com/fiedl/clsim/compare/3703cb2aa42c831623bc6763bf631cbdebf7d0a2...fiedl:clsim:sf/hole-ice-2018?w=1

Or show that diff locally:

[2022-09-10 15:17:33] fiedl@fiedl-mbp ~/icecube
▶ git clone [email protected]:fiedl/clsim.git

[2022-09-10 15:17:33] fiedl@fiedl-mbp ~/icecube/clsim sf/hole-ice-2018 32215a5
▶ git diff --ignore-all-space 3703cb2a..sf/hole-ice-2018

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.