Upgrade diagram filters for configurable name?

Asked by Zachary Marshall

Hi all,

Looking at the diagram filter functionality:
https://cp3.irmp.ucl.ac.be/projects/madgraph/wiki/FAQ-General-15

and:
https://github.com/mg5amcnlo/mg5amcnlo/blob/55a291dc8def762938a964cc1343c6d76af5b843/madgraph/core/diagram_generation.py#L909

I think it's a bit awkward that these names are hard-coded. It also means in an installation or system we can only use one user filter at a time, I believe (please correct me if I'm wrong!).

It feels like this would be straightforward to extend, to allow --diagram_filter to take an optional argument that is the name of the filter, and then to look for that module if available (and user_filter by default). Did I understand this correctly? Would such an extension be doable?

Thanks,
Zach

Question information

Language:
English Edit question
Status:
Answered
For:
MadGraph5_aMC@NLO Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#1

Should be doable yes.

Olivier

> On 19 Nov 2024, at 13:51, Zachary Marshall <email address hidden> wrote:
>
> New question #819375 on MadGraph5_aMC@NLO:
> https://answers.launchpad.net/mg5amcnlo/+question/819375
>
> Hi all,
>
> Looking at the diagram filter functionality:
> https://cp3.irmp.ucl.ac.be/projects/madgraph/wiki/FAQ-General-15
>
> and:
> https://github.com/mg5amcnlo/mg5amcnlo/blob/55a291dc8def762938a964cc1343c6d76af5b843/madgraph/core/diagram_generation.py#L909
>
> I think it's a bit awkward that these names are hard-coded. It also means in an installation or system we can only use one user filter at a time, I believe (please correct me if I'm wrong!).
>
> It feels like this would be straightforward to extend, to allow --diagram_filter to take an optional argument that is the name of the filter, and then to look for that module if available (and user_filter by default). Did I understand this correctly? Would such an extension be doable?
>
> Thanks,
> Zach
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Can you help with this problem?

Provide an answer of your own, or ask Zachary Marshall for more information if necessary.

To post a message you must log in.