issue with user-defined propagator in propagator.py file

Asked by Salvator Lombardo

I am interested in modifying the Higgs propagator in a SM UFO file. I created a new propagator in propagator.py:

denominator = "P('mu', id) * P('mu', id) - Mass(id) * Mass(id) + complex(0,1) * Mass(id) * Width(id)"
S2 = Propagator(name = "S2",
               numerator = "complex(0,1)",
               denominator = denominator
               )

and I link this propagator to the Higgs

H = Particle(pdg_code = 25,
             name = 'H',
             antiname = 'H',
             spin = 1,
             color = 1,
             mass = Param.MH,
             width = Param.WH,
             texname = 'H',
             antitexname = 'H',
             charge = 0,
             GhostNumber = 0,
             LeptonNumber = 0,
             Y = 0,
             propagator = Prop.S2)

However, I receive an error after creating output with madgraph of
"Command "output directory" interrupted with error:
TypeError : not enough arguments for format string
Please report this bug on https://bugs.launchpad.net/mg5amcnlo
More information is found in 'MG5_debug'.
Please attach this file to your report."

Is this a bug, or am I doing something wrong?

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

Dear Salvator,

I have did the same thing as you.
(More exactly I did the following:)
Cd models
Cp -r sm sm_test
Cd sm_test
Cp ../EWDim6/__init__.py .
Cp ../EWDim6/object_library.py .
Cp ../EWDim6/propagators.py .
Cp ../EWDim6/function_library.py .

Then I did your modification to both particles.py and propagators.py
Just adding one more line in propagators.py
Import propagators as Prop

Then I can use the sm_tests model without any problem.

So I can not really comment on this without seeing the debug file.

Cheers,

Olivier

> On 25 May 2017, at 22:34, Salvator Lombardo <email address hidden> wrote:
>
> New question #634619 on MadGraph5_aMC@NLO:
> https://answers.launchpad.net/mg5amcnlo/+question/634619
>
> I am interested in modifying the Higgs propagator in a SM UFO file. I created a new propagator in propagator.py:
>
> denominator = "P('mu', id) * P('mu', id) - Mass(id) * Mass(id) + complex(0,1) * Mass(id) * Width(id)"
> S2 = Propagator(name = "S2",
> numerator = "complex(0,1)",
> denominator = denominator
> )
>
> and I link this propagator to the Higgs
>
> H = Particle(pdg_code = 25,
> name = 'H',
> antiname = 'H',
> spin = 1,
> color = 1,
> mass = Param.MH,
> width = Param.WH,
> texname = 'H',
> antitexname = 'H',
> charge = 0,
> GhostNumber = 0,
> LeptonNumber = 0,
> Y = 0,
> propagator = Prop.S2)
>
> However, I receive an error after creating output with madgraph of
> "Command "output directory" interrupted with error:
> TypeError : not enough arguments for format string
> Please report this bug on https://bugs.launchpad.net/mg5amcnlo
> More information is found in 'MG5_debug'.
> Please attach this file to your report."
>
>
> Is this a bug, or am I doing something wrong?
>
>
> --
> You received this question notification because you are an answer
> contact for MadGraph5_aMC@NLO.

Revision history for this message
Salvator Lombardo (sallombardo) said :
#2

I have attached the debug file. I noticed that this is not an issue with older versions of mad graph (v2_2_3 works fine).

