import FWCore.ParameterSet.Config as cms

from Configuration.Generator.Pythia8CommonSettings_cfi import *
from Configuration.Generator.Pythia8CUEP8M1Settings_cfi import *

generator = cms.EDFilter("Pythia8HadronizerFilter",
 maxEventsToPrint = cms.untracked.int32(1),
 pythiaPylistVerbosity = cms.untracked.int32(1),
 filterEfficiency = cms.untracked.double(1.0),
 pythiaHepMCVerbosity = cms.untracked.bool(False),
 comEnergy = cms.double(13000.),
 PythiaParameters = cms.PSet(
 pythia8CommonSettingsBlock,
 pythia8CUEP8M1SettingsBlock,
 processParameters = cms.vstring(
 'JetMatching:setMad = off',
 'JetMatching:scheme = 1',
 'JetMatching:merge = on',
 'JetMatching:jetAlgorithm = 2',
 'JetMatching:etaJetMax = 5.',
 'JetMatching:coneRadius = 1.',
 'JetMatching:slowJetPower = 1',
 'JetMatching:qCut = 90', #this is the actual merging scale
 'JetMatching:nQmatch = 5', #4 corresponds to 4-flavour scheme (no matching of b-quarks), 5 for 5-flavour scheme
 'JetMatching:nJetMax = 1', #number of partons in born matrix element for highest multiplicity
 'JetMatching:doShowerKt = off', #off for MLM matching, turn on for shower-kT matching
 'Check:epTolErr = 0.0003',
 '9100000:new  = MED MED 3 0 0 X_MMed_X 0 0 0 99999',
 '9100022:new  = DM  DM  2 0 0 X_MFM_X  0 0 0 99999',
 '9100022:mayDecay = off'
 ),
 parameterSets = cms.vstring('pythia8CommonSettings',
 'pythia8CUEP8M1Settings',
 'processParameters',
 )
 )
)