ROOT Environment

Hello,

I am currently working on a code that relies on ROOT libraries. However, I have encountered an issue where the code runs without generating any errors or output. I am struggling to identify whether the problem lies within my code or if it is related to the ROOT dependency.

I have attached the relevant code file calibration_macro.C (4.5 KB) for your reference.

I would greatly appreciate any insights or guidance you can provide regarding this matter. Your expertise would be invaluable in helping me resolve this issue.

Thank you very much for your time and assistance.

Warm regards,

Bharat Kharpuse

It’s probably not a problem with ROOT but with the logic in your code. E.g., with these:

    if (label != prevLabel) {
      // Clear vectors if it's a new dataset
      channel.clear();
      energy.clear();
      prevLabel = label; // Update previous label
    }
    channel.push_back(channelValue);
    energy.push_back(energyValue);

    if (label != prevLabel) {
      // Process the dataset when label changes
      processDataset(label, channel, energy);
    }

you never reach the line processDataset(label, channel, energy);.

1 Like

Dear Dastudillo,

Thanks for the clearing my doubt, I will try to modify this logic as you suggest.

Thanks,

Regards,
Bharat

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.