Skip to content

Wrong visualization #75

@jackerschott

Description

@jackerschott

Take the following hepmc2 file containing a single semileptonic ttH event: events.zip and visualize this event using pyhepmc version 2.13.2 to a pdf (I am piping to dot -Tpdf > event.pdf):

with pyhepmc.open("test.hepmc") as f:
    event = f.read()
    print(to_dot(event))

The resulting event contains two W bosons (which one can easily search for in the PDF) one of which contains into a single up quark and nothing else. However if I do

import pyhepmc
import numpy as np

with pyhepmc.open("test.hepmc") as f:
    event = f.read()
    for particle in event.particles:
        if np.abs(particle.pid) == 24:
            print(len(particle.children))

I can see that len(particle.children) is 2 for both W bosons as it should be. Seems like there is a bug in the to_dot function.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions