Skip to content

rmadar/perf-gohep

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Performances comparison: go-hep v.s. ROOT

This repository hosts a couple of small benchmark based on a TTree reading in order to compare performances of go-hep and ROOT.

Toy data

In these test, fake data are generated, with 30 branches of either floats or slices (slice size varies between 1 and n=30). The test consists in loading all the branches and computing three sums (involving all values of all branches). One can regenerate the fake data with:

$> go run ./gen-data.go

The following table shows the time (milliseconds per 10k events) for different codes, using the exact same input file, both for ROOT (left) and go-hep (middle), as well as the ratio between go-hep and the ROOT branch approach (right):

Root go-hep go-hep / branch
Method Floats Slices
branch 2.4 23
reader 1.8 11
Commit Floats Slices
b5f3896 1.2 12
839f662 3.8 45
feb48b1 4.7 59
go-hep commit Floats Slices
b5f3896 0.5 0.5
839f662 1.6 2.0
feb48b1 1.9 2.7

Realistic data

In this test, 42 float branches are loaded for 720k events (contact me if you want to access the input file).

GOHEP

  • b5f3896: 1.6 ms/kEvt (1.1 s for 720 kEvts)
  • 839f662: 4.5 ms/kEvt (3.3 s for 720 kEvts)
  • feb48b1: 5.2 ms/kEvt (3.7 s for 720 kEvts)

ROOT

  • 2.6 ms/kEvt (1.9 s for 720 kEvts)

About

Comparing performance of go-hep and ROOT

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published