uproot5 icon indicating copy to clipboard operation
uproot5 copied to clipboard

Unexpected number of partitions with multiple files

Open alexander-held opened this issue 6 months ago • 0 comments

When opening a single file with uproot.dask(..., steps_per_file=1) I see one partition as expected. Opening two such files creates an object with three partitions:

prefix = "https://xrootd-local.unl.edu:1094//store/user/AGC/nanoAOD/TT_TuneCUETP8M1_13TeV-powheg-pythia8/"
fname_1 = prefix + "cmsopendata2015_ttbar_19980_PU25nsData2015v1_76X_mcRun2_asymptotic_v12_ext3-v1_00000_0000.root"
fname_2 = prefix + "cmsopendata2015_ttbar_19980_PU25nsData2015v1_76X_mcRun2_asymptotic_v12_ext3-v1_00000_0001.root"

evts_1 = uproot.dask({fname_1: "Events"}, steps_per_file=1)
assert evts_1.npartitions == 1

evts_2 = uproot.dask({fname_1: "Events"}, steps_per_file=1)
assert evts_2.npartitions == 1

evts_1_and_2 = uproot.dask({fname_1: "Events", fname_2: "Events"}, steps_per_file=1)
print(evts_1_and_2.npartitions)

-> prints 3

I would have expected two partitions to be created here (the sum over both files). Am I misunderstanding the intended behavior or is this a bug? I am using uproot version 5.3.10.

alexander-held avatar Aug 15 '24 10:08 alexander-held