> On May 26, 2017, at 3:34 AM, Olivier Mattelaer <email address hidden> wrote:
>
> Your question #634619 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/634619 <https://answers.launchpad.net/mg5amcnlo/+question/634619>
>
> Status: Open => Answered
>
> Olivier Mattelaer proposed the following answer:
> Dear Salvator,
>
> I have did the same thing as you.
> (More exactly I did the following:)
> Cd models
> Cp -r sm sm_test
> Cd sm_test
> Cp ../EWDim6/__init__.py .
> Cp ../EWDim6/object_library.py .
> Cp ../EWDim6/propagators.py .
> Cp ../EWDim6/function_library.py .
>
> Then I did your modification to both particles.py and propagators.py
> Just adding one more line in propagators.py
> Import propagators as Prop
>
> Then I can use the sm_tests model without any problem.
>
> So I can not really comment on this without seeing the debug file.
>
> Cheers,
>
> Olivier
>
>> On 25 May 2017, at 22:34, Salvator Lombardo <<email address hidden> <mailto:<email address hidden>>> wrote:
>>
>> New question #634619 on MadGraph5_aMC@NLO:
>> https://answers.launchpad.net/mg5amcnlo/+question/634619
>>
>> I am interested in modifying the Higgs propagator in a SM UFO file. I created a new propagator in propagator.py:
>>
>> denominator = "P('mu', id) * P('mu', id) - Mass(id) * Mass(id) + complex(0,1) * Mass(id) * Width(id)"
>> S2 = Propagator(name = "S2",
>> numerator = "complex(0,1)",
>> denominator = denominator
>> )
>>
>> and I link this propagator to the Higgs
>>
>> H = Particle(pdg_code = 25,
>> name = 'H',
>> antiname = 'H',
>> spin = 1,
>> color = 1,
>> mass = Param.MH,
>> width = Param.WH,
>> texname = 'H',
>> antitexname = 'H',
>> charge = 0,
>> GhostNumber = 0,
>> LeptonNumber = 0,
>> Y = 0,
>> propagator = Prop.S2)
>>
>> However, I receive an error after creating output with madgraph of
>> "Command "output directory" interrupted with error:
>> TypeError : not enough arguments for format string
>> Please report this bug on https://bugs.launchpad.net/mg5amcnlo
>> More information is found in 'MG5_debug'.
>> Please attach this file to your report."
>>
>>
>> Is this a bug, or am I doing something wrong?
>>
>>
>> --
>> You received this question notification because you are an answer
>> contact for MadGraph5_aMC@NLO.
>
> --
> If this answers your question, please go to the following page to let us
> know that it is solved:
> https://answers.launchpad.net/mg5amcnlo/+question/634619/+confirm?answer_id=0 <https://answers.launchpad.net/mg5amcnlo/+question/634619/+confirm?answer_id=0>
>
> If you still need help, you can reply to this email or go to the
> following page to enter your feedback:
> https://answers.launchpad.net/mg5amcnlo/+question/634619 <https://answers.launchpad.net/mg5amcnlo/+question/634619>
>
> You received this question notification because you asked the question.

Revision history for this message
Salvator Lombardo (sallombardo) said :
#3

#************************************************************
#* MadGraph5_aMC@NLO *
#* *
#* * * *
#* * * * * *
#* * * * * 5 * * * * *
#* * * * * *
#* * * *
#* *
#* *
#* VERSION 2.5.3 2017-03-09 *
#* *
#* The MadGraph5_aMC@NLO Development Team - Find us at *
#* https://server06.fynu.ucl.ac.be/projects/madgraph *
#* *
#************************************************************
#* *
#* Command File for MadGraph5_aMC@NLO *
#* *
#* run as ./bin/mg5_aMC filename *
#* *
#************************************************************
set group_subprocesses Auto
set ignore_six_quark_processes False
set loop_optimized_output True
set loop_color_flows False
set gauge unitary
set complex_mass_scheme False
set max_npoint_for_channel 0
import model sm
define p = g u c d s u~ c~ d~ s~
define j = g u c d s u~ c~ d~ s~
define l+ = e+ mu+
define l- = e- mu-
define vl = ve vm vt
define vl~ = ve~ vm~ vt~
import model SM_MOD
generate w+ w- > w+ w-
output test
Traceback (most recent call last):
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/extended_cmd.py", line 1414, in onecmd
    return self.onecmd_orig(line, **opt)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/extended_cmd.py", line 1369, in onecmd_orig
    return func(arg, **opt)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/master_interface.py", line 287, in do_output
    self.cmd.do_output(self, line, *args, **opts)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/madgraph_interface.py", line 7445, in do_output
    self.finalize(nojpeg, flaglist=flaglist)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/madgraph_interface.py", line 7732, in finalize
    wanted_couplings)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/iolibs/export_v4.py", line 3334, in convert_model
    wanted_lorentz, wanted_couplings)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/iolibs/export_v4.py", line 879, in convert_model
    aloha_model.write(write_dir, 'Fortran')
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/create_aloha.py", line 1011, in write
    abstract_routine.write(output_dir, language)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/create_aloha.py", line 89, in write
    text = writer.write(mode=mode, **opt)
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/aloha_writers.py", line 241, in write
    core_text = self.define_expression()
  File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/aloha_writers.py", line 805, in define_expression
    formatted = '(%s)*%s' % tuple(formatted.split('*',1))
