cms-tau-pog / TauFW

Analysis framework for tau analysis at CMS using NanoAOD
9 stars 40 forks source link

Do multiple tries to get number of events #27

Closed DennRoy closed 1 year ago

DennRoy commented 1 year ago

Sometimes the script crashes for me with an error because a file couldn't the read in DAS, but then it works the second time, only to crash again at a later time. Doing multiple attempts would fix this.

IzaakWN commented 1 year ago

I am fine with this, but just FYI: If you have to frequently submit jobs split on an event-basis, you can save a lot of time by storing the total number of events per NANOAOD file (whether it is on the GRID or on a local storage system) into a text file with

pico.py write -y UL2018 --nevts

You can also add the option --try 6 to try again 6 times before giving up, and specify with e.g. -s DY*Jets what samples you want to get the filenames & event number for.

Once you have the text files, you can set the filelist in the sample config file, e.g. here.

For more instructions, please see https://github.com/cms-tau-pog/TauFW/tree/master/PicoProducer#samples

IzaakWN commented 1 year ago

@DennRoy, apologies for not following up on this. Was the problem solved with my previous suggestion in the end?

DennRoy commented 1 year ago

Hi Izaak, yes, that's right. It's better with your suggestion.