Git Product home page Git Product logo

Comments (6)

JStrydhorst avatar JStrydhorst commented on August 22, 2024

I suspect the problem is in the analysis. How are you extracting the energy spectra? Are you using an actor that filters on primary particles generated? That you have an identical number of entries in both spectra is suspicious. At the very least, there should be far fewer positrons (~32 per million decays) than brem photons (~6 % of the number of decays).

from gate.

canonnervio avatar canonnervio commented on August 22, 2024

I'm using the code you provided in plot.C:

...
// open the output file 
TFile* f2 =new TFile (" fastY90Pos.root"); 
// and print the content
f2->ls();

// retrieve the energy spectrum histogram 
TH1F * h2 = (TH1F*)f2->Get("energySpectrum");
h2->SetLineColor(kRed);
// set title and the axis legend
h2->SetTitle("fastY90 positron kinetic energy");
h2->GetXaxis()->SetTitle("Energy (MeV)");
h2->GetYaxis()->SetTitle("Counts");
h2->GetXaxis()->SetRangeUser(0. ,1);

// statistic type ( (1) write mean value, number of entries and RMS)
h2->SetStats(1);

// draw histogram using point (P) associated with error bar (E) or HIST for histogramm
c1->cd(2);
h2->Draw("HIST");
...

and the output was generated with the unmodified output.mac:

...
/gate/actor/addActor EnergySpectrumActor pos_actor
/gate/actor/pos_actor/attachTo MainBox
/gate/actor/pos_actor/addFilter    particleFilter
/gate/actor/pos_actor/particleFilter/addParticle  e+
/gate/actor/pos_actor/save output/fastY90Pos.root
/gate/actor/pos_actor/energySpectrum/setEmin 0 eV
/gate/actor/pos_actor/energySpectrum/setEmax 1 MeV
/gate/actor/pos_actor/energySpectrum/setNumberOfBins 100

I agree with your point on the suspicious numbers of particles being exactly the same. Even inspecting the fastY90Pos.root file directly yields the duplicate data:
fasty90pos_root

from gate.

JStrydhorst avatar JStrydhorst commented on August 22, 2024

I really don't understand. I created the example plot using the code that's in the example directory, and rereading, everything appears to be in order.

One thing I do notice is that the total number of entries in your output (6504827) is exactly equal to the sum of the brem and positron entries (6501704 and 3123 respectively) that I got when I created the example. It seems like the particle filter of the actor is doing nothing and both of your outputs contain both the gammas and the positrons. The number of positrons is small, so the peak isn't visible in the plot.

from gate.

dsarrut avatar dsarrut commented on August 22, 2024

Hello,
any progress on that issue ? Should we still consider it as open ?

from gate.

canonnervio avatar canonnervio commented on August 22, 2024

I tried to reproduce this behavior on multiple machines with the same configuration (Ubuntu 16.04 LTS, Geant4.10.02.p02, Root 5.34.36) and I could not get the plots provided, i.e. the correct positron kinetic energy. Maybe someone else can try and confirm this issue?

from gate.

canonnervio avatar canonnervio commented on August 22, 2024

I re-evaluated this issue with Gate 8.0, Geant4 10.3.1 and root 6.10/00 and I cannot reproduce it any more.
With the versions mentioned it works as intended. I consider this issue closed.

from gate.

Related Issues (20)

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.