Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use OmniFactories without explicit wiring #384

Open
DraTeots opened this issue Nov 17, 2024 · 0 comments
Open

Use OmniFactories without explicit wiring #384

DraTeots opened this issue Nov 17, 2024 · 0 comments

Comments

@DraTeots
Copy link
Collaborator

DraTeots commented Nov 17, 2024

Trying to use JANA2 JOmniFactory. Unfortunately using i

    struct ReconstructedHitFactory : public JOmniFactory<ReconstructedHitFactory> {
        PodioInput<tdis::DigitizedMtpcMcHit> m_mc_hits_in {this, {"DigitizedMtpcMcHit"}};
        PodioOutput<edm4eic::TrackerHit> m_tracker_hits_out {this, "TrackerHit"};
//...

    auto reco_hit_generator = new JOmniFactoryGeneratorT<tdis::tracking::ReconstructedHitFactory>();
    app.Add(reco_hit_generator);

This will not work until explicit wiring is added

    reco_hit_generator->AddWiring("TrackerHitGenerator", {"DigitizedMtpcMcHit"}, {"TrackerHit"});

This line basically rewrites the above values. I understand that this is supported to nourish some expectations of some EICRecon developers. But in smaller application I don't see any value in this. On opposite, it makes people to write these string names in another part of codebase and makes code more difficult to grasp for those not familiar with JANA2. JANA2 wiring is still automatic and not explicit in general.

I have a couple of JANA2 applications for different experiments and projects. For all of them it is a problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant