GithubHelp home page GithubHelp logo

mmlynari / k4geo Goto Github PK

View Code? Open in Web Editor NEW

This project forked from key4hep/k4geo

0.0 0.0 0.0 26.96 MB

DD4hep based geometry models for lepton collider detectors (Formerly known as lcgeo)

License: GNU General Public License v3.0

Shell 0.50% C++ 94.66% Python 3.22% C 0.11% TeX 0.68% CMake 0.84%

k4geo's Introduction

lcgeo (Lepton Collider Geometry)

Build Coverity Scan Build Status

Implementation of Lepton Collider detector models in DD4hep.

lcgeo is distributed under the GPLv3 License

License

Requirements

DD4hep built with Geant4 and LCIO

Download and Installation

Download

  • git clone https://github.com/iLCSoft/lcgeo.git

  • cd lcgeo ; mkdir build ; cd build

Initialize dependency

  • source __path_to_DD4hep__/bin/thisdd4hep.sh

  • cmake -DBoost_NO_BOOST_CMAKE=ON ..

Build

  • make -j4 install

Initialize

  • source ../bin/thislcgeo.sh

Running some examples

go to cd ./example

Create single particle input file

Modify the python script ./example/lcio_particle_gun.py in order to create an LCIO input file with single particles:

  • export PYTHONPATH=${LCIO}/src/python:${ROOTSYS}/lib:$PYTHONPATH
  • python lcio_particle_gun.py

There is also example input file with 10 singe muons: ./mcparticles.slcio

Run the simulation:

  • ddsim --compactFile ../ILD/compact/ILD_o1_v05/ILD_o1_v05.xml --inputFiles mcparticles.slcio -N 10

This creates an lcio file simple_lcio.slcio with sim hits and MCParticles.

You can look at it in the usual way

  • anajob simple_lcio.slcio

  • dumpevent simple_lcio.slcio 1

Change the ddsim command line parameters as needed to read other input files.

Event displays:

There are several ways for visualizing the detector geometry and the simulated events:

  1. CED event display

    ced2go -d gear_ILD_o1_v05_ORG.xml -t ced2go-template.xml simple_lcio.slcio

  2. teveDisplay

    ln -s simple_lcio.slcio teve_infile.slcio

    teveDisplay ../ILD/compact/ILD_o1_v05/ILD_o1_v05.xml

  3. DDEve:

    root

    .x $DD4hepINSTALL/examples/DDEve/DDEve.C()

    and then load

    ../ILD/compact/ILD_o1_v05/DDEve.xml

Running the reconstruction with Marlin (EXPERIMENTAL)

  1. create a gear file from the DD4hep detector model, e.g.

    convertToGear default ../trunk/ILD/compact/ILD_o1_v05.xml gear_ILD_o1_v05_dd4hep.xml

    [ Friendly reminder: in order to work you need to explicitly build DD4hep with GEAR enabled. Use the flag -DDD4HEP_USE_GEAR="ON" for the cmake command. ]

    Note: currently this might still be incomplete and you can copy missing information for example from the original Mokka gear files ( or use $DDSIM/example/gear_ILD_o1_v05_dd4hep.xml )

  2. run simulation (as described above), e.g.:

    python ddsim.py ../ILD/compact/ILD_o1_v05/ILD_o1_v05.xml

  3. run the standard reconstruction ( tracking only so far ):

    Marlin ../example/ild_dd4hep_stdreco.xml
    --global.LCIOInputFiles=./simple_lcio.slcio --MyLCIOOutputProcessor.LCIOOutputFile=./simple_lcio_REC.slcio

  4. look at the result w/ the CED event display, e.g.

    ced2go -d ../example/gear_ILD_o1_v05_ORG.xml -t ../example/ced2go-template.xml simple_lcio_REC.slcio

License and Copyright

Copyright (C), lcgeo Authors

lcgeo is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License long with this program. If not, see http://www.gnu.org/licenses/.

k4geo's People

Contributors

shaojunlu avatar gaede avatar andresailer avatar protopopescu avatar danieljeans avatar nikiforosnikiforou avatar atolosadelgado avatar tiborild avatar brieucf avatar rete avatar jmcarcell avatar swathisasikumar avatar tmadlener avatar pawlikb avatar giovannimarchiori avatar vvolkl avatar voutsi avatar thorbenquast avatar zwu0922 avatar aidanrobson avatar jstrube avatar eleogran avatar markusfrankatcernch avatar simoniel avatar bartosik-hep avatar criticanalytic avatar zehvogel avatar bogdanmishchenko avatar zaborowska avatar armin-ilg avatar

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.