TypeError: not enough arguments for format string
                          MadGraph5_aMC@NLO Options
                          ----------------
        complex_mass_scheme : False
                      gauge : unitary
         group_subprocesses : Auto
  ignore_six_quark_processes : False
           loop_color_flows : False
      loop_optimized_output : True
  low_mem_multicore_nlo_generation : False
     max_npoint_for_channel : 0
               stdout_level : 20 (user set)

                         MadEvent Options
                          ----------------
     automatic_html_opening : True
                    nb_core : None
        notification_center : True
                   run_mode : 2

                      Configuration Options
                      ---------------------
                        OLP : MadLoop
                    amcfast : amcfast-config
                   applgrid : applgrid-config
                auto_update : 7
         cluster_local_path : None
           cluster_nb_retry : 1
              cluster_queue : None (user set)
         cluster_retry_wait : 300
               cluster_size : 100
      cluster_status_update : (600, 30)
          cluster_temp_path : None
               cluster_type : condor
                    collier : ./HEPTools/lib
               cpp_compiler : None
               delphes_path : ./Delphes
                 eps_viewer : None
        exrootanalysis_path : ./ExRootAnalysis
              f2py_compiler : None
                    fastjet : None (user set)
           fortran_compiler : None
                      golem : None (user set)
                 hepmc_path : None (user set)
                  hwpp_path : None (user set)
                     lhapdf : lhapdf-config
          madanalysis5_path : None (user set)
           madanalysis_path : ./MadAnalysis
  mg5amc_py8_interface_path : None (user set)
                      ninja : ./HEPTools/lib
        output_dependencies : external
                      pjfry : None (user set)
            pythia-pgs_path : ./pythia-pgs
               pythia8_path : None (user set)
                    samurai : None
               syscalc_path : ./SysCalc
                    td_path : ./td
                text_editor : None
                thepeg_path : None (user set)
                    timeout : 60
                web_browser : None

Revision history for this message
Olivier Mattelaer (olivier-mattelaer) said :
#4

Hi,

Ah ok, this is a know bug which is fixed in 2.5.5 (which was released this morning).

Cheers,

Olivier

