From 17b83d0e6a77f3e9c1bf3f9d714f081bd1740a37 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Wed, 8 Nov 2023 11:34:31 +0100 Subject: [PATCH 1/4] chore: update pre-commit hooks (#386) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore: update pre-commit hooks updates: - [github.com/psf/black-pre-commit-mirror: 23.10.0 → 23.10.1](https://github.com/psf/black-pre-commit-mirror/compare/23.10.0...23.10.1) - [github.com/astral-sh/ruff-pre-commit: v0.1.1 → v0.1.4](https://github.com/astral-sh/ruff-pre-commit/compare/v0.1.1...v0.1.4) * style: pre-commit fixes --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .pre-commit-config.yaml | 4 ++-- src/decaylanguage/decay/decay.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cc3f9b46..3b36f3ee 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,7 +4,7 @@ ci: repos: - repo: https://github.com/psf/black-pre-commit-mirror - rev: 23.10.0 + rev: 23.10.1 hooks: - id: black-jupyter @@ -24,7 +24,7 @@ repos: - id: end-of-file-fixer - repo: https://github.com/astral-sh/ruff-pre-commit - rev: "v0.1.1" + rev: "v0.1.4" hooks: - id: ruff args: ["--fix", "--show-fixes"] diff --git a/src/decaylanguage/decay/decay.py b/src/decaylanguage/decay/decay.py index 7613f74a..b9c462f6 100644 --- a/src/decaylanguage/decay/decay.py +++ b/src/decaylanguage/decay/decay.py @@ -19,7 +19,7 @@ Self_DaughtersDict = TypeVar("Self_DaughtersDict", bound="DaughtersDict") -if TYPE_CHECKING: # noqa: SIM108 +if TYPE_CHECKING: CounterStr = Counter[str] # pragma: no cover else: CounterStr = Counter From 51d6d46679fbf9ba4e7a68e268a3a97caa380d4b Mon Sep 17 00:00:00 2001 From: Eduardo Rodrigues Date: Wed, 8 Nov 2023 11:43:38 +0100 Subject: [PATCH 2/4] Update ci.yml to pin Python to 3.11 in pre-commit checks while pylcn gets fixed for 3.12 (#388) See https://github.com/scikit-hep/decaylanguage/pull/386. --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 30d35e38..bac17629 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-python@v4 with: - python-version: "3.x" + python-version: "3.11" - uses: pre-commit/action@v3.0.0 with: extra_args: --all-files --hook-stage manual From 8dc6b85e5d8bf21d529e15c35c88b511a07b0ba7 Mon Sep 17 00:00:00 2001 From: Eduardo Rodrigues Date: Wed, 8 Nov 2023 12:29:31 +0100 Subject: [PATCH 3/4] Test suite to verify all EvtGen models are parsed correctly - take 6 (#387) * Add .dec files for more model tests * Test them * Add missing doc for a test .dec file * style: pre-commit fixes * Fix conflicts after rebase * Fix typos * Add test file and test for very peculiar model PTO3P * style: pre-commit fixes --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- tests/data/models/model-BQTOLLLL.dec | 34 +++++ tests/data/models/model-BQTOLLLLHYPERCP.dec | 22 +++ tests/data/models/model-BTOSLLALI.dec | 7 + tests/data/models/model-BTOSLLBALL.dec | 7 + tests/data/models/model-BTOSLLMS.dec | 8 ++ tests/data/models/model-BTOSLLMSEXT.dec | 41 ++++++ tests/data/models/model-BTOVLNUBALL.dec | 12 ++ tests/data/models/model-CB3PI-MPP.dec | 9 ++ tests/data/models/model-CB3PI-P00.dec | 9 ++ tests/data/models/model-ETA_LLPIPI.dec | 7 + tests/data/models/model-FLATQ2.dec | 7 + tests/data/models/model-FOURBODYPHSP.dec | 13 ++ tests/data/models/model-HELAMP.dec | 7 + tests/data/models/model-PTO3P.dec | 40 ++++++ tests/dec/test_known_decay_models.py | 150 +++++++++++++++++--- 15 files changed, 357 insertions(+), 16 deletions(-) create mode 100644 tests/data/models/model-BQTOLLLL.dec create mode 100644 tests/data/models/model-BQTOLLLLHYPERCP.dec create mode 100644 tests/data/models/model-BTOSLLALI.dec create mode 100644 tests/data/models/model-BTOSLLBALL.dec create mode 100644 tests/data/models/model-BTOSLLMSEXT.dec create mode 100644 tests/data/models/model-BTOVLNUBALL.dec create mode 100644 tests/data/models/model-CB3PI-MPP.dec create mode 100644 tests/data/models/model-CB3PI-P00.dec create mode 100644 tests/data/models/model-ETA_LLPIPI.dec create mode 100644 tests/data/models/model-FLATQ2.dec create mode 100644 tests/data/models/model-FOURBODYPHSP.dec create mode 100644 tests/data/models/model-HELAMP.dec create mode 100644 tests/data/models/model-PTO3P.dec diff --git a/tests/data/models/model-BQTOLLLL.dec b/tests/data/models/model-BQTOLLLL.dec new file mode 100644 index 00000000..7f5b1049 --- /dev/null +++ b/tests/data/models/model-BQTOLLLL.dec @@ -0,0 +1,34 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +# Documentation: the B_d0 -> mu^+ mu^- mu^+ mu^- decay based on MNT-model for +# B_d0 -> mu^+ mu^- gamma decay +# mu - the scale parameter (in GeV's); +# Nf - number of "effective" flavors (for b-quark Nf=5); +# res_swch - resonant switching parameter: +# = 0 the resonant contribution switched OFF, +# = 1 the resonant contribution switched ON; +# ias - switching parameter for \alpha_s(M_Z) value: +# = 0 PDG 1sigma minimal alpha_s(M_Z), +# = 1 PDG average value alpha_s(M_Z), +# = 2 PDG 1sigma maximal alpha_s(M_Z). +# Wolfenstein parameterization for CKM matrix: +# A +# lambda +# barrho +# bareta +# EndDocumentation + +Define mu 5.0 +Define Nf 5 +Define res_swch 0 +Define ias 1 +Define A 0.88 +Define lambda 0.227 +Define barrho 0.22 +Define bareta 0.34 + +Decay B0sig + 1.0 mu+ mu- mu+ mu- BQTOLLLL mu Nf res_swch ias A lambda barrho bareta; +Enddecay + +End diff --git a/tests/data/models/model-BQTOLLLLHYPERCP.dec b/tests/data/models/model-BQTOLLLLHYPERCP.dec new file mode 100644 index 00000000..830d384b --- /dev/null +++ b/tests/data/models/model-BQTOLLLLHYPERCP.dec @@ -0,0 +1,22 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Define mS 2.5 +Define mP 0.214 +Define gammaS 0.0001 +Define gammaP 0.0001 +Define mLiiLR 1.0 +Define Fc 1.0 +Define mD23LL 450.0 +Define mD23RR 0.0 +Define mD32LL 450.0 +Define mD32RR 0.0 +Define mD13LL 380.0 +Define mD13RR 0.0 +Define mD31LL 380.0 +Define mD31RR 0.0 + +Decay B0sig + 1.000 mu+ mu- mu+ mu- BQTOLLLLHYPERCP mS mP gammaS gammaP mLiiLR Fc mD23LL mD23RR mD32LL mD32RR mD13LL mD13RR mD31LL mD31RR; +Enddecay + +End diff --git a/tests/data/models/model-BTOSLLALI.dec b/tests/data/models/model-BTOSLLALI.dec new file mode 100644 index 00000000..89af09ff --- /dev/null +++ b/tests/data/models/model-BTOSLLALI.dec @@ -0,0 +1,7 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Decay B_s0sig + 1.0 phi mu+ mu- BTOSLLALI; +Enddecay + +End diff --git a/tests/data/models/model-BTOSLLBALL.dec b/tests/data/models/model-BTOSLLBALL.dec new file mode 100644 index 00000000..af656b07 --- /dev/null +++ b/tests/data/models/model-BTOSLLBALL.dec @@ -0,0 +1,7 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Decay B+sig +1.0 pi+ e+ e- PHOTOS BTOSLLBALL 6; +Enddecay + +End diff --git a/tests/data/models/model-BTOSLLMS.dec b/tests/data/models/model-BTOSLLMS.dec index d930e1a1..897cb772 100644 --- a/tests/data/models/model-BTOSLLMS.dec +++ b/tests/data/models/model-BTOSLLMS.dec @@ -1,5 +1,13 @@ # File for testing purposes. Contains a single decay mode with a specific model. +# Documentation: the B -> phi mu^+ mu^- decay with the transition form factors +# from the paper D.Melikhov, B.Stech, PRD62, 014006 (2000). +# Input parameters - mu - the scale parameter (in GeV's); +# res_swch - resonant switching parameter: +# ias - switching parameter for \alpha_s(M_Z) value: +# Wolfenstein parameterization for CKM matrix: +# EndDocumentation + Define mu 5.0 Define Nf 5 Define res_swch 0 diff --git a/tests/data/models/model-BTOSLLMSEXT.dec b/tests/data/models/model-BTOSLLMSEXT.dec new file mode 100644 index 00000000..a6e84160 --- /dev/null +++ b/tests/data/models/model-BTOSLLMSEXT.dec @@ -0,0 +1,41 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +# Documentation: the B_d^0 -> rho^0 ell^+ ell^- decay with the transition form factors +# from the paper D.Melikhov, B.Stech, PRD62, 014006 (2000). +# mu - the scale parameter (in GeV's); +# Nf - number of "effective" flavors (for b-quark Nf=5); +# res_swch - resonant switching parameter: +# = 0 the resonant contribution switched OFF, +# = 1 the resonant contribution switched ON; +# ias - switching parameter for \alpha_s(M_Z) value: +# = 0 PDG 1sigma minimal alpha_s(M_Z), +# = 1 PDG average value alpha_s(M_Z), +# = 2 PDG 1sigma maximal alpha_s(M_Z). +# Wolfenstein parameterization for CKM matrix: +# A +# lambda +# barrho +# bareta +# Multiplication coefficients +# A7 = ReA7 + i*ImA7 +# A10 = ReA10 + i*ImA10 +# EndDocumentation + +Define mu 5.0 +Define Nf 5 +Define res_swch 0 +Define ias 1 +Define A 0.88 +Define lambda 0.227 +Define barrho 0.22 +Define bareta 0.34 +Define ReA7 1.0 +Define ImA7 0.0 +Define ReA10 -1.0 +Define ImA10 0.0 + +Decay B0sig + 1.0 MyRho0 mu+ mu- BTOSLLMSEXT mu Nf res_swch ias A lambda barrho bareta ReA7 ImA7 ReA10 ImA10; +Enddecay + +End diff --git a/tests/data/models/model-BTOVLNUBALL.dec b/tests/data/models/model-BTOVLNUBALL.dec new file mode 100644 index 00000000..4f267d3e --- /dev/null +++ b/tests/data/models/model-BTOVLNUBALL.dec @@ -0,0 +1,12 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +# Documentation: Decay file for [B+ -> (phi(1020) -> K+ K-) mu+ nu_mu]cc, +# using the BToVlnuBall model (for Bs -> phi, lacking an alternative), see https://arxiv.org/pdf/hep-ph/0412079.pdf +# order is r2_A1 mfit2_A1 r1_A2 r2_A2 mfit2_A2 r1_V r2_V mfit2_V +# EndDocumentation + +Decay B+sig + 1.0 MyPhi mu+ nu_mu PHOTOS BTOVLNUBALL 0.308 36.54 -0.054 0.288 48.94 1.484 -1.049 39.52; +Enddecay + +End diff --git a/tests/data/models/model-CB3PI-MPP.dec b/tests/data/models/model-CB3PI-MPP.dec new file mode 100644 index 00000000..cbaca725 --- /dev/null +++ b/tests/data/models/model-CB3PI-MPP.dec @@ -0,0 +1,9 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Define alpha 1.365 + +Decay B+ +1.0 pi+ pi+ pi- CB3PI-MPP alpha; +Enddecay + +End diff --git a/tests/data/models/model-CB3PI-P00.dec b/tests/data/models/model-CB3PI-P00.dec new file mode 100644 index 00000000..45d55f60 --- /dev/null +++ b/tests/data/models/model-CB3PI-P00.dec @@ -0,0 +1,9 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Define alpha 1.365 + +Decay B- +0.000026 pi- pi0 pi0 CB3PI-P00 alpha; +Enddecay + +End diff --git a/tests/data/models/model-ETA_LLPIPI.dec b/tests/data/models/model-ETA_LLPIPI.dec new file mode 100644 index 00000000..cd2efa64 --- /dev/null +++ b/tests/data/models/model-ETA_LLPIPI.dec @@ -0,0 +1,7 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Decay eta + 1.0 mu+ mu- pi+ pi- ETA_LLPIPI; +Enddecay + +End diff --git a/tests/data/models/model-FLATQ2.dec b/tests/data/models/model-FLATQ2.dec new file mode 100644 index 00000000..51ac1265 --- /dev/null +++ b/tests/data/models/model-FLATQ2.dec @@ -0,0 +1,7 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Decay B+sig + 1.0 MyKst+ mu+ mu- FLATQ2 1; +Enddecay + +End diff --git a/tests/data/models/model-FOURBODYPHSP.dec b/tests/data/models/model-FOURBODYPHSP.dec new file mode 100644 index 00000000..4a40aecc --- /dev/null +++ b/tests/data/models/model-FOURBODYPHSP.dec @@ -0,0 +1,13 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +# Flat phase space in the analysis region of B0 -> D0 D0b. +Define m12_min 1.3 # The model will take at least m1+m2 +Define m12_max 2.5 # Must be in GeV/c^2 +Define m34_min 1.3 # The model will take at least m1+m2 +Define m34_max 2.5 # Must be in GeV/c^2 + +Decay B0 + 1.0 K+ K- K- pi+ FOURBODYPHSP m12_min m12_max m34_min m34_max; +Enddecay + +End diff --git a/tests/data/models/model-HELAMP.dec b/tests/data/models/model-HELAMP.dec new file mode 100644 index 00000000..02a068f6 --- /dev/null +++ b/tests/data/models/model-HELAMP.dec @@ -0,0 +1,7 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +Decay h_b(2P) + 0.22 gamma eta_b HELAMP 1.0 0.0 1.0 0.0; +Enddecay + +End diff --git a/tests/data/models/model-PTO3P.dec b/tests/data/models/model-PTO3P.dec new file mode 100644 index 00000000..9abb4852 --- /dev/null +++ b/tests/data/models/model-PTO3P.dec @@ -0,0 +1,40 @@ +# File for testing purposes. Contains a single decay mode with a specific model. + +# B+ decay to pi+, K- and K+ with Dalitz model so as to agree roughly with the Dalitz plot distribution +Decay B+ +1.000 K+ K- pi+ PTO3P + MAXPDF 0.09 + #SCANPDF 10000 + AMPLITUDE RESONANCE BC K*0 + ANGULAR AC + TYPE RBW_ZEMACH + DVFF BLATTWEISSKOPF 4.0 + COEFFICIENT POLAR_RAD 1.0 0.0 + AMPLITUDE LASS BC 1.412 0.294 2.07 + 3.32 1.8 + COEFFICIENT POLAR_RAD 32.9 -0.38 + AMPLITUDE RESONANCE AB phi + ANGULAR CA + TYPE RBW_ZEMACH + DVFF BLATTWEISSKOPF 4.0 + COEFFICIENT POLAR_RAD 6.04 2.99 + AMPLITUDE RESONANCE AB f_0 0.965 0.695 + ANGULAR CA + TYPE FLATTE 0.165 0.13957 0.13957 + COEFFICIENT POLAR_RAD 5.28 0.48 + AMPLITUDE RESONANCE AB f_0(1500) 1.539 + 0.257 + ANGULAR CA + TYPE RBW_ZEMACH + COEFFICIENT POLAR_RAD 24.0 1.29 + AMPLITUDE RESONANCE AB chi_c0 + ANGULAR CA + TYPE RBW_ZEMACH + DVFF BLATTWEISSKOPF 4.0 + COEFFICIENT POLAR_RAD 0.437 -1.02 + AMPLITUDE PHASESPACE + COEFFICIENT POLAR_RAD 6.9 -2.29 + ; +Enddecay + +End diff --git a/tests/dec/test_known_decay_models.py b/tests/dec/test_known_decay_models.py index 5af81f97..9df00058 100644 --- a/tests/dec/test_known_decay_models.py +++ b/tests/dec/test_known_decay_models.py @@ -82,22 +82,40 @@ def test_lark_file_model_list_consistency(): [5.0, 5, 0, 0, 1, 0.000001, 0.8250, 0.22509, 0.1598, 0.3499, 4.5], ), ("BSTOGLLMNT", [5.0, 5, 1, 1, 0.02, 0.88, 0.227, 0.22, 0.34]), - # ("BT02PI_CP_ISO", ""), # No dec file available from LHCb or Belle-II + # ("BT02PI_CP_ISO", ""), # No dec file available for testing from LHCb or Belle-II ("BTO3PI_CP", [0.507e12, 1.365]), ("BTODDALITZCPK", [1.22, 2.27, 0.10]), ("BToDiBaryonlnupQCD", [67.7, -280.0, -38.3, -840.0, -10.1, -157.0, 800000]), - # ("BTOSLLALI", ""), - # ("BTOSLLBALL", ""), + ("BTOSLLALI", ""), + ("BTOSLLBALL", [6.0]), ("BTOSLLMS", [5.0, 5.0, 0.0, 1.0, 0.88, 0.227, 0.22, 0.34]), - # ("BTOSLLMSEXT", ""), - # ("BTOVLNUBALL", ""), + ("BTOSLLMSEXT", [5.0, 5.0, 0.0, 1.0, 0.88, 0.227, 0.22, 0.34, 1.0, 0.0, -1.0, 0.0]), + ("BTOVLNUBALL", [0.308, 36.54, -0.054, 0.288, 48.94, 1.484, -1.049, 39.52]), ("BTOXSGAMMA", [2.0]), # ("BTOXELNU", ""), ("BTOXSLL", [4.8, 0.2, 0.0, 0.41]), - # ("BQTOLLLLHYPERCP", ""), - # ("BQTOLLLL", ""), - # ("CB3PI-MPP", ""), - # ("CB3PI-P00", ""), + ( + "BQTOLLLLHYPERCP", + [ + 2.5, + 0.214, + 0.0001, + 0.0001, + 1.0, + 1.0, + 450.0, + 0.0, + 450.0, + 0.0, + 380.0, + 0.0, + 380.0, + 0.0, + ], + ), + ("BQTOLLLL", [5.0, 5.0, 0.0, 1.0, 0.88, 0.227, 0.22, 0.34]), + ("CB3PI-MPP", [1.365]), + ("CB3PI-P00", [1.365]), ("D_DALITZ", ""), ("D_hhhh", [11.0]), ("D0GAMMADALITZ", ""), @@ -106,14 +124,14 @@ def test_lark_file_model_list_consistency(): ("ETAPRIME_DALITZ", [-0.047, -0.069, 0.0, 0.073]), ("ETA_DALITZ", ""), ("ETA_FULLDALITZ", [-1.128, 0.153, 0.0, 0.085, 0.0, 0.173]), - # ("ETA_LLPIPI", ""), + ("ETA_LLPIPI", ""), ("ETA_PI0DALITZ", [-0.0135]), - # ("FLATQ2", ""), + ("FLATQ2", [1.0]), ("FLATSQDALITZ", ""), - # ("FOURBODYPHSP", ""), - # ("GENERIC_DALITZ", ""), # no dec file currently available for a test + ("FOURBODYPHSP", [1.3, 2.5, 1.3, 2.5]), + # ("GENERIC_DALITZ", ""), # No dec file available for testing from LHCb or Belle-II ("GOITY_ROBERTS", ""), - # ("HELAMP", ""), + ("HELAMP", [1.0, 0.0, 1.0, 0.0]), ("HQET3", [0.920, 1.205, 1.21, 1.404, 0.854]), ("HQET2", [1.18, 1.074]), # ("HQET", ""), @@ -137,7 +155,107 @@ def test_lark_file_model_list_consistency(): ("PHSP", ""), ("PI0_DALITZ", ""), # ("PROPSLPOLE", ""), - # ("PTO3P", ""), + ( + "PTO3P", + [ + "MAXPDF", + 0.09, + "AMPLITUDE", + "RESONANCE", + "BC", + "K*0", + "ANGULAR", + "AC", + "TYPE", + "RBW_ZEMACH", + "DVFF", + "BLATTWEISSKOPF", + 4.0, + "COEFFICIENT", + "POLAR_RAD", + 1.0, + 0.0, + "AMPLITUDE", + "LASS", + "BC", + 1.412, + 0.294, + 2.07, + 3.32, + 1.8, + "COEFFICIENT", + "POLAR_RAD", + 32.9, + -0.38, + "AMPLITUDE", + "RESONANCE", + "AB", + "phi", + "ANGULAR", + "CA", + "TYPE", + "RBW_ZEMACH", + "DVFF", + "BLATTWEISSKOPF", + 4.0, + "COEFFICIENT", + "POLAR_RAD", + 6.04, + 2.99, + "AMPLITUDE", + "RESONANCE", + "AB", + "f_0", + 0.965, + 0.695, + "ANGULAR", + "CA", + "TYPE", + "FLATTE", + 0.165, + 0.13957, + 0.13957, + "COEFFICIENT", + "POLAR_RAD", + 5.28, + 0.48, + "AMPLITUDE", + "RESONANCE", + "AB", + "f_0(1500)", + 1.539, + 0.257, + "ANGULAR", + "CA", + "TYPE", + "RBW_ZEMACH", + "COEFFICIENT", + "POLAR_RAD", + 24.0, + 1.29, + "AMPLITUDE", + "RESONANCE", + "AB", + "chi_c0", + "ANGULAR", + "CA", + "TYPE", + "RBW_ZEMACH", + "DVFF", + "BLATTWEISSKOPF", + 4.0, + "COEFFICIENT", + "POLAR_RAD", + 0.437, + -1.02, + "AMPLITUDE", + "PHASESPACE", + "COEFFICIENT", + "POLAR_RAD", + 6.9, + -2.29, + ], + ), # ("PVV_CPLH", ""), # ("PYCONT", ""), ("PYTHIA", [21]), @@ -192,7 +310,7 @@ def test_lark_file_model_list_consistency(): def test_parsing_of_all_known_models_are_tested(): assert ( - len(parsed_models) == len(known_decay_models) - 65 + len(parsed_models) == len(known_decay_models) - 52 ) # subtract for now the number of models not yet tested From d1fdf16d39ebc8c0d477880cf3c0e11658862796 Mon Sep 17 00:00:00 2001 From: Eduardo Rodrigues Date: Wed, 8 Nov 2023 12:56:10 +0100 Subject: [PATCH 4/4] Fix LHCb model name - take 2 (#389) * Remove EvtGen wrongly added in PR 336 * Update tests/dec/test_known_decay_models.py accordingly --- src/decaylanguage/data/decfile.lark | 2 +- src/decaylanguage/dec/enums.py | 1 - tests/dec/test_known_decay_models.py | 3 +-- 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/decaylanguage/data/decfile.lark b/src/decaylanguage/data/decfile.lark index fd78653c..18f6fdfa 100644 --- a/src/decaylanguage/data/decfile.lark +++ b/src/decaylanguage/data/decfile.lark @@ -65,7 +65,7 @@ MODEL_NAME_AND_WS.2: MODEL_NAME _WS+ MODEL_NAME_AND_SC.2: MODEL_NAME _WS* _SEMICOLON+ MODEL_NAME_MULTILINE.2: MODEL_NAME NEWLINE _WS* -MODEL_NAME : "BaryonPCR"|"BC_SMN"|"BC_TMN"|"BC_VHAD"|"BC_VMN"|"BCL"|"BGL"|"BLLNUL"|"BNOCB0TO4PICP"|"BNOCBPTO3HPI0"|"BNOCBPTOKSHHH"|"BS_MUMUKK"|"BSTOGLLISRFSR"|"BSTOGLLMNT"|"BT02PI_CP_ISO"|"BTO3PI_CP"|"BTODDALITZCPK"|"BToDiBaryonlnupQCD"|"BTOSLLALI"|"BTOSLLBALL"|"BTOSLLMS"|"BTOSLLMSEXT"|"BTOVLNUBALL"|"BTOXSGAMMA"|"BTOXELNU"|"BTOXSLL"|"BQTOLLLLHYPERCP"|"BQTOLLLL"|"CB3PI-MPP"|"CB3PI-P00"|"D_DALITZ"|"D_hhhh"|"D0GAMMADALITZ"|"D0MIXDALITZ"|"DToKpienu"|"ETAPRIME_DALITZ"|"ETA_DALITZ"|"ETA_FULLDALITZ"|"ETA_LLPIPI"|"ETA_PI0DALITZ"|"FLATQ2"|"FLATSQDALITZ"|"FOURBODYPHSP"|"GENERIC_DALITZ"|"GOITY_ROBERTS"|"HELAMP"|"HQET3"|"HQET2"|"HQET"|"imqp"|"ISGW2"|"ISGW"|"KS_PI0MUMU"|"Lb2Baryonlnu"|"Lb2plnuLCSR"|"Lb2plnuLQCD"|"LbAmpGen"|"LLSW"|"LNUGAMMA"|"LQCD"|"MELIKHOV"|"OMEGA_DALITZ"|"PARTWAVE"|"PHI_DALITZ"|"PHSPDECAYTIMECUT"|"PHSPFLATLIFETIME"|"PHSP"|"PI0_DALITZ"|"PROPSLPOLE"|"PTO3P"|"PVV_CPLH"|"PYCONT"|"PYTHIA"|"SLBKPOLE"|"SLL"|"SLN"|"SLPOLE"|"SSD_CP"|"SSD_DirectCP"|"SSS_CP_PNG"|"SSS_CP"|"SSS_CPT"|"STS_CP"|"STS"|"SVP_CP"|"SVP_HELAMP"|"SVP"|"SVS_CP_ISO"|"SVS_CPLH"|"SVS_CP"|"SVS_NONCPEIGEN"|"SVS"|"SVV_CPLH"|"SVV_CP"|"SVV_HELAMP"|"SVV_NONCPEIGEN"|"SVVHELCPMIX"|"TAUHADNU"|"TAULNUNU"|"TAUOLA"|"TAUSCALARNU"|"TAUVECTORNU"|"THREEBODYPHSP"|"TSS"|"TVP"|"TVS_PWAVE"|"VLL"|"VSP_PWAVE"|"VSS_BMIX"|"VSS_MIX"|"VSS"|"VTOSLL"|"VUB"|"VVPIPI"|"VVP"|"VVS_PWAVE"|"XLL"|"YMSTOYNSPIPICLEO"|"YMSTOYNSPIPICLEOBOOST" +MODEL_NAME : "BaryonPCR"|"BC_SMN"|"BC_TMN"|"BC_VHAD"|"BC_VMN"|"BCL"|"BGL"|"BLLNUL"|"BNOCB0TO4PICP"|"BNOCBPTO3HPI0"|"BNOCBPTOKSHHH"|"BS_MUMUKK"|"BSTOGLLISRFSR"|"BSTOGLLMNT"|"BT02PI_CP_ISO"|"BTO3PI_CP"|"BTODDALITZCPK"|"BToDiBaryonlnupQCD"|"BTOSLLALI"|"BTOSLLBALL"|"BTOSLLMS"|"BTOSLLMSEXT"|"BTOVLNUBALL"|"BTOXSGAMMA"|"BTOXELNU"|"BTOXSLL"|"BQTOLLLLHYPERCP"|"BQTOLLLL"|"CB3PI-MPP"|"CB3PI-P00"|"D_DALITZ"|"D_hhhh"|"D0GAMMADALITZ"|"D0MIXDALITZ"|"DToKpienu"|"ETAPRIME_DALITZ"|"ETA_DALITZ"|"ETA_FULLDALITZ"|"ETA_LLPIPI"|"ETA_PI0DALITZ"|"FLATQ2"|"FLATSQDALITZ"|"FOURBODYPHSP"|"GENERIC_DALITZ"|"GOITY_ROBERTS"|"HELAMP"|"HQET3"|"HQET2"|"HQET"|"ISGW2"|"ISGW"|"KS_PI0MUMU"|"Lb2Baryonlnu"|"Lb2plnuLCSR"|"Lb2plnuLQCD"|"LbAmpGen"|"LLSW"|"LNUGAMMA"|"LQCD"|"MELIKHOV"|"OMEGA_DALITZ"|"PARTWAVE"|"PHI_DALITZ"|"PHSPDECAYTIMECUT"|"PHSPFLATLIFETIME"|"PHSP"|"PI0_DALITZ"|"PROPSLPOLE"|"PTO3P"|"PVV_CPLH"|"PYCONT"|"PYTHIA"|"SLBKPOLE"|"SLL"|"SLN"|"SLPOLE"|"SSD_CP"|"SSD_DirectCP"|"SSS_CP_PNG"|"SSS_CP"|"SSS_CPT"|"STS_CP"|"STS"|"SVP_CP"|"SVP_HELAMP"|"SVP"|"SVS_CP_ISO"|"SVS_CPLH"|"SVS_CP"|"SVS_NONCPEIGEN"|"SVS"|"SVV_CPLH"|"SVV_CP"|"SVV_HELAMP"|"SVV_NONCPEIGEN"|"SVVHELCPMIX"|"TAUHADNU"|"TAULNUNU"|"TAUOLA"|"TAUSCALARNU"|"TAUVECTORNU"|"THREEBODYPHSP"|"TSS"|"TVP"|"TVS_PWAVE"|"VLL"|"VSP_PWAVE"|"VSS_BMIX"|"VSS_MIX"|"VSS"|"VTOSLL"|"VUB"|"VVPIPI"|"VVP"|"VVS_PWAVE"|"XLL"|"YMSTOYNSPIPICLEO"|"YMSTOYNSPIPICLEOBOOST" // model : model_generic // model_helamp : "HELAMP" (SIGNED_NUMBER SIGNED_NUMBER)+ diff --git a/src/decaylanguage/dec/enums.py b/src/decaylanguage/dec/enums.py index 946a8d8e..dc9ab26a 100644 --- a/src/decaylanguage/dec/enums.py +++ b/src/decaylanguage/dec/enums.py @@ -69,7 +69,6 @@ class PhotosEnum(IntEnum): "HQET3", "HQET2", "HQET", - "imqp", "ISGW2", "ISGW", "KS_PI0MUMU", diff --git a/tests/dec/test_known_decay_models.py b/tests/dec/test_known_decay_models.py index 9df00058..15a42027 100644 --- a/tests/dec/test_known_decay_models.py +++ b/tests/dec/test_known_decay_models.py @@ -135,7 +135,6 @@ def test_lark_file_model_list_consistency(): ("HQET3", [0.920, 1.205, 1.21, 1.404, 0.854]), ("HQET2", [1.18, 1.074]), # ("HQET", ""), - # ("imqp", ""), # ("ISGW2", ""), # ("ISGW", ""), # ("KS_PI0MUMU", ""), @@ -310,7 +309,7 @@ def test_lark_file_model_list_consistency(): def test_parsing_of_all_known_models_are_tested(): assert ( - len(parsed_models) == len(known_decay_models) - 52 + len(parsed_models) == len(known_decay_models) - 51 ) # subtract for now the number of models not yet tested