> On 26 May 2017, at 17:14, Salvator Lombardo <email address hidden> wrote:
>
> Question #634619 on MadGraph5_aMC@NLO changed:
> https://answers.launchpad.net/mg5amcnlo/+question/634619
>
> Salvator Lombardo gave more information on the question:
> #************************************************************
> #* MadGraph5_aMC@NLO *
> #* *
> #* * * *
> #* * * * * *
> #* * * * * 5 * * * * *
> #* * * * * *
> #* * * *
> #* *
> #* *
> #* VERSION 2.5.3 2017-03-09 *
> #* *
> #* The MadGraph5_aMC@NLO Development Team - Find us at *
> #* https://server06.fynu.ucl.ac.be/projects/madgraph *
> #* *
> #************************************************************
> #* *
> #* Command File for MadGraph5_aMC@NLO *
> #* *
> #* run as ./bin/mg5_aMC filename *
> #* *
> #************************************************************
> set group_subprocesses Auto
> set ignore_six_quark_processes False
> set loop_optimized_output True
> set loop_color_flows False
> set gauge unitary
> set complex_mass_scheme False
> set max_npoint_for_channel 0
> import model sm
> define p = g u c d s u~ c~ d~ s~
> define j = g u c d s u~ c~ d~ s~
> define l+ = e+ mu+
> define l- = e- mu-
> define vl = ve vm vt
> define vl~ = ve~ vm~ vt~
> import model SM_MOD
> generate w+ w- > w+ w-
> output test
> Traceback (most recent call last):
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/extended_cmd.py", line 1414, in onecmd
> return self.onecmd_orig(line, **opt)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/extended_cmd.py", line 1369, in onecmd_orig
> return func(arg, **opt)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/master_interface.py", line 287, in do_output
> self.cmd.do_output(self, line, *args, **opts)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/madgraph_interface.py", line 7445, in do_output
> self.finalize(nojpeg, flaglist=flaglist)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/interface/madgraph_interface.py", line 7732, in finalize
> wanted_couplings)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/iolibs/export_v4.py", line 3334, in convert_model
> wanted_lorentz, wanted_couplings)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/madgraph/iolibs/export_v4.py", line 879, in convert_model
> aloha_model.write(write_dir, 'Fortran')
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/create_aloha.py", line 1011, in write
> abstract_routine.write(output_dir, language)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/create_aloha.py", line 89, in write
> text = writer.write(mode=mode, **opt)
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/aloha_writers.py", line 241, in write
> core_text = self.define_expression()
> File "/Users/sal/Workspace/MG5_aMC_v2_5_3/aloha/aloha_writers.py", line 805, in define_expression
> formatted = '(%s)*%s' % tuple(formatted.split('*',1))
> TypeError: not enough arguments for format string
> MadGraph5_aMC@NLO Options
> ----------------
> complex_mass_scheme : False
> gauge : unitary
> group_subprocesses : Auto
> ignore_six_quark_processes : False
> loop_color_flows : False
> loop_optimized_output : True
> low_mem_multicore_nlo_generation : False
> max_npoint_for_channel : 0
> stdout_level : 20 (user set)
>
> MadEvent Options
> ----------------
> automatic_html_opening : True
> nb_core : None
> notification_center : True
> run_mode : 2
>
> Configuration Options
> ---------------------
> OLP : MadLoop
> amcfast : amcfast-config
> applgrid : applgrid-config
> auto_update : 7
> cluster_local_path : None
> cluster_nb_retry : 1
> cluster_queue : None (user set)
> cluster_retry_wait : 300
> cluster_size : 100
> cluster_status_update : (600, 30)
> cluster_temp_path : None
> cluster_type : condor
> collier : ./HEPTools/lib
> cpp_compiler : None
> delphes_path : ./Delphes
> eps_viewer : None
> exrootanalysis_path : ./ExRootAnalysis
> f2py_compiler : None
> fastjet : None (user set)
> fortran_compiler : None
> golem : None (user set)
> hepmc_path : None (user set)
> hwpp_path : None (user set)
> lhapdf : lhapdf-config
> madanalysis5_path : None (user set)
> madanalysis_path : ./MadAnalysis
> mg5amc_py8_interface_path : None (user set)
> ninja : ./HEPTools/lib
> output_dependencies : external
> pjfry : None (user set)
> pythia-pgs_path : ./pythia-pgs
> pythia8_path : None (user set)
> samurai : None
> syscalc_path : ./SysCalc
> td_path : ./td
> text_editor : None
> thepeg_path : None (user set)
> timeout : 60
> web_browser : None
>
> --
> 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 Salvator Lombardo for more information if necessary.

To post a message you must log in.