diff --git "a/medomni/models.build/module.models.Qformer.cpp" "b/medomni/models.build/module.models.Qformer.cpp" deleted file mode 100644--- "a/medomni/models.build/module.models.Qformer.cpp" +++ /dev/null @@ -1,50300 +0,0 @@ -/* Generated code for Python module 'models.Qformer' - * created by Nuitka version 0.6.16 - * - * This code is in part copyright 2021 Kay Hayen. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#include "nuitka/prelude.h" - -#include "nuitka/unfreezing.h" - -#include "__helpers.h" - -/* The "module_models$Qformer" is a Python object pointer of module type. - * - * Note: For full compatibility with CPython, every module variable access - * needs to go through it except for cases where the module cannot possibly - * have changed in the mean time. - */ - -PyObject *module_models$Qformer; -PyDictObject *moduledict_models$Qformer; - -/* The declarations of module constants used, if any. */ -static PyObject *mod_consts[460]; - -static PyObject *module_filename_obj = NULL; - -/* Indicator if this modules private constants were created yet. */ -static bool constants_created = false; - -/* Function to create module private constants. */ -static void createModuleConstants(void) { - if (constants_created == false) { - loadConstantsBlob(&mod_consts[0], UNTRANSLATE("models.Qformer")); - constants_created = true; - } -} - -/* For multiprocessing, we want to be able to initialize the __main__ constants. */ -#if (_NUITKA_PLUGIN_MULTIPROCESSING_ENABLED || _NUITKA_PLUGIN_TRACEBACK_ENCRYPTION_ENABLED) && 0 -void createMainModuleConstants(void) { - createModuleConstants(); -} -#endif - -/* Function to verify module private constants for non-corruption. */ -#ifndef __NUITKA_NO_ASSERT__ -void checkModuleConstants_models$Qformer(void) { - // The module may not have been used at all, then ignore this. - if (constants_created == false) return; - - checkConstantsBlob(&mod_consts[0], "models.Qformer"); -} -#endif - -// The module code objects. -static PyCodeObject *codeobj_1a1e9c3c58d7ea5e2798e2bba549af89; -static PyCodeObject *codeobj_d4ada818f6656268c254961d6faa630a; -static PyCodeObject *codeobj_67be2144f29b126bccab22fc958e7dc4; -static PyCodeObject *codeobj_3b8e99b3705bb48cdf88a9a082001f87; -static PyCodeObject *codeobj_2bb9003dfff85549a8e8392e723ec6c8; -static PyCodeObject *codeobj_5bfea05f5a06871ae56cfaab6dbe57ba; -static PyCodeObject *codeobj_0c0a0597d4b4257046a86687ff948770; -static PyCodeObject *codeobj_e1623af249db2190f4f0a833e30e71e3; -static PyCodeObject *codeobj_e5264d356d902ef78943e91fb87114a1; -static PyCodeObject *codeobj_7007713779c26360c0f6632cb2047835; -static PyCodeObject *codeobj_aa454e092d5abc9f5e4553a289907508; -static PyCodeObject *codeobj_6e22728e3deba4360239f923eb721087; -static PyCodeObject *codeobj_a081438c9da0f662f5a4de30a72f53eb; -static PyCodeObject *codeobj_25865ea0df4a3f86bdd137c22518ab84; -static PyCodeObject *codeobj_2f024c1c2781aa4346c9360dc9ca9c37; -static PyCodeObject *codeobj_2997152d8a9cec4ec6825b911abbb306; -static PyCodeObject *codeobj_ab5a99313f9b6e1e298f4606848400d8; -static PyCodeObject *codeobj_2ba10c444d39cd9fbc64d82f9cd4789e; -static PyCodeObject *codeobj_1e694c28c1cb7b88d842a0230f304b37; -static PyCodeObject *codeobj_39fcb37e2c2b36c20e772de986f100d1; -static PyCodeObject *codeobj_cc56a3d4cf1124558e66a811713c588d; -static PyCodeObject *codeobj_5cc68962f3dad1def9ff2c335252cee0; -static PyCodeObject *codeobj_3ffa23d628f575a2f740dcb6fe8c1a15; -static PyCodeObject *codeobj_bc386502a8ad779e82b56ce3a01a046c; -static PyCodeObject *codeobj_da381dec774f92fc3fdec9b27fb9d857; -static PyCodeObject *codeobj_dbb5244b0ee9d68abb3ae7983cb8df4b; -static PyCodeObject *codeobj_3183350d90f44f69878dab33e80e4921; -static PyCodeObject *codeobj_ca40fb07238f33d953447de3e31806fd; -static PyCodeObject *codeobj_9c6e6b2c3e0641a7465eeb0788b5b6dd; -static PyCodeObject *codeobj_fa49026615d06e8f214b8591603bbecd; -static PyCodeObject *codeobj_3fed784111b2af0b6a6ffc26ac50d650; -static PyCodeObject *codeobj_e2b0deaa42e6635507b21870f60576c4; -static PyCodeObject *codeobj_8e16adea762727bda11361e993d1476d; -static PyCodeObject *codeobj_df9ac5d0a974d8e6803dbf3d6f292953; -static PyCodeObject *codeobj_269652cb22803d15cde90d439879a1a2; -static PyCodeObject *codeobj_9044624cc871cfe54b3607752fe57f1c; -static PyCodeObject *codeobj_4147f3aad460337a90fc69f511dba483; -static PyCodeObject *codeobj_99e6e0fbfb9cc4282b3a8f4787f1fc90; -static PyCodeObject *codeobj_be03d43782ce0c74a753536e9a4f0743; -static PyCodeObject *codeobj_9bc2c26bc51f7651d0836f8203f94193; -static PyCodeObject *codeobj_340e4e883925405252be80b1c8cda477; -static PyCodeObject *codeobj_c4755f7ecaad447ef5e0ea80f9a42013; -static PyCodeObject *codeobj_bc4467ccc7610a81a2b180cada5c22ef; -static PyCodeObject *codeobj_ef7df7f2aae603ea3cb921a91d68b297; -static PyCodeObject *codeobj_ef32505124b25b3c551fd3017e359336; -static PyCodeObject *codeobj_e5d530bc114f61caefcc8e7e58348d97; -static PyCodeObject *codeobj_222d3cb8bbe72424730d64c2fb38796b; -static PyCodeObject *codeobj_38c0c92910efd854dc73aa8a49f61b57; -static PyCodeObject *codeobj_02c26eebaf2303eb7380395e131d8a5e; -static PyCodeObject *codeobj_fb4ac8ca5f5c6cf5999268c801f1a60e; -static PyCodeObject *codeobj_efe9f30d4ed10b98b0f8cc575424636a; -static PyCodeObject *codeobj_e2c151c9b0676788eee114d75e2c1886; -static PyCodeObject *codeobj_ac223922169c79b32778e1fea6b86d12; -static PyCodeObject *codeobj_d74dc7aa09a16c42b6aa4ce3077a906f; -static PyCodeObject *codeobj_7c295c83a4e918fa0e86389ee3693174; -static PyCodeObject *codeobj_960ad736510918980c376a071f656626; -static PyCodeObject *codeobj_0d13c366fa26a472a6b7f1562ae363de; -static PyCodeObject *codeobj_0eb4b4b7e57523c96bf4c60654493887; -static PyCodeObject *codeobj_00cbf7e5232472b130db964e018f1f81; -static PyCodeObject *codeobj_527cb4fbc9a5e67eae366d93117b1142; -static PyCodeObject *codeobj_a5b726196dc433c291a911837adced9c; -static PyCodeObject *codeobj_64584954755a32f374a421edcbab9154; -static PyCodeObject *codeobj_d801348fdc3b19f91ac75fd50193d3b0; -static PyCodeObject *codeobj_ca38f33a6576fe8e2962a38a6c08a7da; -static PyCodeObject *codeobj_ded4b18b08a0de899e2560321c2271bc; -static PyCodeObject *codeobj_0b0b36faf8277ec302d6c6695f619e8c; -static PyCodeObject *codeobj_7dc435c7821988f8361240f6dacceca5; -static PyCodeObject *codeobj_45b23ddb210e7fae6e94b686bdca3187; -static PyCodeObject *codeobj_721775a04cb45ee2837ea767c0780001; -static PyCodeObject *codeobj_74af6475e06de1d3e4323696e9d6b171; -static PyCodeObject *codeobj_0fd009d1dbe4c7c46c53f9bdc210148d; -static PyCodeObject *codeobj_d1badd3898339991bfdc4579ffa91ae1; - -static void createModuleCodeObjects(void) { - module_filename_obj = MAKE_RELATIVE_PATH(mod_consts[419]); CHECK_OBJECT(module_filename_obj); - codeobj_1a1e9c3c58d7ea5e2798e2bba549af89 = MAKE_CODEOBJECT(module_filename_obj, 1124, CO_GENERATOR | CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[167], mod_consts[420], NULL, 1, 0, 0); - codeobj_d4ada818f6656268c254961d6faa630a = MAKE_CODEOBJECT(module_filename_obj, 572, CO_GENERATOR | CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[167], mod_consts[421], NULL, 1, 0, 0); - codeobj_67be2144f29b126bccab22fc958e7dc4 = MAKE_CODEOBJECT(module_filename_obj, 492, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[422], mod_consts[423], NULL, 1, 0, 0); - codeobj_3b8e99b3705bb48cdf88a9a082001f87 = MAKE_CODEOBJECT(module_filename_obj, 915, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[422], mod_consts[424], NULL, 1, 0, 0); - codeobj_2bb9003dfff85549a8e8392e723ec6c8 = MAKE_CODEOBJECT(module_filename_obj, 1, CO_NOFREE, mod_consts[425], NULL, NULL, 0, 0, 0); - codeobj_5bfea05f5a06871ae56cfaab6dbe57ba = MAKE_CODEOBJECT(module_filename_obj, 292, CO_NOFREE, mod_consts[109], mod_consts[426], NULL, 0, 0, 0); - codeobj_0c0a0597d4b4257046a86687ff948770 = MAKE_CODEOBJECT(module_filename_obj, 51, CO_NOFREE, mod_consts[193], mod_consts[426], NULL, 0, 0, 0); - codeobj_e1623af249db2190f4f0a833e30e71e3 = MAKE_CODEOBJECT(module_filename_obj, 487, CO_NOFREE, mod_consts[194], mod_consts[426], NULL, 0, 0, 0); - codeobj_e5264d356d902ef78943e91fb87114a1 = MAKE_CODEOBJECT(module_filename_obj, 1131, CO_NOFREE, mod_consts[413], mod_consts[426], NULL, 0, 0, 0); - codeobj_7007713779c26360c0f6632cb2047835 = MAKE_CODEOBJECT(module_filename_obj, 349, CO_NOFREE, mod_consts[117], mod_consts[426], NULL, 0, 0, 0); - codeobj_aa454e092d5abc9f5e4553a289907508 = MAKE_CODEOBJECT(module_filename_obj, 968, CO_NOFREE, mod_consts[397], mod_consts[426], NULL, 0, 0, 0); - codeobj_6e22728e3deba4360239f923eb721087 = MAKE_CODEOBJECT(module_filename_obj, 624, CO_NOFREE, mod_consts[180], mod_consts[426], NULL, 0, 0, 0); - codeobj_a081438c9da0f662f5a4de30a72f53eb = MAKE_CODEOBJECT(module_filename_obj, 378, CO_NOFREE, mod_consts[139], mod_consts[426], NULL, 0, 0, 0); - codeobj_25865ea0df4a3f86bdd137c22518ab84 = MAKE_CODEOBJECT(module_filename_obj, 677, CO_NOFREE, mod_consts[239], mod_consts[426], NULL, 0, 0, 0); - codeobj_2f024c1c2781aa4346c9360dc9ca9c37 = MAKE_CODEOBJECT(module_filename_obj, 644, CO_NOFREE, mod_consts[242], mod_consts[426], NULL, 0, 0, 0); - codeobj_2997152d8a9cec4ec6825b911abbb306 = MAKE_CODEOBJECT(module_filename_obj, 364, CO_NOFREE, mod_consts[119], mod_consts[426], NULL, 0, 0, 0); - codeobj_ab5a99313f9b6e1e298f4606848400d8 = MAKE_CODEOBJECT(module_filename_obj, 592, CO_NOFREE, mod_consts[196], mod_consts[426], NULL, 0, 0, 0); - codeobj_2ba10c444d39cd9fbc64d82f9cd4789e = MAKE_CODEOBJECT(module_filename_obj, 654, CO_NOFREE, mod_consts[375], mod_consts[426], NULL, 0, 0, 0); - codeobj_1e694c28c1cb7b88d842a0230f304b37 = MAKE_CODEOBJECT(module_filename_obj, 607, CO_NOFREE, mod_consts[173], mod_consts[426], NULL, 0, 0, 0); - codeobj_39fcb37e2c2b36c20e772de986f100d1 = MAKE_CODEOBJECT(module_filename_obj, 111, CO_NOFREE, mod_consts[93], mod_consts[426], NULL, 0, 0, 0); - codeobj_cc56a3d4cf1124558e66a811713c588d = MAKE_CODEOBJECT(module_filename_obj, 278, CO_NOFREE, mod_consts[94], mod_consts[426], NULL, 0, 0, 0); - codeobj_5cc68962f3dad1def9ff2c335252cee0 = MAKE_CODEOBJECT(module_filename_obj, 54, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_3ffa23d628f575a2f740dcb6fe8c1a15 = MAKE_CODEOBJECT(module_filename_obj, 279, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_bc386502a8ad779e82b56ce3a01a046c = MAKE_CODEOBJECT(module_filename_obj, 350, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_da381dec774f92fc3fdec9b27fb9d857 = MAKE_CODEOBJECT(module_filename_obj, 365, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_dbb5244b0ee9d68abb3ae7983cb8df4b = MAKE_CODEOBJECT(module_filename_obj, 488, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_3183350d90f44f69878dab33e80e4921 = MAKE_CODEOBJECT(module_filename_obj, 593, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_ca40fb07238f33d953447de3e31806fd = MAKE_CODEOBJECT(module_filename_obj, 608, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_9c6e6b2c3e0641a7465eeb0788b5b6dd = MAKE_CODEOBJECT(module_filename_obj, 625, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_fa49026615d06e8f214b8591603bbecd = MAKE_CODEOBJECT(module_filename_obj, 645, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_3fed784111b2af0b6a6ffc26ac50d650 = MAKE_CODEOBJECT(module_filename_obj, 973, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_e2b0deaa42e6635507b21870f60576c4 = MAKE_CODEOBJECT(module_filename_obj, 1136, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[427], mod_consts[426], 2, 0, 0); - codeobj_8e16adea762727bda11361e993d1476d = MAKE_CODEOBJECT(module_filename_obj, 687, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[428], mod_consts[426], 3, 0, 0); - codeobj_df9ac5d0a974d8e6803dbf3d6f292953 = MAKE_CODEOBJECT(module_filename_obj, 112, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[429], mod_consts[426], 3, 0, 0); - codeobj_269652cb22803d15cde90d439879a1a2 = MAKE_CODEOBJECT(module_filename_obj, 293, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[429], mod_consts[426], 3, 0, 0); - codeobj_9044624cc871cfe54b3607752fe57f1c = MAKE_CODEOBJECT(module_filename_obj, 379, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[1], mod_consts[430], mod_consts[426], 3, 0, 0); - codeobj_4147f3aad460337a90fc69f511dba483 = MAKE_CODEOBJECT(module_filename_obj, 664, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[381], mod_consts[431], NULL, 2, 0, 0); - codeobj_99e6e0fbfb9cc4282b3a8f4787f1fc90 = MAKE_CODEOBJECT(module_filename_obj, 705, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[389], mod_consts[432], NULL, 2, 0, 0); - codeobj_be03d43782ce0c74a753536e9a4f0743 = MAKE_CODEOBJECT(module_filename_obj, 1120, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[411], mod_consts[433], NULL, 3, 0, 0); - codeobj_9bc2c26bc51f7651d0836f8203f94193 = MAKE_CODEOBJECT(module_filename_obj, 533, CO_OPTIMIZED | CO_NEWLOCALS, mod_consts[151], mod_consts[434], mod_consts[435], 1, 0, 0); - codeobj_340e4e883925405252be80b1c8cda477 = MAKE_CODEOBJECT(module_filename_obj, 534, CO_OPTIMIZED | CO_NEWLOCALS | CO_VARARGS, mod_consts[164], mod_consts[436], mod_consts[437], 0, 0, 0); - codeobj_c4755f7ecaad447ef5e0ea80f9a42013 = MAKE_CODEOBJECT(module_filename_obj, 476, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[133], mod_consts[438], NULL, 2, 0, 0); - codeobj_bc4467ccc7610a81a2b180cada5c22ef = MAKE_CODEOBJECT(module_filename_obj, 481, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[131], mod_consts[438], NULL, 2, 0, 0); - codeobj_ef7df7f2aae603ea3cb921a91d68b297 = MAKE_CODEOBJECT(module_filename_obj, 358, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[439], NULL, 2, 0, 0); - codeobj_ef32505124b25b3c551fd3017e359336 = MAKE_CODEOBJECT(module_filename_obj, 617, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[439], NULL, 2, 0, 0); - codeobj_e5d530bc114f61caefcc8e7e58348d97 = MAKE_CODEOBJECT(module_filename_obj, 638, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[439], NULL, 2, 0, 0); - codeobj_222d3cb8bbe72424730d64c2fb38796b = MAKE_CODEOBJECT(module_filename_obj, 169, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[440], NULL, 8, 0, 0); - codeobj_38c0c92910efd854dc73aa8a49f61b57 = MAKE_CODEOBJECT(module_filename_obj, 402, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[441], NULL, 9, 0, 0); - codeobj_02c26eebaf2303eb7380395e131d8a5e = MAKE_CODEOBJECT(module_filename_obj, 322, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[442], NULL, 8, 0, 0); - codeobj_fb4ac8ca5f5c6cf5999268c801f1a60e = MAKE_CODEOBJECT(module_filename_obj, 495, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[443], NULL, 12, 0, 0); - codeobj_efe9f30d4ed10b98b0f8cc575424636a = MAKE_CODEOBJECT(module_filename_obj, 598, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[444], NULL, 2, 0, 0); - codeobj_e2c151c9b0676788eee114d75e2c1886 = MAKE_CODEOBJECT(module_filename_obj, 285, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[445], NULL, 3, 0, 0); - codeobj_ac223922169c79b32778e1fea6b86d12 = MAKE_CODEOBJECT(module_filename_obj, 371, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[445], NULL, 3, 0, 0); - codeobj_d74dc7aa09a16c42b6aa4ce3077a906f = MAKE_CODEOBJECT(module_filename_obj, 1150, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[446], NULL, 14, 0, 0); - codeobj_7c295c83a4e918fa0e86389ee3693174 = MAKE_CODEOBJECT(module_filename_obj, 987, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[447], NULL, 17, 0, 0); - codeobj_960ad736510918980c376a071f656626 = MAKE_CODEOBJECT(module_filename_obj, 804, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[448], NULL, 14, 0, 0); - codeobj_0d13c366fa26a472a6b7f1562ae363de = MAKE_CODEOBJECT(module_filename_obj, 78, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[449], NULL, 5, 0, 0); - codeobj_0eb4b4b7e57523c96bf4c60654493887 = MAKE_CODEOBJECT(module_filename_obj, 649, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[336], mod_consts[450], NULL, 2, 0, 0); - codeobj_00cbf7e5232472b130db964e018f1f81 = MAKE_CODEOBJECT(module_filename_obj, 158, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[344], mod_consts[451], NULL, 1, 0, 0); - codeobj_527cb4fbc9a5e67eae366d93117b1142 = MAKE_CODEOBJECT(module_filename_obj, 152, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[341], mod_consts[451], NULL, 1, 0, 0); - codeobj_a5b726196dc433c291a911837adced9c = MAKE_CODEOBJECT(module_filename_obj, 713, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[226], mod_consts[452], NULL, 6, 0, 0); - codeobj_64584954755a32f374a421edcbab9154 = MAKE_CODEOBJECT(module_filename_obj, 699, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[385], mod_consts[451], NULL, 1, 0, 0); - codeobj_d801348fdc3b19f91ac75fd50193d3b0 = MAKE_CODEOBJECT(module_filename_obj, 981, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[402], mod_consts[451], NULL, 1, 0, 0); - codeobj_ca38f33a6576fe8e2962a38a6c08a7da = MAKE_CODEOBJECT(module_filename_obj, 1144, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[402], mod_consts[451], NULL, 1, 0, 0); - codeobj_ded4b18b08a0de899e2560321c2271bc = MAKE_CODEOBJECT(module_filename_obj, 1097, CO_OPTIMIZED | CO_NEWLOCALS | CO_VARKEYWORDS | CO_NOFREE, mod_consts[409], mod_consts[453], NULL, 5, 0, 0); - codeobj_0b0b36faf8277ec302d6c6695f619e8c = MAKE_CODEOBJECT(module_filename_obj, 299, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[200], mod_consts[454], NULL, 2, 0, 0); - codeobj_7dc435c7821988f8361240f6dacceca5 = MAKE_CODEOBJECT(module_filename_obj, 155, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[85], mod_consts[455], NULL, 2, 0, 0); - codeobj_45b23ddb210e7fae6e94b686bdca3187 = MAKE_CODEOBJECT(module_filename_obj, 149, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[88], mod_consts[456], NULL, 2, 0, 0); - codeobj_721775a04cb45ee2837ea767c0780001 = MAKE_CODEOBJECT(module_filename_obj, 702, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[387], mod_consts[457], NULL, 2, 0, 0); - codeobj_74af6475e06de1d3e4323696e9d6b171 = MAKE_CODEOBJECT(module_filename_obj, 984, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[404], mod_consts[458], NULL, 2, 0, 0); - codeobj_0fd009d1dbe4c7c46c53f9bdc210148d = MAKE_CODEOBJECT(module_filename_obj, 1147, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[404], mod_consts[458], NULL, 2, 0, 0); - codeobj_d1badd3898339991bfdc4579ffa91ae1 = MAKE_CODEOBJECT(module_filename_obj, 161, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE, mod_consts[59], mod_consts[459], NULL, 2, 0, 0); -} - -// The module function declarations. -static PyObject *MAKE_GENERATOR_models$Qformer$$$function__24_forward$$$genexpr__1_genexpr(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_GENERATOR_models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr(struct Nuitka_CellObject **closure); - - -NUITKA_CROSS_MODULE PyObject *impl_models$$$function__1__mro_entries_conversion(PyObject **python_pars); - - -NUITKA_CROSS_MODULE PyObject *impl_models$$$function__2_complex_call_helper_star_list(PyObject **python_pars); - - -NUITKA_CROSS_MODULE PyObject *impl_models$$$function__4__unpack_list(PyObject **python_pars); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__10___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__11_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__12___init__(PyObject *defaults, struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__13_prune_heads(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__14_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__15___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__16_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__17___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__18_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__19___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__1___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__20_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__21_feed_forward_chunk(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__22_feed_forward_chunk_query(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__23___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__24_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward$$$function__1_custom_forward(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__25___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__26_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__27___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__28_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__29___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__2_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__30_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__31___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__32_forward(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__33__init_weights(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__34___init__(PyObject *defaults, struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__35_get_input_embeddings(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__36_set_input_embeddings(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__37__prune_heads(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__38_get_extended_attention_mask(PyObject *defaults, PyObject *annotations); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__39_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__3___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__40___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__41_get_output_embeddings(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__42_set_output_embeddings(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__43_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__44_prepare_inputs_for_generation(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__45__reorder_cache(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__46___init__(struct Nuitka_CellObject **closure); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__47_get_output_embeddings(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__48_set_output_embeddings(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__49_forward(PyObject *defaults); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__4_save_attn_gradients(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__5_get_attn_gradients(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__6_save_attention_map(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__7_get_attention_map(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__8_transpose_for_scores(); - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__9_forward(PyObject *defaults); - - -// The module function definitions. -static PyObject *impl_models$Qformer$$$function__1___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_5cc68962f3dad1def9ff2c335252cee0; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_5cc68962f3dad1def9ff2c335252cee0 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_5cc68962f3dad1def9ff2c335252cee0)) { - Py_XDECREF(cache_frame_5cc68962f3dad1def9ff2c335252cee0); - -#if _DEBUG_REFCOUNTS - if (cache_frame_5cc68962f3dad1def9ff2c335252cee0 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_5cc68962f3dad1def9ff2c335252cee0 = MAKE_FUNCTION_FRAME(codeobj_5cc68962f3dad1def9ff2c335252cee0, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_5cc68962f3dad1def9ff2c335252cee0->m_type_description == NULL); - frame_5cc68962f3dad1def9ff2c335252cee0 = cache_frame_5cc68962f3dad1def9ff2c335252cee0; - - // Push the new frame as the currently active one. - pushFrameStack(frame_5cc68962f3dad1def9ff2c335252cee0); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_5cc68962f3dad1def9ff2c335252cee0) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 55; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 55; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 55; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 55; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - PyObject *tmp_expression_name_4; - PyObject *tmp_assattr_target_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 56; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[3]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 56; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[4]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 57; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_name_1 = PyTuple_New(2); - { - PyObject *tmp_expression_name_3; - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 57; - type_description_1 = "ooc"; - goto tuple_build_exception_1; - } - - tmp_expression_name_3 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[6]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 57; - type_description_1 = "ooc"; - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_args_name_1, 1, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_dict_key_1 = mod_consts[7]; - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 57; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_config; - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[8]); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - - exception_lineno = 57; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_1 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 56; - tmp_assattr_name_1 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 56; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[9], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 56; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_5; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_7; - PyObject *tmp_assattr_target_2; - tmp_expression_name_5 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_5 == NULL)) { - tmp_expression_name_5 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 59; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[3]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 59; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 60; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[10]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 60; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 60; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_config; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[6]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 60; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 59; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_2, call_args); - } - - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 59; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[11], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 59; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_8; - PyObject *tmp_args_name_2; - PyObject *tmp_tuple_element_2; - PyObject *tmp_expression_name_9; - PyObject *tmp_kwargs_name_2; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - PyObject *tmp_expression_name_10; - PyObject *tmp_assattr_target_3; - tmp_expression_name_8 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_8 == NULL)) { - tmp_expression_name_8 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[12]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_9 = par_config; - tmp_tuple_element_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[6]); - if (tmp_tuple_element_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_2, 0, tmp_tuple_element_2); - tmp_dict_key_2 = mod_consts[13]; - if (par_config == NULL) { - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_10 = par_config; - tmp_dict_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[14]); - if (tmp_dict_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_2); - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_2 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - Py_DECREF(tmp_dict_value_2); - assert(!(tmp_res != 0)); - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 65; - tmp_assattr_name_3 = CALL_FUNCTION(tmp_called_name_3, tmp_args_name_2, tmp_kwargs_name_2); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_2); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[12], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 65; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_4; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_11; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_12; - PyObject *tmp_assattr_target_4; - tmp_expression_name_11 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_11 == NULL)) { - tmp_expression_name_11 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 66; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[15]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 66; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 66; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_12 = par_config; - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[16]); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 66; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 66; - tmp_assattr_name_4 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_4, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 66; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_4 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[17], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 66; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_13; - PyObject *tmp_call_result_2; - PyObject *tmp_args_element_name_4; - PyObject *tmp_args_element_name_5; - PyObject *tmp_called_instance_2; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_14; - PyObject *tmp_args_element_name_6; - PyObject *tmp_expression_name_15; - CHECK_OBJECT(par_self); - tmp_expression_name_13 = par_self; - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[18]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 69; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_element_name_4 = mod_consts[19]; - tmp_expression_name_14 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_14 == NULL)) { - tmp_expression_name_14 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 70; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[21]); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 70; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_called_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 70; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_15 = par_config; - tmp_args_element_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[10]); - if (tmp_args_element_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 70; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 70; - tmp_called_instance_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_6, tmp_args_element_name_6); - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_args_element_name_6); - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 70; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 70; - tmp_args_element_name_5 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_2, - mod_consts[22], - &PyTuple_GET_ITEM(mod_consts[23], 0) - ); - - Py_DECREF(tmp_called_instance_2); - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 70; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_5cc68962f3dad1def9ff2c335252cee0->m_frame.f_lineno = 69; - { - PyObject *call_args[] = {tmp_args_element_name_4, tmp_args_element_name_5}; - tmp_call_result_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_5, call_args); - } - - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_5); - if (tmp_call_result_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 69; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_2); - } - { - PyObject *tmp_assattr_name_5; - PyObject *tmp_getattr_target_1; - PyObject *tmp_getattr_attr_1; - PyObject *tmp_getattr_default_1; - PyObject *tmp_assattr_target_5; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 73; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_getattr_target_1 = par_config; - tmp_getattr_attr_1 = mod_consts[24]; - tmp_getattr_default_1 = mod_consts[25]; - tmp_assattr_name_5 = BUILTIN_GETATTR(tmp_getattr_target_1, tmp_getattr_attr_1, tmp_getattr_default_1); - if (tmp_assattr_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 72; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 72; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_5 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_5, mod_consts[24], tmp_assattr_name_5); - Py_DECREF(tmp_assattr_name_5); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 72; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_6; - PyObject *tmp_assattr_target_6; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 76; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_name_6 = par_config; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 76; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_6 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_6, mod_consts[5], tmp_assattr_name_6); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 76; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_5cc68962f3dad1def9ff2c335252cee0); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_5cc68962f3dad1def9ff2c335252cee0); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_5cc68962f3dad1def9ff2c335252cee0, exception_lineno); - } else if (exception_tb->tb_frame != &frame_5cc68962f3dad1def9ff2c335252cee0->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_5cc68962f3dad1def9ff2c335252cee0, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_5cc68962f3dad1def9ff2c335252cee0, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_5cc68962f3dad1def9ff2c335252cee0 == cache_frame_5cc68962f3dad1def9ff2c335252cee0) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_5cc68962f3dad1def9ff2c335252cee0); - cache_frame_5cc68962f3dad1def9ff2c335252cee0 = NULL; - } - - assertFrameObject(frame_5cc68962f3dad1def9ff2c335252cee0); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__2_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_input_ids = python_pars[1]; - PyObject *par_position_ids = python_pars[2]; - PyObject *par_query_embeds = python_pars[3]; - PyObject *par_past_key_values_length = python_pars[4]; - PyObject *var_seq_length = NULL; - PyObject *var_embeddings = NULL; - PyObject *var_position_embeddings = NULL; - struct Nuitka_FrameObject *frame_0d13c366fa26a472a6b7f1562ae363de; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_0d13c366fa26a472a6b7f1562ae363de = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_0d13c366fa26a472a6b7f1562ae363de)) { - Py_XDECREF(cache_frame_0d13c366fa26a472a6b7f1562ae363de); - -#if _DEBUG_REFCOUNTS - if (cache_frame_0d13c366fa26a472a6b7f1562ae363de == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_0d13c366fa26a472a6b7f1562ae363de = MAKE_FUNCTION_FRAME(codeobj_0d13c366fa26a472a6b7f1562ae363de, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_0d13c366fa26a472a6b7f1562ae363de->m_type_description == NULL); - frame_0d13c366fa26a472a6b7f1562ae363de = cache_frame_0d13c366fa26a472a6b7f1562ae363de; - - // Push the new frame as the currently active one. - pushFrameStack(frame_0d13c366fa26a472a6b7f1562ae363de); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_0d13c366fa26a472a6b7f1562ae363de) == 2); // Frame stack - - // Framed code: - { - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - CHECK_OBJECT(par_input_ids); - tmp_compexpr_left_1 = par_input_ids; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_subscript_name_1; - CHECK_OBJECT(par_input_ids); - tmp_called_instance_1 = par_input_ids; - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 86; - tmp_expression_name_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[27]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 86; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_1 = mod_consts[28]; - tmp_assign_source_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_1, tmp_subscript_name_1, 1); - Py_DECREF(tmp_expression_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 86; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - assert(var_seq_length == NULL); - var_seq_length = tmp_assign_source_1; - } - goto branch_end_1; - branch_no_1:; - { - PyObject *tmp_assign_source_2; - tmp_assign_source_2 = mod_consts[29]; - assert(var_seq_length == NULL); - Py_INCREF(tmp_assign_source_2); - var_seq_length = tmp_assign_source_2; - } - branch_end_1:; - { - bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - CHECK_OBJECT(par_position_ids); - tmp_compexpr_left_2 = par_position_ids; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_2 = (tmp_compexpr_left_2 == tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_2 != false) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_instance_2; - PyObject *tmp_expression_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_subscript_name_2; - PyObject *tmp_tuple_element_1; - CHECK_OBJECT(par_self); - tmp_expression_name_3 = par_self; - tmp_expression_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[19]); - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 91; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_1 = mod_consts[30]; - tmp_subscript_name_2 = PyTuple_New(2); - { - PyObject *tmp_start_name_1; - PyObject *tmp_stop_name_1; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - PyTuple_SET_ITEM0(tmp_subscript_name_2, 0, tmp_tuple_element_1); - CHECK_OBJECT(par_past_key_values_length); - tmp_start_name_1 = par_past_key_values_length; - CHECK_OBJECT(var_seq_length); - tmp_left_name_1 = var_seq_length; - CHECK_OBJECT(par_past_key_values_length); - tmp_right_name_1 = par_past_key_values_length; - tmp_stop_name_1 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - if (tmp_stop_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 92; - type_description_1 = "oooooooo"; - goto tuple_build_exception_1; - } - tmp_tuple_element_1 = MAKE_SLICEOBJ2(tmp_start_name_1, tmp_stop_name_1); - Py_DECREF(tmp_stop_name_1); - assert(!(tmp_tuple_element_1 == NULL)); - PyTuple_SET_ITEM(tmp_subscript_name_2, 1, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_expression_name_2); - Py_DECREF(tmp_subscript_name_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_called_instance_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_2, tmp_subscript_name_2); - Py_DECREF(tmp_expression_name_2); - Py_DECREF(tmp_subscript_name_2); - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 91; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 91; - tmp_assign_source_3 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[31]); - Py_DECREF(tmp_called_instance_2); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 91; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_position_ids; - assert(old != NULL); - par_position_ids = tmp_assign_source_3; - Py_DECREF(old); - } - - } - branch_no_2:; - { - bool tmp_condition_result_3; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - if (par_input_ids == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 95; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_compexpr_left_3 = par_input_ids; - tmp_compexpr_right_3 = Py_None; - tmp_condition_result_3 = (tmp_compexpr_left_3 != tmp_compexpr_right_3) ? true : false; - if (tmp_condition_result_3 != false) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_assign_source_4; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_4; - PyObject *tmp_args_element_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 96; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[9]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 96; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - if (par_input_ids == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 96; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_1 = par_input_ids; - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 96; - tmp_assign_source_4 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - Py_DECREF(tmp_called_name_1); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 96; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - assert(var_embeddings == NULL); - var_embeddings = tmp_assign_source_4; - } - { - nuitka_bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - PyObject *tmp_expression_name_5; - PyObject *tmp_tmp_condition_result_4_object_1; - int tmp_truth_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 97; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_5 = par_self; - tmp_compexpr_left_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[24]); - if (tmp_compexpr_left_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 97; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_4 = mod_consts[25]; - tmp_tmp_condition_result_4_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_4, tmp_compexpr_right_4); - Py_DECREF(tmp_compexpr_left_4); - if (tmp_tmp_condition_result_4_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 97; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_tmp_condition_result_4_object_1); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_4_object_1); - - exception_lineno = 97; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_4 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_4_object_1); - if (tmp_condition_result_4 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - } - branch_yes_4:; - { - PyObject *tmp_assign_source_5; - PyObject *tmp_called_instance_3; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 98; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_3 = par_self; - CHECK_OBJECT(par_position_ids); - tmp_args_element_name_2 = par_position_ids; - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 98; - tmp_assign_source_5 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_3, mod_consts[11], tmp_args_element_name_2); - if (tmp_assign_source_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 98; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - assert(var_position_embeddings == NULL); - var_position_embeddings = tmp_assign_source_5; - } - { - PyObject *tmp_assign_source_6; - PyObject *tmp_left_name_2; - PyObject *tmp_right_name_2; - CHECK_OBJECT(var_embeddings); - tmp_left_name_2 = var_embeddings; - CHECK_OBJECT(var_position_embeddings); - tmp_right_name_2 = var_position_embeddings; - tmp_assign_source_6 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_2, tmp_right_name_2); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 99; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_embeddings; - var_embeddings = tmp_assign_source_6; - Py_XDECREF(old); - } - - } - branch_no_4:; - { - bool tmp_condition_result_5; - PyObject *tmp_compexpr_left_5; - PyObject *tmp_compexpr_right_5; - CHECK_OBJECT(par_query_embeds); - tmp_compexpr_left_5 = par_query_embeds; - tmp_compexpr_right_5 = Py_None; - tmp_condition_result_5 = (tmp_compexpr_left_5 != tmp_compexpr_right_5) ? true : false; - if (tmp_condition_result_5 != false) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - { - PyObject *tmp_assign_source_7; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_6; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_2; - PyObject *tmp_tuple_element_3; - PyObject *tmp_kwargs_name_1; - tmp_expression_name_6 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_6 == NULL)) { - tmp_expression_name_6 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 102; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[33]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 102; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_query_embeds); - tmp_tuple_element_3 = par_query_embeds; - tmp_tuple_element_2 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_tuple_element_2, 0, tmp_tuple_element_3); - CHECK_OBJECT(var_embeddings); - tmp_tuple_element_3 = var_embeddings; - PyTuple_SET_ITEM0(tmp_tuple_element_2, 1, tmp_tuple_element_3); - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_2); - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[34]); - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 102; - tmp_assign_source_7 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 102; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_embeddings; - var_embeddings = tmp_assign_source_7; - Py_XDECREF(old); - } - - } - branch_no_5:; - goto branch_end_3; - branch_no_3:; - { - PyObject *tmp_assign_source_8; - CHECK_OBJECT(par_query_embeds); - tmp_assign_source_8 = par_query_embeds; - assert(var_embeddings == NULL); - Py_INCREF(tmp_assign_source_8); - var_embeddings = tmp_assign_source_8; - } - branch_end_3:; - { - PyObject *tmp_assign_source_9; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_args_element_name_3; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 106; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_self; - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[12]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 106; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - if (var_embeddings == NULL) { - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[35]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 106; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_3 = var_embeddings; - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 106; - tmp_assign_source_9 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_3); - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 106; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_embeddings; - var_embeddings = tmp_assign_source_9; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_10; - PyObject *tmp_called_instance_4; - PyObject *tmp_args_element_name_4; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 107; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_4 = par_self; - CHECK_OBJECT(var_embeddings); - tmp_args_element_name_4 = var_embeddings; - frame_0d13c366fa26a472a6b7f1562ae363de->m_frame.f_lineno = 107; - tmp_assign_source_10 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_4, mod_consts[17], tmp_args_element_name_4); - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 107; - type_description_1 = "oooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_embeddings; - var_embeddings = tmp_assign_source_10; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0d13c366fa26a472a6b7f1562ae363de); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0d13c366fa26a472a6b7f1562ae363de); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_0d13c366fa26a472a6b7f1562ae363de, exception_lineno); - } else if (exception_tb->tb_frame != &frame_0d13c366fa26a472a6b7f1562ae363de->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_0d13c366fa26a472a6b7f1562ae363de, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_0d13c366fa26a472a6b7f1562ae363de, - type_description_1, - par_self, - par_input_ids, - par_position_ids, - par_query_embeds, - par_past_key_values_length, - var_seq_length, - var_embeddings, - var_position_embeddings - ); - - - // Release cached frame if used for exception. - if (frame_0d13c366fa26a472a6b7f1562ae363de == cache_frame_0d13c366fa26a472a6b7f1562ae363de) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_0d13c366fa26a472a6b7f1562ae363de); - cache_frame_0d13c366fa26a472a6b7f1562ae363de = NULL; - } - - assertFrameObject(frame_0d13c366fa26a472a6b7f1562ae363de); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_embeddings); - tmp_return_value = var_embeddings; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_past_key_values_length); - par_past_key_values_length = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - CHECK_OBJECT(var_embeddings); - Py_DECREF(var_embeddings); - var_embeddings = NULL; - Py_XDECREF(var_position_embeddings); - var_position_embeddings = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_past_key_values_length); - par_past_key_values_length = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_embeddings); - var_embeddings = NULL; - Py_XDECREF(var_position_embeddings); - var_position_embeddings = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__3___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - PyObject *par_is_cross_attention = python_pars[2]; - struct Nuitka_FrameObject *frame_df9ac5d0a974d8e6803dbf3d6f292953; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_df9ac5d0a974d8e6803dbf3d6f292953 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_df9ac5d0a974d8e6803dbf3d6f292953)) { - Py_XDECREF(cache_frame_df9ac5d0a974d8e6803dbf3d6f292953); - -#if _DEBUG_REFCOUNTS - if (cache_frame_df9ac5d0a974d8e6803dbf3d6f292953 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_df9ac5d0a974d8e6803dbf3d6f292953 = MAKE_FUNCTION_FRAME(codeobj_df9ac5d0a974d8e6803dbf3d6f292953, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_df9ac5d0a974d8e6803dbf3d6f292953->m_type_description == NULL); - frame_df9ac5d0a974d8e6803dbf3d6f292953 = cache_frame_df9ac5d0a974d8e6803dbf3d6f292953; - - // Push the new frame as the currently active one. - pushFrameStack(frame_df9ac5d0a974d8e6803dbf3d6f292953); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_df9ac5d0a974d8e6803dbf3d6f292953) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 113; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 113; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 113; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 113; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - CHECK_OBJECT(par_config); - tmp_assattr_name_1 = par_config; - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[5], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 114; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - nuitka_bool tmp_condition_result_1; - int tmp_and_left_truth_1; - nuitka_bool tmp_and_left_value_1; - nuitka_bool tmp_and_right_value_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_left_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_tmp_and_left_value_1_object_1; - int tmp_truth_name_1; - PyObject *tmp_operand_name_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_attribute_name_1; - CHECK_OBJECT(par_config); - tmp_expression_name_1 = par_config; - tmp_left_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[6]); - if (tmp_left_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_left_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_2 = par_config; - tmp_right_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[36]); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_compexpr_left_1 = BINARY_OPERATION_MOD_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_compexpr_left_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_1 = mod_consts[29]; - tmp_tmp_and_left_value_1_object_1 = RICH_COMPARE_NE_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_1, tmp_compexpr_right_1); - Py_DECREF(tmp_compexpr_left_1); - if (tmp_tmp_and_left_value_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_tmp_and_left_value_1_object_1); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_and_left_value_1_object_1); - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_and_left_value_1 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_and_left_value_1_object_1); - tmp_and_left_truth_1 = tmp_and_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_and_left_truth_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (tmp_and_left_truth_1 == 1) { - goto and_right_1; - } else { - goto and_left_1; - } - and_right_1:; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 116; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_config; - tmp_attribute_name_1 = mod_consts[37]; - tmp_res = BUILTIN_HASATTR_BOOL(tmp_expression_name_3, tmp_attribute_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_operand_name_1 = (tmp_res != 0) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 115; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_and_right_value_1 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - tmp_condition_result_1 = tmp_and_right_value_1; - goto and_end_1; - and_left_1:; - tmp_condition_result_1 = tmp_and_left_value_1; - and_end_1:; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_raise_type_1; - PyObject *tmp_make_exception_arg_1; - PyObject *tmp_left_name_2; - PyObject *tmp_right_name_2; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_4; - tmp_left_name_2 = mod_consts[38]; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 120; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[6]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 120; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_right_name_2 = PyTuple_New(2); - { - PyObject *tmp_expression_name_5; - PyTuple_SET_ITEM(tmp_right_name_2, 0, tmp_tuple_element_1); - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 120; - type_description_1 = "oooc"; - goto tuple_build_exception_1; - } - - tmp_expression_name_5 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[36]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 120; - type_description_1 = "oooc"; - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_right_name_2, 1, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_right_name_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_make_exception_arg_1 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_right_name_2); - if (tmp_make_exception_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 119; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 118; - tmp_raise_type_1 = CALL_FUNCTION_WITH_SINGLE_ARG(PyExc_ValueError, tmp_make_exception_arg_1); - Py_DECREF(tmp_make_exception_arg_1); - assert(!(tmp_raise_type_1 == NULL)); - exception_type = tmp_raise_type_1; - exception_lineno = 118; - RAISE_EXCEPTION_WITH_TYPE(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - branch_no_1:; - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_expression_name_6; - PyObject *tmp_assattr_target_2; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 123; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_assattr_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[36]); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 123; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[36], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 123; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_int_arg_1; - PyObject *tmp_left_name_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_right_name_3; - PyObject *tmp_expression_name_8; - PyObject *tmp_assattr_target_3; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_config; - tmp_left_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[6]); - if (tmp_left_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_left_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_config; - tmp_right_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[36]); - if (tmp_right_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_3); - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_int_arg_1 = BINARY_OPERATION_TRUEDIV_OBJECT_OBJECT_OBJECT(tmp_left_name_3, tmp_right_name_3); - Py_DECREF(tmp_left_name_3); - Py_DECREF(tmp_right_name_3); - if (tmp_int_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_assattr_name_3 = PyNumber_Int(tmp_int_arg_1); - Py_DECREF(tmp_int_arg_1); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[39], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 124; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_4; - PyObject *tmp_left_name_4; - PyObject *tmp_expression_name_9; - PyObject *tmp_right_name_4; - PyObject *tmp_expression_name_10; - PyObject *tmp_assattr_target_4; - CHECK_OBJECT(par_self); - tmp_expression_name_9 = par_self; - tmp_left_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[36]); - if (tmp_left_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 125; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_left_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 125; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_10 = par_self; - tmp_right_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[39]); - if (tmp_right_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_4); - - exception_lineno = 125; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_assattr_name_4 = BINARY_OPERATION_MULT_OBJECT_OBJECT_OBJECT(tmp_left_name_4, tmp_right_name_4); - Py_DECREF(tmp_left_name_4); - Py_DECREF(tmp_right_name_4); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 125; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 125; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_4 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[40], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 125; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_5; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_11; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_12; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_13; - PyObject *tmp_assattr_target_5; - tmp_expression_name_11 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_11 == NULL)) { - tmp_expression_name_11 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[41]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_12 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[6]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_13 = par_self; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[40]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 127; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_5 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_5 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_5, mod_consts[42], tmp_assattr_name_5); - Py_DECREF(tmp_assattr_name_5); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 127; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - nuitka_bool tmp_condition_result_2; - int tmp_truth_name_2; - CHECK_OBJECT(par_is_cross_attention); - tmp_truth_name_2 = CHECK_IF_TRUE(par_is_cross_attention); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 128; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_condition_result_2 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_2 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_assattr_name_6; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_14; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_15; - PyObject *tmp_args_element_name_4; - PyObject *tmp_expression_name_16; - PyObject *tmp_assattr_target_6; - tmp_expression_name_14 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_14 == NULL)) { - tmp_expression_name_14 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[41]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_15 = par_config; - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[43]); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_16 = par_self; - tmp_args_element_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_16, mod_consts[40]); - if (tmp_args_element_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_3); - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 129; - { - PyObject *call_args[] = {tmp_args_element_name_3, tmp_args_element_name_4}; - tmp_assattr_name_6 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_2, call_args); - } - - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_3); - Py_DECREF(tmp_args_element_name_4); - if (tmp_assattr_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_6 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_6, mod_consts[44], tmp_assattr_name_6); - Py_DECREF(tmp_assattr_name_6); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 129; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_7; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_17; - PyObject *tmp_args_element_name_5; - PyObject *tmp_expression_name_18; - PyObject *tmp_args_element_name_6; - PyObject *tmp_expression_name_19; - PyObject *tmp_assattr_target_7; - tmp_expression_name_17 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_17 == NULL)) { - tmp_expression_name_17 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[41]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_18 = par_config; - tmp_args_element_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_18, mod_consts[43]); - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_19 = par_self; - tmp_args_element_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[40]); - if (tmp_args_element_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_5); - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 130; - { - PyObject *call_args[] = {tmp_args_element_name_5, tmp_args_element_name_6}; - tmp_assattr_name_7 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_3, call_args); - } - - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_5); - Py_DECREF(tmp_args_element_name_6); - if (tmp_assattr_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_7 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_7, mod_consts[45], tmp_assattr_name_7); - Py_DECREF(tmp_assattr_name_7); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 130; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - goto branch_end_2; - branch_no_2:; - { - PyObject *tmp_assattr_name_8; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_20; - PyObject *tmp_args_element_name_7; - PyObject *tmp_expression_name_21; - PyObject *tmp_args_element_name_8; - PyObject *tmp_expression_name_22; - PyObject *tmp_assattr_target_8; - tmp_expression_name_20 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_20 == NULL)) { - tmp_expression_name_20 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[41]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_21 = par_config; - tmp_args_element_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_21, mod_consts[6]); - if (tmp_args_element_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_22 = par_self; - tmp_args_element_name_8 = LOOKUP_ATTRIBUTE(tmp_expression_name_22, mod_consts[40]); - if (tmp_args_element_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_7); - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 132; - { - PyObject *call_args[] = {tmp_args_element_name_7, tmp_args_element_name_8}; - tmp_assattr_name_8 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_4, call_args); - } - - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_7); - Py_DECREF(tmp_args_element_name_8); - if (tmp_assattr_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_8); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_8 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_8, mod_consts[44], tmp_assattr_name_8); - Py_DECREF(tmp_assattr_name_8); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 132; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_9; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_23; - PyObject *tmp_args_element_name_9; - PyObject *tmp_expression_name_24; - PyObject *tmp_args_element_name_10; - PyObject *tmp_expression_name_25; - PyObject *tmp_assattr_target_9; - tmp_expression_name_23 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_23 == NULL)) { - tmp_expression_name_23 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[41]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_24 = par_config; - tmp_args_element_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_24, mod_consts[6]); - if (tmp_args_element_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_9); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_25 = par_self; - tmp_args_element_name_10 = LOOKUP_ATTRIBUTE(tmp_expression_name_25, mod_consts[40]); - if (tmp_args_element_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_9); - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 133; - { - PyObject *call_args[] = {tmp_args_element_name_9, tmp_args_element_name_10}; - tmp_assattr_name_9 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_5, call_args); - } - - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_9); - Py_DECREF(tmp_args_element_name_10); - if (tmp_assattr_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_9); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_9 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_9, mod_consts[45], tmp_assattr_name_9); - Py_DECREF(tmp_assattr_name_9); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 133; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - branch_end_2:; - { - PyObject *tmp_assattr_name_10; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_26; - PyObject *tmp_args_element_name_11; - PyObject *tmp_expression_name_27; - PyObject *tmp_assattr_target_10; - tmp_expression_name_26 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_26 == NULL)) { - tmp_expression_name_26 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_26, mod_consts[15]); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_27 = par_config; - tmp_args_element_name_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_27, mod_consts[46]); - if (tmp_args_element_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 135; - tmp_assattr_name_10 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_6, tmp_args_element_name_11); - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_args_element_name_11); - if (tmp_assattr_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_10); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_10 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_10, mod_consts[17], tmp_assattr_name_10); - Py_DECREF(tmp_assattr_name_10); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 135; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_11; - PyObject *tmp_getattr_target_1; - PyObject *tmp_getattr_attr_1; - PyObject *tmp_getattr_default_1; - PyObject *tmp_assattr_target_11; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 137; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_getattr_target_1 = par_config; - tmp_getattr_attr_1 = mod_consts[24]; - tmp_getattr_default_1 = mod_consts[25]; - tmp_assattr_name_11 = BUILTIN_GETATTR(tmp_getattr_target_1, tmp_getattr_attr_1, tmp_getattr_default_1); - if (tmp_assattr_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 136; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_11); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 136; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_11 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_11, mod_consts[24], tmp_assattr_name_11); - Py_DECREF(tmp_assattr_name_11); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 136; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - nuitka_bool tmp_condition_result_3; - int tmp_or_left_truth_1; - nuitka_bool tmp_or_left_value_1; - nuitka_bool tmp_or_right_value_1; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - PyObject *tmp_expression_name_28; - PyObject *tmp_tmp_or_left_value_1_object_1; - int tmp_truth_name_3; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - PyObject *tmp_expression_name_29; - PyObject *tmp_tmp_or_right_value_1_object_1; - int tmp_truth_name_4; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 140; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_28 = par_self; - tmp_compexpr_left_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_28, mod_consts[24]); - if (tmp_compexpr_left_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 140; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_2 = mod_consts[47]; - tmp_tmp_or_left_value_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_2, tmp_compexpr_right_2); - Py_DECREF(tmp_compexpr_left_2); - if (tmp_tmp_or_left_value_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 140; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_truth_name_3 = CHECK_IF_TRUE(tmp_tmp_or_left_value_1_object_1); - if (tmp_truth_name_3 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_or_left_value_1_object_1); - - exception_lineno = 140; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_or_left_value_1 = tmp_truth_name_3 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_or_left_value_1_object_1); - tmp_or_left_truth_1 = tmp_or_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_or_left_truth_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 141; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (tmp_or_left_truth_1 == 1) { - goto or_left_1; - } else { - goto or_right_1; - } - or_right_1:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 141; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_29 = par_self; - tmp_compexpr_left_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_29, mod_consts[24]); - if (tmp_compexpr_left_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 141; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_3 = mod_consts[48]; - tmp_tmp_or_right_value_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_3, tmp_compexpr_right_3); - Py_DECREF(tmp_compexpr_left_3); - if (tmp_tmp_or_right_value_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 141; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_truth_name_4 = CHECK_IF_TRUE(tmp_tmp_or_right_value_1_object_1); - if (tmp_truth_name_4 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_or_right_value_1_object_1); - - exception_lineno = 141; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_or_right_value_1 = tmp_truth_name_4 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_or_right_value_1_object_1); - tmp_condition_result_3 = tmp_or_right_value_1; - goto or_end_1; - or_left_1:; - tmp_condition_result_3 = tmp_or_left_value_1; - or_end_1:; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_assattr_name_12; - PyObject *tmp_expression_name_30; - PyObject *tmp_assattr_target_12; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 143; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_30 = par_config; - tmp_assattr_name_12 = LOOKUP_ATTRIBUTE(tmp_expression_name_30, mod_consts[10]); - if (tmp_assattr_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 143; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_12); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 143; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_12 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_12, mod_consts[10], tmp_assattr_name_12); - Py_DECREF(tmp_assattr_name_12); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 143; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_13; - PyObject *tmp_called_name_7; - PyObject *tmp_expression_name_31; - PyObject *tmp_args_element_name_12; - PyObject *tmp_left_name_5; - PyObject *tmp_left_name_6; - PyObject *tmp_right_name_5; - PyObject *tmp_expression_name_32; - PyObject *tmp_right_name_6; - PyObject *tmp_args_element_name_13; - PyObject *tmp_expression_name_33; - PyObject *tmp_assattr_target_13; - tmp_expression_name_31 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_31 == NULL)) { - tmp_expression_name_31 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_31 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 144; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_called_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_31, mod_consts[3]); - if (tmp_called_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 144; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_left_name_6 = mod_consts[49]; - if (par_config == NULL) { - Py_DECREF(tmp_called_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 145; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_32 = par_config; - tmp_right_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_32, mod_consts[10]); - if (tmp_right_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_7); - - exception_lineno = 145; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_left_name_5 = BINARY_OPERATION_MULT_OBJECT_LONG_OBJECT(tmp_left_name_6, tmp_right_name_5); - Py_DECREF(tmp_right_name_5); - if (tmp_left_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_7); - - exception_lineno = 145; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_right_name_6 = mod_consts[28]; - tmp_args_element_name_12 = BINARY_OPERATION_SUB_OBJECT_OBJECT_LONG(tmp_left_name_5, tmp_right_name_6); - Py_DECREF(tmp_left_name_5); - if (tmp_args_element_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_7); - - exception_lineno = 145; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_element_name_12); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 145; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_33 = par_self; - tmp_args_element_name_13 = LOOKUP_ATTRIBUTE(tmp_expression_name_33, mod_consts[39]); - if (tmp_args_element_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_element_name_12); - - exception_lineno = 145; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame.f_lineno = 144; - { - PyObject *call_args[] = {tmp_args_element_name_12, tmp_args_element_name_13}; - tmp_assattr_name_13 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_7, call_args); - } - - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_element_name_12); - Py_DECREF(tmp_args_element_name_13); - if (tmp_assattr_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 144; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_13); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 144; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_13 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_13, mod_consts[50], tmp_assattr_name_13); - Py_DECREF(tmp_assattr_name_13); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 144; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - branch_no_3:; - { - PyObject *tmp_assattr_name_14; - PyObject *tmp_assattr_target_14; - tmp_assattr_name_14 = Py_False; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 147; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_14 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_14, mod_consts[51], tmp_assattr_name_14); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 147; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_df9ac5d0a974d8e6803dbf3d6f292953); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_df9ac5d0a974d8e6803dbf3d6f292953); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_df9ac5d0a974d8e6803dbf3d6f292953, exception_lineno); - } else if (exception_tb->tb_frame != &frame_df9ac5d0a974d8e6803dbf3d6f292953->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_df9ac5d0a974d8e6803dbf3d6f292953, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_df9ac5d0a974d8e6803dbf3d6f292953, - type_description_1, - par_self, - par_config, - par_is_cross_attention, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_df9ac5d0a974d8e6803dbf3d6f292953 == cache_frame_df9ac5d0a974d8e6803dbf3d6f292953) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_df9ac5d0a974d8e6803dbf3d6f292953); - cache_frame_df9ac5d0a974d8e6803dbf3d6f292953 = NULL; - } - - assertFrameObject(frame_df9ac5d0a974d8e6803dbf3d6f292953); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - CHECK_OBJECT(par_is_cross_attention); - Py_DECREF(par_is_cross_attention); - par_is_cross_attention = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - CHECK_OBJECT(par_is_cross_attention); - Py_DECREF(par_is_cross_attention); - par_is_cross_attention = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__4_save_attn_gradients(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_attn_gradients = python_pars[1]; - struct Nuitka_FrameObject *frame_45b23ddb210e7fae6e94b686bdca3187; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - bool tmp_result; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_45b23ddb210e7fae6e94b686bdca3187 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_45b23ddb210e7fae6e94b686bdca3187)) { - Py_XDECREF(cache_frame_45b23ddb210e7fae6e94b686bdca3187); - -#if _DEBUG_REFCOUNTS - if (cache_frame_45b23ddb210e7fae6e94b686bdca3187 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_45b23ddb210e7fae6e94b686bdca3187 = MAKE_FUNCTION_FRAME(codeobj_45b23ddb210e7fae6e94b686bdca3187, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_45b23ddb210e7fae6e94b686bdca3187->m_type_description == NULL); - frame_45b23ddb210e7fae6e94b686bdca3187 = cache_frame_45b23ddb210e7fae6e94b686bdca3187; - - // Push the new frame as the currently active one. - pushFrameStack(frame_45b23ddb210e7fae6e94b686bdca3187); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_45b23ddb210e7fae6e94b686bdca3187) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - CHECK_OBJECT(par_attn_gradients); - tmp_assattr_name_1 = par_attn_gradients; - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[52], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 150; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_45b23ddb210e7fae6e94b686bdca3187); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_45b23ddb210e7fae6e94b686bdca3187); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_45b23ddb210e7fae6e94b686bdca3187, exception_lineno); - } else if (exception_tb->tb_frame != &frame_45b23ddb210e7fae6e94b686bdca3187->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_45b23ddb210e7fae6e94b686bdca3187, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_45b23ddb210e7fae6e94b686bdca3187, - type_description_1, - par_self, - par_attn_gradients - ); - - - // Release cached frame if used for exception. - if (frame_45b23ddb210e7fae6e94b686bdca3187 == cache_frame_45b23ddb210e7fae6e94b686bdca3187) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_45b23ddb210e7fae6e94b686bdca3187); - cache_frame_45b23ddb210e7fae6e94b686bdca3187 = NULL; - } - - assertFrameObject(frame_45b23ddb210e7fae6e94b686bdca3187); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_attn_gradients); - Py_DECREF(par_attn_gradients); - par_attn_gradients = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_attn_gradients); - Py_DECREF(par_attn_gradients); - par_attn_gradients = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__5_get_attn_gradients(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - struct Nuitka_FrameObject *frame_527cb4fbc9a5e67eae366d93117b1142; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_527cb4fbc9a5e67eae366d93117b1142 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_527cb4fbc9a5e67eae366d93117b1142)) { - Py_XDECREF(cache_frame_527cb4fbc9a5e67eae366d93117b1142); - -#if _DEBUG_REFCOUNTS - if (cache_frame_527cb4fbc9a5e67eae366d93117b1142 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_527cb4fbc9a5e67eae366d93117b1142 = MAKE_FUNCTION_FRAME(codeobj_527cb4fbc9a5e67eae366d93117b1142, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_527cb4fbc9a5e67eae366d93117b1142->m_type_description == NULL); - frame_527cb4fbc9a5e67eae366d93117b1142 = cache_frame_527cb4fbc9a5e67eae366d93117b1142; - - // Push the new frame as the currently active one. - pushFrameStack(frame_527cb4fbc9a5e67eae366d93117b1142); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_527cb4fbc9a5e67eae366d93117b1142) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_expression_name_1; - CHECK_OBJECT(par_self); - tmp_expression_name_1 = par_self; - tmp_return_value = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[52]); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 153; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_527cb4fbc9a5e67eae366d93117b1142); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_527cb4fbc9a5e67eae366d93117b1142); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_527cb4fbc9a5e67eae366d93117b1142); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_527cb4fbc9a5e67eae366d93117b1142, exception_lineno); - } else if (exception_tb->tb_frame != &frame_527cb4fbc9a5e67eae366d93117b1142->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_527cb4fbc9a5e67eae366d93117b1142, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_527cb4fbc9a5e67eae366d93117b1142, - type_description_1, - par_self - ); - - - // Release cached frame if used for exception. - if (frame_527cb4fbc9a5e67eae366d93117b1142 == cache_frame_527cb4fbc9a5e67eae366d93117b1142) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_527cb4fbc9a5e67eae366d93117b1142); - cache_frame_527cb4fbc9a5e67eae366d93117b1142 = NULL; - } - - assertFrameObject(frame_527cb4fbc9a5e67eae366d93117b1142); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__6_save_attention_map(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_attention_map = python_pars[1]; - struct Nuitka_FrameObject *frame_7dc435c7821988f8361240f6dacceca5; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - bool tmp_result; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_7dc435c7821988f8361240f6dacceca5 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_7dc435c7821988f8361240f6dacceca5)) { - Py_XDECREF(cache_frame_7dc435c7821988f8361240f6dacceca5); - -#if _DEBUG_REFCOUNTS - if (cache_frame_7dc435c7821988f8361240f6dacceca5 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_7dc435c7821988f8361240f6dacceca5 = MAKE_FUNCTION_FRAME(codeobj_7dc435c7821988f8361240f6dacceca5, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_7dc435c7821988f8361240f6dacceca5->m_type_description == NULL); - frame_7dc435c7821988f8361240f6dacceca5 = cache_frame_7dc435c7821988f8361240f6dacceca5; - - // Push the new frame as the currently active one. - pushFrameStack(frame_7dc435c7821988f8361240f6dacceca5); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_7dc435c7821988f8361240f6dacceca5) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - CHECK_OBJECT(par_attention_map); - tmp_assattr_name_1 = par_attention_map; - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[53], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 156; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7dc435c7821988f8361240f6dacceca5); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7dc435c7821988f8361240f6dacceca5); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_7dc435c7821988f8361240f6dacceca5, exception_lineno); - } else if (exception_tb->tb_frame != &frame_7dc435c7821988f8361240f6dacceca5->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_7dc435c7821988f8361240f6dacceca5, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_7dc435c7821988f8361240f6dacceca5, - type_description_1, - par_self, - par_attention_map - ); - - - // Release cached frame if used for exception. - if (frame_7dc435c7821988f8361240f6dacceca5 == cache_frame_7dc435c7821988f8361240f6dacceca5) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_7dc435c7821988f8361240f6dacceca5); - cache_frame_7dc435c7821988f8361240f6dacceca5 = NULL; - } - - assertFrameObject(frame_7dc435c7821988f8361240f6dacceca5); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_attention_map); - Py_DECREF(par_attention_map); - par_attention_map = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_attention_map); - Py_DECREF(par_attention_map); - par_attention_map = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__7_get_attention_map(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - struct Nuitka_FrameObject *frame_00cbf7e5232472b130db964e018f1f81; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_00cbf7e5232472b130db964e018f1f81 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_00cbf7e5232472b130db964e018f1f81)) { - Py_XDECREF(cache_frame_00cbf7e5232472b130db964e018f1f81); - -#if _DEBUG_REFCOUNTS - if (cache_frame_00cbf7e5232472b130db964e018f1f81 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_00cbf7e5232472b130db964e018f1f81 = MAKE_FUNCTION_FRAME(codeobj_00cbf7e5232472b130db964e018f1f81, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_00cbf7e5232472b130db964e018f1f81->m_type_description == NULL); - frame_00cbf7e5232472b130db964e018f1f81 = cache_frame_00cbf7e5232472b130db964e018f1f81; - - // Push the new frame as the currently active one. - pushFrameStack(frame_00cbf7e5232472b130db964e018f1f81); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_00cbf7e5232472b130db964e018f1f81) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_expression_name_1; - CHECK_OBJECT(par_self); - tmp_expression_name_1 = par_self; - tmp_return_value = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[53]); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 159; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_00cbf7e5232472b130db964e018f1f81); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_00cbf7e5232472b130db964e018f1f81); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_00cbf7e5232472b130db964e018f1f81); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_00cbf7e5232472b130db964e018f1f81, exception_lineno); - } else if (exception_tb->tb_frame != &frame_00cbf7e5232472b130db964e018f1f81->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_00cbf7e5232472b130db964e018f1f81, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_00cbf7e5232472b130db964e018f1f81, - type_description_1, - par_self - ); - - - // Release cached frame if used for exception. - if (frame_00cbf7e5232472b130db964e018f1f81 == cache_frame_00cbf7e5232472b130db964e018f1f81) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_00cbf7e5232472b130db964e018f1f81); - cache_frame_00cbf7e5232472b130db964e018f1f81 = NULL; - } - - assertFrameObject(frame_00cbf7e5232472b130db964e018f1f81); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__8_transpose_for_scores(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_x = python_pars[1]; - PyObject *var_new_x_shape = NULL; - struct Nuitka_FrameObject *frame_d1badd3898339991bfdc4579ffa91ae1; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - PyObject *tmp_return_value = NULL; - static struct Nuitka_FrameObject *cache_frame_d1badd3898339991bfdc4579ffa91ae1 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_d1badd3898339991bfdc4579ffa91ae1)) { - Py_XDECREF(cache_frame_d1badd3898339991bfdc4579ffa91ae1); - -#if _DEBUG_REFCOUNTS - if (cache_frame_d1badd3898339991bfdc4579ffa91ae1 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_d1badd3898339991bfdc4579ffa91ae1 = MAKE_FUNCTION_FRAME(codeobj_d1badd3898339991bfdc4579ffa91ae1, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_d1badd3898339991bfdc4579ffa91ae1->m_type_description == NULL); - frame_d1badd3898339991bfdc4579ffa91ae1 = cache_frame_d1badd3898339991bfdc4579ffa91ae1; - - // Push the new frame as the currently active one. - pushFrameStack(frame_d1badd3898339991bfdc4579ffa91ae1); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_d1badd3898339991bfdc4579ffa91ae1) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_left_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_subscript_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_x); - tmp_called_instance_1 = par_x; - frame_d1badd3898339991bfdc4579ffa91ae1->m_frame.f_lineno = 162; - tmp_expression_name_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[27]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 162; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_1 = mod_consts[54]; - tmp_left_name_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_1, tmp_subscript_name_1); - Py_DECREF(tmp_expression_name_1); - if (tmp_left_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 162; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[36]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 163; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_right_name_1 = PyTuple_New(2); - { - PyObject *tmp_expression_name_3; - PyTuple_SET_ITEM(tmp_right_name_1, 0, tmp_tuple_element_1); - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 164; - type_description_1 = "ooo"; - goto tuple_build_exception_1; - } - - tmp_expression_name_3 = par_self; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[39]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 164; - type_description_1 = "ooo"; - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_right_name_1, 1, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_assign_source_1 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 162; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - assert(var_new_x_shape == NULL); - var_new_x_shape = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_dircall_arg1_1; - PyObject *tmp_expression_name_4; - PyObject *tmp_dircall_arg2_1; - if (par_x == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[55]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 166; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_x; - tmp_dircall_arg1_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[56]); - if (tmp_dircall_arg1_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 166; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_new_x_shape); - tmp_dircall_arg2_1 = var_new_x_shape; - Py_INCREF(tmp_dircall_arg2_1); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_1, tmp_dircall_arg2_1}; - tmp_assign_source_2 = impl_models$$$function__2_complex_call_helper_star_list(dir_call_args); - } - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 166; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_x; - par_x = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_called_instance_2; - CHECK_OBJECT(par_x); - tmp_called_instance_2 = par_x; - frame_d1badd3898339991bfdc4579ffa91ae1->m_frame.f_lineno = 167; - tmp_return_value = CALL_METHOD_WITH_ARGS4( - tmp_called_instance_2, - mod_consts[57], - &PyTuple_GET_ITEM(mod_consts[58], 0) - ); - - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 167; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d1badd3898339991bfdc4579ffa91ae1); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d1badd3898339991bfdc4579ffa91ae1); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d1badd3898339991bfdc4579ffa91ae1); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_d1badd3898339991bfdc4579ffa91ae1, exception_lineno); - } else if (exception_tb->tb_frame != &frame_d1badd3898339991bfdc4579ffa91ae1->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_d1badd3898339991bfdc4579ffa91ae1, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_d1badd3898339991bfdc4579ffa91ae1, - type_description_1, - par_self, - par_x, - var_new_x_shape - ); - - - // Release cached frame if used for exception. - if (frame_d1badd3898339991bfdc4579ffa91ae1 == cache_frame_d1badd3898339991bfdc4579ffa91ae1) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_d1badd3898339991bfdc4579ffa91ae1); - cache_frame_d1badd3898339991bfdc4579ffa91ae1 = NULL; - } - - assertFrameObject(frame_d1badd3898339991bfdc4579ffa91ae1); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_x); - par_x = NULL; - CHECK_OBJECT(var_new_x_shape); - Py_DECREF(var_new_x_shape); - var_new_x_shape = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_x); - par_x = NULL; - Py_XDECREF(var_new_x_shape); - var_new_x_shape = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__9_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_head_mask = python_pars[3]; - PyObject *par_encoder_hidden_states = python_pars[4]; - PyObject *par_encoder_attention_mask = python_pars[5]; - PyObject *par_past_key_value = python_pars[6]; - PyObject *par_output_attentions = python_pars[7]; - PyObject *var_is_cross_attention = NULL; - PyObject *var_key_layer = NULL; - PyObject *var_value_layer = NULL; - PyObject *var_mixed_query_layer = NULL; - PyObject *var_query_layer = NULL; - PyObject *var_attention_scores = NULL; - PyObject *var_seq_length = NULL; - PyObject *var_position_ids_l = NULL; - PyObject *var_position_ids_r = NULL; - PyObject *var_distance = NULL; - PyObject *var_positional_embedding = NULL; - PyObject *var_relative_position_scores = NULL; - PyObject *var_relative_position_scores_query = NULL; - PyObject *var_relative_position_scores_key = NULL; - PyObject *var_attention_probs = NULL; - PyObject *var_attention_probs_dropped = NULL; - PyObject *var_context_layer = NULL; - PyObject *var_new_context_layer_shape = NULL; - PyObject *var_outputs = NULL; - struct Nuitka_FrameObject *frame_222d3cb8bbe72424730d64c2fb38796b; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - static struct Nuitka_FrameObject *cache_frame_222d3cb8bbe72424730d64c2fb38796b = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - { - PyObject *tmp_assign_source_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_compexpr_left_1 = par_encoder_hidden_states; - tmp_compexpr_right_1 = Py_None; - tmp_assign_source_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? Py_True : Py_False; - assert(var_is_cross_attention == NULL); - Py_INCREF(tmp_assign_source_1); - var_is_cross_attention = tmp_assign_source_1; - } - // Tried code: - if (isFrameUnusable(cache_frame_222d3cb8bbe72424730d64c2fb38796b)) { - Py_XDECREF(cache_frame_222d3cb8bbe72424730d64c2fb38796b); - -#if _DEBUG_REFCOUNTS - if (cache_frame_222d3cb8bbe72424730d64c2fb38796b == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_222d3cb8bbe72424730d64c2fb38796b = MAKE_FUNCTION_FRAME(codeobj_222d3cb8bbe72424730d64c2fb38796b, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_222d3cb8bbe72424730d64c2fb38796b->m_type_description == NULL); - frame_222d3cb8bbe72424730d64c2fb38796b = cache_frame_222d3cb8bbe72424730d64c2fb38796b; - - // Push the new frame as the currently active one. - pushFrameStack(frame_222d3cb8bbe72424730d64c2fb38796b); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_222d3cb8bbe72424730d64c2fb38796b) == 2); // Frame stack - - // Framed code: - { - bool tmp_condition_result_1; - CHECK_OBJECT(var_is_cross_attention); - tmp_condition_result_1 = CHECK_IF_TRUE(var_is_cross_attention) == 1; - if (tmp_condition_result_1 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_2; - CHECK_OBJECT(par_self); - tmp_expression_name_1 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[59]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 186; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 186; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_args_element_name_2 = par_encoder_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 186; - tmp_args_element_name_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[44], tmp_args_element_name_2); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 186; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 186; - tmp_assign_source_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 186; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_key_layer == NULL); - var_key_layer = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_3; - PyObject *tmp_args_element_name_4; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_2 = par_self; - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[59]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_self; - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[45]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_encoder_hidden_states == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[60]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_4 = par_encoder_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 187; - tmp_args_element_name_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_4); - Py_DECREF(tmp_called_name_3); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 187; - tmp_assign_source_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 187; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_value_layer == NULL); - var_value_layer = tmp_assign_source_3; - } - { - PyObject *tmp_assign_source_4; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_assign_source_4 = par_encoder_attention_mask; - { - PyObject *old = par_attention_mask; - assert(old != NULL); - par_attention_mask = tmp_assign_source_4; - Py_INCREF(par_attention_mask); - Py_DECREF(old); - } - - } - goto branch_end_1; - branch_no_1:; - { - bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - CHECK_OBJECT(par_past_key_value); - tmp_compexpr_left_2 = par_past_key_value; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_2 = (tmp_compexpr_left_2 != tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_2 != false) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_assign_source_5; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_4; - PyObject *tmp_args_element_name_5; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_6; - CHECK_OBJECT(par_self); - tmp_expression_name_4 = par_self; - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[59]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 190; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 190; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_6 = par_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 190; - tmp_args_element_name_5 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[44], tmp_args_element_name_6); - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 190; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 190; - tmp_assign_source_5 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_4, tmp_args_element_name_5); - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_5); - if (tmp_assign_source_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 190; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_key_layer == NULL); - var_key_layer = tmp_assign_source_5; - } - { - PyObject *tmp_assign_source_6; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_5; - PyObject *tmp_args_element_name_7; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_6; - PyObject *tmp_args_element_name_8; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_5 = par_self; - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[59]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_self; - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[45]); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_hidden_states == NULL) { - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_called_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_8 = par_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 191; - tmp_args_element_name_7 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_6, tmp_args_element_name_8); - Py_DECREF(tmp_called_name_6); - if (tmp_args_element_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 191; - tmp_assign_source_6 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_5, tmp_args_element_name_7); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_7); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 191; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_value_layer == NULL); - var_value_layer = tmp_assign_source_6; - } - { - PyObject *tmp_assign_source_7; - PyObject *tmp_called_name_7; - PyObject *tmp_expression_name_7; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_list_element_1; - PyObject *tmp_expression_name_8; - PyObject *tmp_subscript_name_1; - PyObject *tmp_kwargs_name_1; - tmp_expression_name_7 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_7 == NULL)) { - tmp_expression_name_7 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 192; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[33]); - if (tmp_called_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 192; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_past_key_value); - tmp_expression_name_8 = par_past_key_value; - tmp_subscript_name_1 = mod_consts[29]; - tmp_list_element_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_8, tmp_subscript_name_1, 0); - if (tmp_list_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_7); - - exception_lineno = 192; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_1 = PyList_New(2); - PyList_SET_ITEM(tmp_tuple_element_1, 0, tmp_list_element_1); - CHECK_OBJECT(var_key_layer); - tmp_list_element_1 = var_key_layer; - PyList_SET_ITEM0(tmp_tuple_element_1, 1, tmp_list_element_1); - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[62]); - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 192; - tmp_assign_source_7 = CALL_FUNCTION(tmp_called_name_7, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 192; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_key_layer; - var_key_layer = tmp_assign_source_7; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_8; - PyObject *tmp_called_name_8; - PyObject *tmp_expression_name_9; - PyObject *tmp_args_name_2; - PyObject *tmp_tuple_element_2; - PyObject *tmp_list_element_2; - PyObject *tmp_expression_name_10; - PyObject *tmp_subscript_name_2; - PyObject *tmp_kwargs_name_2; - tmp_expression_name_9 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_9 == NULL)) { - tmp_expression_name_9 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 193; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_8 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[33]); - if (tmp_called_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 193; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_past_key_value); - tmp_expression_name_10 = par_past_key_value; - tmp_subscript_name_2 = mod_consts[28]; - tmp_list_element_2 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_10, tmp_subscript_name_2, 1); - if (tmp_list_element_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_8); - - exception_lineno = 193; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_2 = PyList_New(2); - PyList_SET_ITEM(tmp_tuple_element_2, 0, tmp_list_element_2); - CHECK_OBJECT(var_value_layer); - tmp_list_element_2 = var_value_layer; - PyList_SET_ITEM0(tmp_tuple_element_2, 1, tmp_list_element_2); - tmp_args_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_2, 0, tmp_tuple_element_2); - tmp_kwargs_name_2 = PyDict_Copy(mod_consts[62]); - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 193; - tmp_assign_source_8 = CALL_FUNCTION(tmp_called_name_8, tmp_args_name_2, tmp_kwargs_name_2); - Py_DECREF(tmp_called_name_8); - Py_DECREF(tmp_args_name_2); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 193; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_value_layer; - var_value_layer = tmp_assign_source_8; - Py_XDECREF(old); - } - - } - goto branch_end_2; - branch_no_2:; - { - PyObject *tmp_assign_source_9; - PyObject *tmp_called_name_9; - PyObject *tmp_expression_name_11; - PyObject *tmp_args_element_name_9; - PyObject *tmp_called_instance_3; - PyObject *tmp_args_element_name_10; - CHECK_OBJECT(par_self); - tmp_expression_name_11 = par_self; - tmp_called_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[59]); - if (tmp_called_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 195; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_9); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 195; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_3 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_10 = par_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 195; - tmp_args_element_name_9 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_3, mod_consts[44], tmp_args_element_name_10); - if (tmp_args_element_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_9); - - exception_lineno = 195; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 195; - tmp_assign_source_9 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_9, tmp_args_element_name_9); - Py_DECREF(tmp_called_name_9); - Py_DECREF(tmp_args_element_name_9); - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 195; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_key_layer == NULL); - var_key_layer = tmp_assign_source_9; - } - { - PyObject *tmp_assign_source_10; - PyObject *tmp_called_name_10; - PyObject *tmp_expression_name_12; - PyObject *tmp_args_element_name_11; - PyObject *tmp_called_name_11; - PyObject *tmp_expression_name_13; - PyObject *tmp_args_element_name_12; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_12 = par_self; - tmp_called_name_10 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[59]); - if (tmp_called_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_10); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_13 = par_self; - tmp_called_name_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[45]); - if (tmp_called_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_10); - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_hidden_states == NULL) { - Py_DECREF(tmp_called_name_10); - Py_DECREF(tmp_called_name_11); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_12 = par_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 196; - tmp_args_element_name_11 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_11, tmp_args_element_name_12); - Py_DECREF(tmp_called_name_11); - if (tmp_args_element_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_10); - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 196; - tmp_assign_source_10 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_10, tmp_args_element_name_11); - Py_DECREF(tmp_called_name_10); - Py_DECREF(tmp_args_element_name_11); - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 196; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_value_layer == NULL); - var_value_layer = tmp_assign_source_10; - } - branch_end_2:; - branch_end_1:; - { - PyObject *tmp_assign_source_11; - PyObject *tmp_called_name_12; - PyObject *tmp_expression_name_14; - PyObject *tmp_args_element_name_13; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 198; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_14 = par_self; - tmp_called_name_12 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[42]); - if (tmp_called_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 198; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_hidden_states == NULL) { - Py_DECREF(tmp_called_name_12); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 198; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_13 = par_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 198; - tmp_assign_source_11 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_12, tmp_args_element_name_13); - Py_DECREF(tmp_called_name_12); - if (tmp_assign_source_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 198; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_mixed_query_layer == NULL); - var_mixed_query_layer = tmp_assign_source_11; - } - { - PyObject *tmp_assign_source_12; - PyObject *tmp_called_instance_4; - PyObject *tmp_args_element_name_14; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 200; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_4 = par_self; - CHECK_OBJECT(var_mixed_query_layer); - tmp_args_element_name_14 = var_mixed_query_layer; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 200; - tmp_assign_source_12 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_4, mod_consts[59], tmp_args_element_name_14); - if (tmp_assign_source_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 200; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_query_layer == NULL); - var_query_layer = tmp_assign_source_12; - } - { - PyObject *tmp_assign_source_13; - PyObject *tmp_tuple_element_3; - if (var_key_layer == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[63]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 202; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_3 = var_key_layer; - tmp_assign_source_13 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_assign_source_13, 0, tmp_tuple_element_3); - if (var_value_layer == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[64]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 202; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_3 = var_value_layer; - PyTuple_SET_ITEM0(tmp_assign_source_13, 1, tmp_tuple_element_3); - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_assign_source_13); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - { - PyObject *old = par_past_key_value; - assert(old != NULL); - par_past_key_value = tmp_assign_source_13; - Py_DECREF(old); - } - - } - { - PyObject *tmp_assign_source_14; - PyObject *tmp_called_name_13; - PyObject *tmp_expression_name_15; - PyObject *tmp_args_element_name_15; - PyObject *tmp_args_element_name_16; - PyObject *tmp_called_instance_5; - tmp_expression_name_15 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_15 == NULL)) { - tmp_expression_name_15 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 205; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_13 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[65]); - if (tmp_called_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 205; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_query_layer); - tmp_args_element_name_15 = var_query_layer; - if (var_key_layer == NULL) { - Py_DECREF(tmp_called_name_13); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[63]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 205; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_5 = var_key_layer; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 205; - tmp_args_element_name_16 = CALL_METHOD_WITH_ARGS2( - tmp_called_instance_5, - mod_consts[66], - &PyTuple_GET_ITEM(mod_consts[67], 0) - ); - - if (tmp_args_element_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_13); - - exception_lineno = 205; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 205; - { - PyObject *call_args[] = {tmp_args_element_name_15, tmp_args_element_name_16}; - tmp_assign_source_14 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_13, call_args); - } - - Py_DECREF(tmp_called_name_13); - Py_DECREF(tmp_args_element_name_16); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 205; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_attention_scores == NULL); - var_attention_scores = tmp_assign_source_14; - } - { - nuitka_bool tmp_condition_result_3; - int tmp_or_left_truth_1; - nuitka_bool tmp_or_left_value_1; - nuitka_bool tmp_or_right_value_1; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - PyObject *tmp_expression_name_16; - PyObject *tmp_tmp_or_left_value_1_object_1; - int tmp_truth_name_1; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - PyObject *tmp_expression_name_17; - PyObject *tmp_tmp_or_right_value_1_object_1; - int tmp_truth_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 208; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_16 = par_self; - tmp_compexpr_left_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_16, mod_consts[24]); - if (tmp_compexpr_left_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 208; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_3 = mod_consts[47]; - tmp_tmp_or_left_value_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_3, tmp_compexpr_right_3); - Py_DECREF(tmp_compexpr_left_3); - if (tmp_tmp_or_left_value_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 208; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_tmp_or_left_value_1_object_1); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_or_left_value_1_object_1); - - exception_lineno = 208; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_or_left_value_1 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_or_left_value_1_object_1); - tmp_or_left_truth_1 = tmp_or_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_or_left_truth_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 209; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (tmp_or_left_truth_1 == 1) { - goto or_left_1; - } else { - goto or_right_1; - } - or_right_1:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 209; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_17 = par_self; - tmp_compexpr_left_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[24]); - if (tmp_compexpr_left_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 209; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_4 = mod_consts[48]; - tmp_tmp_or_right_value_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_4, tmp_compexpr_right_4); - Py_DECREF(tmp_compexpr_left_4); - if (tmp_tmp_or_right_value_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 209; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_2 = CHECK_IF_TRUE(tmp_tmp_or_right_value_1_object_1); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_or_right_value_1_object_1); - - exception_lineno = 209; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_or_right_value_1 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_or_right_value_1_object_1); - tmp_condition_result_3 = tmp_or_right_value_1; - goto or_end_1; - or_left_1:; - tmp_condition_result_3 = tmp_or_left_value_1; - or_end_1:; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_assign_source_15; - PyObject *tmp_expression_name_18; - PyObject *tmp_called_instance_6; - PyObject *tmp_subscript_name_3; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 211; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_6 = par_hidden_states; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 211; - tmp_expression_name_18 = CALL_METHOD_NO_ARGS(tmp_called_instance_6, mod_consts[27]); - if (tmp_expression_name_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 211; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_3 = mod_consts[28]; - tmp_assign_source_15 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_18, tmp_subscript_name_3, 1); - Py_DECREF(tmp_expression_name_18); - if (tmp_assign_source_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 211; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_seq_length == NULL); - var_seq_length = tmp_assign_source_15; - } - { - PyObject *tmp_assign_source_16; - PyObject *tmp_called_instance_7; - PyObject *tmp_called_name_14; - PyObject *tmp_expression_name_19; - PyObject *tmp_args_name_3; - PyObject *tmp_tuple_element_4; - PyObject *tmp_kwargs_name_3; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - PyObject *tmp_expression_name_20; - tmp_expression_name_19 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_19 == NULL)) { - tmp_expression_name_19 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 212; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_14 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[21]); - if (tmp_called_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 212; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_seq_length); - tmp_tuple_element_4 = var_seq_length; - tmp_args_name_3 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_3, 0, tmp_tuple_element_4); - tmp_dict_key_1 = mod_consts[68]; - tmp_expression_name_20 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_20 == NULL)) { - tmp_expression_name_20 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_14); - Py_DECREF(tmp_args_name_3); - - exception_lineno = 213; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[69]); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_14); - Py_DECREF(tmp_args_name_3); - - exception_lineno = 213; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_3 = _PyDict_NewPresized( 2 ); - { - PyObject *tmp_expression_name_21; - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[70]; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 213; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_expression_name_21 = par_hidden_states; - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_21, mod_consts[70]); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 213; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_called_name_14); - Py_DECREF(tmp_args_name_3); - Py_DECREF(tmp_kwargs_name_3); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 212; - tmp_called_instance_7 = CALL_FUNCTION(tmp_called_name_14, tmp_args_name_3, tmp_kwargs_name_3); - Py_DECREF(tmp_called_name_14); - Py_DECREF(tmp_args_name_3); - Py_DECREF(tmp_kwargs_name_3); - if (tmp_called_instance_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 212; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 212; - tmp_assign_source_16 = CALL_METHOD_WITH_ARGS2( - tmp_called_instance_7, - mod_consts[56], - &PyTuple_GET_ITEM(mod_consts[71], 0) - ); - - Py_DECREF(tmp_called_instance_7); - if (tmp_assign_source_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 212; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_position_ids_l == NULL); - var_position_ids_l = tmp_assign_source_16; - } - { - PyObject *tmp_assign_source_17; - PyObject *tmp_called_instance_8; - PyObject *tmp_called_name_15; - PyObject *tmp_expression_name_22; - PyObject *tmp_args_name_4; - PyObject *tmp_tuple_element_5; - PyObject *tmp_kwargs_name_4; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - PyObject *tmp_expression_name_23; - tmp_expression_name_22 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_22 == NULL)) { - tmp_expression_name_22 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_22 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 215; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_15 = LOOKUP_ATTRIBUTE(tmp_expression_name_22, mod_consts[21]); - if (tmp_called_name_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 215; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (var_seq_length == NULL) { - Py_DECREF(tmp_called_name_15); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[72]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 216; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_5 = var_seq_length; - tmp_args_name_4 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_4, 0, tmp_tuple_element_5); - tmp_dict_key_2 = mod_consts[68]; - tmp_expression_name_23 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_23 == NULL)) { - tmp_expression_name_23 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_15); - Py_DECREF(tmp_args_name_4); - - exception_lineno = 216; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[69]); - if (tmp_dict_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_15); - Py_DECREF(tmp_args_name_4); - - exception_lineno = 216; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_4 = _PyDict_NewPresized( 2 ); - { - PyObject *tmp_expression_name_24; - tmp_res = PyDict_SetItem(tmp_kwargs_name_4, tmp_dict_key_2, tmp_dict_value_2); - Py_DECREF(tmp_dict_value_2); - assert(!(tmp_res != 0)); - tmp_dict_key_2 = mod_consts[70]; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 216; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto dict_build_exception_2; - } - - tmp_expression_name_24 = par_hidden_states; - tmp_dict_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_24, mod_consts[70]); - if (tmp_dict_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 216; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto dict_build_exception_2; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_4, tmp_dict_key_2, tmp_dict_value_2); - Py_DECREF(tmp_dict_value_2); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_2; - // Exception handling pass through code for dict_build: - dict_build_exception_2:; - Py_DECREF(tmp_called_name_15); - Py_DECREF(tmp_args_name_4); - Py_DECREF(tmp_kwargs_name_4); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_2:; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 215; - tmp_called_instance_8 = CALL_FUNCTION(tmp_called_name_15, tmp_args_name_4, tmp_kwargs_name_4); - Py_DECREF(tmp_called_name_15); - Py_DECREF(tmp_args_name_4); - Py_DECREF(tmp_kwargs_name_4); - if (tmp_called_instance_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 215; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 215; - tmp_assign_source_17 = CALL_METHOD_WITH_ARGS2( - tmp_called_instance_8, - mod_consts[56], - &PyTuple_GET_ITEM(mod_consts[73], 0) - ); - - Py_DECREF(tmp_called_instance_8); - if (tmp_assign_source_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 215; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_position_ids_r == NULL); - var_position_ids_r = tmp_assign_source_17; - } - { - PyObject *tmp_assign_source_18; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - CHECK_OBJECT(var_position_ids_l); - tmp_left_name_1 = var_position_ids_l; - CHECK_OBJECT(var_position_ids_r); - tmp_right_name_1 = var_position_ids_r; - tmp_assign_source_18 = BINARY_OPERATION_SUB_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - if (tmp_assign_source_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 218; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_distance == NULL); - var_distance = tmp_assign_source_18; - } - { - PyObject *tmp_assign_source_19; - PyObject *tmp_called_name_16; - PyObject *tmp_expression_name_25; - PyObject *tmp_args_element_name_17; - PyObject *tmp_left_name_2; - PyObject *tmp_left_name_3; - PyObject *tmp_right_name_2; - PyObject *tmp_expression_name_26; - PyObject *tmp_right_name_3; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 219; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_25 = par_self; - tmp_called_name_16 = LOOKUP_ATTRIBUTE(tmp_expression_name_25, mod_consts[50]); - if (tmp_called_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 219; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_distance); - tmp_left_name_3 = var_distance; - if (par_self == NULL) { - Py_DECREF(tmp_called_name_16); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 220; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_26 = par_self; - tmp_right_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_26, mod_consts[10]); - if (tmp_right_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_16); - - exception_lineno = 220; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_left_name_2 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_3, tmp_right_name_2); - Py_DECREF(tmp_right_name_2); - if (tmp_left_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_16); - - exception_lineno = 220; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_right_name_3 = mod_consts[28]; - tmp_args_element_name_17 = BINARY_OPERATION_SUB_OBJECT_OBJECT_LONG(tmp_left_name_2, tmp_right_name_3); - Py_DECREF(tmp_left_name_2); - if (tmp_args_element_name_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_16); - - exception_lineno = 220; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 219; - tmp_assign_source_19 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_16, tmp_args_element_name_17); - Py_DECREF(tmp_called_name_16); - Py_DECREF(tmp_args_element_name_17); - if (tmp_assign_source_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 219; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_positional_embedding == NULL); - var_positional_embedding = tmp_assign_source_19; - } - { - PyObject *tmp_assign_source_20; - PyObject *tmp_called_name_17; - PyObject *tmp_expression_name_27; - PyObject *tmp_kwargs_name_5; - PyObject *tmp_dict_key_3; - PyObject *tmp_dict_value_3; - PyObject *tmp_expression_name_28; - CHECK_OBJECT(var_positional_embedding); - tmp_expression_name_27 = var_positional_embedding; - tmp_called_name_17 = LOOKUP_ATTRIBUTE(tmp_expression_name_27, mod_consts[74]); - if (tmp_called_name_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 222; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_3 = mod_consts[68]; - if (var_query_layer == NULL) { - Py_DECREF(tmp_called_name_17); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[75]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 223; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_28 = var_query_layer; - tmp_dict_value_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_28, mod_consts[68]); - if (tmp_dict_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_17); - - exception_lineno = 223; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_5 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_3, tmp_dict_value_3); - Py_DECREF(tmp_dict_value_3); - assert(!(tmp_res != 0)); - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 222; - tmp_assign_source_20 = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_17, tmp_kwargs_name_5); - Py_DECREF(tmp_called_name_17); - Py_DECREF(tmp_kwargs_name_5); - if (tmp_assign_source_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 222; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_positional_embedding; - var_positional_embedding = tmp_assign_source_20; - Py_XDECREF(old); - } - - } - { - nuitka_bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_5; - PyObject *tmp_compexpr_right_5; - PyObject *tmp_expression_name_29; - PyObject *tmp_tmp_condition_result_4_object_1; - int tmp_truth_name_3; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 226; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_29 = par_self; - tmp_compexpr_left_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_29, mod_consts[24]); - if (tmp_compexpr_left_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 226; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_5 = mod_consts[47]; - tmp_tmp_condition_result_4_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_5, tmp_compexpr_right_5); - Py_DECREF(tmp_compexpr_left_5); - if (tmp_tmp_condition_result_4_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 226; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_3 = CHECK_IF_TRUE(tmp_tmp_condition_result_4_object_1); - if (tmp_truth_name_3 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_4_object_1); - - exception_lineno = 226; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_4 = tmp_truth_name_3 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_4_object_1); - if (tmp_condition_result_4 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - } - branch_yes_4:; - { - PyObject *tmp_assign_source_21; - PyObject *tmp_called_name_18; - PyObject *tmp_expression_name_30; - PyObject *tmp_args_element_name_18; - PyObject *tmp_args_element_name_19; - PyObject *tmp_args_element_name_20; - tmp_expression_name_30 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_30 == NULL)) { - tmp_expression_name_30 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_30 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 227; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_18 = LOOKUP_ATTRIBUTE(tmp_expression_name_30, mod_consts[76]); - if (tmp_called_name_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 227; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_18 = mod_consts[77]; - if (var_query_layer == NULL) { - Py_DECREF(tmp_called_name_18); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[75]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 228; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_19 = var_query_layer; - CHECK_OBJECT(var_positional_embedding); - tmp_args_element_name_20 = var_positional_embedding; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 227; - { - PyObject *call_args[] = {tmp_args_element_name_18, tmp_args_element_name_19, tmp_args_element_name_20}; - tmp_assign_source_21 = CALL_FUNCTION_WITH_ARGS3(tmp_called_name_18, call_args); - } - - Py_DECREF(tmp_called_name_18); - if (tmp_assign_source_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 227; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_relative_position_scores == NULL); - var_relative_position_scores = tmp_assign_source_21; - } - { - PyObject *tmp_assign_source_22; - PyObject *tmp_left_name_4; - PyObject *tmp_right_name_4; - CHECK_OBJECT(var_attention_scores); - tmp_left_name_4 = var_attention_scores; - CHECK_OBJECT(var_relative_position_scores); - tmp_right_name_4 = var_relative_position_scores; - tmp_assign_source_22 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_4, tmp_right_name_4); - if (tmp_assign_source_22 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 230; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_attention_scores; - var_attention_scores = tmp_assign_source_22; - Py_XDECREF(old); - } - - } - goto branch_end_4; - branch_no_4:; - { - nuitka_bool tmp_condition_result_5; - PyObject *tmp_compexpr_left_6; - PyObject *tmp_compexpr_right_6; - PyObject *tmp_expression_name_31; - PyObject *tmp_tmp_condition_result_5_object_1; - int tmp_truth_name_4; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 231; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_31 = par_self; - tmp_compexpr_left_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_31, mod_consts[24]); - if (tmp_compexpr_left_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 231; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_6 = mod_consts[48]; - tmp_tmp_condition_result_5_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_6, tmp_compexpr_right_6); - Py_DECREF(tmp_compexpr_left_6); - if (tmp_tmp_condition_result_5_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 231; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_4 = CHECK_IF_TRUE(tmp_tmp_condition_result_5_object_1); - if (tmp_truth_name_4 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_5_object_1); - - exception_lineno = 231; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_5 = tmp_truth_name_4 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_5_object_1); - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - { - PyObject *tmp_assign_source_23; - PyObject *tmp_called_name_19; - PyObject *tmp_expression_name_32; - PyObject *tmp_args_element_name_21; - PyObject *tmp_args_element_name_22; - PyObject *tmp_args_element_name_23; - tmp_expression_name_32 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_32 == NULL)) { - tmp_expression_name_32 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_32 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 232; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_19 = LOOKUP_ATTRIBUTE(tmp_expression_name_32, mod_consts[76]); - if (tmp_called_name_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 232; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_21 = mod_consts[77]; - if (var_query_layer == NULL) { - Py_DECREF(tmp_called_name_19); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[75]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 233; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_22 = var_query_layer; - CHECK_OBJECT(var_positional_embedding); - tmp_args_element_name_23 = var_positional_embedding; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 232; - { - PyObject *call_args[] = {tmp_args_element_name_21, tmp_args_element_name_22, tmp_args_element_name_23}; - tmp_assign_source_23 = CALL_FUNCTION_WITH_ARGS3(tmp_called_name_19, call_args); - } - - Py_DECREF(tmp_called_name_19); - if (tmp_assign_source_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 232; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_relative_position_scores_query == NULL); - var_relative_position_scores_query = tmp_assign_source_23; - } - { - PyObject *tmp_assign_source_24; - PyObject *tmp_called_name_20; - PyObject *tmp_expression_name_33; - PyObject *tmp_args_element_name_24; - PyObject *tmp_args_element_name_25; - PyObject *tmp_args_element_name_26; - tmp_expression_name_33 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_33 == NULL)) { - tmp_expression_name_33 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_33 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 235; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_20 = LOOKUP_ATTRIBUTE(tmp_expression_name_33, mod_consts[76]); - if (tmp_called_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 235; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_24 = mod_consts[78]; - if (var_key_layer == NULL) { - Py_DECREF(tmp_called_name_20); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[63]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 236; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_25 = var_key_layer; - if (var_positional_embedding == NULL) { - Py_DECREF(tmp_called_name_20); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[79]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 236; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_26 = var_positional_embedding; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 235; - { - PyObject *call_args[] = {tmp_args_element_name_24, tmp_args_element_name_25, tmp_args_element_name_26}; - tmp_assign_source_24 = CALL_FUNCTION_WITH_ARGS3(tmp_called_name_20, call_args); - } - - Py_DECREF(tmp_called_name_20); - if (tmp_assign_source_24 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 235; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_relative_position_scores_key == NULL); - var_relative_position_scores_key = tmp_assign_source_24; - } - { - PyObject *tmp_assign_source_25; - PyObject *tmp_left_name_5; - PyObject *tmp_left_name_6; - PyObject *tmp_right_name_5; - PyObject *tmp_right_name_6; - CHECK_OBJECT(var_attention_scores); - tmp_left_name_6 = var_attention_scores; - CHECK_OBJECT(var_relative_position_scores_query); - tmp_right_name_5 = var_relative_position_scores_query; - tmp_left_name_5 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_6, tmp_right_name_5); - if (tmp_left_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 239; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_relative_position_scores_key); - tmp_right_name_6 = var_relative_position_scores_key; - tmp_assign_source_25 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_5, tmp_right_name_6); - Py_DECREF(tmp_left_name_5); - if (tmp_assign_source_25 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 239; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_attention_scores; - var_attention_scores = tmp_assign_source_25; - Py_XDECREF(old); - } - - } - branch_no_5:; - branch_end_4:; - branch_no_3:; - { - PyObject *tmp_assign_source_26; - PyObject *tmp_left_name_7; - PyObject *tmp_right_name_7; - PyObject *tmp_called_name_21; - PyObject *tmp_expression_name_34; - PyObject *tmp_args_element_name_27; - PyObject *tmp_expression_name_35; - if (var_attention_scores == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[80]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_left_name_7 = var_attention_scores; - tmp_expression_name_34 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[81]); - - if (unlikely(tmp_expression_name_34 == NULL)) { - tmp_expression_name_34 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[81]); - } - - if (tmp_expression_name_34 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_21 = LOOKUP_ATTRIBUTE(tmp_expression_name_34, mod_consts[82]); - if (tmp_called_name_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_21); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_35 = par_self; - tmp_args_element_name_27 = LOOKUP_ATTRIBUTE(tmp_expression_name_35, mod_consts[39]); - if (tmp_args_element_name_27 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_21); - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 244; - tmp_right_name_7 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_21, tmp_args_element_name_27); - Py_DECREF(tmp_called_name_21); - Py_DECREF(tmp_args_element_name_27); - if (tmp_right_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_26 = BINARY_OPERATION_TRUEDIV_OBJECT_OBJECT_OBJECT(tmp_left_name_7, tmp_right_name_7); - Py_DECREF(tmp_right_name_7); - if (tmp_assign_source_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 244; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_attention_scores; - var_attention_scores = tmp_assign_source_26; - Py_XDECREF(old); - } - - } - { - bool tmp_condition_result_6; - PyObject *tmp_compexpr_left_7; - PyObject *tmp_compexpr_right_7; - CHECK_OBJECT(par_attention_mask); - tmp_compexpr_left_7 = par_attention_mask; - tmp_compexpr_right_7 = Py_None; - tmp_condition_result_6 = (tmp_compexpr_left_7 != tmp_compexpr_right_7) ? true : false; - if (tmp_condition_result_6 != false) { - goto branch_yes_6; - } else { - goto branch_no_6; - } - } - branch_yes_6:; - { - PyObject *tmp_assign_source_27; - PyObject *tmp_left_name_8; - PyObject *tmp_right_name_8; - CHECK_OBJECT(var_attention_scores); - tmp_left_name_8 = var_attention_scores; - CHECK_OBJECT(par_attention_mask); - tmp_right_name_8 = par_attention_mask; - tmp_assign_source_27 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_8, tmp_right_name_8); - if (tmp_assign_source_27 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 247; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_attention_scores; - var_attention_scores = tmp_assign_source_27; - Py_XDECREF(old); - } - - } - branch_no_6:; - { - PyObject *tmp_assign_source_28; - PyObject *tmp_called_name_22; - PyObject *tmp_called_name_23; - PyObject *tmp_expression_name_36; - PyObject *tmp_kwargs_name_6; - PyObject *tmp_args_element_name_28; - tmp_expression_name_36 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_36 == NULL)) { - tmp_expression_name_36 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_36 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 250; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_23 = LOOKUP_ATTRIBUTE(tmp_expression_name_36, mod_consts[83]); - if (tmp_called_name_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 250; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_6 = PyDict_Copy(mod_consts[84]); - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 250; - tmp_called_name_22 = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_23, tmp_kwargs_name_6); - Py_DECREF(tmp_called_name_23); - Py_DECREF(tmp_kwargs_name_6); - if (tmp_called_name_22 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 250; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_attention_scores); - tmp_args_element_name_28 = var_attention_scores; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 250; - tmp_assign_source_28 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_22, tmp_args_element_name_28); - Py_DECREF(tmp_called_name_22); - if (tmp_assign_source_28 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 250; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_attention_probs == NULL); - var_attention_probs = tmp_assign_source_28; - } - { - nuitka_bool tmp_condition_result_7; - int tmp_and_left_truth_1; - nuitka_bool tmp_and_left_value_1; - nuitka_bool tmp_and_right_value_1; - int tmp_truth_name_5; - PyObject *tmp_expression_name_37; - PyObject *tmp_attribute_value_1; - int tmp_truth_name_6; - CHECK_OBJECT(var_is_cross_attention); - tmp_truth_name_5 = CHECK_IF_TRUE(var_is_cross_attention); - assert(!(tmp_truth_name_5 == -1)); - tmp_and_left_value_1 = tmp_truth_name_5 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - tmp_and_left_truth_1 = tmp_and_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_and_left_truth_1 == 1) { - goto and_right_1; - } else { - goto and_left_1; - } - and_right_1:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 252; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_37 = par_self; - tmp_attribute_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_37, mod_consts[51]); - if (tmp_attribute_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 252; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_6 = CHECK_IF_TRUE(tmp_attribute_value_1); - if (tmp_truth_name_6 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_attribute_value_1); - - exception_lineno = 252; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_and_right_value_1 = tmp_truth_name_6 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_attribute_value_1); - tmp_condition_result_7 = tmp_and_right_value_1; - goto and_end_1; - and_left_1:; - tmp_condition_result_7 = tmp_and_left_value_1; - and_end_1:; - if (tmp_condition_result_7 == NUITKA_BOOL_TRUE) { - goto branch_yes_7; - } else { - goto branch_no_7; - } - } - branch_yes_7:; - { - PyObject *tmp_called_instance_9; - PyObject *tmp_call_result_1; - PyObject *tmp_args_element_name_29; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 253; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_9 = par_self; - CHECK_OBJECT(var_attention_probs); - tmp_args_element_name_29 = var_attention_probs; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 253; - tmp_call_result_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_9, mod_consts[85], tmp_args_element_name_29); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 253; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_called_name_24; - PyObject *tmp_expression_name_38; - PyObject *tmp_call_result_2; - PyObject *tmp_args_element_name_30; - PyObject *tmp_expression_name_39; - if (var_attention_probs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[86]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 254; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_38 = var_attention_probs; - tmp_called_name_24 = LOOKUP_ATTRIBUTE(tmp_expression_name_38, mod_consts[87]); - if (tmp_called_name_24 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 254; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_called_name_24); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 254; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_39 = par_self; - tmp_args_element_name_30 = LOOKUP_ATTRIBUTE(tmp_expression_name_39, mod_consts[88]); - if (tmp_args_element_name_30 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_24); - - exception_lineno = 254; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 254; - tmp_call_result_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_24, tmp_args_element_name_30); - Py_DECREF(tmp_called_name_24); - Py_DECREF(tmp_args_element_name_30); - if (tmp_call_result_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 254; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_2); - } - branch_no_7:; - { - PyObject *tmp_assign_source_29; - PyObject *tmp_called_name_25; - PyObject *tmp_expression_name_40; - PyObject *tmp_args_element_name_31; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 258; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_40 = par_self; - tmp_called_name_25 = LOOKUP_ATTRIBUTE(tmp_expression_name_40, mod_consts[17]); - if (tmp_called_name_25 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 258; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (var_attention_probs == NULL) { - Py_DECREF(tmp_called_name_25); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[86]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 258; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_31 = var_attention_probs; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 258; - tmp_assign_source_29 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_25, tmp_args_element_name_31); - Py_DECREF(tmp_called_name_25); - if (tmp_assign_source_29 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 258; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_attention_probs_dropped == NULL); - var_attention_probs_dropped = tmp_assign_source_29; - } - { - bool tmp_condition_result_8; - PyObject *tmp_compexpr_left_8; - PyObject *tmp_compexpr_right_8; - CHECK_OBJECT(par_head_mask); - tmp_compexpr_left_8 = par_head_mask; - tmp_compexpr_right_8 = Py_None; - tmp_condition_result_8 = (tmp_compexpr_left_8 != tmp_compexpr_right_8) ? true : false; - if (tmp_condition_result_8 != false) { - goto branch_yes_8; - } else { - goto branch_no_8; - } - } - branch_yes_8:; - { - PyObject *tmp_assign_source_30; - PyObject *tmp_left_name_9; - PyObject *tmp_right_name_9; - CHECK_OBJECT(var_attention_probs_dropped); - tmp_left_name_9 = var_attention_probs_dropped; - CHECK_OBJECT(par_head_mask); - tmp_right_name_9 = par_head_mask; - tmp_assign_source_30 = BINARY_OPERATION_MULT_OBJECT_OBJECT_OBJECT(tmp_left_name_9, tmp_right_name_9); - if (tmp_assign_source_30 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 262; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_attention_probs_dropped; - var_attention_probs_dropped = tmp_assign_source_30; - Py_XDECREF(old); - } - - } - branch_no_8:; - { - PyObject *tmp_assign_source_31; - PyObject *tmp_called_name_26; - PyObject *tmp_expression_name_41; - PyObject *tmp_args_element_name_32; - PyObject *tmp_args_element_name_33; - tmp_expression_name_41 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_41 == NULL)) { - tmp_expression_name_41 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_41 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 264; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_26 = LOOKUP_ATTRIBUTE(tmp_expression_name_41, mod_consts[65]); - if (tmp_called_name_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 264; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_attention_probs_dropped); - tmp_args_element_name_32 = var_attention_probs_dropped; - if (var_value_layer == NULL) { - Py_DECREF(tmp_called_name_26); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[64]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 264; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_33 = var_value_layer; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 264; - { - PyObject *call_args[] = {tmp_args_element_name_32, tmp_args_element_name_33}; - tmp_assign_source_31 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_26, call_args); - } - - Py_DECREF(tmp_called_name_26); - if (tmp_assign_source_31 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 264; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_context_layer == NULL); - var_context_layer = tmp_assign_source_31; - } - { - PyObject *tmp_assign_source_32; - PyObject *tmp_called_instance_10; - PyObject *tmp_called_instance_11; - CHECK_OBJECT(var_context_layer); - tmp_called_instance_11 = var_context_layer; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 266; - tmp_called_instance_10 = CALL_METHOD_WITH_ARGS4( - tmp_called_instance_11, - mod_consts[57], - &PyTuple_GET_ITEM(mod_consts[58], 0) - ); - - if (tmp_called_instance_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 266; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 266; - tmp_assign_source_32 = CALL_METHOD_NO_ARGS(tmp_called_instance_10, mod_consts[89]); - Py_DECREF(tmp_called_instance_10); - if (tmp_assign_source_32 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 266; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_context_layer; - var_context_layer = tmp_assign_source_32; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_33; - PyObject *tmp_left_name_10; - PyObject *tmp_expression_name_42; - PyObject *tmp_called_instance_12; - PyObject *tmp_subscript_name_4; - PyObject *tmp_right_name_10; - PyObject *tmp_tuple_element_6; - PyObject *tmp_expression_name_43; - CHECK_OBJECT(var_context_layer); - tmp_called_instance_12 = var_context_layer; - frame_222d3cb8bbe72424730d64c2fb38796b->m_frame.f_lineno = 267; - tmp_expression_name_42 = CALL_METHOD_NO_ARGS(tmp_called_instance_12, mod_consts[27]); - if (tmp_expression_name_42 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 267; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_4 = mod_consts[90]; - tmp_left_name_10 = LOOKUP_SUBSCRIPT(tmp_expression_name_42, tmp_subscript_name_4); - Py_DECREF(tmp_expression_name_42); - if (tmp_left_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 267; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_left_name_10); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 267; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_43 = par_self; - tmp_tuple_element_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_43, mod_consts[40]); - if (tmp_tuple_element_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_10); - - exception_lineno = 267; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_right_name_10 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_right_name_10, 0, tmp_tuple_element_6); - tmp_assign_source_33 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_10, tmp_right_name_10); - Py_DECREF(tmp_left_name_10); - Py_DECREF(tmp_right_name_10); - if (tmp_assign_source_33 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 267; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_new_context_layer_shape == NULL); - var_new_context_layer_shape = tmp_assign_source_33; - } - { - PyObject *tmp_assign_source_34; - PyObject *tmp_dircall_arg1_1; - PyObject *tmp_expression_name_44; - PyObject *tmp_dircall_arg2_1; - if (var_context_layer == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[91]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 268; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_44 = var_context_layer; - tmp_dircall_arg1_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_44, mod_consts[56]); - if (tmp_dircall_arg1_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 268; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_new_context_layer_shape); - tmp_dircall_arg2_1 = var_new_context_layer_shape; - Py_INCREF(tmp_dircall_arg2_1); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_1, tmp_dircall_arg2_1}; - tmp_assign_source_34 = impl_models$$$function__2_complex_call_helper_star_list(dir_call_args); - } - if (tmp_assign_source_34 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 268; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_context_layer; - var_context_layer = tmp_assign_source_34; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_35; - nuitka_bool tmp_condition_result_9; - int tmp_truth_name_7; - PyObject *tmp_tuple_element_7; - PyObject *tmp_tuple_element_8; - CHECK_OBJECT(par_output_attentions); - tmp_truth_name_7 = CHECK_IF_TRUE(par_output_attentions); - if (tmp_truth_name_7 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 271; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_9 = tmp_truth_name_7 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_9 == NUITKA_BOOL_TRUE) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - CHECK_OBJECT(var_context_layer); - tmp_tuple_element_7 = var_context_layer; - tmp_assign_source_35 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_assign_source_35, 0, tmp_tuple_element_7); - if (var_attention_probs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[86]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 271; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto tuple_build_exception_2; - } - - tmp_tuple_element_7 = var_attention_probs; - PyTuple_SET_ITEM0(tmp_assign_source_35, 1, tmp_tuple_element_7); - goto tuple_build_noexception_2; - // Exception handling pass through code for tuple_build: - tuple_build_exception_2:; - Py_DECREF(tmp_assign_source_35); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_2:; - goto condexpr_end_1; - condexpr_false_1:; - CHECK_OBJECT(var_context_layer); - tmp_tuple_element_8 = var_context_layer; - tmp_assign_source_35 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_assign_source_35, 0, tmp_tuple_element_8); - condexpr_end_1:; - assert(var_outputs == NULL); - var_outputs = tmp_assign_source_35; - } - { - PyObject *tmp_assign_source_36; - PyObject *tmp_left_name_11; - PyObject *tmp_right_name_11; - PyObject *tmp_tuple_element_9; - CHECK_OBJECT(var_outputs); - tmp_left_name_11 = var_outputs; - CHECK_OBJECT(par_past_key_value); - tmp_tuple_element_9 = par_past_key_value; - tmp_right_name_11 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_right_name_11, 0, tmp_tuple_element_9); - tmp_assign_source_36 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_11, tmp_right_name_11); - Py_DECREF(tmp_right_name_11); - if (tmp_assign_source_36 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 274; - type_description_1 = "ooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_outputs; - var_outputs = tmp_assign_source_36; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_222d3cb8bbe72424730d64c2fb38796b); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_222d3cb8bbe72424730d64c2fb38796b); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_222d3cb8bbe72424730d64c2fb38796b, exception_lineno); - } else if (exception_tb->tb_frame != &frame_222d3cb8bbe72424730d64c2fb38796b->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_222d3cb8bbe72424730d64c2fb38796b, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_222d3cb8bbe72424730d64c2fb38796b, - type_description_1, - par_self, - par_hidden_states, - par_attention_mask, - par_head_mask, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_past_key_value, - par_output_attentions, - var_is_cross_attention, - var_key_layer, - var_value_layer, - var_mixed_query_layer, - var_query_layer, - var_attention_scores, - var_seq_length, - var_position_ids_l, - var_position_ids_r, - var_distance, - var_positional_embedding, - var_relative_position_scores, - var_relative_position_scores_query, - var_relative_position_scores_key, - var_attention_probs, - var_attention_probs_dropped, - var_context_layer, - var_new_context_layer_shape, - var_outputs - ); - - - // Release cached frame if used for exception. - if (frame_222d3cb8bbe72424730d64c2fb38796b == cache_frame_222d3cb8bbe72424730d64c2fb38796b) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_222d3cb8bbe72424730d64c2fb38796b); - cache_frame_222d3cb8bbe72424730d64c2fb38796b = NULL; - } - - assertFrameObject(frame_222d3cb8bbe72424730d64c2fb38796b); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_outputs); - tmp_return_value = var_outputs; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - CHECK_OBJECT(par_encoder_attention_mask); - Py_DECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - CHECK_OBJECT(par_past_key_value); - Py_DECREF(par_past_key_value); - par_past_key_value = NULL; - CHECK_OBJECT(par_output_attentions); - Py_DECREF(par_output_attentions); - par_output_attentions = NULL; - CHECK_OBJECT(var_is_cross_attention); - Py_DECREF(var_is_cross_attention); - var_is_cross_attention = NULL; - Py_XDECREF(var_key_layer); - var_key_layer = NULL; - Py_XDECREF(var_value_layer); - var_value_layer = NULL; - Py_XDECREF(var_mixed_query_layer); - var_mixed_query_layer = NULL; - Py_XDECREF(var_query_layer); - var_query_layer = NULL; - Py_XDECREF(var_attention_scores); - var_attention_scores = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_position_ids_l); - var_position_ids_l = NULL; - Py_XDECREF(var_position_ids_r); - var_position_ids_r = NULL; - Py_XDECREF(var_distance); - var_distance = NULL; - Py_XDECREF(var_positional_embedding); - var_positional_embedding = NULL; - Py_XDECREF(var_relative_position_scores); - var_relative_position_scores = NULL; - Py_XDECREF(var_relative_position_scores_query); - var_relative_position_scores_query = NULL; - Py_XDECREF(var_relative_position_scores_key); - var_relative_position_scores_key = NULL; - Py_XDECREF(var_attention_probs); - var_attention_probs = NULL; - Py_XDECREF(var_attention_probs_dropped); - var_attention_probs_dropped = NULL; - CHECK_OBJECT(var_context_layer); - Py_DECREF(var_context_layer); - var_context_layer = NULL; - CHECK_OBJECT(var_new_context_layer_shape); - Py_DECREF(var_new_context_layer_shape); - var_new_context_layer_shape = NULL; - CHECK_OBJECT(var_outputs); - Py_DECREF(var_outputs); - var_outputs = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - CHECK_OBJECT(par_encoder_attention_mask); - Py_DECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - CHECK_OBJECT(par_past_key_value); - Py_DECREF(par_past_key_value); - par_past_key_value = NULL; - CHECK_OBJECT(par_output_attentions); - Py_DECREF(par_output_attentions); - par_output_attentions = NULL; - CHECK_OBJECT(var_is_cross_attention); - Py_DECREF(var_is_cross_attention); - var_is_cross_attention = NULL; - Py_XDECREF(var_key_layer); - var_key_layer = NULL; - Py_XDECREF(var_value_layer); - var_value_layer = NULL; - Py_XDECREF(var_mixed_query_layer); - var_mixed_query_layer = NULL; - Py_XDECREF(var_query_layer); - var_query_layer = NULL; - Py_XDECREF(var_attention_scores); - var_attention_scores = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_position_ids_l); - var_position_ids_l = NULL; - Py_XDECREF(var_position_ids_r); - var_position_ids_r = NULL; - Py_XDECREF(var_distance); - var_distance = NULL; - Py_XDECREF(var_positional_embedding); - var_positional_embedding = NULL; - Py_XDECREF(var_relative_position_scores); - var_relative_position_scores = NULL; - Py_XDECREF(var_relative_position_scores_query); - var_relative_position_scores_query = NULL; - Py_XDECREF(var_relative_position_scores_key); - var_relative_position_scores_key = NULL; - Py_XDECREF(var_attention_probs); - var_attention_probs = NULL; - Py_XDECREF(var_attention_probs_dropped); - var_attention_probs_dropped = NULL; - Py_XDECREF(var_context_layer); - var_context_layer = NULL; - Py_XDECREF(var_new_context_layer_shape); - var_new_context_layer_shape = NULL; - Py_XDECREF(var_outputs); - var_outputs = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__10___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_3ffa23d628f575a2f740dcb6fe8c1a15; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15)) { - Py_XDECREF(cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15); - -#if _DEBUG_REFCOUNTS - if (cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15 = MAKE_FUNCTION_FRAME(codeobj_3ffa23d628f575a2f740dcb6fe8c1a15, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15->m_type_description == NULL); - frame_3ffa23d628f575a2f740dcb6fe8c1a15 = cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15; - - // Push the new frame as the currently active one. - pushFrameStack(frame_3ffa23d628f575a2f740dcb6fe8c1a15); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_3ffa23d628f575a2f740dcb6fe8c1a15) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 280; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 280; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_3ffa23d628f575a2f740dcb6fe8c1a15->m_frame.f_lineno = 280; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 280; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_assattr_target_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[6]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_config; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[6]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_3ffa23d628f575a2f740dcb6fe8c1a15->m_frame.f_lineno = 281; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[92], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 281; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_4; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_5; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_assattr_target_2; - tmp_expression_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_4 == NULL)) { - tmp_expression_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[12]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_5 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[6]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[13]; - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[14]); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_1 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_3ffa23d628f575a2f740dcb6fe8c1a15->m_frame.f_lineno = 282; - tmp_assattr_name_2 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[12], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 282; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_8; - PyObject *tmp_assattr_target_3; - tmp_expression_name_7 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_7 == NULL)) { - tmp_expression_name_7 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 283; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[15]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 283; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 283; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_config; - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[16]); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 283; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_3ffa23d628f575a2f740dcb6fe8c1a15->m_frame.f_lineno = 283; - tmp_assattr_name_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 283; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[17], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 283; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3ffa23d628f575a2f740dcb6fe8c1a15); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3ffa23d628f575a2f740dcb6fe8c1a15); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_3ffa23d628f575a2f740dcb6fe8c1a15, exception_lineno); - } else if (exception_tb->tb_frame != &frame_3ffa23d628f575a2f740dcb6fe8c1a15->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_3ffa23d628f575a2f740dcb6fe8c1a15, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_3ffa23d628f575a2f740dcb6fe8c1a15, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_3ffa23d628f575a2f740dcb6fe8c1a15 == cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15); - cache_frame_3ffa23d628f575a2f740dcb6fe8c1a15 = NULL; - } - - assertFrameObject(frame_3ffa23d628f575a2f740dcb6fe8c1a15); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__11_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *par_input_tensor = python_pars[2]; - struct Nuitka_FrameObject *frame_e2c151c9b0676788eee114d75e2c1886; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_e2c151c9b0676788eee114d75e2c1886 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_e2c151c9b0676788eee114d75e2c1886)) { - Py_XDECREF(cache_frame_e2c151c9b0676788eee114d75e2c1886); - -#if _DEBUG_REFCOUNTS - if (cache_frame_e2c151c9b0676788eee114d75e2c1886 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_e2c151c9b0676788eee114d75e2c1886 = MAKE_FUNCTION_FRAME(codeobj_e2c151c9b0676788eee114d75e2c1886, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_e2c151c9b0676788eee114d75e2c1886->m_type_description == NULL); - frame_e2c151c9b0676788eee114d75e2c1886 = cache_frame_e2c151c9b0676788eee114d75e2c1886; - - // Push the new frame as the currently active one. - pushFrameStack(frame_e2c151c9b0676788eee114d75e2c1886); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_e2c151c9b0676788eee114d75e2c1886) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_1 = par_hidden_states; - frame_e2c151c9b0676788eee114d75e2c1886->m_frame.f_lineno = 286; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[92], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 286; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 287; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_2 = par_hidden_states; - frame_e2c151c9b0676788eee114d75e2c1886->m_frame.f_lineno = 287; - tmp_assign_source_2 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[17], tmp_args_element_name_2); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 287; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_3; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 288; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_1 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[12]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 288; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_hidden_states); - tmp_left_name_1 = par_hidden_states; - CHECK_OBJECT(par_input_tensor); - tmp_right_name_1 = par_input_tensor; - tmp_args_element_name_3 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 288; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - frame_e2c151c9b0676788eee114d75e2c1886->m_frame.f_lineno = 288; - tmp_assign_source_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 288; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e2c151c9b0676788eee114d75e2c1886); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e2c151c9b0676788eee114d75e2c1886); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_e2c151c9b0676788eee114d75e2c1886, exception_lineno); - } else if (exception_tb->tb_frame != &frame_e2c151c9b0676788eee114d75e2c1886->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_e2c151c9b0676788eee114d75e2c1886, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_e2c151c9b0676788eee114d75e2c1886, - type_description_1, - par_self, - par_hidden_states, - par_input_tensor - ); - - - // Release cached frame if used for exception. - if (frame_e2c151c9b0676788eee114d75e2c1886 == cache_frame_e2c151c9b0676788eee114d75e2c1886) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_e2c151c9b0676788eee114d75e2c1886); - cache_frame_e2c151c9b0676788eee114d75e2c1886 = NULL; - } - - assertFrameObject(frame_e2c151c9b0676788eee114d75e2c1886); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(par_hidden_states); - tmp_return_value = par_hidden_states; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_input_tensor); - par_input_tensor = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_input_tensor); - par_input_tensor = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__12___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - PyObject *par_is_cross_attention = python_pars[2]; - struct Nuitka_FrameObject *frame_269652cb22803d15cde90d439879a1a2; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_269652cb22803d15cde90d439879a1a2 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_269652cb22803d15cde90d439879a1a2)) { - Py_XDECREF(cache_frame_269652cb22803d15cde90d439879a1a2); - -#if _DEBUG_REFCOUNTS - if (cache_frame_269652cb22803d15cde90d439879a1a2 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_269652cb22803d15cde90d439879a1a2 = MAKE_FUNCTION_FRAME(codeobj_269652cb22803d15cde90d439879a1a2, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_269652cb22803d15cde90d439879a1a2->m_type_description == NULL); - frame_269652cb22803d15cde90d439879a1a2 = cache_frame_269652cb22803d15cde90d439879a1a2; - - // Push the new frame as the currently active one. - pushFrameStack(frame_269652cb22803d15cde90d439879a1a2); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_269652cb22803d15cde90d439879a1a2) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 294; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 294; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_269652cb22803d15cde90d439879a1a2->m_frame.f_lineno = 294; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 294; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_assattr_target_1; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[93]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[93]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 295; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_1 = par_config; - CHECK_OBJECT(par_is_cross_attention); - tmp_args_element_name_2 = par_is_cross_attention; - frame_269652cb22803d15cde90d439879a1a2->m_frame.f_lineno = 295; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 295; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[26], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 295; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_assattr_target_2; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[94]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[94]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 296; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_3 = par_config; - frame_269652cb22803d15cde90d439879a1a2->m_frame.f_lineno = 296; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_3); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 296; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[95], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 296; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_assattr_target_3; - tmp_assattr_name_3 = PySet_New(NULL); - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[96], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 297; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_269652cb22803d15cde90d439879a1a2); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_269652cb22803d15cde90d439879a1a2); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_269652cb22803d15cde90d439879a1a2, exception_lineno); - } else if (exception_tb->tb_frame != &frame_269652cb22803d15cde90d439879a1a2->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_269652cb22803d15cde90d439879a1a2, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_269652cb22803d15cde90d439879a1a2, - type_description_1, - par_self, - par_config, - par_is_cross_attention, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_269652cb22803d15cde90d439879a1a2 == cache_frame_269652cb22803d15cde90d439879a1a2) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_269652cb22803d15cde90d439879a1a2); - cache_frame_269652cb22803d15cde90d439879a1a2 = NULL; - } - - assertFrameObject(frame_269652cb22803d15cde90d439879a1a2); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_config); - Py_DECREF(par_config); - par_config = NULL; - CHECK_OBJECT(par_is_cross_attention); - Py_DECREF(par_is_cross_attention); - par_is_cross_attention = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_config); - Py_DECREF(par_config); - par_config = NULL; - CHECK_OBJECT(par_is_cross_attention); - Py_DECREF(par_is_cross_attention); - par_is_cross_attention = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__13_prune_heads(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_heads = python_pars[1]; - PyObject *var_index = NULL; - PyObject *tmp_tuple_unpack_1__element_1 = NULL; - PyObject *tmp_tuple_unpack_1__element_2 = NULL; - PyObject *tmp_tuple_unpack_1__source_iter = NULL; - struct Nuitka_FrameObject *frame_0b0b36faf8277ec302d6c6695f619e8c; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - PyObject *tmp_return_value = NULL; - PyObject *tmp_iterator_attempt; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_0b0b36faf8277ec302d6c6695f619e8c = NULL; - PyObject *exception_keeper_type_3; - PyObject *exception_keeper_value_3; - PyTracebackObject *exception_keeper_tb_3; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_3; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_0b0b36faf8277ec302d6c6695f619e8c)) { - Py_XDECREF(cache_frame_0b0b36faf8277ec302d6c6695f619e8c); - -#if _DEBUG_REFCOUNTS - if (cache_frame_0b0b36faf8277ec302d6c6695f619e8c == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_0b0b36faf8277ec302d6c6695f619e8c = MAKE_FUNCTION_FRAME(codeobj_0b0b36faf8277ec302d6c6695f619e8c, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_0b0b36faf8277ec302d6c6695f619e8c->m_type_description == NULL); - frame_0b0b36faf8277ec302d6c6695f619e8c = cache_frame_0b0b36faf8277ec302d6c6695f619e8c; - - // Push the new frame as the currently active one. - pushFrameStack(frame_0b0b36faf8277ec302d6c6695f619e8c); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_0b0b36faf8277ec302d6c6695f619e8c) == 2); // Frame stack - - // Framed code: - { - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_len_arg_1; - PyObject *tmp_tmp_condition_result_1_object_1; - CHECK_OBJECT(par_heads); - tmp_len_arg_1 = par_heads; - tmp_compexpr_left_1 = BUILTIN_LEN(tmp_len_arg_1); - if (tmp_compexpr_left_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 300; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_1 = mod_consts[29]; - tmp_tmp_condition_result_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_1, tmp_compexpr_right_1); - Py_DECREF(tmp_compexpr_left_1); - assert(!(tmp_tmp_condition_result_1_object_1 == NULL)); - tmp_condition_result_1 = CHECK_IF_TRUE(tmp_tmp_condition_result_1_object_1) == 1; - Py_DECREF(tmp_tmp_condition_result_1_object_1); - if (tmp_condition_result_1 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto frame_return_exit_1; - branch_no_1:; - // Tried code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_iter_arg_1; - PyObject *tmp_called_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_3; - PyObject *tmp_expression_name_4; - PyObject *tmp_args_element_name_4; - PyObject *tmp_expression_name_5; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[97]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[97]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 302; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - if (par_heads == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[98]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 303; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - - tmp_args_element_name_1 = par_heads; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[26]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 304; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[36]); - Py_DECREF(tmp_expression_name_1); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 304; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 305; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - - tmp_expression_name_4 = par_self; - tmp_expression_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[26]); - if (tmp_expression_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_2); - - exception_lineno = 305; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[39]); - Py_DECREF(tmp_expression_name_3); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_2); - - exception_lineno = 305; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_2); - Py_DECREF(tmp_args_element_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 306; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - - tmp_expression_name_5 = par_self; - tmp_args_element_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[96]); - if (tmp_args_element_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_2); - Py_DECREF(tmp_args_element_name_3); - - exception_lineno = 306; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame.f_lineno = 302; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2, tmp_args_element_name_3, tmp_args_element_name_4}; - tmp_iter_arg_1 = CALL_FUNCTION_WITH_ARGS4(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_args_element_name_2); - Py_DECREF(tmp_args_element_name_3); - Py_DECREF(tmp_args_element_name_4); - if (tmp_iter_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 302; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - tmp_assign_source_1 = MAKE_UNPACK_ITERATOR(tmp_iter_arg_1); - Py_DECREF(tmp_iter_arg_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 302; - type_description_1 = "ooo"; - goto try_except_handler_2; - } - assert(tmp_tuple_unpack_1__source_iter == NULL); - tmp_tuple_unpack_1__source_iter = tmp_assign_source_1; - } - // Tried code: - { - PyObject *tmp_assign_source_2; - PyObject *tmp_unpack_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_1 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_2 = UNPACK_NEXT(tmp_unpack_1, 0, 2); - if (tmp_assign_source_2 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "ooo"; - exception_lineno = 302; - goto try_except_handler_3; - } - assert(tmp_tuple_unpack_1__element_1 == NULL); - tmp_tuple_unpack_1__element_1 = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_unpack_2; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_2 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_3 = UNPACK_NEXT(tmp_unpack_2, 1, 2); - if (tmp_assign_source_3 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "ooo"; - exception_lineno = 302; - goto try_except_handler_3; - } - assert(tmp_tuple_unpack_1__element_2 == NULL); - tmp_tuple_unpack_1__element_2 = tmp_assign_source_3; - } - { - PyObject *tmp_iterator_name_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_iterator_name_1 = tmp_tuple_unpack_1__source_iter; - // Check if iterator has left-over elements. - CHECK_OBJECT(tmp_iterator_name_1); assert(HAS_ITERNEXT(tmp_iterator_name_1)); - - tmp_iterator_attempt = (*Py_TYPE(tmp_iterator_name_1)->tp_iternext)(tmp_iterator_name_1); - - if (likely(tmp_iterator_attempt == NULL)) { - PyObject *error = GET_ERROR_OCCURRED(); - - if (error != NULL) { - if (EXCEPTION_MATCH_BOOL_SINGLE(error, PyExc_StopIteration)) { - CLEAR_ERROR_OCCURRED(); - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - type_description_1 = "ooo"; - exception_lineno = 302; - goto try_except_handler_3; - } - } - } else { - Py_DECREF(tmp_iterator_attempt); - - exception_type = PyExc_ValueError; - Py_INCREF(PyExc_ValueError); - exception_value = mod_consts[99]; - Py_INCREF(exception_value); - exception_tb = NULL; - - type_description_1 = "ooo"; - exception_lineno = 302; - goto try_except_handler_3; - } - } - goto try_end_1; - // Exception handler code: - try_except_handler_3:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto try_except_handler_2; - // End of try: - try_end_1:; - goto try_end_2; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto frame_exception_exit_1; - // End of try: - try_end_2:; - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - { - PyObject *tmp_assign_source_4; - CHECK_OBJECT(tmp_tuple_unpack_1__element_1); - tmp_assign_source_4 = tmp_tuple_unpack_1__element_1; - { - PyObject *old = par_heads; - par_heads = tmp_assign_source_4; - Py_INCREF(par_heads); - Py_XDECREF(old); - } - - } - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - - { - PyObject *tmp_assign_source_5; - CHECK_OBJECT(tmp_tuple_unpack_1__element_2); - tmp_assign_source_5 = tmp_tuple_unpack_1__element_2; - assert(var_index == NULL); - Py_INCREF(tmp_assign_source_5); - var_index = tmp_assign_source_5; - } - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_5; - PyObject *tmp_expression_name_6; - PyObject *tmp_expression_name_7; - PyObject *tmp_args_element_name_6; - PyObject *tmp_assattr_target_1; - PyObject *tmp_expression_name_8; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[100]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[100]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_self; - tmp_expression_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[26]); - if (tmp_expression_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[42]); - Py_DECREF(tmp_expression_name_6); - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_index); - tmp_args_element_name_6 = var_index; - frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame.f_lineno = 310; - { - PyObject *call_args[] = {tmp_args_element_name_5, tmp_args_element_name_6}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_2, call_args); - } - - Py_DECREF(tmp_args_element_name_5); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_self; - tmp_assattr_target_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[26]); - if (tmp_assattr_target_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_1); - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[42], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - Py_DECREF(tmp_assattr_target_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 310; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_3; - PyObject *tmp_args_element_name_7; - PyObject *tmp_expression_name_9; - PyObject *tmp_expression_name_10; - PyObject *tmp_args_element_name_8; - PyObject *tmp_assattr_target_2; - PyObject *tmp_expression_name_11; - tmp_called_name_3 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[100]); - - if (unlikely(tmp_called_name_3 == NULL)) { - tmp_called_name_3 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[100]); - } - - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_10 = par_self; - tmp_expression_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[26]); - if (tmp_expression_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[44]); - Py_DECREF(tmp_expression_name_9); - if (tmp_args_element_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_index); - tmp_args_element_name_8 = var_index; - frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame.f_lineno = 311; - { - PyObject *call_args[] = {tmp_args_element_name_7, tmp_args_element_name_8}; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_3, call_args); - } - - Py_DECREF(tmp_args_element_name_7); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_11 = par_self; - tmp_assattr_target_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[26]); - if (tmp_assattr_target_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_2); - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[44], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - Py_DECREF(tmp_assattr_target_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 311; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_called_name_4; - PyObject *tmp_args_element_name_9; - PyObject *tmp_expression_name_12; - PyObject *tmp_expression_name_13; - PyObject *tmp_args_element_name_10; - PyObject *tmp_assattr_target_3; - PyObject *tmp_expression_name_14; - tmp_called_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[100]); - - if (unlikely(tmp_called_name_4 == NULL)) { - tmp_called_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[100]); - } - - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_13 = par_self; - tmp_expression_name_12 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[26]); - if (tmp_expression_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[45]); - Py_DECREF(tmp_expression_name_12); - if (tmp_args_element_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_index); - tmp_args_element_name_10 = var_index; - frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame.f_lineno = 312; - { - PyObject *call_args[] = {tmp_args_element_name_9, tmp_args_element_name_10}; - tmp_assattr_name_3 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_4, call_args); - } - - Py_DECREF(tmp_args_element_name_9); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_14 = par_self; - tmp_assattr_target_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[26]); - if (tmp_assattr_target_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_3); - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[45], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - Py_DECREF(tmp_assattr_target_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 312; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_4; - PyObject *tmp_called_name_5; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_15; - PyObject *tmp_expression_name_16; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_assattr_target_4; - PyObject *tmp_expression_name_17; - tmp_called_name_5 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[100]); - - if (unlikely(tmp_called_name_5 == NULL)) { - tmp_called_name_5 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[100]); - } - - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_16 = par_self; - tmp_expression_name_15 = LOOKUP_ATTRIBUTE(tmp_expression_name_16, mod_consts[95]); - if (tmp_expression_name_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[92]); - Py_DECREF(tmp_expression_name_15); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_args_name_1 = PyTuple_New(2); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - CHECK_OBJECT(var_index); - tmp_tuple_element_1 = var_index; - PyTuple_SET_ITEM0(tmp_args_name_1, 1, tmp_tuple_element_1); - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[34]); - frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame.f_lineno = 313; - tmp_assattr_name_4 = CALL_FUNCTION(tmp_called_name_5, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_17 = par_self; - tmp_assattr_target_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[95]); - if (tmp_assattr_target_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_4); - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[92], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - Py_DECREF(tmp_assattr_target_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 313; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_5; - PyObject *tmp_left_name_1; - PyObject *tmp_expression_name_18; - PyObject *tmp_expression_name_19; - PyObject *tmp_right_name_1; - PyObject *tmp_len_arg_2; - PyObject *tmp_assattr_target_5; - PyObject *tmp_expression_name_20; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_19 = par_self; - tmp_expression_name_18 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[26]); - if (tmp_expression_name_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_left_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_18, mod_consts[36]); - Py_DECREF(tmp_expression_name_18); - if (tmp_left_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_heads); - tmp_len_arg_2 = par_heads; - tmp_right_name_1 = BUILTIN_LEN(tmp_len_arg_2); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_assattr_name_5 = BINARY_OPERATION_SUB_OBJECT_OBJECT_LONG(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assattr_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_20 = par_self; - tmp_assattr_target_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[26]); - if (tmp_assattr_target_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_5); - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_5, mod_consts[36], tmp_assattr_name_5); - Py_DECREF(tmp_assattr_name_5); - Py_DECREF(tmp_assattr_target_5); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 316; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_6; - PyObject *tmp_left_name_2; - PyObject *tmp_expression_name_21; - PyObject *tmp_expression_name_22; - PyObject *tmp_right_name_2; - PyObject *tmp_expression_name_23; - PyObject *tmp_expression_name_24; - PyObject *tmp_assattr_target_6; - PyObject *tmp_expression_name_25; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_22 = par_self; - tmp_expression_name_21 = LOOKUP_ATTRIBUTE(tmp_expression_name_22, mod_consts[26]); - if (tmp_expression_name_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_left_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_21, mod_consts[39]); - Py_DECREF(tmp_expression_name_21); - if (tmp_left_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_left_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_24 = par_self; - tmp_expression_name_23 = LOOKUP_ATTRIBUTE(tmp_expression_name_24, mod_consts[26]); - if (tmp_expression_name_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_2); - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_right_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[36]); - Py_DECREF(tmp_expression_name_23); - if (tmp_right_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_2); - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_assattr_name_6 = BINARY_OPERATION_MULT_OBJECT_OBJECT_OBJECT(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_left_name_2); - Py_DECREF(tmp_right_name_2); - if (tmp_assattr_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 318; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 317; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_25 = par_self; - tmp_assattr_target_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_25, mod_consts[26]); - if (tmp_assattr_target_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_6); - - exception_lineno = 317; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_6, mod_consts[40], tmp_assattr_name_6); - Py_DECREF(tmp_assattr_name_6); - Py_DECREF(tmp_assattr_target_6); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 317; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_7; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_26; - PyObject *tmp_expression_name_27; - PyObject *tmp_args_element_name_11; - PyObject *tmp_assattr_target_7; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_27 = par_self; - tmp_expression_name_26 = LOOKUP_ATTRIBUTE(tmp_expression_name_27, mod_consts[96]); - if (tmp_expression_name_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_26, mod_consts[101]); - Py_DECREF(tmp_expression_name_26); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_heads == NULL) { - Py_DECREF(tmp_called_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[98]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_11 = par_heads; - frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame.f_lineno = 320; - tmp_assattr_name_7 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_6, tmp_args_element_name_11); - Py_DECREF(tmp_called_name_6); - if (tmp_assattr_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_7 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_7, mod_consts[96], tmp_assattr_name_7); - Py_DECREF(tmp_assattr_name_7); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 320; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0b0b36faf8277ec302d6c6695f619e8c); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0b0b36faf8277ec302d6c6695f619e8c); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0b0b36faf8277ec302d6c6695f619e8c); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_0b0b36faf8277ec302d6c6695f619e8c, exception_lineno); - } else if (exception_tb->tb_frame != &frame_0b0b36faf8277ec302d6c6695f619e8c->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_0b0b36faf8277ec302d6c6695f619e8c, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_0b0b36faf8277ec302d6c6695f619e8c, - type_description_1, - par_self, - par_heads, - var_index - ); - - - // Release cached frame if used for exception. - if (frame_0b0b36faf8277ec302d6c6695f619e8c == cache_frame_0b0b36faf8277ec302d6c6695f619e8c) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_0b0b36faf8277ec302d6c6695f619e8c); - cache_frame_0b0b36faf8277ec302d6c6695f619e8c = NULL; - } - - assertFrameObject(frame_0b0b36faf8277ec302d6c6695f619e8c); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_heads); - par_heads = NULL; - Py_XDECREF(var_index); - var_index = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_3 = exception_type; - exception_keeper_value_3 = exception_value; - exception_keeper_tb_3 = exception_tb; - exception_keeper_lineno_3 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_heads); - par_heads = NULL; - Py_XDECREF(var_index); - var_index = NULL; - // Re-raise. - exception_type = exception_keeper_type_3; - exception_value = exception_keeper_value_3; - exception_tb = exception_keeper_tb_3; - exception_lineno = exception_keeper_lineno_3; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__14_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_head_mask = python_pars[3]; - PyObject *par_encoder_hidden_states = python_pars[4]; - PyObject *par_encoder_attention_mask = python_pars[5]; - PyObject *par_past_key_value = python_pars[6]; - PyObject *par_output_attentions = python_pars[7]; - PyObject *var_self_outputs = NULL; - PyObject *var_attention_output = NULL; - PyObject *var_outputs = NULL; - struct Nuitka_FrameObject *frame_02c26eebaf2303eb7380395e131d8a5e; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_02c26eebaf2303eb7380395e131d8a5e = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_02c26eebaf2303eb7380395e131d8a5e)) { - Py_XDECREF(cache_frame_02c26eebaf2303eb7380395e131d8a5e); - -#if _DEBUG_REFCOUNTS - if (cache_frame_02c26eebaf2303eb7380395e131d8a5e == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_02c26eebaf2303eb7380395e131d8a5e = MAKE_FUNCTION_FRAME(codeobj_02c26eebaf2303eb7380395e131d8a5e, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_02c26eebaf2303eb7380395e131d8a5e->m_type_description == NULL); - frame_02c26eebaf2303eb7380395e131d8a5e = cache_frame_02c26eebaf2303eb7380395e131d8a5e; - - // Push the new frame as the currently active one. - pushFrameStack(frame_02c26eebaf2303eb7380395e131d8a5e); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_02c26eebaf2303eb7380395e131d8a5e) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_args_element_name_4; - PyObject *tmp_args_element_name_5; - PyObject *tmp_args_element_name_6; - PyObject *tmp_args_element_name_7; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_1 = par_hidden_states; - CHECK_OBJECT(par_attention_mask); - tmp_args_element_name_2 = par_attention_mask; - CHECK_OBJECT(par_head_mask); - tmp_args_element_name_3 = par_head_mask; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_args_element_name_4 = par_encoder_hidden_states; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_args_element_name_5 = par_encoder_attention_mask; - CHECK_OBJECT(par_past_key_value); - tmp_args_element_name_6 = par_past_key_value; - CHECK_OBJECT(par_output_attentions); - tmp_args_element_name_7 = par_output_attentions; - frame_02c26eebaf2303eb7380395e131d8a5e->m_frame.f_lineno = 332; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2, tmp_args_element_name_3, tmp_args_element_name_4, tmp_args_element_name_5, tmp_args_element_name_6, tmp_args_element_name_7}; - tmp_assign_source_1 = CALL_METHOD_WITH_ARGS7( - tmp_called_instance_1, - mod_consts[26], - call_args - ); - } - - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 332; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_self_outputs == NULL); - var_self_outputs = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_8; - PyObject *tmp_expression_name_2; - PyObject *tmp_subscript_name_1; - PyObject *tmp_args_element_name_9; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 341; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_1 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[95]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 341; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_self_outputs); - tmp_expression_name_2 = var_self_outputs; - tmp_subscript_name_1 = mod_consts[29]; - tmp_args_element_name_8 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_2, tmp_subscript_name_1, 0); - if (tmp_args_element_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 341; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - if (par_hidden_states == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_8); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 341; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_9 = par_hidden_states; - frame_02c26eebaf2303eb7380395e131d8a5e->m_frame.f_lineno = 341; - { - PyObject *call_args[] = {tmp_args_element_name_8, tmp_args_element_name_9}; - tmp_assign_source_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_8); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 341; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_attention_output == NULL); - var_attention_output = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_left_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_subscript_name_2; - CHECK_OBJECT(var_attention_output); - tmp_tuple_element_1 = var_attention_output; - tmp_left_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_left_name_1, 0, tmp_tuple_element_1); - CHECK_OBJECT(var_self_outputs); - tmp_expression_name_3 = var_self_outputs; - tmp_subscript_name_2 = mod_consts[102]; - tmp_right_name_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_3, tmp_subscript_name_2); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 343; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_3 = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 343; - type_description_1 = "ooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_outputs == NULL); - var_outputs = tmp_assign_source_3; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_02c26eebaf2303eb7380395e131d8a5e); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_02c26eebaf2303eb7380395e131d8a5e); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_02c26eebaf2303eb7380395e131d8a5e, exception_lineno); - } else if (exception_tb->tb_frame != &frame_02c26eebaf2303eb7380395e131d8a5e->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_02c26eebaf2303eb7380395e131d8a5e, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_02c26eebaf2303eb7380395e131d8a5e, - type_description_1, - par_self, - par_hidden_states, - par_attention_mask, - par_head_mask, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_past_key_value, - par_output_attentions, - var_self_outputs, - var_attention_output, - var_outputs - ); - - - // Release cached frame if used for exception. - if (frame_02c26eebaf2303eb7380395e131d8a5e == cache_frame_02c26eebaf2303eb7380395e131d8a5e) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_02c26eebaf2303eb7380395e131d8a5e); - cache_frame_02c26eebaf2303eb7380395e131d8a5e = NULL; - } - - assertFrameObject(frame_02c26eebaf2303eb7380395e131d8a5e); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_outputs); - tmp_return_value = var_outputs; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_past_key_value); - par_past_key_value = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - CHECK_OBJECT(var_self_outputs); - Py_DECREF(var_self_outputs); - var_self_outputs = NULL; - CHECK_OBJECT(var_attention_output); - Py_DECREF(var_attention_output); - var_attention_output = NULL; - CHECK_OBJECT(var_outputs); - Py_DECREF(var_outputs); - var_outputs = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_past_key_value); - par_past_key_value = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(var_self_outputs); - var_self_outputs = NULL; - Py_XDECREF(var_attention_output); - var_attention_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__15___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_bc386502a8ad779e82b56ce3a01a046c; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_bc386502a8ad779e82b56ce3a01a046c = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_bc386502a8ad779e82b56ce3a01a046c)) { - Py_XDECREF(cache_frame_bc386502a8ad779e82b56ce3a01a046c); - -#if _DEBUG_REFCOUNTS - if (cache_frame_bc386502a8ad779e82b56ce3a01a046c == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_bc386502a8ad779e82b56ce3a01a046c = MAKE_FUNCTION_FRAME(codeobj_bc386502a8ad779e82b56ce3a01a046c, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_bc386502a8ad779e82b56ce3a01a046c->m_type_description == NULL); - frame_bc386502a8ad779e82b56ce3a01a046c = cache_frame_bc386502a8ad779e82b56ce3a01a046c; - - // Push the new frame as the currently active one. - pushFrameStack(frame_bc386502a8ad779e82b56ce3a01a046c); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_bc386502a8ad779e82b56ce3a01a046c) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 351; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 351; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_bc386502a8ad779e82b56ce3a01a046c->m_frame.f_lineno = 351; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 351; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_assattr_target_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[6]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_config; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[103]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_bc386502a8ad779e82b56ce3a01a046c->m_frame.f_lineno = 352; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[92], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 352; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - nuitka_bool tmp_condition_result_1; - PyObject *tmp_isinstance_inst_1; - PyObject *tmp_isinstance_cls_1; - PyObject *tmp_expression_name_4; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 353; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_config; - tmp_isinstance_inst_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[104]); - if (tmp_isinstance_inst_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 353; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_isinstance_cls_1 = (PyObject *)&PyUnicode_Type; - tmp_res = Nuitka_IsInstance(tmp_isinstance_inst_1, tmp_isinstance_cls_1); - Py_DECREF(tmp_isinstance_inst_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 353; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_condition_result_1 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_expression_name_5; - PyObject *tmp_subscript_name_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_assattr_target_2; - tmp_expression_name_5 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[105]); - - if (unlikely(tmp_expression_name_5 == NULL)) { - tmp_expression_name_5 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[105]); - } - - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 354; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 354; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_subscript_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[104]); - if (tmp_subscript_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 354; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_assattr_name_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_5, tmp_subscript_name_1); - Py_DECREF(tmp_subscript_name_1); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 354; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[106], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 354; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - goto branch_end_1; - branch_no_1:; - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_assattr_target_3; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 356; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_config; - tmp_assattr_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[104]); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 356; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[106], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 356; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - branch_end_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_bc386502a8ad779e82b56ce3a01a046c); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_bc386502a8ad779e82b56ce3a01a046c); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_bc386502a8ad779e82b56ce3a01a046c, exception_lineno); - } else if (exception_tb->tb_frame != &frame_bc386502a8ad779e82b56ce3a01a046c->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_bc386502a8ad779e82b56ce3a01a046c, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_bc386502a8ad779e82b56ce3a01a046c, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_bc386502a8ad779e82b56ce3a01a046c == cache_frame_bc386502a8ad779e82b56ce3a01a046c) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_bc386502a8ad779e82b56ce3a01a046c); - cache_frame_bc386502a8ad779e82b56ce3a01a046c = NULL; - } - - assertFrameObject(frame_bc386502a8ad779e82b56ce3a01a046c); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__16_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - struct Nuitka_FrameObject *frame_ef7df7f2aae603ea3cb921a91d68b297; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_ef7df7f2aae603ea3cb921a91d68b297 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_ef7df7f2aae603ea3cb921a91d68b297)) { - Py_XDECREF(cache_frame_ef7df7f2aae603ea3cb921a91d68b297); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ef7df7f2aae603ea3cb921a91d68b297 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ef7df7f2aae603ea3cb921a91d68b297 = MAKE_FUNCTION_FRAME(codeobj_ef7df7f2aae603ea3cb921a91d68b297, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ef7df7f2aae603ea3cb921a91d68b297->m_type_description == NULL); - frame_ef7df7f2aae603ea3cb921a91d68b297 = cache_frame_ef7df7f2aae603ea3cb921a91d68b297; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ef7df7f2aae603ea3cb921a91d68b297); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ef7df7f2aae603ea3cb921a91d68b297) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_1 = par_hidden_states; - frame_ef7df7f2aae603ea3cb921a91d68b297->m_frame.f_lineno = 359; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[92], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 359; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 360; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_2 = par_hidden_states; - frame_ef7df7f2aae603ea3cb921a91d68b297->m_frame.f_lineno = 360; - tmp_assign_source_2 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[106], tmp_args_element_name_2); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 360; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ef7df7f2aae603ea3cb921a91d68b297); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ef7df7f2aae603ea3cb921a91d68b297); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ef7df7f2aae603ea3cb921a91d68b297, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ef7df7f2aae603ea3cb921a91d68b297->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ef7df7f2aae603ea3cb921a91d68b297, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ef7df7f2aae603ea3cb921a91d68b297, - type_description_1, - par_self, - par_hidden_states - ); - - - // Release cached frame if used for exception. - if (frame_ef7df7f2aae603ea3cb921a91d68b297 == cache_frame_ef7df7f2aae603ea3cb921a91d68b297) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ef7df7f2aae603ea3cb921a91d68b297); - cache_frame_ef7df7f2aae603ea3cb921a91d68b297 = NULL; - } - - assertFrameObject(frame_ef7df7f2aae603ea3cb921a91d68b297); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(par_hidden_states); - tmp_return_value = par_hidden_states; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__17___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_da381dec774f92fc3fdec9b27fb9d857; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_da381dec774f92fc3fdec9b27fb9d857 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_da381dec774f92fc3fdec9b27fb9d857)) { - Py_XDECREF(cache_frame_da381dec774f92fc3fdec9b27fb9d857); - -#if _DEBUG_REFCOUNTS - if (cache_frame_da381dec774f92fc3fdec9b27fb9d857 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_da381dec774f92fc3fdec9b27fb9d857 = MAKE_FUNCTION_FRAME(codeobj_da381dec774f92fc3fdec9b27fb9d857, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_da381dec774f92fc3fdec9b27fb9d857->m_type_description == NULL); - frame_da381dec774f92fc3fdec9b27fb9d857 = cache_frame_da381dec774f92fc3fdec9b27fb9d857; - - // Push the new frame as the currently active one. - pushFrameStack(frame_da381dec774f92fc3fdec9b27fb9d857); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_da381dec774f92fc3fdec9b27fb9d857) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 366; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 366; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_da381dec774f92fc3fdec9b27fb9d857->m_frame.f_lineno = 366; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 366; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_assattr_target_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[103]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_config; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[6]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_da381dec774f92fc3fdec9b27fb9d857->m_frame.f_lineno = 367; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[92], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 367; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_4; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_5; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_assattr_target_2; - tmp_expression_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_4 == NULL)) { - tmp_expression_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[12]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_5 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[6]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[13]; - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[14]); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_1 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_da381dec774f92fc3fdec9b27fb9d857->m_frame.f_lineno = 368; - tmp_assattr_name_2 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[12], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 368; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_8; - PyObject *tmp_assattr_target_3; - tmp_expression_name_7 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_7 == NULL)) { - tmp_expression_name_7 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 369; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[15]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 369; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 369; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_config; - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[16]); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 369; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_da381dec774f92fc3fdec9b27fb9d857->m_frame.f_lineno = 369; - tmp_assattr_name_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 369; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[17], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 369; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_da381dec774f92fc3fdec9b27fb9d857); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_da381dec774f92fc3fdec9b27fb9d857); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_da381dec774f92fc3fdec9b27fb9d857, exception_lineno); - } else if (exception_tb->tb_frame != &frame_da381dec774f92fc3fdec9b27fb9d857->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_da381dec774f92fc3fdec9b27fb9d857, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_da381dec774f92fc3fdec9b27fb9d857, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_da381dec774f92fc3fdec9b27fb9d857 == cache_frame_da381dec774f92fc3fdec9b27fb9d857) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_da381dec774f92fc3fdec9b27fb9d857); - cache_frame_da381dec774f92fc3fdec9b27fb9d857 = NULL; - } - - assertFrameObject(frame_da381dec774f92fc3fdec9b27fb9d857); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__18_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *par_input_tensor = python_pars[2]; - struct Nuitka_FrameObject *frame_ac223922169c79b32778e1fea6b86d12; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_ac223922169c79b32778e1fea6b86d12 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_ac223922169c79b32778e1fea6b86d12)) { - Py_XDECREF(cache_frame_ac223922169c79b32778e1fea6b86d12); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ac223922169c79b32778e1fea6b86d12 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ac223922169c79b32778e1fea6b86d12 = MAKE_FUNCTION_FRAME(codeobj_ac223922169c79b32778e1fea6b86d12, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ac223922169c79b32778e1fea6b86d12->m_type_description == NULL); - frame_ac223922169c79b32778e1fea6b86d12 = cache_frame_ac223922169c79b32778e1fea6b86d12; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ac223922169c79b32778e1fea6b86d12); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ac223922169c79b32778e1fea6b86d12) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_1 = par_hidden_states; - frame_ac223922169c79b32778e1fea6b86d12->m_frame.f_lineno = 372; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[92], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 372; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 373; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_2 = par_hidden_states; - frame_ac223922169c79b32778e1fea6b86d12->m_frame.f_lineno = 373; - tmp_assign_source_2 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[17], tmp_args_element_name_2); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 373; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_3; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 374; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_1 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[12]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 374; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_hidden_states); - tmp_left_name_1 = par_hidden_states; - CHECK_OBJECT(par_input_tensor); - tmp_right_name_1 = par_input_tensor; - tmp_args_element_name_3 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 374; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - frame_ac223922169c79b32778e1fea6b86d12->m_frame.f_lineno = 374; - tmp_assign_source_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 374; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ac223922169c79b32778e1fea6b86d12); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ac223922169c79b32778e1fea6b86d12); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ac223922169c79b32778e1fea6b86d12, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ac223922169c79b32778e1fea6b86d12->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ac223922169c79b32778e1fea6b86d12, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ac223922169c79b32778e1fea6b86d12, - type_description_1, - par_self, - par_hidden_states, - par_input_tensor - ); - - - // Release cached frame if used for exception. - if (frame_ac223922169c79b32778e1fea6b86d12 == cache_frame_ac223922169c79b32778e1fea6b86d12) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ac223922169c79b32778e1fea6b86d12); - cache_frame_ac223922169c79b32778e1fea6b86d12 = NULL; - } - - assertFrameObject(frame_ac223922169c79b32778e1fea6b86d12); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(par_hidden_states); - tmp_return_value = par_hidden_states; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_input_tensor); - par_input_tensor = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_input_tensor); - par_input_tensor = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__19___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - PyObject *par_layer_num = python_pars[2]; - struct Nuitka_FrameObject *frame_9044624cc871cfe54b3607752fe57f1c; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_9044624cc871cfe54b3607752fe57f1c = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_9044624cc871cfe54b3607752fe57f1c)) { - Py_XDECREF(cache_frame_9044624cc871cfe54b3607752fe57f1c); - -#if _DEBUG_REFCOUNTS - if (cache_frame_9044624cc871cfe54b3607752fe57f1c == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_9044624cc871cfe54b3607752fe57f1c = MAKE_FUNCTION_FRAME(codeobj_9044624cc871cfe54b3607752fe57f1c, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_9044624cc871cfe54b3607752fe57f1c->m_type_description == NULL); - frame_9044624cc871cfe54b3607752fe57f1c = cache_frame_9044624cc871cfe54b3607752fe57f1c; - - // Push the new frame as the currently active one. - pushFrameStack(frame_9044624cc871cfe54b3607752fe57f1c); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_9044624cc871cfe54b3607752fe57f1c) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 380; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 380; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 380; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 380; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - CHECK_OBJECT(par_config); - tmp_assattr_name_1 = par_config; - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[5], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 381; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_expression_name_1; - PyObject *tmp_assattr_target_2; - CHECK_OBJECT(par_config); - tmp_expression_name_1 = par_config; - tmp_assattr_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[107]); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 382; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[107], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 382; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_assattr_target_3; - tmp_assattr_name_3 = mod_consts[28]; - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[108], tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 383; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_4; - PyObject *tmp_called_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_assattr_target_4; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[109]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[109]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 384; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 384; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_1 = par_config; - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 384; - tmp_assattr_name_4 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 384; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_4 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[110], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 384; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_5; - PyObject *tmp_assattr_target_5; - CHECK_OBJECT(par_layer_num); - tmp_assattr_name_5 = par_layer_num; - CHECK_OBJECT(par_self); - tmp_assattr_target_5 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_5, mod_consts[111], tmp_assattr_name_5); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 385; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - nuitka_bool tmp_condition_result_1; - int tmp_and_left_truth_1; - nuitka_bool tmp_and_left_value_1; - nuitka_bool tmp_and_right_value_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_attribute_value_1; - int tmp_truth_name_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_4; - PyObject *tmp_expression_name_5; - PyObject *tmp_tmp_and_right_value_1_object_1; - int tmp_truth_name_2; - CHECK_OBJECT(par_self); - tmp_expression_name_3 = par_self; - tmp_expression_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[5]); - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 387; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_attribute_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[112]); - Py_DECREF(tmp_expression_name_2); - if (tmp_attribute_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 387; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_attribute_value_1); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_attribute_value_1); - - exception_lineno = 387; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_and_left_value_1 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_attribute_value_1); - tmp_and_left_truth_1 = tmp_and_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_and_left_truth_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (tmp_and_left_truth_1 == 1) { - goto and_right_1; - } else { - goto and_left_1; - } - and_right_1:; - CHECK_OBJECT(par_layer_num); - tmp_left_name_1 = par_layer_num; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_5 = par_self; - tmp_expression_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[5]); - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_right_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[113]); - Py_DECREF(tmp_expression_name_4); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_compexpr_left_1 = BINARY_OPERATION_MOD_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_compexpr_left_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_1 = mod_consts[29]; - tmp_tmp_and_right_value_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_1, tmp_compexpr_right_1); - Py_DECREF(tmp_compexpr_left_1); - if (tmp_tmp_and_right_value_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_truth_name_2 = CHECK_IF_TRUE(tmp_tmp_and_right_value_1_object_1); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_and_right_value_1_object_1); - - exception_lineno = 388; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_and_right_value_1 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_and_right_value_1_object_1); - tmp_condition_result_1 = tmp_and_right_value_1; - goto and_end_1; - and_left_1:; - tmp_condition_result_1 = tmp_and_left_value_1; - and_end_1:; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assattr_name_6; - PyObject *tmp_called_name_2; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_expression_name_7; - PyObject *tmp_assattr_target_6; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[109]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[109]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 390; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 391; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_1 = par_config; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[114]; - if (par_self == NULL) { - Py_DECREF(tmp_args_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 391; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_self; - tmp_expression_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[5]); - if (tmp_expression_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_name_1); - - exception_lineno = 391; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[112]); - Py_DECREF(tmp_expression_name_6); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_name_1); - - exception_lineno = 391; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_1 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 390; - tmp_assattr_name_6 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 390; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 390; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_6 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_6, mod_consts[115], tmp_assattr_name_6); - Py_DECREF(tmp_assattr_name_6); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 390; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_7; - PyObject *tmp_assattr_target_7; - tmp_assattr_name_7 = Py_True; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 393; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_7 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_7, mod_consts[116], tmp_assattr_name_7); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 393; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - goto branch_end_1; - branch_no_1:; - { - PyObject *tmp_assattr_name_8; - PyObject *tmp_assattr_target_8; - tmp_assattr_name_8 = Py_False; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 395; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_8 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_8, mod_consts[116], tmp_assattr_name_8); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 395; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - branch_end_1:; - { - PyObject *tmp_assattr_name_9; - PyObject *tmp_called_name_3; - PyObject *tmp_args_element_name_2; - PyObject *tmp_assattr_target_9; - tmp_called_name_3 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[117]); - - if (unlikely(tmp_called_name_3 == NULL)) { - tmp_called_name_3 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[117]); - } - - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 396; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 396; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_2 = par_config; - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 396; - tmp_assattr_name_9 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_2); - if (tmp_assattr_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 396; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_9); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 396; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_9 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_9, mod_consts[118], tmp_assattr_name_9); - Py_DECREF(tmp_assattr_name_9); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 396; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_10; - PyObject *tmp_called_name_4; - PyObject *tmp_args_element_name_3; - PyObject *tmp_assattr_target_10; - tmp_called_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[119]); - - if (unlikely(tmp_called_name_4 == NULL)) { - tmp_called_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[119]); - } - - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 397; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 397; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_3 = par_config; - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 397; - tmp_assattr_name_10 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_4, tmp_args_element_name_3); - if (tmp_assattr_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 397; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_10); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 397; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_10 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_10, mod_consts[95], tmp_assattr_name_10); - Py_DECREF(tmp_assattr_name_10); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 397; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_11; - PyObject *tmp_called_name_5; - PyObject *tmp_args_element_name_4; - PyObject *tmp_assattr_target_11; - tmp_called_name_5 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[117]); - - if (unlikely(tmp_called_name_5 == NULL)) { - tmp_called_name_5 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[117]); - } - - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 399; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 399; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_4 = par_config; - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 399; - tmp_assattr_name_11 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_5, tmp_args_element_name_4); - if (tmp_assattr_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 399; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_11); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 399; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_11 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_11, mod_consts[120], tmp_assattr_name_11); - Py_DECREF(tmp_assattr_name_11); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 399; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_12; - PyObject *tmp_called_name_6; - PyObject *tmp_args_element_name_5; - PyObject *tmp_assattr_target_12; - tmp_called_name_6 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[119]); - - if (unlikely(tmp_called_name_6 == NULL)) { - tmp_called_name_6 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[119]); - } - - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 400; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 400; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_5 = par_config; - frame_9044624cc871cfe54b3607752fe57f1c->m_frame.f_lineno = 400; - tmp_assattr_name_12 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_6, tmp_args_element_name_5); - if (tmp_assattr_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 400; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_12); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 400; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_target_12 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_12, mod_consts[121], tmp_assattr_name_12); - Py_DECREF(tmp_assattr_name_12); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 400; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_9044624cc871cfe54b3607752fe57f1c); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_9044624cc871cfe54b3607752fe57f1c); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_9044624cc871cfe54b3607752fe57f1c, exception_lineno); - } else if (exception_tb->tb_frame != &frame_9044624cc871cfe54b3607752fe57f1c->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_9044624cc871cfe54b3607752fe57f1c, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_9044624cc871cfe54b3607752fe57f1c, - type_description_1, - par_self, - par_config, - par_layer_num, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_9044624cc871cfe54b3607752fe57f1c == cache_frame_9044624cc871cfe54b3607752fe57f1c) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_9044624cc871cfe54b3607752fe57f1c); - cache_frame_9044624cc871cfe54b3607752fe57f1c = NULL; - } - - assertFrameObject(frame_9044624cc871cfe54b3607752fe57f1c); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - Py_XDECREF(par_layer_num); - par_layer_num = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - Py_XDECREF(par_layer_num); - par_layer_num = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__20_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_head_mask = python_pars[3]; - PyObject *par_encoder_hidden_states = python_pars[4]; - PyObject *par_encoder_attention_mask = python_pars[5]; - PyObject *par_past_key_value = python_pars[6]; - PyObject *par_output_attentions = python_pars[7]; - PyObject *par_query_length = python_pars[8]; - PyObject *var_self_attn_past_key_value = NULL; - PyObject *var_self_attention_outputs = NULL; - PyObject *var_attention_output = NULL; - PyObject *var_outputs = NULL; - PyObject *var_present_key_value = NULL; - PyObject *var_query_attention_output = NULL; - PyObject *var_cross_attention_outputs = NULL; - PyObject *var_layer_output = NULL; - PyObject *var_layer_output_text = NULL; - struct Nuitka_FrameObject *frame_38c0c92910efd854dc73aa8a49f61b57; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_38c0c92910efd854dc73aa8a49f61b57 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_38c0c92910efd854dc73aa8a49f61b57)) { - Py_XDECREF(cache_frame_38c0c92910efd854dc73aa8a49f61b57); - -#if _DEBUG_REFCOUNTS - if (cache_frame_38c0c92910efd854dc73aa8a49f61b57 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_38c0c92910efd854dc73aa8a49f61b57 = MAKE_FUNCTION_FRAME(codeobj_38c0c92910efd854dc73aa8a49f61b57, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_38c0c92910efd854dc73aa8a49f61b57->m_type_description == NULL); - frame_38c0c92910efd854dc73aa8a49f61b57 = cache_frame_38c0c92910efd854dc73aa8a49f61b57; - - // Push the new frame as the currently active one. - pushFrameStack(frame_38c0c92910efd854dc73aa8a49f61b57); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_38c0c92910efd854dc73aa8a49f61b57) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_subscript_name_1; - CHECK_OBJECT(par_past_key_value); - tmp_compexpr_left_1 = par_past_key_value; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - CHECK_OBJECT(par_past_key_value); - tmp_expression_name_1 = par_past_key_value; - tmp_subscript_name_1 = mod_consts[122]; - tmp_assign_source_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_1, tmp_subscript_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 415; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto condexpr_end_1; - condexpr_false_1:; - tmp_assign_source_1 = Py_None; - Py_INCREF(tmp_assign_source_1); - condexpr_end_1:; - assert(var_self_attn_past_key_value == NULL); - var_self_attn_past_key_value = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[110]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 417; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_hidden_states); - tmp_tuple_element_1 = par_hidden_states; - tmp_args_name_1 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - CHECK_OBJECT(par_attention_mask); - tmp_tuple_element_1 = par_attention_mask; - PyTuple_SET_ITEM0(tmp_args_name_1, 1, tmp_tuple_element_1); - CHECK_OBJECT(par_head_mask); - tmp_tuple_element_1 = par_head_mask; - PyTuple_SET_ITEM0(tmp_args_name_1, 2, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[123]; - CHECK_OBJECT(par_output_attentions); - tmp_dict_value_1 = par_output_attentions; - tmp_kwargs_name_1 = _PyDict_NewPresized( 2 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[124]; - CHECK_OBJECT(var_self_attn_past_key_value); - tmp_dict_value_1 = var_self_attn_past_key_value; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_38c0c92910efd854dc73aa8a49f61b57->m_frame.f_lineno = 417; - tmp_assign_source_2 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 417; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_self_attention_outputs == NULL); - var_self_attention_outputs = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_expression_name_3; - PyObject *tmp_subscript_name_2; - CHECK_OBJECT(var_self_attention_outputs); - tmp_expression_name_3 = var_self_attention_outputs; - tmp_subscript_name_2 = mod_consts[29]; - tmp_assign_source_3 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_3, tmp_subscript_name_2, 0); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 424; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_attention_output == NULL); - var_attention_output = tmp_assign_source_3; - } - { - PyObject *tmp_assign_source_4; - PyObject *tmp_expression_name_4; - PyObject *tmp_subscript_name_3; - CHECK_OBJECT(var_self_attention_outputs); - tmp_expression_name_4 = var_self_attention_outputs; - tmp_subscript_name_3 = mod_consts[125]; - tmp_assign_source_4 = LOOKUP_SUBSCRIPT(tmp_expression_name_4, tmp_subscript_name_3); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 425; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_outputs == NULL); - var_outputs = tmp_assign_source_4; - } - { - PyObject *tmp_assign_source_5; - PyObject *tmp_expression_name_5; - PyObject *tmp_subscript_name_4; - CHECK_OBJECT(var_self_attention_outputs); - tmp_expression_name_5 = var_self_attention_outputs; - tmp_subscript_name_4 = mod_consts[126]; - tmp_assign_source_5 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_5, tmp_subscript_name_4, -1); - if (tmp_assign_source_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 427; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_present_key_value == NULL); - var_present_key_value = tmp_assign_source_5; - } - { - nuitka_bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - PyObject *tmp_tmp_condition_result_2_object_1; - int tmp_truth_name_1; - CHECK_OBJECT(par_query_length); - tmp_compexpr_left_2 = par_query_length; - tmp_compexpr_right_2 = mod_consts[29]; - tmp_tmp_condition_result_2_object_1 = RICH_COMPARE_GT_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_2, tmp_compexpr_right_2); - if (tmp_tmp_condition_result_2_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 429; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_tmp_condition_result_2_object_1); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_2_object_1); - - exception_lineno = 429; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_2 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_2_object_1); - if (tmp_condition_result_2 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_6; - PyObject *tmp_expression_name_6; - PyObject *tmp_subscript_name_5; - PyObject *tmp_tuple_element_2; - CHECK_OBJECT(var_attention_output); - tmp_expression_name_6 = var_attention_output; - tmp_tuple_element_2 = mod_consts[30]; - tmp_subscript_name_5 = PyTuple_New(3); - { - PyObject *tmp_stop_name_1; - PyTuple_SET_ITEM0(tmp_subscript_name_5, 0, tmp_tuple_element_2); - CHECK_OBJECT(par_query_length); - tmp_stop_name_1 = par_query_length; - tmp_tuple_element_2 = MAKE_SLICEOBJ1(tmp_stop_name_1); - assert(!(tmp_tuple_element_2 == NULL)); - PyTuple_SET_ITEM(tmp_subscript_name_5, 1, tmp_tuple_element_2); - tmp_tuple_element_2 = mod_consts[30]; - PyTuple_SET_ITEM0(tmp_subscript_name_5, 2, tmp_tuple_element_2); - } - tmp_assign_source_6 = LOOKUP_SUBSCRIPT(tmp_expression_name_6, tmp_subscript_name_5); - Py_DECREF(tmp_subscript_name_5); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 430; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_query_attention_output == NULL); - var_query_attention_output = tmp_assign_source_6; - } - { - nuitka_bool tmp_condition_result_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_attribute_value_1; - int tmp_truth_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 432; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_self; - tmp_attribute_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[116]); - if (tmp_attribute_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 432; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_2 = CHECK_IF_TRUE(tmp_attribute_value_1); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_attribute_value_1); - - exception_lineno = 432; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_3 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_attribute_value_1); - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_compexpr_left_3 = par_encoder_hidden_states; - tmp_compexpr_right_3 = Py_None; - tmp_condition_result_4 = (tmp_compexpr_left_3 == tmp_compexpr_right_3) ? true : false; - if (tmp_condition_result_4 != false) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_raise_type_1; - PyObject *tmp_raise_value_1; - tmp_raise_type_1 = PyExc_AssertionError; - tmp_raise_value_1 = mod_consts[127]; - exception_type = tmp_raise_type_1; - Py_INCREF(tmp_raise_type_1); - exception_value = tmp_raise_value_1; - Py_INCREF(tmp_raise_value_1); - exception_lineno = 433; - RAISE_EXCEPTION_WITH_VALUE(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - branch_no_3:; - { - PyObject *tmp_assign_source_7; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_8; - PyObject *tmp_args_name_2; - PyObject *tmp_tuple_element_3; - PyObject *tmp_kwargs_name_2; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 436; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_self; - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[115]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 436; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_query_attention_output); - tmp_tuple_element_3 = var_query_attention_output; - tmp_args_name_2 = PyTuple_New(5); - PyTuple_SET_ITEM0(tmp_args_name_2, 0, tmp_tuple_element_3); - if (par_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 438; - type_description_1 = "oooooooooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_3 = par_attention_mask; - PyTuple_SET_ITEM0(tmp_args_name_2, 1, tmp_tuple_element_3); - if (par_head_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[129]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 439; - type_description_1 = "oooooooooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_3 = par_head_mask; - PyTuple_SET_ITEM0(tmp_args_name_2, 2, tmp_tuple_element_3); - CHECK_OBJECT(par_encoder_hidden_states); - tmp_tuple_element_3 = par_encoder_hidden_states; - PyTuple_SET_ITEM0(tmp_args_name_2, 3, tmp_tuple_element_3); - CHECK_OBJECT(par_encoder_attention_mask); - tmp_tuple_element_3 = par_encoder_attention_mask; - PyTuple_SET_ITEM0(tmp_args_name_2, 4, tmp_tuple_element_3); - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_dict_key_2 = mod_consts[123]; - if (par_output_attentions == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[123]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 442; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_2 = par_output_attentions; - tmp_kwargs_name_2 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - frame_38c0c92910efd854dc73aa8a49f61b57->m_frame.f_lineno = 436; - tmp_assign_source_7 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_2, tmp_kwargs_name_2); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_2); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 436; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_cross_attention_outputs == NULL); - var_cross_attention_outputs = tmp_assign_source_7; - } - { - PyObject *tmp_assign_source_8; - PyObject *tmp_expression_name_9; - PyObject *tmp_subscript_name_6; - CHECK_OBJECT(var_cross_attention_outputs); - tmp_expression_name_9 = var_cross_attention_outputs; - tmp_subscript_name_6 = mod_consts[29]; - tmp_assign_source_8 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_9, tmp_subscript_name_6, 0); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 444; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_query_attention_output; - var_query_attention_output = tmp_assign_source_8; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_9; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_10; - PyObject *tmp_subscript_name_7; - CHECK_OBJECT(var_outputs); - tmp_left_name_1 = var_outputs; - CHECK_OBJECT(var_cross_attention_outputs); - tmp_expression_name_10 = var_cross_attention_outputs; - tmp_subscript_name_7 = mod_consts[125]; - tmp_right_name_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_10, tmp_subscript_name_7); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 446; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_9 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 446; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_outputs; - var_outputs = tmp_assign_source_9; - Py_XDECREF(old); - } - - } - branch_no_2:; - { - PyObject *tmp_assign_source_10; - PyObject *tmp_called_name_3; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_11; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_12; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_13; - PyObject *tmp_args_element_name_4; - tmp_called_name_3 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[130]); - - if (unlikely(tmp_called_name_3 == NULL)) { - tmp_called_name_3 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[130]); - } - - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 449; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 450; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_11 = par_self; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[131]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 450; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 451; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_12 = par_self; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[107]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 451; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 452; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_13 = par_self; - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[108]); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - - exception_lineno = 452; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_query_attention_output); - tmp_args_element_name_4 = var_query_attention_output; - frame_38c0c92910efd854dc73aa8a49f61b57->m_frame.f_lineno = 449; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2, tmp_args_element_name_3, tmp_args_element_name_4}; - tmp_assign_source_10 = CALL_FUNCTION_WITH_ARGS4(tmp_called_name_3, call_args); - } - - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - Py_DECREF(tmp_args_element_name_3); - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 449; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_layer_output == NULL); - var_layer_output = tmp_assign_source_10; - } - { - nuitka_bool tmp_condition_result_5; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - PyObject *tmp_expression_name_14; - PyObject *tmp_expression_name_15; - PyObject *tmp_subscript_name_8; - CHECK_OBJECT(var_attention_output); - tmp_expression_name_15 = var_attention_output; - tmp_expression_name_14 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[132]); - if (tmp_expression_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 455; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_8 = mod_consts[28]; - tmp_compexpr_left_4 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_14, tmp_subscript_name_8, 1); - Py_DECREF(tmp_expression_name_14); - if (tmp_compexpr_left_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 455; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_query_length); - tmp_compexpr_right_4 = par_query_length; - tmp_condition_result_5 = RICH_COMPARE_GT_NBOOL_OBJECT_OBJECT(tmp_compexpr_left_4, tmp_compexpr_right_4); - Py_DECREF(tmp_compexpr_left_4); - if (tmp_condition_result_5 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 455; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - assert(tmp_condition_result_5 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_4:; - { - PyObject *tmp_assign_source_11; - PyObject *tmp_called_name_4; - PyObject *tmp_args_element_name_5; - PyObject *tmp_expression_name_16; - PyObject *tmp_args_element_name_6; - PyObject *tmp_expression_name_17; - PyObject *tmp_args_element_name_7; - PyObject *tmp_expression_name_18; - PyObject *tmp_args_element_name_8; - PyObject *tmp_expression_name_19; - PyObject *tmp_subscript_name_9; - PyObject *tmp_tuple_element_4; - tmp_called_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[130]); - - if (unlikely(tmp_called_name_4 == NULL)) { - tmp_called_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[130]); - } - - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 456; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 457; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_16 = par_self; - tmp_args_element_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_16, mod_consts[133]); - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 457; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 458; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_17 = par_self; - tmp_args_element_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[107]); - if (tmp_args_element_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_5); - - exception_lineno = 458; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_5); - Py_DECREF(tmp_args_element_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 459; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_18 = par_self; - tmp_args_element_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_18, mod_consts[108]); - if (tmp_args_element_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_5); - Py_DECREF(tmp_args_element_name_6); - - exception_lineno = 459; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (var_attention_output == NULL) { - Py_DECREF(tmp_args_element_name_5); - Py_DECREF(tmp_args_element_name_6); - Py_DECREF(tmp_args_element_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[134]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 460; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_19 = var_attention_output; - tmp_tuple_element_4 = mod_consts[30]; - tmp_subscript_name_9 = PyTuple_New(3); - { - PyObject *tmp_start_name_1; - PyObject *tmp_stop_name_2; - PyTuple_SET_ITEM0(tmp_subscript_name_9, 0, tmp_tuple_element_4); - CHECK_OBJECT(par_query_length); - tmp_start_name_1 = par_query_length; - tmp_stop_name_2 = Py_None; - tmp_tuple_element_4 = MAKE_SLICEOBJ2(tmp_start_name_1, tmp_stop_name_2); - assert(!(tmp_tuple_element_4 == NULL)); - PyTuple_SET_ITEM(tmp_subscript_name_9, 1, tmp_tuple_element_4); - tmp_tuple_element_4 = mod_consts[30]; - PyTuple_SET_ITEM0(tmp_subscript_name_9, 2, tmp_tuple_element_4); - } - tmp_args_element_name_8 = LOOKUP_SUBSCRIPT(tmp_expression_name_19, tmp_subscript_name_9); - Py_DECREF(tmp_subscript_name_9); - if (tmp_args_element_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_5); - Py_DECREF(tmp_args_element_name_6); - Py_DECREF(tmp_args_element_name_7); - - exception_lineno = 460; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_38c0c92910efd854dc73aa8a49f61b57->m_frame.f_lineno = 456; - { - PyObject *call_args[] = {tmp_args_element_name_5, tmp_args_element_name_6, tmp_args_element_name_7, tmp_args_element_name_8}; - tmp_assign_source_11 = CALL_FUNCTION_WITH_ARGS4(tmp_called_name_4, call_args); - } - - Py_DECREF(tmp_args_element_name_5); - Py_DECREF(tmp_args_element_name_6); - Py_DECREF(tmp_args_element_name_7); - Py_DECREF(tmp_args_element_name_8); - if (tmp_assign_source_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 456; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_layer_output_text == NULL); - var_layer_output_text = tmp_assign_source_11; - } - { - PyObject *tmp_assign_source_12; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_20; - PyObject *tmp_args_name_3; - PyObject *tmp_tuple_element_5; - PyObject *tmp_list_element_1; - PyObject *tmp_kwargs_name_3; - tmp_expression_name_20 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_20 == NULL)) { - tmp_expression_name_20 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 462; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[33]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 462; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_layer_output); - tmp_list_element_1 = var_layer_output; - tmp_tuple_element_5 = PyList_New(2); - PyList_SET_ITEM0(tmp_tuple_element_5, 0, tmp_list_element_1); - CHECK_OBJECT(var_layer_output_text); - tmp_list_element_1 = var_layer_output_text; - PyList_SET_ITEM0(tmp_tuple_element_5, 1, tmp_list_element_1); - tmp_args_name_3 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_3, 0, tmp_tuple_element_5); - tmp_kwargs_name_3 = PyDict_Copy(mod_consts[34]); - frame_38c0c92910efd854dc73aa8a49f61b57->m_frame.f_lineno = 462; - tmp_assign_source_12 = CALL_FUNCTION(tmp_called_name_5, tmp_args_name_3, tmp_kwargs_name_3); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_name_3); - Py_DECREF(tmp_kwargs_name_3); - if (tmp_assign_source_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 462; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_layer_output; - var_layer_output = tmp_assign_source_12; - Py_XDECREF(old); - } - - } - branch_no_4:; - goto branch_end_1; - branch_no_1:; - { - PyObject *tmp_assign_source_13; - PyObject *tmp_called_name_6; - PyObject *tmp_args_element_name_9; - PyObject *tmp_expression_name_21; - PyObject *tmp_args_element_name_10; - PyObject *tmp_expression_name_22; - PyObject *tmp_args_element_name_11; - PyObject *tmp_expression_name_23; - PyObject *tmp_args_element_name_12; - tmp_called_name_6 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[130]); - - if (unlikely(tmp_called_name_6 == NULL)) { - tmp_called_name_6 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[130]); - } - - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 464; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 465; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_21 = par_self; - tmp_args_element_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_21, mod_consts[133]); - if (tmp_args_element_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 465; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_9); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 466; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_22 = par_self; - tmp_args_element_name_10 = LOOKUP_ATTRIBUTE(tmp_expression_name_22, mod_consts[107]); - if (tmp_args_element_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_9); - - exception_lineno = 466; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_args_element_name_9); - Py_DECREF(tmp_args_element_name_10); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 467; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_23 = par_self; - tmp_args_element_name_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[108]); - if (tmp_args_element_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_9); - Py_DECREF(tmp_args_element_name_10); - - exception_lineno = 467; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_attention_output); - tmp_args_element_name_12 = var_attention_output; - frame_38c0c92910efd854dc73aa8a49f61b57->m_frame.f_lineno = 464; - { - PyObject *call_args[] = {tmp_args_element_name_9, tmp_args_element_name_10, tmp_args_element_name_11, tmp_args_element_name_12}; - tmp_assign_source_13 = CALL_FUNCTION_WITH_ARGS4(tmp_called_name_6, call_args); - } - - Py_DECREF(tmp_args_element_name_9); - Py_DECREF(tmp_args_element_name_10); - Py_DECREF(tmp_args_element_name_11); - if (tmp_assign_source_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 464; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_layer_output == NULL); - var_layer_output = tmp_assign_source_13; - } - branch_end_1:; - { - PyObject *tmp_assign_source_14; - PyObject *tmp_left_name_2; - PyObject *tmp_tuple_element_6; - PyObject *tmp_right_name_2; - if (var_layer_output == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[135]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 470; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_6 = var_layer_output; - tmp_left_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_left_name_2, 0, tmp_tuple_element_6); - if (var_outputs == NULL) { - Py_DECREF(tmp_left_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[136]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 470; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_right_name_2 = var_outputs; - tmp_assign_source_14 = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_left_name_2); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 470; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_outputs; - var_outputs = tmp_assign_source_14; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_15; - PyObject *tmp_left_name_3; - PyObject *tmp_right_name_3; - PyObject *tmp_tuple_element_7; - CHECK_OBJECT(var_outputs); - tmp_left_name_3 = var_outputs; - CHECK_OBJECT(var_present_key_value); - tmp_tuple_element_7 = var_present_key_value; - tmp_right_name_3 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_right_name_3, 0, tmp_tuple_element_7); - tmp_assign_source_15 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_3, tmp_right_name_3); - Py_DECREF(tmp_right_name_3); - if (tmp_assign_source_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 472; - type_description_1 = "oooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_outputs; - var_outputs = tmp_assign_source_15; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_38c0c92910efd854dc73aa8a49f61b57); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_38c0c92910efd854dc73aa8a49f61b57); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_38c0c92910efd854dc73aa8a49f61b57, exception_lineno); - } else if (exception_tb->tb_frame != &frame_38c0c92910efd854dc73aa8a49f61b57->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_38c0c92910efd854dc73aa8a49f61b57, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_38c0c92910efd854dc73aa8a49f61b57, - type_description_1, - par_self, - par_hidden_states, - par_attention_mask, - par_head_mask, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_past_key_value, - par_output_attentions, - par_query_length, - var_self_attn_past_key_value, - var_self_attention_outputs, - var_attention_output, - var_outputs, - var_present_key_value, - var_query_attention_output, - var_cross_attention_outputs, - var_layer_output, - var_layer_output_text - ); - - - // Release cached frame if used for exception. - if (frame_38c0c92910efd854dc73aa8a49f61b57 == cache_frame_38c0c92910efd854dc73aa8a49f61b57) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_38c0c92910efd854dc73aa8a49f61b57); - cache_frame_38c0c92910efd854dc73aa8a49f61b57 = NULL; - } - - assertFrameObject(frame_38c0c92910efd854dc73aa8a49f61b57); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_outputs); - tmp_return_value = var_outputs; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - CHECK_OBJECT(par_past_key_value); - Py_DECREF(par_past_key_value); - par_past_key_value = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - CHECK_OBJECT(par_query_length); - Py_DECREF(par_query_length); - par_query_length = NULL; - Py_XDECREF(var_self_attn_past_key_value); - var_self_attn_past_key_value = NULL; - CHECK_OBJECT(var_self_attention_outputs); - Py_DECREF(var_self_attention_outputs); - var_self_attention_outputs = NULL; - Py_XDECREF(var_attention_output); - var_attention_output = NULL; - CHECK_OBJECT(var_outputs); - Py_DECREF(var_outputs); - var_outputs = NULL; - CHECK_OBJECT(var_present_key_value); - Py_DECREF(var_present_key_value); - var_present_key_value = NULL; - Py_XDECREF(var_query_attention_output); - var_query_attention_output = NULL; - Py_XDECREF(var_cross_attention_outputs); - var_cross_attention_outputs = NULL; - Py_XDECREF(var_layer_output); - var_layer_output = NULL; - Py_XDECREF(var_layer_output_text); - var_layer_output_text = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - CHECK_OBJECT(par_past_key_value); - Py_DECREF(par_past_key_value); - par_past_key_value = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - CHECK_OBJECT(par_query_length); - Py_DECREF(par_query_length); - par_query_length = NULL; - Py_XDECREF(var_self_attn_past_key_value); - var_self_attn_past_key_value = NULL; - Py_XDECREF(var_self_attention_outputs); - var_self_attention_outputs = NULL; - Py_XDECREF(var_attention_output); - var_attention_output = NULL; - Py_XDECREF(var_outputs); - var_outputs = NULL; - Py_XDECREF(var_present_key_value); - var_present_key_value = NULL; - Py_XDECREF(var_query_attention_output); - var_query_attention_output = NULL; - Py_XDECREF(var_cross_attention_outputs); - var_cross_attention_outputs = NULL; - Py_XDECREF(var_layer_output); - var_layer_output = NULL; - Py_XDECREF(var_layer_output_text); - var_layer_output_text = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__21_feed_forward_chunk(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_attention_output = python_pars[1]; - PyObject *var_intermediate_output = NULL; - PyObject *var_layer_output = NULL; - struct Nuitka_FrameObject *frame_c4755f7ecaad447ef5e0ea80f9a42013; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_c4755f7ecaad447ef5e0ea80f9a42013 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_c4755f7ecaad447ef5e0ea80f9a42013)) { - Py_XDECREF(cache_frame_c4755f7ecaad447ef5e0ea80f9a42013); - -#if _DEBUG_REFCOUNTS - if (cache_frame_c4755f7ecaad447ef5e0ea80f9a42013 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_c4755f7ecaad447ef5e0ea80f9a42013 = MAKE_FUNCTION_FRAME(codeobj_c4755f7ecaad447ef5e0ea80f9a42013, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_c4755f7ecaad447ef5e0ea80f9a42013->m_type_description == NULL); - frame_c4755f7ecaad447ef5e0ea80f9a42013 = cache_frame_c4755f7ecaad447ef5e0ea80f9a42013; - - // Push the new frame as the currently active one. - pushFrameStack(frame_c4755f7ecaad447ef5e0ea80f9a42013); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_c4755f7ecaad447ef5e0ea80f9a42013) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_attention_output); - tmp_args_element_name_1 = par_attention_output; - frame_c4755f7ecaad447ef5e0ea80f9a42013->m_frame.f_lineno = 477; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[118], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 477; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(var_intermediate_output == NULL); - var_intermediate_output = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 478; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_1 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[95]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 478; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_intermediate_output); - tmp_args_element_name_2 = var_intermediate_output; - if (par_attention_output == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[134]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 478; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_3 = par_attention_output; - frame_c4755f7ecaad447ef5e0ea80f9a42013->m_frame.f_lineno = 478; - { - PyObject *call_args[] = {tmp_args_element_name_2, tmp_args_element_name_3}; - tmp_assign_source_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 478; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(var_layer_output == NULL); - var_layer_output = tmp_assign_source_2; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_c4755f7ecaad447ef5e0ea80f9a42013); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_c4755f7ecaad447ef5e0ea80f9a42013); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_c4755f7ecaad447ef5e0ea80f9a42013, exception_lineno); - } else if (exception_tb->tb_frame != &frame_c4755f7ecaad447ef5e0ea80f9a42013->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_c4755f7ecaad447ef5e0ea80f9a42013, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_c4755f7ecaad447ef5e0ea80f9a42013, - type_description_1, - par_self, - par_attention_output, - var_intermediate_output, - var_layer_output - ); - - - // Release cached frame if used for exception. - if (frame_c4755f7ecaad447ef5e0ea80f9a42013 == cache_frame_c4755f7ecaad447ef5e0ea80f9a42013) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_c4755f7ecaad447ef5e0ea80f9a42013); - cache_frame_c4755f7ecaad447ef5e0ea80f9a42013 = NULL; - } - - assertFrameObject(frame_c4755f7ecaad447ef5e0ea80f9a42013); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_layer_output); - tmp_return_value = var_layer_output; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_attention_output); - par_attention_output = NULL; - Py_XDECREF(var_intermediate_output); - var_intermediate_output = NULL; - CHECK_OBJECT(var_layer_output); - Py_DECREF(var_layer_output); - var_layer_output = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_attention_output); - par_attention_output = NULL; - Py_XDECREF(var_intermediate_output); - var_intermediate_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__22_feed_forward_chunk_query(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_attention_output = python_pars[1]; - PyObject *var_intermediate_output = NULL; - PyObject *var_layer_output = NULL; - struct Nuitka_FrameObject *frame_bc4467ccc7610a81a2b180cada5c22ef; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_bc4467ccc7610a81a2b180cada5c22ef = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_bc4467ccc7610a81a2b180cada5c22ef)) { - Py_XDECREF(cache_frame_bc4467ccc7610a81a2b180cada5c22ef); - -#if _DEBUG_REFCOUNTS - if (cache_frame_bc4467ccc7610a81a2b180cada5c22ef == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_bc4467ccc7610a81a2b180cada5c22ef = MAKE_FUNCTION_FRAME(codeobj_bc4467ccc7610a81a2b180cada5c22ef, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_bc4467ccc7610a81a2b180cada5c22ef->m_type_description == NULL); - frame_bc4467ccc7610a81a2b180cada5c22ef = cache_frame_bc4467ccc7610a81a2b180cada5c22ef; - - // Push the new frame as the currently active one. - pushFrameStack(frame_bc4467ccc7610a81a2b180cada5c22ef); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_bc4467ccc7610a81a2b180cada5c22ef) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_attention_output); - tmp_args_element_name_1 = par_attention_output; - frame_bc4467ccc7610a81a2b180cada5c22ef->m_frame.f_lineno = 482; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[120], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 482; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(var_intermediate_output == NULL); - var_intermediate_output = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 483; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_1 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[121]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 483; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_intermediate_output); - tmp_args_element_name_2 = var_intermediate_output; - if (par_attention_output == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[134]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 483; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_3 = par_attention_output; - frame_bc4467ccc7610a81a2b180cada5c22ef->m_frame.f_lineno = 483; - { - PyObject *call_args[] = {tmp_args_element_name_2, tmp_args_element_name_3}; - tmp_assign_source_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 483; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(var_layer_output == NULL); - var_layer_output = tmp_assign_source_2; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_bc4467ccc7610a81a2b180cada5c22ef); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_bc4467ccc7610a81a2b180cada5c22ef); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_bc4467ccc7610a81a2b180cada5c22ef, exception_lineno); - } else if (exception_tb->tb_frame != &frame_bc4467ccc7610a81a2b180cada5c22ef->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_bc4467ccc7610a81a2b180cada5c22ef, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_bc4467ccc7610a81a2b180cada5c22ef, - type_description_1, - par_self, - par_attention_output, - var_intermediate_output, - var_layer_output - ); - - - // Release cached frame if used for exception. - if (frame_bc4467ccc7610a81a2b180cada5c22ef == cache_frame_bc4467ccc7610a81a2b180cada5c22ef) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_bc4467ccc7610a81a2b180cada5c22ef); - cache_frame_bc4467ccc7610a81a2b180cada5c22ef = NULL; - } - - assertFrameObject(frame_bc4467ccc7610a81a2b180cada5c22ef); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_layer_output); - tmp_return_value = var_layer_output; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_attention_output); - par_attention_output = NULL; - Py_XDECREF(var_intermediate_output); - var_intermediate_output = NULL; - CHECK_OBJECT(var_layer_output); - Py_DECREF(var_layer_output); - var_layer_output = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_attention_output); - par_attention_output = NULL; - Py_XDECREF(var_intermediate_output); - var_intermediate_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__23___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - PyObject *outline_0_var_i = NULL; - PyObject *tmp_listcomp_1__$0 = NULL; - PyObject *tmp_listcomp_1__contraction = NULL; - PyObject *tmp_listcomp_1__iter_value_0 = NULL; - struct Nuitka_FrameObject *frame_dbb5244b0ee9d68abb3ae7983cb8df4b; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - struct Nuitka_FrameObject *frame_67be2144f29b126bccab22fc958e7dc4_2; - NUITKA_MAY_BE_UNUSED char const *type_description_2 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - static struct Nuitka_FrameObject *cache_frame_67be2144f29b126bccab22fc958e7dc4_2 = NULL; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - static struct Nuitka_FrameObject *cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_3; - PyObject *exception_keeper_value_3; - PyTracebackObject *exception_keeper_tb_3; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_3; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b)) { - Py_XDECREF(cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b); - -#if _DEBUG_REFCOUNTS - if (cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b = MAKE_FUNCTION_FRAME(codeobj_dbb5244b0ee9d68abb3ae7983cb8df4b, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b->m_type_description == NULL); - frame_dbb5244b0ee9d68abb3ae7983cb8df4b = cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b; - - // Push the new frame as the currently active one. - pushFrameStack(frame_dbb5244b0ee9d68abb3ae7983cb8df4b); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_dbb5244b0ee9d68abb3ae7983cb8df4b) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 489; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 489; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_dbb5244b0ee9d68abb3ae7983cb8df4b->m_frame.f_lineno = 489; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 489; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - CHECK_OBJECT(par_config); - tmp_assattr_name_1 = par_config; - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[5], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 490; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_assattr_target_2; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 491; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[137]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 491; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - // Tried code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_iter_arg_1; - PyObject *tmp_xrange_low_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_xrange_low_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[138]); - if (tmp_xrange_low_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_1 = "ooc"; - goto try_except_handler_2; - } - tmp_iter_arg_1 = BUILTIN_XRANGE1(tmp_xrange_low_1); - Py_DECREF(tmp_xrange_low_1); - if (tmp_iter_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_1 = "ooc"; - goto try_except_handler_2; - } - tmp_assign_source_1 = MAKE_ITERATOR(tmp_iter_arg_1); - Py_DECREF(tmp_iter_arg_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_1 = "ooc"; - goto try_except_handler_2; - } - assert(tmp_listcomp_1__$0 == NULL); - tmp_listcomp_1__$0 = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - tmp_assign_source_2 = PyList_New(0); - assert(tmp_listcomp_1__contraction == NULL); - tmp_listcomp_1__contraction = tmp_assign_source_2; - } - if (isFrameUnusable(cache_frame_67be2144f29b126bccab22fc958e7dc4_2)) { - Py_XDECREF(cache_frame_67be2144f29b126bccab22fc958e7dc4_2); - -#if _DEBUG_REFCOUNTS - if (cache_frame_67be2144f29b126bccab22fc958e7dc4_2 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_67be2144f29b126bccab22fc958e7dc4_2 = MAKE_FUNCTION_FRAME(codeobj_67be2144f29b126bccab22fc958e7dc4, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_67be2144f29b126bccab22fc958e7dc4_2->m_type_description == NULL); - frame_67be2144f29b126bccab22fc958e7dc4_2 = cache_frame_67be2144f29b126bccab22fc958e7dc4_2; - - // Push the new frame as the currently active one. - pushFrameStack(frame_67be2144f29b126bccab22fc958e7dc4_2); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_67be2144f29b126bccab22fc958e7dc4_2) == 2); // Frame stack - - // Framed code: - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_3; - CHECK_OBJECT(tmp_listcomp_1__$0); - tmp_next_source_1 = tmp_listcomp_1__$0; - tmp_assign_source_3 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_3 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - type_description_2 = "oo"; - exception_lineno = 492; - goto try_except_handler_3; - } - } - - { - PyObject *old = tmp_listcomp_1__iter_value_0; - tmp_listcomp_1__iter_value_0 = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_4; - CHECK_OBJECT(tmp_listcomp_1__iter_value_0); - tmp_assign_source_4 = tmp_listcomp_1__iter_value_0; - { - PyObject *old = outline_0_var_i; - outline_0_var_i = tmp_assign_source_4; - Py_INCREF(outline_0_var_i); - Py_XDECREF(old); - } - - } - { - PyObject *tmp_append_list_1; - PyObject *tmp_append_value_1; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - CHECK_OBJECT(tmp_listcomp_1__contraction); - tmp_append_list_1 = tmp_listcomp_1__contraction; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[139]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[139]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_2 = "oo"; - goto try_except_handler_3; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 492; - type_description_2 = "oo"; - goto try_except_handler_3; - } - - tmp_args_element_name_2 = par_config; - CHECK_OBJECT(outline_0_var_i); - tmp_args_element_name_3 = outline_0_var_i; - frame_67be2144f29b126bccab22fc958e7dc4_2->m_frame.f_lineno = 492; - { - PyObject *call_args[] = {tmp_args_element_name_2, tmp_args_element_name_3}; - tmp_append_value_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_2, call_args); - } - - if (tmp_append_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_2 = "oo"; - goto try_except_handler_3; - } - assert(PyList_Check(tmp_append_list_1)); - tmp_result = LIST_APPEND1(tmp_append_list_1, tmp_append_value_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_2 = "oo"; - goto try_except_handler_3; - } - } - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 492; - type_description_2 = "oo"; - goto try_except_handler_3; - } - goto loop_start_1; - loop_end_1:; - CHECK_OBJECT(tmp_listcomp_1__contraction); - tmp_args_element_name_1 = tmp_listcomp_1__contraction; - Py_INCREF(tmp_args_element_name_1); - goto try_return_handler_3; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_3:; - Py_XDECREF(tmp_listcomp_1__$0); - tmp_listcomp_1__$0 = NULL; - CHECK_OBJECT(tmp_listcomp_1__contraction); - Py_DECREF(tmp_listcomp_1__contraction); - tmp_listcomp_1__contraction = NULL; - Py_XDECREF(tmp_listcomp_1__iter_value_0); - tmp_listcomp_1__iter_value_0 = NULL; - goto frame_return_exit_1; - // Exception handler code: - try_except_handler_3:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_listcomp_1__$0); - tmp_listcomp_1__$0 = NULL; - CHECK_OBJECT(tmp_listcomp_1__contraction); - Py_DECREF(tmp_listcomp_1__contraction); - tmp_listcomp_1__contraction = NULL; - Py_XDECREF(tmp_listcomp_1__iter_value_0); - tmp_listcomp_1__iter_value_0 = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto frame_exception_exit_2; - // End of try: - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_67be2144f29b126bccab22fc958e7dc4_2); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_67be2144f29b126bccab22fc958e7dc4_2); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_2; - - frame_exception_exit_2:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_67be2144f29b126bccab22fc958e7dc4_2); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_67be2144f29b126bccab22fc958e7dc4_2, exception_lineno); - } else if (exception_tb->tb_frame != &frame_67be2144f29b126bccab22fc958e7dc4_2->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_67be2144f29b126bccab22fc958e7dc4_2, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_67be2144f29b126bccab22fc958e7dc4_2, - type_description_2, - outline_0_var_i, - par_config - ); - - - // Release cached frame if used for exception. - if (frame_67be2144f29b126bccab22fc958e7dc4_2 == cache_frame_67be2144f29b126bccab22fc958e7dc4_2) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_67be2144f29b126bccab22fc958e7dc4_2); - cache_frame_67be2144f29b126bccab22fc958e7dc4_2 = NULL; - } - - assertFrameObject(frame_67be2144f29b126bccab22fc958e7dc4_2); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_1; - - frame_no_exception_1:; - goto skip_nested_handling_1; - nested_frame_exit_1:; - type_description_1 = "ooc"; - goto try_except_handler_2; - skip_nested_handling_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_2:; - Py_XDECREF(outline_0_var_i); - outline_0_var_i = NULL; - goto outline_result_1; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(outline_0_var_i); - outline_0_var_i = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto outline_exception_1; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_1:; - exception_lineno = 492; - goto frame_exception_exit_1; - outline_result_1:; - frame_dbb5244b0ee9d68abb3ae7983cb8df4b->m_frame.f_lineno = 491; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 491; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[140], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 491; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_dbb5244b0ee9d68abb3ae7983cb8df4b); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_2; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_dbb5244b0ee9d68abb3ae7983cb8df4b); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_dbb5244b0ee9d68abb3ae7983cb8df4b, exception_lineno); - } else if (exception_tb->tb_frame != &frame_dbb5244b0ee9d68abb3ae7983cb8df4b->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_dbb5244b0ee9d68abb3ae7983cb8df4b, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_dbb5244b0ee9d68abb3ae7983cb8df4b, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_dbb5244b0ee9d68abb3ae7983cb8df4b == cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b); - cache_frame_dbb5244b0ee9d68abb3ae7983cb8df4b = NULL; - } - - assertFrameObject(frame_dbb5244b0ee9d68abb3ae7983cb8df4b); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_2:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_3 = exception_type; - exception_keeper_value_3 = exception_value; - exception_keeper_tb_3 = exception_tb; - exception_keeper_lineno_3 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_3; - exception_value = exception_keeper_value_3; - exception_tb = exception_keeper_tb_3; - exception_lineno = exception_keeper_lineno_3; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__24_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_head_mask = python_pars[3]; - PyObject *par_encoder_hidden_states = python_pars[4]; - PyObject *par_encoder_attention_mask = python_pars[5]; - PyObject *par_past_key_values = python_pars[6]; - PyObject *par_use_cache = python_pars[7]; - struct Nuitka_CellObject *par_output_attentions = Nuitka_Cell_New1(python_pars[8]); - PyObject *par_output_hidden_states = python_pars[9]; - PyObject *par_return_dict = python_pars[10]; - struct Nuitka_CellObject *par_query_length = Nuitka_Cell_New1(python_pars[11]); - PyObject *var_all_hidden_states = NULL; - PyObject *var_all_self_attentions = NULL; - PyObject *var_all_cross_attentions = NULL; - PyObject *var_next_decoder_cache = NULL; - PyObject *var_i = NULL; - PyObject *var_layer_module = NULL; - PyObject *var_layer_head_mask = NULL; - struct Nuitka_CellObject *var_past_key_value = Nuitka_Cell_Empty(); - PyObject *var_create_custom_forward = NULL; - PyObject *var_layer_outputs = NULL; - PyObject *tmp_for_loop_1__for_iterator = NULL; - PyObject *tmp_for_loop_1__iter_value = NULL; - PyObject *tmp_genexpr_1__$0 = NULL; - struct Nuitka_FrameObject *frame_fb4ac8ca5f5c6cf5999268c801f1a60e; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - bool tmp_result; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - int tmp_res; - PyObject *tmp_return_value = NULL; - static struct Nuitka_FrameObject *cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e = NULL; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e)) { - Py_XDECREF(cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e); - -#if _DEBUG_REFCOUNTS - if (cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e = MAKE_FUNCTION_FRAME(codeobj_fb4ac8ca5f5c6cf5999268c801f1a60e, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_type_description == NULL); - frame_fb4ac8ca5f5c6cf5999268c801f1a60e = cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e; - - // Push the new frame as the currently active one. - pushFrameStack(frame_fb4ac8ca5f5c6cf5999268c801f1a60e); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_fb4ac8ca5f5c6cf5999268c801f1a60e) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - nuitka_bool tmp_condition_result_1; - int tmp_truth_name_1; - CHECK_OBJECT(par_output_hidden_states); - tmp_truth_name_1 = CHECK_IF_TRUE(par_output_hidden_states); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 509; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_condition_result_1 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - tmp_assign_source_1 = mod_consts[141]; - goto condexpr_end_1; - condexpr_false_1:; - tmp_assign_source_1 = Py_None; - condexpr_end_1:; - assert(var_all_hidden_states == NULL); - Py_INCREF(tmp_assign_source_1); - var_all_hidden_states = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - nuitka_bool tmp_condition_result_2; - int tmp_truth_name_2; - CHECK_OBJECT(Nuitka_Cell_GET(par_output_attentions)); - tmp_truth_name_2 = CHECK_IF_TRUE(Nuitka_Cell_GET(par_output_attentions)); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 510; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_condition_result_2 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_2 == NUITKA_BOOL_TRUE) { - goto condexpr_true_2; - } else { - goto condexpr_false_2; - } - condexpr_true_2:; - tmp_assign_source_2 = mod_consts[141]; - goto condexpr_end_2; - condexpr_false_2:; - tmp_assign_source_2 = Py_None; - condexpr_end_2:; - assert(var_all_self_attentions == NULL); - Py_INCREF(tmp_assign_source_2); - var_all_self_attentions = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - nuitka_bool tmp_condition_result_3; - int tmp_and_left_truth_1; - nuitka_bool tmp_and_left_value_1; - nuitka_bool tmp_and_right_value_1; - int tmp_truth_name_3; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_attribute_value_1; - int tmp_truth_name_4; - CHECK_OBJECT(Nuitka_Cell_GET(par_output_attentions)); - tmp_truth_name_3 = CHECK_IF_TRUE(Nuitka_Cell_GET(par_output_attentions)); - if (tmp_truth_name_3 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 512; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_and_left_value_1 = tmp_truth_name_3 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - tmp_and_left_truth_1 = tmp_and_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_and_left_truth_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 512; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - if (tmp_and_left_truth_1 == 1) { - goto and_right_1; - } else { - goto and_left_1; - } - and_right_1:; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[5]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 512; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_attribute_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[112]); - Py_DECREF(tmp_expression_name_1); - if (tmp_attribute_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 512; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_truth_name_4 = CHECK_IF_TRUE(tmp_attribute_value_1); - if (tmp_truth_name_4 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_attribute_value_1); - - exception_lineno = 512; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_and_right_value_1 = tmp_truth_name_4 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_attribute_value_1); - tmp_condition_result_3 = tmp_and_right_value_1; - goto and_end_1; - and_left_1:; - tmp_condition_result_3 = tmp_and_left_value_1; - and_end_1:; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto condexpr_true_3; - } else { - goto condexpr_false_3; - } - condexpr_true_3:; - tmp_assign_source_3 = mod_consts[141]; - goto condexpr_end_3; - condexpr_false_3:; - tmp_assign_source_3 = Py_None; - condexpr_end_3:; - assert(var_all_cross_attentions == NULL); - Py_INCREF(tmp_assign_source_3); - var_all_cross_attentions = tmp_assign_source_3; - } - { - PyObject *tmp_assign_source_4; - nuitka_bool tmp_condition_result_4; - int tmp_truth_name_5; - CHECK_OBJECT(par_use_cache); - tmp_truth_name_5 = CHECK_IF_TRUE(par_use_cache); - if (tmp_truth_name_5 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 515; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_condition_result_4 = tmp_truth_name_5 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_4 == NUITKA_BOOL_TRUE) { - goto condexpr_true_4; - } else { - goto condexpr_false_4; - } - condexpr_true_4:; - tmp_assign_source_4 = mod_consts[141]; - goto condexpr_end_4; - condexpr_false_4:; - tmp_assign_source_4 = Py_None; - condexpr_end_4:; - assert(var_next_decoder_cache == NULL); - Py_INCREF(tmp_assign_source_4); - var_next_decoder_cache = tmp_assign_source_4; - } - { - PyObject *tmp_assign_source_5; - PyObject *tmp_iter_arg_1; - PyObject *tmp_xrange_low_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_expression_name_4; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 517; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_self; - tmp_expression_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[5]); - if (tmp_expression_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 517; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_xrange_low_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[138]); - Py_DECREF(tmp_expression_name_3); - if (tmp_xrange_low_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 517; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_iter_arg_1 = BUILTIN_XRANGE1(tmp_xrange_low_1); - Py_DECREF(tmp_xrange_low_1); - if (tmp_iter_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 517; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_assign_source_5 = MAKE_ITERATOR(tmp_iter_arg_1); - Py_DECREF(tmp_iter_arg_1); - if (tmp_assign_source_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 517; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - assert(tmp_for_loop_1__for_iterator == NULL); - tmp_for_loop_1__for_iterator = tmp_assign_source_5; - } - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_6; - CHECK_OBJECT(tmp_for_loop_1__for_iterator); - tmp_next_source_1 = tmp_for_loop_1__for_iterator; - tmp_assign_source_6 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_6 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oooooooocoocooooooocoo"; - exception_lineno = 517; - goto try_except_handler_2; - } - } - - { - PyObject *old = tmp_for_loop_1__iter_value; - tmp_for_loop_1__iter_value = tmp_assign_source_6; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_7; - CHECK_OBJECT(tmp_for_loop_1__iter_value); - tmp_assign_source_7 = tmp_for_loop_1__iter_value; - { - PyObject *old = var_i; - var_i = tmp_assign_source_7; - Py_INCREF(var_i); - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_8; - PyObject *tmp_expression_name_5; - PyObject *tmp_expression_name_6; - PyObject *tmp_subscript_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 518; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_expression_name_6 = par_self; - tmp_expression_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[140]); - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 518; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - CHECK_OBJECT(var_i); - tmp_subscript_name_1 = var_i; - tmp_assign_source_8 = LOOKUP_SUBSCRIPT(tmp_expression_name_5, tmp_subscript_name_1); - Py_DECREF(tmp_expression_name_5); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 518; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = var_layer_module; - var_layer_module = tmp_assign_source_8; - Py_XDECREF(old); - } - - } - { - nuitka_bool tmp_condition_result_5; - int tmp_truth_name_6; - if (par_output_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[142]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 519; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_truth_name_6 = CHECK_IF_TRUE(par_output_hidden_states); - if (tmp_truth_name_6 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 519; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_condition_result_5 = tmp_truth_name_6 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_9; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_tuple_element_1; - if (var_all_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[143]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 520; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_left_name_1 = var_all_hidden_states; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 520; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_tuple_element_1 = par_hidden_states; - tmp_right_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_right_name_1, 0, tmp_tuple_element_1); - tmp_assign_source_9 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 520; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = var_all_hidden_states; - var_all_hidden_states = tmp_assign_source_9; - Py_XDECREF(old); - } - - } - branch_no_1:; - { - PyObject *tmp_assign_source_10; - bool tmp_condition_result_6; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_expression_name_7; - PyObject *tmp_subscript_name_2; - if (par_head_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[129]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 522; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_compexpr_left_1 = par_head_mask; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_6 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_6 != false) { - goto condexpr_true_5; - } else { - goto condexpr_false_5; - } - condexpr_true_5:; - if (par_head_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[129]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 522; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_expression_name_7 = par_head_mask; - CHECK_OBJECT(var_i); - tmp_subscript_name_2 = var_i; - tmp_assign_source_10 = LOOKUP_SUBSCRIPT(tmp_expression_name_7, tmp_subscript_name_2); - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 522; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - goto condexpr_end_5; - condexpr_false_5:; - tmp_assign_source_10 = Py_None; - Py_INCREF(tmp_assign_source_10); - condexpr_end_5:; - { - PyObject *old = var_layer_head_mask; - var_layer_head_mask = tmp_assign_source_10; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_11; - bool tmp_condition_result_7; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - PyObject *tmp_expression_name_8; - PyObject *tmp_subscript_name_3; - if (par_past_key_values == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[144]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 523; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_compexpr_left_2 = par_past_key_values; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_7 = (tmp_compexpr_left_2 != tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_7 != false) { - goto condexpr_true_6; - } else { - goto condexpr_false_6; - } - condexpr_true_6:; - if (par_past_key_values == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[144]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 523; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_expression_name_8 = par_past_key_values; - CHECK_OBJECT(var_i); - tmp_subscript_name_3 = var_i; - tmp_assign_source_11 = LOOKUP_SUBSCRIPT(tmp_expression_name_8, tmp_subscript_name_3); - if (tmp_assign_source_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 523; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - goto condexpr_end_6; - condexpr_false_6:; - tmp_assign_source_11 = Py_None; - Py_INCREF(tmp_assign_source_11); - condexpr_end_6:; - { - PyObject *old = Nuitka_Cell_GET(var_past_key_value); - PyCell_SET(var_past_key_value, tmp_assign_source_11); - Py_XDECREF(old); - } - - } - { - nuitka_bool tmp_condition_result_8; - int tmp_and_left_truth_2; - nuitka_bool tmp_and_left_value_2; - nuitka_bool tmp_and_right_value_2; - PyObject *tmp_getattr_target_1; - PyObject *tmp_expression_name_9; - PyObject *tmp_getattr_attr_1; - PyObject *tmp_getattr_default_1; - PyObject *tmp_capi_result_1; - int tmp_truth_name_7; - PyObject *tmp_expression_name_10; - PyObject *tmp_attribute_value_2; - int tmp_truth_name_8; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_expression_name_9 = par_self; - tmp_getattr_target_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[5]); - if (tmp_getattr_target_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_getattr_attr_1 = mod_consts[145]; - tmp_getattr_default_1 = Py_False; - tmp_capi_result_1 = BUILTIN_GETATTR(tmp_getattr_target_1, tmp_getattr_attr_1, tmp_getattr_default_1); - Py_DECREF(tmp_getattr_target_1); - if (tmp_capi_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_truth_name_7 = CHECK_IF_TRUE(tmp_capi_result_1); - if (tmp_truth_name_7 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_capi_result_1); - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_and_left_value_2 = tmp_truth_name_7 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_capi_result_1); - tmp_and_left_truth_2 = tmp_and_left_value_2 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_and_left_truth_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - if (tmp_and_left_truth_2 == 1) { - goto and_right_2; - } else { - goto and_left_2; - } - and_right_2:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_expression_name_10 = par_self; - tmp_attribute_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[146]); - if (tmp_attribute_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_truth_name_8 = CHECK_IF_TRUE(tmp_attribute_value_2); - if (tmp_truth_name_8 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_attribute_value_2); - - exception_lineno = 525; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_and_right_value_2 = tmp_truth_name_8 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_attribute_value_2); - tmp_condition_result_8 = tmp_and_right_value_2; - goto and_end_2; - and_left_2:; - tmp_condition_result_8 = tmp_and_left_value_2; - and_end_2:; - if (tmp_condition_result_8 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - nuitka_bool tmp_condition_result_9; - int tmp_truth_name_9; - if (par_use_cache == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[147]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 527; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_truth_name_9 = CHECK_IF_TRUE(par_use_cache); - if (tmp_truth_name_9 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 527; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_condition_result_9 = tmp_truth_name_9 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_9 == NUITKA_BOOL_TRUE) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_called_instance_1; - PyObject *tmp_call_result_1; - tmp_called_instance_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[148]); - - if (unlikely(tmp_called_instance_1 == NULL)) { - tmp_called_instance_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[148]); - } - - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 528; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_frame.f_lineno = 528; - tmp_call_result_1 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_1, - mod_consts[149], - &PyTuple_GET_ITEM(mod_consts[150], 0) - ); - - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 528; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assign_source_12; - tmp_assign_source_12 = Py_False; - { - PyObject *old = par_use_cache; - par_use_cache = tmp_assign_source_12; - Py_INCREF(par_use_cache); - Py_XDECREF(old); - } - - } - branch_no_3:; - { - PyObject *tmp_assign_source_13; - struct Nuitka_CellObject *tmp_closure_1[3]; - - tmp_closure_1[0] = par_output_attentions; - Py_INCREF(tmp_closure_1[0]); - tmp_closure_1[1] = var_past_key_value; - Py_INCREF(tmp_closure_1[1]); - tmp_closure_1[2] = par_query_length; - Py_INCREF(tmp_closure_1[2]); - - tmp_assign_source_13 = MAKE_FUNCTION_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward(tmp_closure_1); - - { - PyObject *old = var_create_custom_forward; - var_create_custom_forward = tmp_assign_source_13; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_14; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_11; - PyObject *tmp_expression_name_12; - PyObject *tmp_expression_name_13; - PyObject *tmp_args_element_name_1; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_args_element_name_4; - PyObject *tmp_args_element_name_5; - PyObject *tmp_args_element_name_6; - PyObject *tmp_args_element_name_7; - tmp_expression_name_13 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_13 == NULL)) { - tmp_expression_name_13 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 541; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_expression_name_12 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[153]); - if (tmp_expression_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 541; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_expression_name_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[154]); - Py_DECREF(tmp_expression_name_12); - if (tmp_expression_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 541; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[154]); - Py_DECREF(tmp_expression_name_11); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 541; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - CHECK_OBJECT(var_create_custom_forward); - tmp_called_name_2 = var_create_custom_forward; - CHECK_OBJECT(var_layer_module); - tmp_args_element_name_2 = var_layer_module; - frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_frame.f_lineno = 542; - tmp_args_element_name_1 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_2); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 542; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - if (par_hidden_states == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 543; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_3 = par_hidden_states; - if (par_attention_mask == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 544; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_4 = par_attention_mask; - CHECK_OBJECT(var_layer_head_mask); - tmp_args_element_name_5 = var_layer_head_mask; - if (par_encoder_hidden_states == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[60]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 546; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_6 = par_encoder_hidden_states; - if (par_encoder_attention_mask == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[155]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 547; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_7 = par_encoder_attention_mask; - frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_frame.f_lineno = 541; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_3, tmp_args_element_name_4, tmp_args_element_name_5, tmp_args_element_name_6, tmp_args_element_name_7}; - tmp_assign_source_14 = CALL_FUNCTION_WITH_ARGS6(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 541; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = var_layer_outputs; - var_layer_outputs = tmp_assign_source_14; - Py_XDECREF(old); - } - - } - goto branch_end_2; - branch_no_2:; - { - PyObject *tmp_assign_source_15; - PyObject *tmp_called_name_3; - PyObject *tmp_args_element_name_8; - PyObject *tmp_args_element_name_9; - PyObject *tmp_args_element_name_10; - PyObject *tmp_args_element_name_11; - PyObject *tmp_args_element_name_12; - PyObject *tmp_args_element_name_13; - PyObject *tmp_args_element_name_14; - PyObject *tmp_args_element_name_15; - CHECK_OBJECT(var_layer_module); - tmp_called_name_3 = var_layer_module; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 551; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_8 = par_hidden_states; - if (par_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 552; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_9 = par_attention_mask; - CHECK_OBJECT(var_layer_head_mask); - tmp_args_element_name_10 = var_layer_head_mask; - if (par_encoder_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[60]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 554; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_11 = par_encoder_hidden_states; - if (par_encoder_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[155]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 555; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_12 = par_encoder_attention_mask; - if (Nuitka_Cell_GET(var_past_key_value) == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[124]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 556; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_13 = Nuitka_Cell_GET(var_past_key_value); - if (Nuitka_Cell_GET(par_output_attentions) == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[123]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 557; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_14 = Nuitka_Cell_GET(par_output_attentions); - if (Nuitka_Cell_GET(par_query_length) == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[156]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 558; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_args_element_name_15 = Nuitka_Cell_GET(par_query_length); - frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_frame.f_lineno = 550; - { - PyObject *call_args[] = {tmp_args_element_name_8, tmp_args_element_name_9, tmp_args_element_name_10, tmp_args_element_name_11, tmp_args_element_name_12, tmp_args_element_name_13, tmp_args_element_name_14, tmp_args_element_name_15}; - tmp_assign_source_15 = CALL_FUNCTION_WITH_ARGS8(tmp_called_name_3, call_args); - } - - if (tmp_assign_source_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 550; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = var_layer_outputs; - var_layer_outputs = tmp_assign_source_15; - Py_XDECREF(old); - } - - } - branch_end_2:; - { - PyObject *tmp_assign_source_16; - PyObject *tmp_expression_name_14; - PyObject *tmp_subscript_name_4; - CHECK_OBJECT(var_layer_outputs); - tmp_expression_name_14 = var_layer_outputs; - tmp_subscript_name_4 = mod_consts[29]; - tmp_assign_source_16 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_14, tmp_subscript_name_4, 0); - if (tmp_assign_source_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 561; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_16; - Py_XDECREF(old); - } - - } - { - nuitka_bool tmp_condition_result_10; - int tmp_truth_name_10; - if (par_use_cache == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[147]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 562; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_truth_name_10 = CHECK_IF_TRUE(par_use_cache); - if (tmp_truth_name_10 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 562; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_condition_result_10 = tmp_truth_name_10 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_10 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - } - branch_yes_4:; - { - PyObject *tmp_assign_source_17; - PyObject *tmp_left_name_2; - PyObject *tmp_right_name_2; - PyObject *tmp_tuple_element_2; - PyObject *tmp_expression_name_15; - PyObject *tmp_subscript_name_5; - if (var_next_decoder_cache == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[157]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 563; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_left_name_2 = var_next_decoder_cache; - CHECK_OBJECT(var_layer_outputs); - tmp_expression_name_15 = var_layer_outputs; - tmp_subscript_name_5 = mod_consts[126]; - tmp_tuple_element_2 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_15, tmp_subscript_name_5, -1); - if (tmp_tuple_element_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 563; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_right_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_right_name_2, 0, tmp_tuple_element_2); - tmp_result = BINARY_OPERATION_ADD_OBJECT_TUPLE_INPLACE(&tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_right_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 563; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_assign_source_17 = tmp_left_name_2; - var_next_decoder_cache = tmp_assign_source_17; - - } - branch_no_4:; - { - nuitka_bool tmp_condition_result_11; - int tmp_truth_name_11; - if (Nuitka_Cell_GET(par_output_attentions) == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[123]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 564; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_truth_name_11 = CHECK_IF_TRUE(Nuitka_Cell_GET(par_output_attentions)); - if (tmp_truth_name_11 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 564; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_condition_result_11 = tmp_truth_name_11 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_11 == NUITKA_BOOL_TRUE) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - { - PyObject *tmp_assign_source_18; - PyObject *tmp_left_name_3; - PyObject *tmp_right_name_3; - PyObject *tmp_tuple_element_3; - PyObject *tmp_expression_name_16; - PyObject *tmp_subscript_name_6; - if (var_all_self_attentions == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[158]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 565; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_left_name_3 = var_all_self_attentions; - CHECK_OBJECT(var_layer_outputs); - tmp_expression_name_16 = var_layer_outputs; - tmp_subscript_name_6 = mod_consts[28]; - tmp_tuple_element_3 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_16, tmp_subscript_name_6, 1); - if (tmp_tuple_element_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 565; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_right_name_3 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_right_name_3, 0, tmp_tuple_element_3); - tmp_assign_source_18 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_3, tmp_right_name_3); - Py_DECREF(tmp_right_name_3); - if (tmp_assign_source_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 565; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = var_all_self_attentions; - var_all_self_attentions = tmp_assign_source_18; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_19; - PyObject *tmp_left_name_4; - PyObject *tmp_right_name_4; - PyObject *tmp_tuple_element_4; - PyObject *tmp_expression_name_17; - PyObject *tmp_subscript_name_7; - if (var_all_cross_attentions == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[159]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 566; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - - tmp_left_name_4 = var_all_cross_attentions; - CHECK_OBJECT(var_layer_outputs); - tmp_expression_name_17 = var_layer_outputs; - tmp_subscript_name_7 = mod_consts[49]; - tmp_tuple_element_4 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_17, tmp_subscript_name_7, 2); - if (tmp_tuple_element_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 566; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - tmp_right_name_4 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_right_name_4, 0, tmp_tuple_element_4); - tmp_assign_source_19 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_4, tmp_right_name_4); - Py_DECREF(tmp_right_name_4); - if (tmp_assign_source_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 566; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - { - PyObject *old = var_all_cross_attentions; - var_all_cross_attentions = tmp_assign_source_19; - Py_XDECREF(old); - } - - } - branch_no_5:; - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 517; - type_description_1 = "oooooooocoocooooooocoo"; - goto try_except_handler_2; - } - goto loop_start_1; - loop_end_1:; - goto try_end_1; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_for_loop_1__iter_value); - tmp_for_loop_1__iter_value = NULL; - Py_XDECREF(tmp_for_loop_1__for_iterator); - tmp_for_loop_1__for_iterator = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto frame_exception_exit_1; - // End of try: - try_end_1:; - Py_XDECREF(tmp_for_loop_1__iter_value); - tmp_for_loop_1__iter_value = NULL; - Py_XDECREF(tmp_for_loop_1__for_iterator); - tmp_for_loop_1__for_iterator = NULL; - { - nuitka_bool tmp_condition_result_12; - int tmp_truth_name_12; - if (par_output_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[142]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 568; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - - tmp_truth_name_12 = CHECK_IF_TRUE(par_output_hidden_states); - if (tmp_truth_name_12 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 568; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_condition_result_12 = tmp_truth_name_12 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_12 == NUITKA_BOOL_TRUE) { - goto branch_yes_6; - } else { - goto branch_no_6; - } - } - branch_yes_6:; - { - PyObject *tmp_assign_source_20; - PyObject *tmp_left_name_5; - PyObject *tmp_right_name_5; - PyObject *tmp_tuple_element_5; - if (var_all_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[143]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 569; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - - tmp_left_name_5 = var_all_hidden_states; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 569; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_5 = par_hidden_states; - tmp_right_name_5 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_right_name_5, 0, tmp_tuple_element_5); - tmp_assign_source_20 = BINARY_OPERATION_ADD_OBJECT_OBJECT_TUPLE(tmp_left_name_5, tmp_right_name_5); - Py_DECREF(tmp_right_name_5); - if (tmp_assign_source_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 569; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_all_hidden_states; - var_all_hidden_states = tmp_assign_source_20; - Py_XDECREF(old); - } - - } - branch_no_6:; - { - nuitka_bool tmp_condition_result_13; - PyObject *tmp_operand_name_1; - CHECK_OBJECT(par_return_dict); - tmp_operand_name_1 = par_return_dict; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 571; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_condition_result_13 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_13 == NUITKA_BOOL_TRUE) { - goto branch_yes_7; - } else { - goto branch_no_7; - } - } - branch_yes_7:; - { - PyObject *tmp_tuple_arg_1; - { - PyObject *tmp_assign_source_21; - PyObject *tmp_iter_arg_2; - PyObject *tmp_tuple_element_6; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 575; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_6 = par_hidden_states; - tmp_iter_arg_2 = PyTuple_New(5); - PyTuple_SET_ITEM0(tmp_iter_arg_2, 0, tmp_tuple_element_6); - if (var_next_decoder_cache == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[157]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 576; - type_description_1 = "oooooooocoocooooooocoo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_6 = var_next_decoder_cache; - PyTuple_SET_ITEM0(tmp_iter_arg_2, 1, tmp_tuple_element_6); - if (var_all_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[143]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 577; - type_description_1 = "oooooooocoocooooooocoo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_6 = var_all_hidden_states; - PyTuple_SET_ITEM0(tmp_iter_arg_2, 2, tmp_tuple_element_6); - if (var_all_self_attentions == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[158]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 578; - type_description_1 = "oooooooocoocooooooocoo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_6 = var_all_self_attentions; - PyTuple_SET_ITEM0(tmp_iter_arg_2, 3, tmp_tuple_element_6); - if (var_all_cross_attentions == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[159]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 579; - type_description_1 = "oooooooocoocooooooocoo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_6 = var_all_cross_attentions; - PyTuple_SET_ITEM0(tmp_iter_arg_2, 4, tmp_tuple_element_6); - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_iter_arg_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_assign_source_21 = MAKE_ITERATOR_INFALLIBLE(tmp_iter_arg_2); - Py_DECREF(tmp_iter_arg_2); - assert(!(tmp_assign_source_21 == NULL)); - assert(tmp_genexpr_1__$0 == NULL); - tmp_genexpr_1__$0 = tmp_assign_source_21; - } - // Tried code: - { - struct Nuitka_CellObject *tmp_closure_2[1]; - - tmp_closure_2[0] = Nuitka_Cell_New0(tmp_genexpr_1__$0); - - tmp_tuple_arg_1 = MAKE_GENERATOR_models$Qformer$$$function__24_forward$$$genexpr__1_genexpr(tmp_closure_2); - - goto try_return_handler_3; - } - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_3:; - CHECK_OBJECT(tmp_genexpr_1__$0); - Py_DECREF(tmp_genexpr_1__$0); - tmp_genexpr_1__$0 = NULL; - goto outline_result_1; - // End of try: - CHECK_OBJECT(tmp_genexpr_1__$0); - Py_DECREF(tmp_genexpr_1__$0); - tmp_genexpr_1__$0 = NULL; - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_result_1:; - tmp_return_value = PySequence_Tuple(tmp_tuple_arg_1); - Py_DECREF(tmp_tuple_arg_1); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 572; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - branch_no_7:; - { - PyObject *tmp_called_name_4; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - tmp_called_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[160]); - - if (unlikely(tmp_called_name_4 == NULL)) { - tmp_called_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[160]); - } - - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 583; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - tmp_dict_key_1 = mod_consts[161]; - if (par_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[61]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 584; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_1 = par_hidden_states; - tmp_kwargs_name_1 = _PyDict_NewPresized( 5 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[144]; - if (var_next_decoder_cache == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[157]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 585; - type_description_1 = "oooooooocoocooooooocoo"; - goto dict_build_exception_1; - } - - tmp_dict_value_1 = var_next_decoder_cache; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[61]; - if (var_all_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[143]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 586; - type_description_1 = "oooooooocoocooooooocoo"; - goto dict_build_exception_1; - } - - tmp_dict_value_1 = var_all_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[162]; - if (var_all_self_attentions == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[158]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 587; - type_description_1 = "oooooooocoocooooooocoo"; - goto dict_build_exception_1; - } - - tmp_dict_value_1 = var_all_self_attentions; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[163]; - if (var_all_cross_attentions == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[159]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 588; - type_description_1 = "oooooooocoocooooooocoo"; - goto dict_build_exception_1; - } - - tmp_dict_value_1 = var_all_cross_attentions; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_kwargs_name_1); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_frame.f_lineno = 583; - tmp_return_value = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_4, tmp_kwargs_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 583; - type_description_1 = "oooooooocoocooooooocoo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_fb4ac8ca5f5c6cf5999268c801f1a60e); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_fb4ac8ca5f5c6cf5999268c801f1a60e); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_fb4ac8ca5f5c6cf5999268c801f1a60e); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_fb4ac8ca5f5c6cf5999268c801f1a60e, exception_lineno); - } else if (exception_tb->tb_frame != &frame_fb4ac8ca5f5c6cf5999268c801f1a60e->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_fb4ac8ca5f5c6cf5999268c801f1a60e, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_fb4ac8ca5f5c6cf5999268c801f1a60e, - type_description_1, - par_self, - par_hidden_states, - par_attention_mask, - par_head_mask, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_past_key_values, - par_use_cache, - par_output_attentions, - par_output_hidden_states, - par_return_dict, - par_query_length, - var_all_hidden_states, - var_all_self_attentions, - var_all_cross_attentions, - var_next_decoder_cache, - var_i, - var_layer_module, - var_layer_head_mask, - var_past_key_value, - var_create_custom_forward, - var_layer_outputs - ); - - - // Release cached frame if used for exception. - if (frame_fb4ac8ca5f5c6cf5999268c801f1a60e == cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e); - cache_frame_fb4ac8ca5f5c6cf5999268c801f1a60e = NULL; - } - - assertFrameObject(frame_fb4ac8ca5f5c6cf5999268c801f1a60e); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_past_key_values); - par_past_key_values = NULL; - Py_XDECREF(par_use_cache); - par_use_cache = NULL; - CHECK_OBJECT(par_output_attentions); - Py_DECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - CHECK_OBJECT(par_return_dict); - Py_DECREF(par_return_dict); - par_return_dict = NULL; - CHECK_OBJECT(par_query_length); - Py_DECREF(par_query_length); - par_query_length = NULL; - Py_XDECREF(var_all_hidden_states); - var_all_hidden_states = NULL; - Py_XDECREF(var_all_self_attentions); - var_all_self_attentions = NULL; - Py_XDECREF(var_all_cross_attentions); - var_all_cross_attentions = NULL; - Py_XDECREF(var_next_decoder_cache); - var_next_decoder_cache = NULL; - Py_XDECREF(var_i); - var_i = NULL; - Py_XDECREF(var_layer_module); - var_layer_module = NULL; - Py_XDECREF(var_layer_head_mask); - var_layer_head_mask = NULL; - CHECK_OBJECT(var_past_key_value); - Py_DECREF(var_past_key_value); - var_past_key_value = NULL; - Py_XDECREF(var_create_custom_forward); - var_create_custom_forward = NULL; - Py_XDECREF(var_layer_outputs); - var_layer_outputs = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_past_key_values); - par_past_key_values = NULL; - Py_XDECREF(par_use_cache); - par_use_cache = NULL; - CHECK_OBJECT(par_output_attentions); - Py_DECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - CHECK_OBJECT(par_return_dict); - Py_DECREF(par_return_dict); - par_return_dict = NULL; - CHECK_OBJECT(par_query_length); - Py_DECREF(par_query_length); - par_query_length = NULL; - Py_XDECREF(var_all_hidden_states); - var_all_hidden_states = NULL; - Py_XDECREF(var_all_self_attentions); - var_all_self_attentions = NULL; - Py_XDECREF(var_all_cross_attentions); - var_all_cross_attentions = NULL; - Py_XDECREF(var_next_decoder_cache); - var_next_decoder_cache = NULL; - Py_XDECREF(var_i); - var_i = NULL; - Py_XDECREF(var_layer_module); - var_layer_module = NULL; - Py_XDECREF(var_layer_head_mask); - var_layer_head_mask = NULL; - CHECK_OBJECT(var_past_key_value); - Py_DECREF(var_past_key_value); - var_past_key_value = NULL; - Py_XDECREF(var_create_custom_forward); - var_create_custom_forward = NULL; - Py_XDECREF(var_layer_outputs); - var_layer_outputs = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - struct Nuitka_CellObject *par_module = Nuitka_Cell_New1(python_pars[0]); - PyObject *var_custom_forward = NULL; - PyObject *tmp_return_value = NULL; - - // Actual function body. - { - PyObject *tmp_assign_source_1; - struct Nuitka_CellObject *tmp_closure_1[4]; - - tmp_closure_1[0] = par_module; - Py_INCREF(tmp_closure_1[0]); - tmp_closure_1[1] = self->m_closure[0]; - Py_INCREF(tmp_closure_1[1]); - tmp_closure_1[2] = self->m_closure[1]; - Py_INCREF(tmp_closure_1[2]); - tmp_closure_1[3] = self->m_closure[2]; - Py_INCREF(tmp_closure_1[3]); - - tmp_assign_source_1 = MAKE_FUNCTION_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward$$$function__1_custom_forward(tmp_closure_1); - - assert(var_custom_forward == NULL); - var_custom_forward = tmp_assign_source_1; - } - // Tried code: - CHECK_OBJECT(var_custom_forward); - tmp_return_value = var_custom_forward; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_module); - Py_DECREF(par_module); - par_module = NULL; - CHECK_OBJECT(var_custom_forward); - Py_DECREF(var_custom_forward); - var_custom_forward = NULL; - goto function_return_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward$$$function__1_custom_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_inputs = python_pars[0]; - struct Nuitka_FrameObject *frame_340e4e883925405252be80b1c8cda477; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_340e4e883925405252be80b1c8cda477 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_340e4e883925405252be80b1c8cda477)) { - Py_XDECREF(cache_frame_340e4e883925405252be80b1c8cda477); - -#if _DEBUG_REFCOUNTS - if (cache_frame_340e4e883925405252be80b1c8cda477 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_340e4e883925405252be80b1c8cda477 = MAKE_FUNCTION_FRAME(codeobj_340e4e883925405252be80b1c8cda477, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_340e4e883925405252be80b1c8cda477->m_type_description == NULL); - frame_340e4e883925405252be80b1c8cda477 = cache_frame_340e4e883925405252be80b1c8cda477; - - // Push the new frame as the currently active one. - pushFrameStack(frame_340e4e883925405252be80b1c8cda477); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_340e4e883925405252be80b1c8cda477) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_dircall_arg1_1; - PyObject *tmp_dircall_arg2_1; - PyObject *tmp_dircall_arg1_2; - PyObject *tmp_tuple_element_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[166]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 535; - type_description_1 = "occcc"; - goto frame_exception_exit_1; - } - - tmp_dircall_arg1_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_inputs); - tmp_tuple_element_1 = par_inputs; - tmp_dircall_arg1_2 = PyTuple_New(4); - { - PyObject *tmp_tuple_element_2; - PyObject *tmp_tuple_element_3; - PyObject *tmp_tuple_element_4; - PyTuple_SET_ITEM0(tmp_dircall_arg1_2, 0, tmp_tuple_element_1); - if (Nuitka_Cell_GET(self->m_closure[2]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[124]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 536; - type_description_1 = "occcc"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_2 = Nuitka_Cell_GET(self->m_closure[2]); - tmp_tuple_element_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_tuple_element_1, 0, tmp_tuple_element_2); - PyTuple_SET_ITEM(tmp_dircall_arg1_2, 1, tmp_tuple_element_1); - if (Nuitka_Cell_GET(self->m_closure[1]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[123]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 536; - type_description_1 = "occcc"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_3 = Nuitka_Cell_GET(self->m_closure[1]); - tmp_tuple_element_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_tuple_element_1, 0, tmp_tuple_element_3); - PyTuple_SET_ITEM(tmp_dircall_arg1_2, 2, tmp_tuple_element_1); - if (Nuitka_Cell_GET(self->m_closure[3]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[156]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 536; - type_description_1 = "occcc"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_4 = Nuitka_Cell_GET(self->m_closure[3]); - tmp_tuple_element_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_tuple_element_1, 0, tmp_tuple_element_4); - PyTuple_SET_ITEM(tmp_dircall_arg1_2, 3, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_dircall_arg1_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_2}; - tmp_dircall_arg2_1 = impl_models$$$function__4__unpack_list(dir_call_args); - } - if (tmp_dircall_arg2_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 535; - type_description_1 = "occcc"; - goto frame_exception_exit_1; - } - Py_INCREF(tmp_dircall_arg1_1); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_1, tmp_dircall_arg2_1}; - tmp_return_value = impl_models$$$function__2_complex_call_helper_star_list(dir_call_args); - } - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 535; - type_description_1 = "occcc"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_340e4e883925405252be80b1c8cda477); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_340e4e883925405252be80b1c8cda477); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_340e4e883925405252be80b1c8cda477); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_340e4e883925405252be80b1c8cda477, exception_lineno); - } else if (exception_tb->tb_frame != &frame_340e4e883925405252be80b1c8cda477->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_340e4e883925405252be80b1c8cda477, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_340e4e883925405252be80b1c8cda477, - type_description_1, - par_inputs, - self->m_closure[0], - self->m_closure[2], - self->m_closure[1], - self->m_closure[3] - ); - - - // Release cached frame if used for exception. - if (frame_340e4e883925405252be80b1c8cda477 == cache_frame_340e4e883925405252be80b1c8cda477) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_340e4e883925405252be80b1c8cda477); - cache_frame_340e4e883925405252be80b1c8cda477 = NULL; - } - - assertFrameObject(frame_340e4e883925405252be80b1c8cda477); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_inputs); - Py_DECREF(par_inputs); - par_inputs = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_inputs); - Py_DECREF(par_inputs); - par_inputs = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - - -struct models$Qformer$$$function__24_forward$$$genexpr__1_genexpr_locals { - PyObject *var_v; - PyObject *tmp_iter_value_0; - char const *type_description_1; - PyObject *exception_type; - PyObject *exception_value; - PyTracebackObject *exception_tb; - int exception_lineno; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - int exception_keeper_lineno_2; -}; - -static PyObject *models$Qformer$$$function__24_forward$$$genexpr__1_genexpr_context(struct Nuitka_GeneratorObject *generator, PyObject *yield_return_value) { - CHECK_OBJECT(generator); - assert(Nuitka_Generator_Check((PyObject *)generator)); - CHECK_OBJECT_X(yield_return_value); - - // Heap access if used. - struct models$Qformer$$$function__24_forward$$$genexpr__1_genexpr_locals *generator_heap = (struct models$Qformer$$$function__24_forward$$$genexpr__1_genexpr_locals *)generator->m_heap_storage; - - // Dispatch to yield based on return label index: - switch(generator->m_yield_return_index) { - case 1: goto yield_return_1; - } - - // Local variable initialization - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - static struct Nuitka_FrameObject *cache_m_frame = NULL; - generator_heap->var_v = NULL; - generator_heap->tmp_iter_value_0 = NULL; - generator_heap->type_description_1 = NULL; - generator_heap->exception_type = NULL; - generator_heap->exception_value = NULL; - generator_heap->exception_tb = NULL; - generator_heap->exception_lineno = 0; - - // Actual generator function body. - // Tried code: - if (isFrameUnusable(cache_m_frame)) { - Py_XDECREF(cache_m_frame); - -#if _DEBUG_REFCOUNTS - if (cache_m_frame == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_m_frame = MAKE_FUNCTION_FRAME(codeobj_d4ada818f6656268c254961d6faa630a, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - generator->m_frame = cache_m_frame; - - // Mark the frame object as in use, ref count 1 will be up for reuse. - Py_INCREF(generator->m_frame); - assert(Py_REFCNT(generator->m_frame) == 2); // Frame stack - -#if PYTHON_VERSION >= 0x340 - generator->m_frame->m_frame.f_gen = (PyObject *)generator; -#endif - - assert(generator->m_frame->m_frame.f_back == NULL); - Py_CLEAR(generator->m_frame->m_frame.f_back); - - generator->m_frame->m_frame.f_back = PyThreadState_GET()->frame; - Py_INCREF(generator->m_frame->m_frame.f_back); - - PyThreadState_GET()->frame = &generator->m_frame->m_frame; - Py_INCREF(generator->m_frame); - - Nuitka_Frame_MarkAsExecuting(generator->m_frame); - -#if PYTHON_VERSION >= 0x300 - // Accept currently existing exception as the one to publish again when we - // yield or yield from. - { - PyThreadState *thread_state = PyThreadState_GET(); - - EXC_TYPE_F(generator) = EXC_TYPE(thread_state); - if (EXC_TYPE_F(generator) == Py_None) EXC_TYPE_F(generator) = NULL; - Py_XINCREF(EXC_TYPE_F(generator)); - EXC_VALUE_F(generator) = EXC_VALUE(thread_state); - Py_XINCREF(EXC_VALUE_F(generator)); - EXC_TRACEBACK_F(generator) = EXC_TRACEBACK(thread_state); - Py_XINCREF(EXC_TRACEBACK_F(generator)); - } - -#endif - - // Framed code: - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_1; - CHECK_OBJECT(Nuitka_Cell_GET(generator->m_closure[0])); - tmp_next_source_1 = Nuitka_Cell_GET(generator->m_closure[0]); - tmp_assign_source_1 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_1 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - generator_heap->type_description_1 = "No"; - generator_heap->exception_lineno = 572; - goto try_except_handler_2; - } - } - - { - PyObject *old = generator_heap->tmp_iter_value_0; - generator_heap->tmp_iter_value_0 = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - CHECK_OBJECT(generator_heap->tmp_iter_value_0); - tmp_assign_source_2 = generator_heap->tmp_iter_value_0; - { - PyObject *old = generator_heap->var_v; - generator_heap->var_v = tmp_assign_source_2; - Py_INCREF(generator_heap->var_v); - Py_XDECREF(old); - } - - } - { - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - CHECK_OBJECT(generator_heap->var_v); - tmp_compexpr_left_1 = generator_heap->var_v; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_expression_name_1; - NUITKA_MAY_BE_UNUSED PyObject *tmp_yield_result_1; - CHECK_OBJECT(generator_heap->var_v); - tmp_expression_name_1 = generator_heap->var_v; - Py_INCREF(tmp_expression_name_1); - generator->m_yield_return_index = 1; - return tmp_expression_name_1; - yield_return_1: - if (yield_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - - - generator_heap->exception_lineno = 572; - generator_heap->type_description_1 = "No"; - goto try_except_handler_2; - } - tmp_yield_result_1 = yield_return_value; - } - branch_no_1:; - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - - - generator_heap->exception_lineno = 572; - generator_heap->type_description_1 = "No"; - goto try_except_handler_2; - } - goto loop_start_1; - loop_end_1:; - goto try_end_1; - // Exception handler code: - try_except_handler_2:; - generator_heap->exception_keeper_type_1 = generator_heap->exception_type; - generator_heap->exception_keeper_value_1 = generator_heap->exception_value; - generator_heap->exception_keeper_tb_1 = generator_heap->exception_tb; - generator_heap->exception_keeper_lineno_1 = generator_heap->exception_lineno; - generator_heap->exception_type = NULL; - generator_heap->exception_value = NULL; - generator_heap->exception_tb = NULL; - generator_heap->exception_lineno = 0; - - Py_XDECREF(generator_heap->tmp_iter_value_0); - generator_heap->tmp_iter_value_0 = NULL; - // Re-raise. - generator_heap->exception_type = generator_heap->exception_keeper_type_1; - generator_heap->exception_value = generator_heap->exception_keeper_value_1; - generator_heap->exception_tb = generator_heap->exception_keeper_tb_1; - generator_heap->exception_lineno = generator_heap->exception_keeper_lineno_1; - - goto frame_exception_exit_1; - // End of try: - try_end_1:; - - Nuitka_Frame_MarkAsNotExecuting(generator->m_frame); - -#if PYTHON_VERSION >= 0x300 - Py_CLEAR(EXC_TYPE_F(generator)); - Py_CLEAR(EXC_VALUE_F(generator)); - Py_CLEAR(EXC_TRACEBACK_F(generator)); -#endif - - // Allow re-use of the frame again. - Py_DECREF(generator->m_frame); - goto frame_no_exception_1; - - frame_exception_exit_1:; - - // If it's not an exit exception, consider and create a traceback for it. - if (!EXCEPTION_MATCH_GENERATOR(generator_heap->exception_type)) { - if (generator_heap->exception_tb == NULL) { - generator_heap->exception_tb = MAKE_TRACEBACK(generator->m_frame, generator_heap->exception_lineno); - } else if (generator_heap->exception_tb->tb_frame != &generator->m_frame->m_frame) { - generator_heap->exception_tb = ADD_TRACEBACK(generator_heap->exception_tb, generator->m_frame, generator_heap->exception_lineno); - } - - Nuitka_Frame_AttachLocals( - generator->m_frame, - generator_heap->type_description_1, - NULL, - generator_heap->var_v - ); - - - // Release cached frame if used for exception. - if (generator->m_frame == cache_m_frame) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_m_frame); - cache_m_frame = NULL; - } - - assertFrameObject(generator->m_frame); - } - -#if PYTHON_VERSION >= 0x300 - Py_CLEAR(EXC_TYPE_F(generator)); - Py_CLEAR(EXC_VALUE_F(generator)); - Py_CLEAR(EXC_TRACEBACK_F(generator)); -#endif - - Py_DECREF(generator->m_frame); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - goto try_end_2; - // Exception handler code: - try_except_handler_1:; - generator_heap->exception_keeper_type_2 = generator_heap->exception_type; - generator_heap->exception_keeper_value_2 = generator_heap->exception_value; - generator_heap->exception_keeper_tb_2 = generator_heap->exception_tb; - generator_heap->exception_keeper_lineno_2 = generator_heap->exception_lineno; - generator_heap->exception_type = NULL; - generator_heap->exception_value = NULL; - generator_heap->exception_tb = NULL; - generator_heap->exception_lineno = 0; - - Py_XDECREF(generator_heap->var_v); - generator_heap->var_v = NULL; - // Re-raise. - generator_heap->exception_type = generator_heap->exception_keeper_type_2; - generator_heap->exception_value = generator_heap->exception_keeper_value_2; - generator_heap->exception_tb = generator_heap->exception_keeper_tb_2; - generator_heap->exception_lineno = generator_heap->exception_keeper_lineno_2; - - goto function_exception_exit; - // End of try: - try_end_2:; - Py_XDECREF(generator_heap->tmp_iter_value_0); - generator_heap->tmp_iter_value_0 = NULL; - Py_XDECREF(generator_heap->var_v); - generator_heap->var_v = NULL; - - - return NULL; - - function_exception_exit: - assert(generator_heap->exception_type); - RESTORE_ERROR_OCCURRED(generator_heap->exception_type, generator_heap->exception_value, generator_heap->exception_tb); - - return NULL; - -} - -static PyObject *MAKE_GENERATOR_models$Qformer$$$function__24_forward$$$genexpr__1_genexpr(struct Nuitka_CellObject **closure) { - return Nuitka_Generator_New( - models$Qformer$$$function__24_forward$$$genexpr__1_genexpr_context, - module_models$Qformer, - mod_consts[167], -#if PYTHON_VERSION >= 0x350 - mod_consts[168], -#endif - codeobj_d4ada818f6656268c254961d6faa630a, - closure, - 1, - sizeof(struct models$Qformer$$$function__24_forward$$$genexpr__1_genexpr_locals) - ); -} - - -static PyObject *impl_models$Qformer$$$function__25___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_3183350d90f44f69878dab33e80e4921; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_3183350d90f44f69878dab33e80e4921 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_3183350d90f44f69878dab33e80e4921)) { - Py_XDECREF(cache_frame_3183350d90f44f69878dab33e80e4921); - -#if _DEBUG_REFCOUNTS - if (cache_frame_3183350d90f44f69878dab33e80e4921 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_3183350d90f44f69878dab33e80e4921 = MAKE_FUNCTION_FRAME(codeobj_3183350d90f44f69878dab33e80e4921, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_3183350d90f44f69878dab33e80e4921->m_type_description == NULL); - frame_3183350d90f44f69878dab33e80e4921 = cache_frame_3183350d90f44f69878dab33e80e4921; - - // Push the new frame as the currently active one. - pushFrameStack(frame_3183350d90f44f69878dab33e80e4921); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_3183350d90f44f69878dab33e80e4921) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 594; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 594; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_3183350d90f44f69878dab33e80e4921->m_frame.f_lineno = 594; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 594; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_assattr_target_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[6]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_config; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[6]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_3183350d90f44f69878dab33e80e4921->m_frame.f_lineno = 595; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[92], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 595; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_assattr_target_2; - tmp_called_instance_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_called_instance_2 == NULL)) { - tmp_called_instance_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 596; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_3183350d90f44f69878dab33e80e4921->m_frame.f_lineno = 596; - tmp_assattr_name_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[169]); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 596; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[170], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 596; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3183350d90f44f69878dab33e80e4921); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3183350d90f44f69878dab33e80e4921); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_3183350d90f44f69878dab33e80e4921, exception_lineno); - } else if (exception_tb->tb_frame != &frame_3183350d90f44f69878dab33e80e4921->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_3183350d90f44f69878dab33e80e4921, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_3183350d90f44f69878dab33e80e4921, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_3183350d90f44f69878dab33e80e4921 == cache_frame_3183350d90f44f69878dab33e80e4921) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_3183350d90f44f69878dab33e80e4921); - cache_frame_3183350d90f44f69878dab33e80e4921 = NULL; - } - - assertFrameObject(frame_3183350d90f44f69878dab33e80e4921); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__26_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - PyObject *var_first_token_tensor = NULL; - PyObject *var_pooled_output = NULL; - struct Nuitka_FrameObject *frame_efe9f30d4ed10b98b0f8cc575424636a; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_efe9f30d4ed10b98b0f8cc575424636a = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_efe9f30d4ed10b98b0f8cc575424636a)) { - Py_XDECREF(cache_frame_efe9f30d4ed10b98b0f8cc575424636a); - -#if _DEBUG_REFCOUNTS - if (cache_frame_efe9f30d4ed10b98b0f8cc575424636a == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_efe9f30d4ed10b98b0f8cc575424636a = MAKE_FUNCTION_FRAME(codeobj_efe9f30d4ed10b98b0f8cc575424636a, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_efe9f30d4ed10b98b0f8cc575424636a->m_type_description == NULL); - frame_efe9f30d4ed10b98b0f8cc575424636a = cache_frame_efe9f30d4ed10b98b0f8cc575424636a; - - // Push the new frame as the currently active one. - pushFrameStack(frame_efe9f30d4ed10b98b0f8cc575424636a); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_efe9f30d4ed10b98b0f8cc575424636a) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_subscript_name_1; - CHECK_OBJECT(par_hidden_states); - tmp_expression_name_1 = par_hidden_states; - tmp_subscript_name_1 = mod_consts[171]; - tmp_assign_source_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_1, tmp_subscript_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 601; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(var_first_token_tensor == NULL); - var_first_token_tensor = tmp_assign_source_1; - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(var_first_token_tensor); - tmp_args_element_name_1 = var_first_token_tensor; - frame_efe9f30d4ed10b98b0f8cc575424636a->m_frame.f_lineno = 602; - tmp_assign_source_2 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[92], tmp_args_element_name_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 602; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(var_pooled_output == NULL); - var_pooled_output = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 603; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(var_pooled_output); - tmp_args_element_name_2 = var_pooled_output; - frame_efe9f30d4ed10b98b0f8cc575424636a->m_frame.f_lineno = 603; - tmp_assign_source_3 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[170], tmp_args_element_name_2); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 603; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_pooled_output; - var_pooled_output = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_efe9f30d4ed10b98b0f8cc575424636a); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_efe9f30d4ed10b98b0f8cc575424636a); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_efe9f30d4ed10b98b0f8cc575424636a, exception_lineno); - } else if (exception_tb->tb_frame != &frame_efe9f30d4ed10b98b0f8cc575424636a->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_efe9f30d4ed10b98b0f8cc575424636a, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_efe9f30d4ed10b98b0f8cc575424636a, - type_description_1, - par_self, - par_hidden_states, - var_first_token_tensor, - var_pooled_output - ); - - - // Release cached frame if used for exception. - if (frame_efe9f30d4ed10b98b0f8cc575424636a == cache_frame_efe9f30d4ed10b98b0f8cc575424636a) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_efe9f30d4ed10b98b0f8cc575424636a); - cache_frame_efe9f30d4ed10b98b0f8cc575424636a = NULL; - } - - assertFrameObject(frame_efe9f30d4ed10b98b0f8cc575424636a); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_pooled_output); - tmp_return_value = var_pooled_output; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(var_first_token_tensor); - var_first_token_tensor = NULL; - CHECK_OBJECT(var_pooled_output); - Py_DECREF(var_pooled_output); - var_pooled_output = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - Py_XDECREF(var_first_token_tensor); - var_first_token_tensor = NULL; - Py_XDECREF(var_pooled_output); - var_pooled_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__27___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_ca40fb07238f33d953447de3e31806fd; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_ca40fb07238f33d953447de3e31806fd = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_ca40fb07238f33d953447de3e31806fd)) { - Py_XDECREF(cache_frame_ca40fb07238f33d953447de3e31806fd); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ca40fb07238f33d953447de3e31806fd == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ca40fb07238f33d953447de3e31806fd = MAKE_FUNCTION_FRAME(codeobj_ca40fb07238f33d953447de3e31806fd, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ca40fb07238f33d953447de3e31806fd->m_type_description == NULL); - frame_ca40fb07238f33d953447de3e31806fd = cache_frame_ca40fb07238f33d953447de3e31806fd; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ca40fb07238f33d953447de3e31806fd); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ca40fb07238f33d953447de3e31806fd) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 609; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 609; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_ca40fb07238f33d953447de3e31806fd->m_frame.f_lineno = 609; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 609; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_assattr_target_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[6]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_config; - tmp_args_element_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[6]); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_ca40fb07238f33d953447de3e31806fd->m_frame.f_lineno = 610; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[92], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 610; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - nuitka_bool tmp_condition_result_1; - PyObject *tmp_isinstance_inst_1; - PyObject *tmp_isinstance_cls_1; - PyObject *tmp_expression_name_4; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 611; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_config; - tmp_isinstance_inst_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[104]); - if (tmp_isinstance_inst_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 611; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_isinstance_cls_1 = (PyObject *)&PyUnicode_Type; - tmp_res = Nuitka_IsInstance(tmp_isinstance_inst_1, tmp_isinstance_cls_1); - Py_DECREF(tmp_isinstance_inst_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 611; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_condition_result_1 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_expression_name_5; - PyObject *tmp_subscript_name_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_assattr_target_2; - tmp_expression_name_5 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[105]); - - if (unlikely(tmp_expression_name_5 == NULL)) { - tmp_expression_name_5 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[105]); - } - - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 612; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 612; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_subscript_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[104]); - if (tmp_subscript_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 612; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_assattr_name_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_5, tmp_subscript_name_1); - Py_DECREF(tmp_subscript_name_1); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 612; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[172], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 612; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - goto branch_end_1; - branch_no_1:; - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_expression_name_7; - PyObject *tmp_assattr_target_3; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 614; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_config; - tmp_assattr_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[104]); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 614; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[172], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 614; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - branch_end_1:; - { - PyObject *tmp_assattr_name_4; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_8; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_9; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - PyObject *tmp_expression_name_10; - PyObject *tmp_assattr_target_4; - tmp_expression_name_8 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_8 == NULL)) { - tmp_expression_name_8 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[12]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_9 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[6]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[13]; - if (par_config == NULL) { - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_10 = par_config; - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[14]); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_1 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_ca40fb07238f33d953447de3e31806fd->m_frame.f_lineno = 615; - tmp_assattr_name_4 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_4 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[12], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 615; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ca40fb07238f33d953447de3e31806fd); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ca40fb07238f33d953447de3e31806fd); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ca40fb07238f33d953447de3e31806fd, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ca40fb07238f33d953447de3e31806fd->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ca40fb07238f33d953447de3e31806fd, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ca40fb07238f33d953447de3e31806fd, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_ca40fb07238f33d953447de3e31806fd == cache_frame_ca40fb07238f33d953447de3e31806fd) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ca40fb07238f33d953447de3e31806fd); - cache_frame_ca40fb07238f33d953447de3e31806fd = NULL; - } - - assertFrameObject(frame_ca40fb07238f33d953447de3e31806fd); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__28_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - struct Nuitka_FrameObject *frame_ef32505124b25b3c551fd3017e359336; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_ef32505124b25b3c551fd3017e359336 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_ef32505124b25b3c551fd3017e359336)) { - Py_XDECREF(cache_frame_ef32505124b25b3c551fd3017e359336); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ef32505124b25b3c551fd3017e359336 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ef32505124b25b3c551fd3017e359336 = MAKE_FUNCTION_FRAME(codeobj_ef32505124b25b3c551fd3017e359336, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ef32505124b25b3c551fd3017e359336->m_type_description == NULL); - frame_ef32505124b25b3c551fd3017e359336 = cache_frame_ef32505124b25b3c551fd3017e359336; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ef32505124b25b3c551fd3017e359336); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ef32505124b25b3c551fd3017e359336) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_1 = par_hidden_states; - frame_ef32505124b25b3c551fd3017e359336->m_frame.f_lineno = 618; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[92], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 618; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 619; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_2 = par_hidden_states; - frame_ef32505124b25b3c551fd3017e359336->m_frame.f_lineno = 619; - tmp_assign_source_2 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[172], tmp_args_element_name_2); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 619; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_instance_3; - PyObject *tmp_args_element_name_3; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 620; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_3 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_3 = par_hidden_states; - frame_ef32505124b25b3c551fd3017e359336->m_frame.f_lineno = 620; - tmp_assign_source_3 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_3, mod_consts[12], tmp_args_element_name_3); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 620; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ef32505124b25b3c551fd3017e359336); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ef32505124b25b3c551fd3017e359336); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ef32505124b25b3c551fd3017e359336, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ef32505124b25b3c551fd3017e359336->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ef32505124b25b3c551fd3017e359336, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ef32505124b25b3c551fd3017e359336, - type_description_1, - par_self, - par_hidden_states - ); - - - // Release cached frame if used for exception. - if (frame_ef32505124b25b3c551fd3017e359336 == cache_frame_ef32505124b25b3c551fd3017e359336) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ef32505124b25b3c551fd3017e359336); - cache_frame_ef32505124b25b3c551fd3017e359336 = NULL; - } - - assertFrameObject(frame_ef32505124b25b3c551fd3017e359336); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(par_hidden_states); - tmp_return_value = par_hidden_states; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__29___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_9c6e6b2c3e0641a7465eeb0788b5b6dd; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd)) { - Py_XDECREF(cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd); - -#if _DEBUG_REFCOUNTS - if (cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd = MAKE_FUNCTION_FRAME(codeobj_9c6e6b2c3e0641a7465eeb0788b5b6dd, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_type_description == NULL); - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd = cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd; - - // Push the new frame as the currently active one. - pushFrameStack(frame_9c6e6b2c3e0641a7465eeb0788b5b6dd); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_9c6e6b2c3e0641a7465eeb0788b5b6dd) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 626; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 626; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_frame.f_lineno = 626; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 626; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_assattr_target_1; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[173]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[173]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 627; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_1 = par_config; - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_frame.f_lineno = 627; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 627; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[174], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 627; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_assattr_target_2; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 631; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 631; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_expression_name_2 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[6]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 631; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_args_name_1 = PyTuple_New(2); - { - PyObject *tmp_expression_name_3; - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 631; - type_description_1 = "ooc"; - goto tuple_build_exception_1; - } - - tmp_expression_name_3 = par_config; - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[4]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 631; - type_description_1 = "ooc"; - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_args_name_1, 1, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[175]); - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_frame.f_lineno = 631; - tmp_assattr_name_2 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 631; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[176], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 631; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_4; - PyObject *tmp_args_element_name_2; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_5; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_6; - PyObject *tmp_assattr_target_3; - tmp_expression_name_4 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_4 == NULL)) { - tmp_expression_name_4 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[177]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_expression_name_5 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_5 == NULL)) { - tmp_expression_name_5 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[178]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_config; - tmp_args_element_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[4]); - if (tmp_args_element_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_frame.f_lineno = 633; - tmp_args_element_name_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_4, tmp_args_element_name_3); - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_3); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_frame.f_lineno = 633; - tmp_assattr_name_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_2); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[179], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 633; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_4; - PyObject *tmp_expression_name_7; - PyObject *tmp_assattr_target_4; - PyObject *tmp_expression_name_8; - CHECK_OBJECT(par_self); - tmp_expression_name_7 = par_self; - tmp_assattr_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[179]); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 636; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_assattr_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 636; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_self; - tmp_assattr_target_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[176]); - if (tmp_assattr_target_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_assattr_name_4); - - exception_lineno = 636; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[179], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - Py_DECREF(tmp_assattr_target_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 636; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_9c6e6b2c3e0641a7465eeb0788b5b6dd); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_9c6e6b2c3e0641a7465eeb0788b5b6dd); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_9c6e6b2c3e0641a7465eeb0788b5b6dd, exception_lineno); - } else if (exception_tb->tb_frame != &frame_9c6e6b2c3e0641a7465eeb0788b5b6dd->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_9c6e6b2c3e0641a7465eeb0788b5b6dd, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_9c6e6b2c3e0641a7465eeb0788b5b6dd, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_9c6e6b2c3e0641a7465eeb0788b5b6dd == cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd); - cache_frame_9c6e6b2c3e0641a7465eeb0788b5b6dd = NULL; - } - - assertFrameObject(frame_9c6e6b2c3e0641a7465eeb0788b5b6dd); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__30_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_hidden_states = python_pars[1]; - struct Nuitka_FrameObject *frame_e5d530bc114f61caefcc8e7e58348d97; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_e5d530bc114f61caefcc8e7e58348d97 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_e5d530bc114f61caefcc8e7e58348d97)) { - Py_XDECREF(cache_frame_e5d530bc114f61caefcc8e7e58348d97); - -#if _DEBUG_REFCOUNTS - if (cache_frame_e5d530bc114f61caefcc8e7e58348d97 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_e5d530bc114f61caefcc8e7e58348d97 = MAKE_FUNCTION_FRAME(codeobj_e5d530bc114f61caefcc8e7e58348d97, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_e5d530bc114f61caefcc8e7e58348d97->m_type_description == NULL); - frame_e5d530bc114f61caefcc8e7e58348d97 = cache_frame_e5d530bc114f61caefcc8e7e58348d97; - - // Push the new frame as the currently active one. - pushFrameStack(frame_e5d530bc114f61caefcc8e7e58348d97); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_e5d530bc114f61caefcc8e7e58348d97) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_1 = par_hidden_states; - frame_e5d530bc114f61caefcc8e7e58348d97->m_frame.f_lineno = 639; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[174], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 639; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_args_element_name_2; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 640; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_self; - CHECK_OBJECT(par_hidden_states); - tmp_args_element_name_2 = par_hidden_states; - frame_e5d530bc114f61caefcc8e7e58348d97->m_frame.f_lineno = 640; - tmp_assign_source_2 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[176], tmp_args_element_name_2); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 640; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_hidden_states; - par_hidden_states = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e5d530bc114f61caefcc8e7e58348d97); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e5d530bc114f61caefcc8e7e58348d97); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_e5d530bc114f61caefcc8e7e58348d97, exception_lineno); - } else if (exception_tb->tb_frame != &frame_e5d530bc114f61caefcc8e7e58348d97->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_e5d530bc114f61caefcc8e7e58348d97, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_e5d530bc114f61caefcc8e7e58348d97, - type_description_1, - par_self, - par_hidden_states - ); - - - // Release cached frame if used for exception. - if (frame_e5d530bc114f61caefcc8e7e58348d97 == cache_frame_e5d530bc114f61caefcc8e7e58348d97) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_e5d530bc114f61caefcc8e7e58348d97); - cache_frame_e5d530bc114f61caefcc8e7e58348d97 = NULL; - } - - assertFrameObject(frame_e5d530bc114f61caefcc8e7e58348d97); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(par_hidden_states); - tmp_return_value = par_hidden_states; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_hidden_states); - Py_DECREF(par_hidden_states); - par_hidden_states = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_hidden_states); - par_hidden_states = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__31___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_fa49026615d06e8f214b8591603bbecd; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_fa49026615d06e8f214b8591603bbecd = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_fa49026615d06e8f214b8591603bbecd)) { - Py_XDECREF(cache_frame_fa49026615d06e8f214b8591603bbecd); - -#if _DEBUG_REFCOUNTS - if (cache_frame_fa49026615d06e8f214b8591603bbecd == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_fa49026615d06e8f214b8591603bbecd = MAKE_FUNCTION_FRAME(codeobj_fa49026615d06e8f214b8591603bbecd, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_fa49026615d06e8f214b8591603bbecd->m_type_description == NULL); - frame_fa49026615d06e8f214b8591603bbecd = cache_frame_fa49026615d06e8f214b8591603bbecd; - - // Push the new frame as the currently active one. - pushFrameStack(frame_fa49026615d06e8f214b8591603bbecd); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_fa49026615d06e8f214b8591603bbecd) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 646; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 646; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - frame_fa49026615d06e8f214b8591603bbecd->m_frame.f_lineno = 646; - tmp_call_result_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[1]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 646; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_assattr_target_1; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[180]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[180]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 647; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_1 = par_config; - frame_fa49026615d06e8f214b8591603bbecd->m_frame.f_lineno = 647; - tmp_assattr_name_1 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 647; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[181], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 647; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_fa49026615d06e8f214b8591603bbecd); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_fa49026615d06e8f214b8591603bbecd); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_fa49026615d06e8f214b8591603bbecd, exception_lineno); - } else if (exception_tb->tb_frame != &frame_fa49026615d06e8f214b8591603bbecd->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_fa49026615d06e8f214b8591603bbecd, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_fa49026615d06e8f214b8591603bbecd, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_fa49026615d06e8f214b8591603bbecd == cache_frame_fa49026615d06e8f214b8591603bbecd) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_fa49026615d06e8f214b8591603bbecd); - cache_frame_fa49026615d06e8f214b8591603bbecd = NULL; - } - - assertFrameObject(frame_fa49026615d06e8f214b8591603bbecd); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_config); - Py_DECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_config); - Py_DECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__32_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_sequence_output = python_pars[1]; - PyObject *var_prediction_scores = NULL; - struct Nuitka_FrameObject *frame_0eb4b4b7e57523c96bf4c60654493887; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_0eb4b4b7e57523c96bf4c60654493887 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_0eb4b4b7e57523c96bf4c60654493887)) { - Py_XDECREF(cache_frame_0eb4b4b7e57523c96bf4c60654493887); - -#if _DEBUG_REFCOUNTS - if (cache_frame_0eb4b4b7e57523c96bf4c60654493887 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_0eb4b4b7e57523c96bf4c60654493887 = MAKE_FUNCTION_FRAME(codeobj_0eb4b4b7e57523c96bf4c60654493887, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_0eb4b4b7e57523c96bf4c60654493887->m_type_description == NULL); - frame_0eb4b4b7e57523c96bf4c60654493887 = cache_frame_0eb4b4b7e57523c96bf4c60654493887; - - // Push the new frame as the currently active one. - pushFrameStack(frame_0eb4b4b7e57523c96bf4c60654493887); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_0eb4b4b7e57523c96bf4c60654493887) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - CHECK_OBJECT(par_self); - tmp_called_instance_1 = par_self; - CHECK_OBJECT(par_sequence_output); - tmp_args_element_name_1 = par_sequence_output; - frame_0eb4b4b7e57523c96bf4c60654493887->m_frame.f_lineno = 650; - tmp_assign_source_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[181], tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 650; - type_description_1 = "ooo"; - goto frame_exception_exit_1; - } - assert(var_prediction_scores == NULL); - var_prediction_scores = tmp_assign_source_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0eb4b4b7e57523c96bf4c60654493887); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0eb4b4b7e57523c96bf4c60654493887); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_0eb4b4b7e57523c96bf4c60654493887, exception_lineno); - } else if (exception_tb->tb_frame != &frame_0eb4b4b7e57523c96bf4c60654493887->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_0eb4b4b7e57523c96bf4c60654493887, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_0eb4b4b7e57523c96bf4c60654493887, - type_description_1, - par_self, - par_sequence_output, - var_prediction_scores - ); - - - // Release cached frame if used for exception. - if (frame_0eb4b4b7e57523c96bf4c60654493887 == cache_frame_0eb4b4b7e57523c96bf4c60654493887) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_0eb4b4b7e57523c96bf4c60654493887); - cache_frame_0eb4b4b7e57523c96bf4c60654493887 = NULL; - } - - assertFrameObject(frame_0eb4b4b7e57523c96bf4c60654493887); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_prediction_scores); - tmp_return_value = var_prediction_scores; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_sequence_output); - par_sequence_output = NULL; - CHECK_OBJECT(var_prediction_scores); - Py_DECREF(var_prediction_scores); - var_prediction_scores = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_sequence_output); - par_sequence_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__33__init_weights(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_module = python_pars[1]; - struct Nuitka_FrameObject *frame_4147f3aad460337a90fc69f511dba483; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - static struct Nuitka_FrameObject *cache_frame_4147f3aad460337a90fc69f511dba483 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_4147f3aad460337a90fc69f511dba483)) { - Py_XDECREF(cache_frame_4147f3aad460337a90fc69f511dba483); - -#if _DEBUG_REFCOUNTS - if (cache_frame_4147f3aad460337a90fc69f511dba483 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_4147f3aad460337a90fc69f511dba483 = MAKE_FUNCTION_FRAME(codeobj_4147f3aad460337a90fc69f511dba483, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_4147f3aad460337a90fc69f511dba483->m_type_description == NULL); - frame_4147f3aad460337a90fc69f511dba483 = cache_frame_4147f3aad460337a90fc69f511dba483; - - // Push the new frame as the currently active one. - pushFrameStack(frame_4147f3aad460337a90fc69f511dba483); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_4147f3aad460337a90fc69f511dba483) == 2); // Frame stack - - // Framed code: - { - nuitka_bool tmp_condition_result_1; - PyObject *tmp_isinstance_inst_1; - PyObject *tmp_isinstance_cls_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_1; - CHECK_OBJECT(par_module); - tmp_isinstance_inst_1 = par_module; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 666; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[41]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 666; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_isinstance_cls_1 = PyTuple_New(2); - { - PyObject *tmp_expression_name_2; - PyTuple_SET_ITEM(tmp_isinstance_cls_1, 0, tmp_tuple_element_1); - tmp_expression_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_2 == NULL)) { - tmp_expression_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 666; - type_description_1 = "oo"; - goto tuple_build_exception_1; - } - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[3]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 666; - type_description_1 = "oo"; - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_isinstance_cls_1, 1, tmp_tuple_element_1); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_isinstance_cls_1); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_res = Nuitka_IsInstance(tmp_isinstance_inst_1, tmp_isinstance_cls_1); - Py_DECREF(tmp_isinstance_cls_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 666; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_condition_result_1 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_expression_name_4; - PyObject *tmp_expression_name_5; - PyObject *tmp_call_result_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - CHECK_OBJECT(par_module); - tmp_expression_name_5 = par_module; - tmp_expression_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[182]); - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 669; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_expression_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[183]); - Py_DECREF(tmp_expression_name_4); - if (tmp_expression_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 669; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[184]); - Py_DECREF(tmp_expression_name_3); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 669; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_dict_key_1 = mod_consts[185]; - tmp_dict_value_1 = mod_consts[186]; - tmp_kwargs_name_1 = _PyDict_NewPresized( 2 ); - { - PyObject *tmp_expression_name_6; - PyObject *tmp_expression_name_7; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[187]; - CHECK_OBJECT(par_self); - tmp_expression_name_7 = par_self; - tmp_expression_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[5]); - if (tmp_expression_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 669; - type_description_1 = "oo"; - goto dict_build_exception_1; - } - tmp_dict_value_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[188]); - Py_DECREF(tmp_expression_name_6); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 669; - type_description_1 = "oo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_kwargs_name_1); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_4147f3aad460337a90fc69f511dba483->m_frame.f_lineno = 669; - tmp_call_result_1 = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 669; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - goto branch_end_1; - branch_no_1:; - { - nuitka_bool tmp_condition_result_2; - PyObject *tmp_isinstance_inst_2; - PyObject *tmp_isinstance_cls_2; - PyObject *tmp_expression_name_8; - CHECK_OBJECT(par_module); - tmp_isinstance_inst_2 = par_module; - tmp_expression_name_8 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_8 == NULL)) { - tmp_expression_name_8 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 670; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_isinstance_cls_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[12]); - if (tmp_isinstance_cls_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 670; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_res = Nuitka_IsInstance(tmp_isinstance_inst_2, tmp_isinstance_cls_2); - Py_DECREF(tmp_isinstance_cls_2); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 670; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_condition_result_2 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_2 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_called_instance_1; - PyObject *tmp_expression_name_9; - PyObject *tmp_expression_name_10; - PyObject *tmp_call_result_2; - CHECK_OBJECT(par_module); - tmp_expression_name_10 = par_module; - tmp_expression_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[179]); - if (tmp_expression_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 671; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_called_instance_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[183]); - Py_DECREF(tmp_expression_name_9); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 671; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - frame_4147f3aad460337a90fc69f511dba483->m_frame.f_lineno = 671; - tmp_call_result_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[189]); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 671; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_2); - } - { - PyObject *tmp_called_instance_2; - PyObject *tmp_expression_name_11; - PyObject *tmp_expression_name_12; - PyObject *tmp_call_result_3; - if (par_module == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[166]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 672; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_12 = par_module; - tmp_expression_name_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[182]); - if (tmp_expression_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 672; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_called_instance_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[183]); - Py_DECREF(tmp_expression_name_11); - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 672; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - frame_4147f3aad460337a90fc69f511dba483->m_frame.f_lineno = 672; - tmp_call_result_3 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_2, - mod_consts[190], - &PyTuple_GET_ITEM(mod_consts[191], 0) - ); - - Py_DECREF(tmp_called_instance_2); - if (tmp_call_result_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 672; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_3); - } - branch_no_2:; - branch_end_1:; - { - nuitka_bool tmp_condition_result_3; - int tmp_and_left_truth_1; - nuitka_bool tmp_and_left_value_1; - nuitka_bool tmp_and_right_value_1; - PyObject *tmp_isinstance_inst_3; - PyObject *tmp_isinstance_cls_3; - PyObject *tmp_expression_name_13; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_expression_name_14; - if (par_module == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[166]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_isinstance_inst_3 = par_module; - tmp_expression_name_13 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_13 == NULL)) { - tmp_expression_name_13 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_isinstance_cls_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[41]); - if (tmp_isinstance_cls_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_res = Nuitka_IsInstance(tmp_isinstance_inst_3, tmp_isinstance_cls_3); - Py_DECREF(tmp_isinstance_cls_3); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_and_left_value_1 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - tmp_and_left_truth_1 = tmp_and_left_value_1 == NUITKA_BOOL_TRUE ? 1 : 0; - if (tmp_and_left_truth_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - if (tmp_and_left_truth_1 == 1) { - goto and_right_1; - } else { - goto and_left_1; - } - and_right_1:; - if (par_module == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[166]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_14 = par_module; - tmp_compexpr_left_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[179]); - if (tmp_compexpr_left_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 673; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_1 = Py_None; - tmp_and_right_value_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - Py_DECREF(tmp_compexpr_left_1); - tmp_condition_result_3 = tmp_and_right_value_1; - goto and_end_1; - and_left_1:; - tmp_condition_result_3 = tmp_and_left_value_1; - and_end_1:; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_called_instance_3; - PyObject *tmp_expression_name_15; - PyObject *tmp_expression_name_16; - PyObject *tmp_call_result_4; - if (par_module == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[166]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 674; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_16 = par_module; - tmp_expression_name_15 = LOOKUP_ATTRIBUTE(tmp_expression_name_16, mod_consts[179]); - if (tmp_expression_name_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 674; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_called_instance_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[183]); - Py_DECREF(tmp_expression_name_15); - if (tmp_called_instance_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 674; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - frame_4147f3aad460337a90fc69f511dba483->m_frame.f_lineno = 674; - tmp_call_result_4 = CALL_METHOD_NO_ARGS(tmp_called_instance_3, mod_consts[189]); - Py_DECREF(tmp_called_instance_3); - if (tmp_call_result_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 674; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_4); - } - branch_no_3:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_4147f3aad460337a90fc69f511dba483); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_4147f3aad460337a90fc69f511dba483); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_4147f3aad460337a90fc69f511dba483, exception_lineno); - } else if (exception_tb->tb_frame != &frame_4147f3aad460337a90fc69f511dba483->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_4147f3aad460337a90fc69f511dba483, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_4147f3aad460337a90fc69f511dba483, - type_description_1, - par_self, - par_module - ); - - - // Release cached frame if used for exception. - if (frame_4147f3aad460337a90fc69f511dba483 == cache_frame_4147f3aad460337a90fc69f511dba483) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_4147f3aad460337a90fc69f511dba483); - cache_frame_4147f3aad460337a90fc69f511dba483 = NULL; - } - - assertFrameObject(frame_4147f3aad460337a90fc69f511dba483); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_module); - par_module = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_module); - par_module = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__34___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - PyObject *par_add_pooling_layer = python_pars[2]; - struct Nuitka_FrameObject *frame_8e16adea762727bda11361e993d1476d; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_8e16adea762727bda11361e993d1476d = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_8e16adea762727bda11361e993d1476d)) { - Py_XDECREF(cache_frame_8e16adea762727bda11361e993d1476d); - -#if _DEBUG_REFCOUNTS - if (cache_frame_8e16adea762727bda11361e993d1476d == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_8e16adea762727bda11361e993d1476d = MAKE_FUNCTION_FRAME(codeobj_8e16adea762727bda11361e993d1476d, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_8e16adea762727bda11361e993d1476d->m_type_description == NULL); - frame_8e16adea762727bda11361e993d1476d = cache_frame_8e16adea762727bda11361e993d1476d; - - // Push the new frame as the currently active one. - pushFrameStack(frame_8e16adea762727bda11361e993d1476d); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_8e16adea762727bda11361e993d1476d) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - PyObject *tmp_args_element_name_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 688; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 688; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_1 = par_config; - frame_8e16adea762727bda11361e993d1476d->m_frame.f_lineno = 688; - tmp_call_result_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[1], tmp_args_element_name_1); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 688; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 689; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_assattr_name_1 = par_config; - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[5], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 689; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_assattr_target_2; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[193]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[193]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 691; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 691; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_2 = par_config; - frame_8e16adea762727bda11361e993d1476d->m_frame.f_lineno = 691; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_2); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 691; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[35], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 691; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_3; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_assattr_target_3; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[194]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[194]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 693; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 693; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_3 = par_config; - frame_8e16adea762727bda11361e993d1476d->m_frame.f_lineno = 693; - tmp_assattr_name_3 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_3); - if (tmp_assattr_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 693; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_3 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_3, mod_consts[195], tmp_assattr_name_3); - Py_DECREF(tmp_assattr_name_3); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 693; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_4; - nuitka_bool tmp_condition_result_1; - int tmp_truth_name_1; - PyObject *tmp_called_name_3; - PyObject *tmp_args_element_name_4; - PyObject *tmp_assattr_target_4; - CHECK_OBJECT(par_add_pooling_layer); - tmp_truth_name_1 = CHECK_IF_TRUE(par_add_pooling_layer); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 695; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - tmp_condition_result_1 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - tmp_called_name_3 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[196]); - - if (unlikely(tmp_called_name_3 == NULL)) { - tmp_called_name_3 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[196]); - } - - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 695; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 695; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_4 = par_config; - frame_8e16adea762727bda11361e993d1476d->m_frame.f_lineno = 695; - tmp_assattr_name_4 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_4); - if (tmp_assattr_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 695; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - goto condexpr_end_1; - condexpr_false_1:; - tmp_assattr_name_4 = Py_None; - Py_INCREF(tmp_assattr_name_4); - condexpr_end_1:; - CHECK_OBJECT(par_self); - tmp_assattr_target_4 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_4, mod_consts[197], tmp_assattr_name_4); - Py_DECREF(tmp_assattr_name_4); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 695; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_called_instance_2; - PyObject *tmp_call_result_2; - CHECK_OBJECT(par_self); - tmp_called_instance_2 = par_self; - frame_8e16adea762727bda11361e993d1476d->m_frame.f_lineno = 697; - tmp_call_result_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[198]); - if (tmp_call_result_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 697; - type_description_1 = "oooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_2); - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_8e16adea762727bda11361e993d1476d); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_8e16adea762727bda11361e993d1476d); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_8e16adea762727bda11361e993d1476d, exception_lineno); - } else if (exception_tb->tb_frame != &frame_8e16adea762727bda11361e993d1476d->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_8e16adea762727bda11361e993d1476d, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_8e16adea762727bda11361e993d1476d, - type_description_1, - par_self, - par_config, - par_add_pooling_layer, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_8e16adea762727bda11361e993d1476d == cache_frame_8e16adea762727bda11361e993d1476d) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_8e16adea762727bda11361e993d1476d); - cache_frame_8e16adea762727bda11361e993d1476d = NULL; - } - - assertFrameObject(frame_8e16adea762727bda11361e993d1476d); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - CHECK_OBJECT(par_add_pooling_layer); - Py_DECREF(par_add_pooling_layer); - par_add_pooling_layer = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - CHECK_OBJECT(par_add_pooling_layer); - Py_DECREF(par_add_pooling_layer); - par_add_pooling_layer = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__35_get_input_embeddings(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - struct Nuitka_FrameObject *frame_64584954755a32f374a421edcbab9154; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_64584954755a32f374a421edcbab9154 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_64584954755a32f374a421edcbab9154)) { - Py_XDECREF(cache_frame_64584954755a32f374a421edcbab9154); - -#if _DEBUG_REFCOUNTS - if (cache_frame_64584954755a32f374a421edcbab9154 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_64584954755a32f374a421edcbab9154 = MAKE_FUNCTION_FRAME(codeobj_64584954755a32f374a421edcbab9154, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_64584954755a32f374a421edcbab9154->m_type_description == NULL); - frame_64584954755a32f374a421edcbab9154 = cache_frame_64584954755a32f374a421edcbab9154; - - // Push the new frame as the currently active one. - pushFrameStack(frame_64584954755a32f374a421edcbab9154); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_64584954755a32f374a421edcbab9154) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[35]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 700; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - tmp_return_value = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[9]); - Py_DECREF(tmp_expression_name_1); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 700; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_64584954755a32f374a421edcbab9154); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_64584954755a32f374a421edcbab9154); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_64584954755a32f374a421edcbab9154); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_64584954755a32f374a421edcbab9154, exception_lineno); - } else if (exception_tb->tb_frame != &frame_64584954755a32f374a421edcbab9154->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_64584954755a32f374a421edcbab9154, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_64584954755a32f374a421edcbab9154, - type_description_1, - par_self - ); - - - // Release cached frame if used for exception. - if (frame_64584954755a32f374a421edcbab9154 == cache_frame_64584954755a32f374a421edcbab9154) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_64584954755a32f374a421edcbab9154); - cache_frame_64584954755a32f374a421edcbab9154 = NULL; - } - - assertFrameObject(frame_64584954755a32f374a421edcbab9154); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__36_set_input_embeddings(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_value = python_pars[1]; - struct Nuitka_FrameObject *frame_721775a04cb45ee2837ea767c0780001; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_721775a04cb45ee2837ea767c0780001 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_721775a04cb45ee2837ea767c0780001)) { - Py_XDECREF(cache_frame_721775a04cb45ee2837ea767c0780001); - -#if _DEBUG_REFCOUNTS - if (cache_frame_721775a04cb45ee2837ea767c0780001 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_721775a04cb45ee2837ea767c0780001 = MAKE_FUNCTION_FRAME(codeobj_721775a04cb45ee2837ea767c0780001, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_721775a04cb45ee2837ea767c0780001->m_type_description == NULL); - frame_721775a04cb45ee2837ea767c0780001 = cache_frame_721775a04cb45ee2837ea767c0780001; - - // Push the new frame as the currently active one. - pushFrameStack(frame_721775a04cb45ee2837ea767c0780001); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_721775a04cb45ee2837ea767c0780001) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - PyObject *tmp_expression_name_1; - CHECK_OBJECT(par_value); - tmp_assattr_name_1 = par_value; - CHECK_OBJECT(par_self); - tmp_expression_name_1 = par_self; - tmp_assattr_target_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[35]); - if (tmp_assattr_target_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 703; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[9], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_target_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 703; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_721775a04cb45ee2837ea767c0780001); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_721775a04cb45ee2837ea767c0780001); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_721775a04cb45ee2837ea767c0780001, exception_lineno); - } else if (exception_tb->tb_frame != &frame_721775a04cb45ee2837ea767c0780001->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_721775a04cb45ee2837ea767c0780001, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_721775a04cb45ee2837ea767c0780001, - type_description_1, - par_self, - par_value - ); - - - // Release cached frame if used for exception. - if (frame_721775a04cb45ee2837ea767c0780001 == cache_frame_721775a04cb45ee2837ea767c0780001) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_721775a04cb45ee2837ea767c0780001); - cache_frame_721775a04cb45ee2837ea767c0780001 = NULL; - } - - assertFrameObject(frame_721775a04cb45ee2837ea767c0780001); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_value); - Py_DECREF(par_value); - par_value = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_value); - Py_DECREF(par_value); - par_value = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__37__prune_heads(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_heads_to_prune = python_pars[1]; - PyObject *var_layer = NULL; - PyObject *var_heads = NULL; - PyObject *tmp_for_loop_1__for_iterator = NULL; - PyObject *tmp_for_loop_1__iter_value = NULL; - PyObject *tmp_tuple_unpack_1__element_1 = NULL; - PyObject *tmp_tuple_unpack_1__element_2 = NULL; - PyObject *tmp_tuple_unpack_1__source_iter = NULL; - struct Nuitka_FrameObject *frame_99e6e0fbfb9cc4282b3a8f4787f1fc90; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - PyObject *tmp_iterator_attempt; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_keeper_type_3; - PyObject *exception_keeper_value_3; - PyTracebackObject *exception_keeper_tb_3; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_3; - static struct Nuitka_FrameObject *cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_4; - PyObject *exception_keeper_value_4; - PyTracebackObject *exception_keeper_tb_4; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_4; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90)) { - Py_XDECREF(cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90); - -#if _DEBUG_REFCOUNTS - if (cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90 = MAKE_FUNCTION_FRAME(codeobj_99e6e0fbfb9cc4282b3a8f4787f1fc90, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90->m_type_description == NULL); - frame_99e6e0fbfb9cc4282b3a8f4787f1fc90 = cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90; - - // Push the new frame as the currently active one. - pushFrameStack(frame_99e6e0fbfb9cc4282b3a8f4787f1fc90); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_99e6e0fbfb9cc4282b3a8f4787f1fc90) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - PyObject *tmp_iter_arg_1; - PyObject *tmp_called_instance_1; - CHECK_OBJECT(par_heads_to_prune); - tmp_called_instance_1 = par_heads_to_prune; - frame_99e6e0fbfb9cc4282b3a8f4787f1fc90->m_frame.f_lineno = 710; - tmp_iter_arg_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[199]); - if (tmp_iter_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 710; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_1 = MAKE_ITERATOR(tmp_iter_arg_1); - Py_DECREF(tmp_iter_arg_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 710; - type_description_1 = "oooo"; - goto frame_exception_exit_1; - } - assert(tmp_for_loop_1__for_iterator == NULL); - tmp_for_loop_1__for_iterator = tmp_assign_source_1; - } - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_2; - CHECK_OBJECT(tmp_for_loop_1__for_iterator); - tmp_next_source_1 = tmp_for_loop_1__for_iterator; - tmp_assign_source_2 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_2 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oooo"; - exception_lineno = 710; - goto try_except_handler_2; - } - } - - { - PyObject *old = tmp_for_loop_1__iter_value; - tmp_for_loop_1__iter_value = tmp_assign_source_2; - Py_XDECREF(old); - } - - } - // Tried code: - { - PyObject *tmp_assign_source_3; - PyObject *tmp_iter_arg_2; - CHECK_OBJECT(tmp_for_loop_1__iter_value); - tmp_iter_arg_2 = tmp_for_loop_1__iter_value; - tmp_assign_source_3 = MAKE_UNPACK_ITERATOR(tmp_iter_arg_2); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 710; - type_description_1 = "oooo"; - goto try_except_handler_3; - } - { - PyObject *old = tmp_tuple_unpack_1__source_iter; - tmp_tuple_unpack_1__source_iter = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - // Tried code: - { - PyObject *tmp_assign_source_4; - PyObject *tmp_unpack_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_1 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_4 = UNPACK_NEXT(tmp_unpack_1, 0, 2); - if (tmp_assign_source_4 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooo"; - exception_lineno = 710; - goto try_except_handler_4; - } - { - PyObject *old = tmp_tuple_unpack_1__element_1; - tmp_tuple_unpack_1__element_1 = tmp_assign_source_4; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_5; - PyObject *tmp_unpack_2; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_2 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_5 = UNPACK_NEXT(tmp_unpack_2, 1, 2); - if (tmp_assign_source_5 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooo"; - exception_lineno = 710; - goto try_except_handler_4; - } - { - PyObject *old = tmp_tuple_unpack_1__element_2; - tmp_tuple_unpack_1__element_2 = tmp_assign_source_5; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_iterator_name_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_iterator_name_1 = tmp_tuple_unpack_1__source_iter; - // Check if iterator has left-over elements. - CHECK_OBJECT(tmp_iterator_name_1); assert(HAS_ITERNEXT(tmp_iterator_name_1)); - - tmp_iterator_attempt = (*Py_TYPE(tmp_iterator_name_1)->tp_iternext)(tmp_iterator_name_1); - - if (likely(tmp_iterator_attempt == NULL)) { - PyObject *error = GET_ERROR_OCCURRED(); - - if (error != NULL) { - if (EXCEPTION_MATCH_BOOL_SINGLE(error, PyExc_StopIteration)) { - CLEAR_ERROR_OCCURRED(); - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - type_description_1 = "oooo"; - exception_lineno = 710; - goto try_except_handler_4; - } - } - } else { - Py_DECREF(tmp_iterator_attempt); - - exception_type = PyExc_ValueError; - Py_INCREF(PyExc_ValueError); - exception_value = mod_consts[99]; - Py_INCREF(exception_value); - exception_tb = NULL; - - type_description_1 = "oooo"; - exception_lineno = 710; - goto try_except_handler_4; - } - } - goto try_end_1; - // Exception handler code: - try_except_handler_4:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto try_except_handler_3; - // End of try: - try_end_1:; - goto try_end_2; - // Exception handler code: - try_except_handler_3:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto try_except_handler_2; - // End of try: - try_end_2:; - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - { - PyObject *tmp_assign_source_6; - CHECK_OBJECT(tmp_tuple_unpack_1__element_1); - tmp_assign_source_6 = tmp_tuple_unpack_1__element_1; - { - PyObject *old = var_layer; - var_layer = tmp_assign_source_6; - Py_INCREF(var_layer); - Py_XDECREF(old); - } - - } - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - - { - PyObject *tmp_assign_source_7; - CHECK_OBJECT(tmp_tuple_unpack_1__element_2); - tmp_assign_source_7 = tmp_tuple_unpack_1__element_2; - { - PyObject *old = var_heads; - var_heads = tmp_assign_source_7; - Py_INCREF(var_heads); - Py_XDECREF(old); - } - - } - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - { - PyObject *tmp_called_instance_2; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_expression_name_4; - PyObject *tmp_subscript_name_1; - PyObject *tmp_call_result_1; - PyObject *tmp_args_element_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 711; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - - tmp_expression_name_4 = par_self; - tmp_expression_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[195]); - if (tmp_expression_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 711; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - tmp_expression_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[140]); - Py_DECREF(tmp_expression_name_3); - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 711; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - CHECK_OBJECT(var_layer); - tmp_subscript_name_1 = var_layer; - tmp_expression_name_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_2, tmp_subscript_name_1); - Py_DECREF(tmp_expression_name_2); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 711; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - tmp_called_instance_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[110]); - Py_DECREF(tmp_expression_name_1); - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 711; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - CHECK_OBJECT(var_heads); - tmp_args_element_name_1 = var_heads; - frame_99e6e0fbfb9cc4282b3a8f4787f1fc90->m_frame.f_lineno = 711; - tmp_call_result_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_2, mod_consts[200], tmp_args_element_name_1); - Py_DECREF(tmp_called_instance_2); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 711; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - Py_DECREF(tmp_call_result_1); - } - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 710; - type_description_1 = "oooo"; - goto try_except_handler_2; - } - goto loop_start_1; - loop_end_1:; - goto try_end_3; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_3 = exception_type; - exception_keeper_value_3 = exception_value; - exception_keeper_tb_3 = exception_tb; - exception_keeper_lineno_3 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_for_loop_1__iter_value); - tmp_for_loop_1__iter_value = NULL; - Py_XDECREF(tmp_for_loop_1__for_iterator); - tmp_for_loop_1__for_iterator = NULL; - // Re-raise. - exception_type = exception_keeper_type_3; - exception_value = exception_keeper_value_3; - exception_tb = exception_keeper_tb_3; - exception_lineno = exception_keeper_lineno_3; - - goto frame_exception_exit_1; - // End of try: - try_end_3:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_99e6e0fbfb9cc4282b3a8f4787f1fc90); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_99e6e0fbfb9cc4282b3a8f4787f1fc90); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_99e6e0fbfb9cc4282b3a8f4787f1fc90, exception_lineno); - } else if (exception_tb->tb_frame != &frame_99e6e0fbfb9cc4282b3a8f4787f1fc90->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_99e6e0fbfb9cc4282b3a8f4787f1fc90, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_99e6e0fbfb9cc4282b3a8f4787f1fc90, - type_description_1, - par_self, - par_heads_to_prune, - var_layer, - var_heads - ); - - - // Release cached frame if used for exception. - if (frame_99e6e0fbfb9cc4282b3a8f4787f1fc90 == cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90); - cache_frame_99e6e0fbfb9cc4282b3a8f4787f1fc90 = NULL; - } - - assertFrameObject(frame_99e6e0fbfb9cc4282b3a8f4787f1fc90); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - Py_XDECREF(tmp_for_loop_1__iter_value); - tmp_for_loop_1__iter_value = NULL; - Py_XDECREF(tmp_for_loop_1__for_iterator); - tmp_for_loop_1__for_iterator = NULL; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_heads_to_prune); - par_heads_to_prune = NULL; - Py_XDECREF(var_layer); - var_layer = NULL; - Py_XDECREF(var_heads); - var_heads = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_4 = exception_type; - exception_keeper_value_4 = exception_value; - exception_keeper_tb_4 = exception_tb; - exception_keeper_lineno_4 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_heads_to_prune); - par_heads_to_prune = NULL; - Py_XDECREF(var_layer); - var_layer = NULL; - Py_XDECREF(var_heads); - var_heads = NULL; - // Re-raise. - exception_type = exception_keeper_type_4; - exception_value = exception_keeper_value_4; - exception_tb = exception_keeper_tb_4; - exception_lineno = exception_keeper_lineno_4; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__38_get_extended_attention_mask(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_attention_mask = python_pars[1]; - PyObject *par_input_shape = python_pars[2]; - PyObject *par_device = python_pars[3]; - PyObject *par_is_decoder = python_pars[4]; - PyObject *par_has_query = python_pars[5]; - PyObject *var_extended_attention_mask = NULL; - PyObject *var_batch_size = NULL; - PyObject *var_seq_length = NULL; - PyObject *var_seq_ids = NULL; - PyObject *var_causal_mask = NULL; - PyObject *var_prefix_seq_len = NULL; - PyObject *tmp_tuple_unpack_1__element_1 = NULL; - PyObject *tmp_tuple_unpack_1__element_2 = NULL; - PyObject *tmp_tuple_unpack_1__source_iter = NULL; - struct Nuitka_FrameObject *frame_a5b726196dc433c291a911837adced9c; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - PyObject *tmp_iterator_attempt; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_a5b726196dc433c291a911837adced9c = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_3; - PyObject *exception_keeper_value_3; - PyTracebackObject *exception_keeper_tb_3; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_3; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_a5b726196dc433c291a911837adced9c)) { - Py_XDECREF(cache_frame_a5b726196dc433c291a911837adced9c); - -#if _DEBUG_REFCOUNTS - if (cache_frame_a5b726196dc433c291a911837adced9c == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_a5b726196dc433c291a911837adced9c = MAKE_FUNCTION_FRAME(codeobj_a5b726196dc433c291a911837adced9c, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_a5b726196dc433c291a911837adced9c->m_type_description == NULL); - frame_a5b726196dc433c291a911837adced9c = cache_frame_a5b726196dc433c291a911837adced9c; - - // Push the new frame as the currently active one. - pushFrameStack(frame_a5b726196dc433c291a911837adced9c); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_a5b726196dc433c291a911837adced9c) == 2); // Frame stack - - // Framed code: - { - nuitka_bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_called_instance_1; - PyObject *tmp_tmp_condition_result_1_object_1; - int tmp_truth_name_1; - CHECK_OBJECT(par_attention_mask); - tmp_called_instance_1 = par_attention_mask; - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 737; - tmp_compexpr_left_1 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[202]); - if (tmp_compexpr_left_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 737; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_1 = mod_consts[203]; - tmp_tmp_condition_result_1_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_1, tmp_compexpr_right_1); - Py_DECREF(tmp_compexpr_left_1); - if (tmp_tmp_condition_result_1_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 737; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_tmp_condition_result_1_object_1); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_1_object_1); - - exception_lineno = 737; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_1 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_1_object_1); - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_subscript_name_1; - if (par_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 738; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_1 = par_attention_mask; - tmp_subscript_name_1 = mod_consts[204]; - tmp_assign_source_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_1, tmp_subscript_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 738; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_extended_attention_mask == NULL); - var_extended_attention_mask = tmp_assign_source_1; - } - goto branch_end_1; - branch_no_1:; - { - nuitka_bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_tmp_condition_result_2_object_1; - int tmp_truth_name_2; - if (par_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 739; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_2 = par_attention_mask; - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 739; - tmp_compexpr_left_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[202]); - if (tmp_compexpr_left_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 739; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_2 = mod_consts[49]; - tmp_tmp_condition_result_2_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_2, tmp_compexpr_right_2); - Py_DECREF(tmp_compexpr_left_2); - if (tmp_tmp_condition_result_2_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 739; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_2 = CHECK_IF_TRUE(tmp_tmp_condition_result_2_object_1); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_2_object_1); - - exception_lineno = 739; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_2 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_2_object_1); - if (tmp_condition_result_2 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - nuitka_bool tmp_condition_result_3; - int tmp_truth_name_3; - CHECK_OBJECT(par_is_decoder); - tmp_truth_name_3 = CHECK_IF_TRUE(par_is_decoder); - if (tmp_truth_name_3 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 743; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_3 = tmp_truth_name_3 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - // Tried code: - { - PyObject *tmp_assign_source_2; - PyObject *tmp_iter_arg_1; - CHECK_OBJECT(par_input_shape); - tmp_iter_arg_1 = par_input_shape; - tmp_assign_source_2 = MAKE_UNPACK_ITERATOR(tmp_iter_arg_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 744; - type_description_1 = "oooooooooooo"; - goto try_except_handler_2; - } - assert(tmp_tuple_unpack_1__source_iter == NULL); - tmp_tuple_unpack_1__source_iter = tmp_assign_source_2; - } - // Tried code: - { - PyObject *tmp_assign_source_3; - PyObject *tmp_unpack_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_1 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_3 = UNPACK_NEXT(tmp_unpack_1, 0, 2); - if (tmp_assign_source_3 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooo"; - exception_lineno = 744; - goto try_except_handler_3; - } - assert(tmp_tuple_unpack_1__element_1 == NULL); - tmp_tuple_unpack_1__element_1 = tmp_assign_source_3; - } - { - PyObject *tmp_assign_source_4; - PyObject *tmp_unpack_2; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_2 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_4 = UNPACK_NEXT(tmp_unpack_2, 1, 2); - if (tmp_assign_source_4 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooo"; - exception_lineno = 744; - goto try_except_handler_3; - } - assert(tmp_tuple_unpack_1__element_2 == NULL); - tmp_tuple_unpack_1__element_2 = tmp_assign_source_4; - } - { - PyObject *tmp_iterator_name_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_iterator_name_1 = tmp_tuple_unpack_1__source_iter; - // Check if iterator has left-over elements. - CHECK_OBJECT(tmp_iterator_name_1); assert(HAS_ITERNEXT(tmp_iterator_name_1)); - - tmp_iterator_attempt = (*Py_TYPE(tmp_iterator_name_1)->tp_iternext)(tmp_iterator_name_1); - - if (likely(tmp_iterator_attempt == NULL)) { - PyObject *error = GET_ERROR_OCCURRED(); - - if (error != NULL) { - if (EXCEPTION_MATCH_BOOL_SINGLE(error, PyExc_StopIteration)) { - CLEAR_ERROR_OCCURRED(); - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - type_description_1 = "oooooooooooo"; - exception_lineno = 744; - goto try_except_handler_3; - } - } - } else { - Py_DECREF(tmp_iterator_attempt); - - exception_type = PyExc_ValueError; - Py_INCREF(PyExc_ValueError); - exception_value = mod_consts[99]; - Py_INCREF(exception_value); - exception_tb = NULL; - - type_description_1 = "oooooooooooo"; - exception_lineno = 744; - goto try_except_handler_3; - } - } - goto try_end_1; - // Exception handler code: - try_except_handler_3:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto try_except_handler_2; - // End of try: - try_end_1:; - goto try_end_2; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto frame_exception_exit_1; - // End of try: - try_end_2:; - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - { - PyObject *tmp_assign_source_5; - CHECK_OBJECT(tmp_tuple_unpack_1__element_1); - tmp_assign_source_5 = tmp_tuple_unpack_1__element_1; - assert(var_batch_size == NULL); - Py_INCREF(tmp_assign_source_5); - var_batch_size = tmp_assign_source_5; - } - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - - { - PyObject *tmp_assign_source_6; - CHECK_OBJECT(tmp_tuple_unpack_1__element_2); - tmp_assign_source_6 = tmp_tuple_unpack_1__element_2; - assert(var_seq_length == NULL); - Py_INCREF(tmp_assign_source_6); - var_seq_length = tmp_assign_source_6; - } - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - { - PyObject *tmp_assign_source_7; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - tmp_expression_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_2 == NULL)) { - tmp_expression_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 746; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[21]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 746; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_seq_length); - tmp_tuple_element_1 = var_seq_length; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[70]; - CHECK_OBJECT(par_device); - tmp_dict_value_1 = par_device; - tmp_kwargs_name_1 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 746; - tmp_assign_source_7 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 746; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_seq_ids == NULL); - var_seq_ids = tmp_assign_source_7; - } - { - PyObject *tmp_assign_source_8; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_expression_name_4; - PyObject *tmp_subscript_name_2; - PyObject *tmp_args_element_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_expression_name_5; - PyObject *tmp_subscript_name_3; - CHECK_OBJECT(var_seq_ids); - tmp_expression_name_4 = var_seq_ids; - tmp_subscript_name_2 = mod_consts[205]; - tmp_expression_name_3 = LOOKUP_SUBSCRIPT(tmp_expression_name_4, tmp_subscript_name_2); - if (tmp_expression_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 748; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[206]); - Py_DECREF(tmp_expression_name_3); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 748; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_batch_size); - tmp_args_element_name_1 = var_batch_size; - if (var_seq_length == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[72]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 748; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_2 = var_seq_length; - tmp_args_element_name_3 = mod_consts[28]; - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 748; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2, tmp_args_element_name_3}; - tmp_compexpr_left_3 = CALL_FUNCTION_WITH_ARGS3(tmp_called_name_2, call_args); - } - - Py_DECREF(tmp_called_name_2); - if (tmp_compexpr_left_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 748; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_seq_ids); - tmp_expression_name_5 = var_seq_ids; - tmp_subscript_name_3 = mod_consts[207]; - tmp_compexpr_right_3 = LOOKUP_SUBSCRIPT(tmp_expression_name_5, tmp_subscript_name_3); - if (tmp_compexpr_right_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_compexpr_left_3); - - exception_lineno = 749; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_8 = RICH_COMPARE_LE_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_3, tmp_compexpr_right_3); - Py_DECREF(tmp_compexpr_left_3); - Py_DECREF(tmp_compexpr_right_3); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 748; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_causal_mask == NULL); - var_causal_mask = tmp_assign_source_8; - } - { - PyObject *tmp_assign_source_9; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_6; - PyObject *tmp_args_element_name_4; - PyObject *tmp_expression_name_7; - CHECK_OBJECT(var_causal_mask); - tmp_expression_name_6 = var_causal_mask; - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[74]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 754; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (par_attention_mask == NULL) { - Py_DECREF(tmp_called_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 754; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_attention_mask; - tmp_args_element_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[68]); - if (tmp_args_element_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_3); - - exception_lineno = 754; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 754; - tmp_assign_source_9 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_3, tmp_args_element_name_4); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_element_name_4); - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 754; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_causal_mask; - var_causal_mask = tmp_assign_source_9; - Py_XDECREF(old); - } - - } - { - nuitka_bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - PyObject *tmp_expression_name_8; - PyObject *tmp_expression_name_9; - PyObject *tmp_subscript_name_4; - PyObject *tmp_expression_name_10; - PyObject *tmp_expression_name_11; - PyObject *tmp_subscript_name_5; - CHECK_OBJECT(var_causal_mask); - tmp_expression_name_9 = var_causal_mask; - tmp_expression_name_8 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[132]); - if (tmp_expression_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 756; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_4 = mod_consts[28]; - tmp_compexpr_left_4 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_8, tmp_subscript_name_4, 1); - Py_DECREF(tmp_expression_name_8); - if (tmp_compexpr_left_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 756; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (par_attention_mask == NULL) { - Py_DECREF(tmp_compexpr_left_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 756; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_11 = par_attention_mask; - tmp_expression_name_10 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[132]); - if (tmp_expression_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_compexpr_left_4); - - exception_lineno = 756; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_5 = mod_consts[28]; - tmp_compexpr_right_4 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_10, tmp_subscript_name_5, 1); - Py_DECREF(tmp_expression_name_10); - if (tmp_compexpr_right_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_compexpr_left_4); - - exception_lineno = 756; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_4 = RICH_COMPARE_LT_NBOOL_OBJECT_OBJECT(tmp_compexpr_left_4, tmp_compexpr_right_4); - Py_DECREF(tmp_compexpr_left_4); - Py_DECREF(tmp_compexpr_right_4); - if (tmp_condition_result_4 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 756; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (tmp_condition_result_4 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - assert(tmp_condition_result_4 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_4:; - { - PyObject *tmp_assign_source_10; - PyObject *tmp_left_name_1; - PyObject *tmp_expression_name_12; - PyObject *tmp_expression_name_13; - PyObject *tmp_subscript_name_6; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_14; - PyObject *tmp_expression_name_15; - PyObject *tmp_subscript_name_7; - if (par_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_13 = par_attention_mask; - tmp_expression_name_12 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[132]); - if (tmp_expression_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_6 = mod_consts[28]; - tmp_left_name_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_12, tmp_subscript_name_6, 1); - Py_DECREF(tmp_expression_name_12); - if (tmp_left_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (var_causal_mask == NULL) { - Py_DECREF(tmp_left_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_15 = var_causal_mask; - tmp_expression_name_14 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[132]); - if (tmp_expression_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_7 = mod_consts[28]; - tmp_right_name_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_14, tmp_subscript_name_7, 1); - Py_DECREF(tmp_expression_name_14); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_10 = BINARY_OPERATION_SUB_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 757; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_prefix_seq_len == NULL); - var_prefix_seq_len = tmp_assign_source_10; - } - { - nuitka_bool tmp_condition_result_5; - int tmp_truth_name_4; - CHECK_OBJECT(par_has_query); - tmp_truth_name_4 = CHECK_IF_TRUE(par_has_query); - if (tmp_truth_name_4 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 758; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_5 = tmp_truth_name_4 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - { - PyObject *tmp_assign_source_11; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_16; - PyObject *tmp_args_name_2; - PyObject *tmp_tuple_element_2; - PyObject *tmp_list_element_1; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_17; - PyObject *tmp_args_name_3; - PyObject *tmp_tuple_element_3; - PyObject *tmp_tuple_element_4; - PyObject *tmp_kwargs_name_2; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - PyObject *tmp_kwargs_name_3; - tmp_expression_name_16 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_16 == NULL)) { - tmp_expression_name_16 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 759; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_16, mod_consts[33]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 759; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_expression_name_17 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_17 == NULL)) { - tmp_expression_name_17 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 761; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[178]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 761; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (var_batch_size == NULL) { - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_called_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[209]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 762; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_4 = var_batch_size; - tmp_tuple_element_3 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_tuple_element_3, 0, tmp_tuple_element_4); - CHECK_OBJECT(var_prefix_seq_len); - tmp_tuple_element_4 = var_prefix_seq_len; - PyTuple_SET_ITEM0(tmp_tuple_element_3, 1, tmp_tuple_element_4); - if (var_seq_length == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[72]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 762; - type_description_1 = "oooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_tuple_element_4 = var_seq_length; - PyTuple_SET_ITEM0(tmp_tuple_element_3, 2, tmp_tuple_element_4); - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_tuple_element_3); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_args_name_3 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_3, 0, tmp_tuple_element_3); - tmp_dict_key_2 = mod_consts[70]; - if (par_device == NULL) { - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[70]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 763; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_2 = par_device; - tmp_kwargs_name_2 = _PyDict_NewPresized( 2 ); - { - PyObject *tmp_expression_name_18; - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - tmp_dict_key_2 = mod_consts[68]; - if (var_causal_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 764; - type_description_1 = "oooooooooooo"; - goto dict_build_exception_1; - } - - tmp_expression_name_18 = var_causal_mask; - tmp_dict_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_18, mod_consts[68]); - if (tmp_dict_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 764; - type_description_1 = "oooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - Py_DECREF(tmp_dict_value_2); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_name_3); - Py_DECREF(tmp_kwargs_name_2); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 761; - tmp_list_element_1 = CALL_FUNCTION(tmp_called_name_5, tmp_args_name_3, tmp_kwargs_name_2); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_name_3); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_list_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 761; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_2 = PyList_New(2); - PyList_SET_ITEM(tmp_tuple_element_2, 0, tmp_list_element_1); - if (var_causal_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 766; - type_description_1 = "oooooooooooo"; - goto list_build_exception_1; - } - - tmp_list_element_1 = var_causal_mask; - PyList_SET_ITEM0(tmp_tuple_element_2, 1, tmp_list_element_1); - goto list_build_noexception_1; - // Exception handling pass through code for list_build: - list_build_exception_1:; - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_tuple_element_2); - goto frame_exception_exit_1; - // Finished with no exception for list_build: - list_build_noexception_1:; - tmp_args_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_2, 0, tmp_tuple_element_2); - tmp_kwargs_name_3 = PyDict_Copy(mod_consts[210]); - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 759; - tmp_assign_source_11 = CALL_FUNCTION(tmp_called_name_4, tmp_args_name_2, tmp_kwargs_name_3); - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_name_2); - Py_DECREF(tmp_kwargs_name_3); - if (tmp_assign_source_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 759; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_causal_mask; - var_causal_mask = tmp_assign_source_11; - Py_XDECREF(old); - } - - } - branch_no_5:; - { - PyObject *tmp_assign_source_12; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_19; - PyObject *tmp_args_name_4; - PyObject *tmp_tuple_element_5; - PyObject *tmp_list_element_2; - PyObject *tmp_called_name_7; - PyObject *tmp_expression_name_20; - PyObject *tmp_args_name_5; - PyObject *tmp_tuple_element_6; - PyObject *tmp_tuple_element_7; - PyObject *tmp_kwargs_name_4; - PyObject *tmp_dict_key_3; - PyObject *tmp_dict_value_3; - PyObject *tmp_kwargs_name_5; - tmp_expression_name_19 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_19 == NULL)) { - tmp_expression_name_19 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 770; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[33]); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 770; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_expression_name_20 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_20 == NULL)) { - tmp_expression_name_20 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 772; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[211]); - if (tmp_called_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 772; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (var_batch_size == NULL) { - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_called_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[209]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 773; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_7 = var_batch_size; - tmp_tuple_element_6 = PyTuple_New(3); - { - PyObject *tmp_expression_name_21; - PyObject *tmp_expression_name_22; - PyObject *tmp_subscript_name_8; - PyTuple_SET_ITEM0(tmp_tuple_element_6, 0, tmp_tuple_element_7); - if (var_causal_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 773; - type_description_1 = "oooooooooooo"; - goto tuple_build_exception_2; - } - - tmp_expression_name_22 = var_causal_mask; - tmp_expression_name_21 = LOOKUP_ATTRIBUTE(tmp_expression_name_22, mod_consts[132]); - if (tmp_expression_name_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 773; - type_description_1 = "oooooooooooo"; - goto tuple_build_exception_2; - } - tmp_subscript_name_8 = mod_consts[28]; - tmp_tuple_element_7 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_21, tmp_subscript_name_8, 1); - Py_DECREF(tmp_expression_name_21); - if (tmp_tuple_element_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 773; - type_description_1 = "oooooooooooo"; - goto tuple_build_exception_2; - } - PyTuple_SET_ITEM(tmp_tuple_element_6, 1, tmp_tuple_element_7); - if (var_prefix_seq_len == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[212]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 773; - type_description_1 = "oooooooooooo"; - goto tuple_build_exception_2; - } - - tmp_tuple_element_7 = var_prefix_seq_len; - PyTuple_SET_ITEM0(tmp_tuple_element_6, 2, tmp_tuple_element_7); - } - goto tuple_build_noexception_2; - // Exception handling pass through code for tuple_build: - tuple_build_exception_2:; - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_tuple_element_6); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_2:; - tmp_args_name_5 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_5, 0, tmp_tuple_element_6); - tmp_dict_key_3 = mod_consts[70]; - if (par_device == NULL) { - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[70]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 774; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_3 = par_device; - tmp_kwargs_name_4 = _PyDict_NewPresized( 2 ); - { - PyObject *tmp_expression_name_23; - tmp_res = PyDict_SetItem(tmp_kwargs_name_4, tmp_dict_key_3, tmp_dict_value_3); - assert(!(tmp_res != 0)); - tmp_dict_key_3 = mod_consts[68]; - if (var_causal_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 775; - type_description_1 = "oooooooooooo"; - goto dict_build_exception_2; - } - - tmp_expression_name_23 = var_causal_mask; - tmp_dict_value_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[68]); - if (tmp_dict_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 775; - type_description_1 = "oooooooooooo"; - goto dict_build_exception_2; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_4, tmp_dict_key_3, tmp_dict_value_3); - Py_DECREF(tmp_dict_value_3); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_2; - // Exception handling pass through code for dict_build: - dict_build_exception_2:; - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_name_5); - Py_DECREF(tmp_kwargs_name_4); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_2:; - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 772; - tmp_list_element_2 = CALL_FUNCTION(tmp_called_name_7, tmp_args_name_5, tmp_kwargs_name_4); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_name_5); - Py_DECREF(tmp_kwargs_name_4); - if (tmp_list_element_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 772; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_5 = PyList_New(2); - PyList_SET_ITEM(tmp_tuple_element_5, 0, tmp_list_element_2); - if (var_causal_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 777; - type_description_1 = "oooooooooooo"; - goto list_build_exception_2; - } - - tmp_list_element_2 = var_causal_mask; - PyList_SET_ITEM0(tmp_tuple_element_5, 1, tmp_list_element_2); - goto list_build_noexception_2; - // Exception handling pass through code for list_build: - list_build_exception_2:; - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_tuple_element_5); - goto frame_exception_exit_1; - // Finished with no exception for list_build: - list_build_noexception_2:; - tmp_args_name_4 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_4, 0, tmp_tuple_element_5); - tmp_kwargs_name_5 = PyDict_Copy(mod_consts[213]); - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 770; - tmp_assign_source_12 = CALL_FUNCTION(tmp_called_name_6, tmp_args_name_4, tmp_kwargs_name_5); - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_args_name_4); - Py_DECREF(tmp_kwargs_name_5); - if (tmp_assign_source_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 770; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_causal_mask; - var_causal_mask = tmp_assign_source_12; - Py_XDECREF(old); - } - - } - branch_no_4:; - { - PyObject *tmp_assign_source_13; - PyObject *tmp_left_name_2; - PyObject *tmp_expression_name_24; - PyObject *tmp_subscript_name_9; - PyObject *tmp_right_name_2; - PyObject *tmp_expression_name_25; - PyObject *tmp_subscript_name_10; - if (var_causal_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[208]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 782; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_24 = var_causal_mask; - tmp_subscript_name_9 = mod_consts[204]; - tmp_left_name_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_24, tmp_subscript_name_9); - if (tmp_left_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 782; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - if (par_attention_mask == NULL) { - Py_DECREF(tmp_left_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 782; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_25 = par_attention_mask; - tmp_subscript_name_10 = mod_consts[214]; - tmp_right_name_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_25, tmp_subscript_name_10); - if (tmp_right_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_2); - - exception_lineno = 782; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_13 = BINARY_OPERATION_MULT_OBJECT_OBJECT_OBJECT(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_left_name_2); - Py_DECREF(tmp_right_name_2); - if (tmp_assign_source_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 782; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_extended_attention_mask == NULL); - var_extended_attention_mask = tmp_assign_source_13; - } - goto branch_end_3; - branch_no_3:; - { - PyObject *tmp_assign_source_14; - PyObject *tmp_expression_name_26; - PyObject *tmp_subscript_name_11; - if (par_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 785; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_26 = par_attention_mask; - tmp_subscript_name_11 = mod_consts[214]; - tmp_assign_source_14 = LOOKUP_SUBSCRIPT(tmp_expression_name_26, tmp_subscript_name_11); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 785; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_extended_attention_mask == NULL); - var_extended_attention_mask = tmp_assign_source_14; - } - branch_end_3:; - goto branch_end_2; - branch_no_2:; - { - PyObject *tmp_raise_type_1; - PyObject *tmp_make_exception_arg_1; - PyObject *tmp_called_name_8; - PyObject *tmp_expression_name_27; - PyObject *tmp_args_element_name_5; - PyObject *tmp_args_element_name_6; - PyObject *tmp_expression_name_28; - tmp_expression_name_27 = mod_consts[215]; - tmp_called_name_8 = LOOKUP_ATTRIBUTE(tmp_expression_name_27, mod_consts[216]); - assert(!(tmp_called_name_8 == NULL)); - CHECK_OBJECT(par_input_shape); - tmp_args_element_name_5 = par_input_shape; - if (par_attention_mask == NULL) { - Py_DECREF(tmp_called_name_8); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[128]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 789; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_28 = par_attention_mask; - tmp_args_element_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_28, mod_consts[132]); - if (tmp_args_element_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_8); - - exception_lineno = 789; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 788; - { - PyObject *call_args[] = {tmp_args_element_name_5, tmp_args_element_name_6}; - tmp_make_exception_arg_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_8, call_args); - } - - Py_DECREF(tmp_called_name_8); - Py_DECREF(tmp_args_element_name_6); - if (tmp_make_exception_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 788; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 787; - tmp_raise_type_1 = CALL_FUNCTION_WITH_SINGLE_ARG(PyExc_ValueError, tmp_make_exception_arg_1); - Py_DECREF(tmp_make_exception_arg_1); - assert(!(tmp_raise_type_1 == NULL)); - exception_type = tmp_raise_type_1; - exception_lineno = 787; - RAISE_EXCEPTION_WITH_TYPE(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - branch_end_2:; - branch_end_1:; - { - PyObject *tmp_assign_source_15; - PyObject *tmp_called_name_9; - PyObject *tmp_expression_name_29; - PyObject *tmp_kwargs_name_6; - PyObject *tmp_dict_key_4; - PyObject *tmp_dict_value_4; - PyObject *tmp_expression_name_30; - if (var_extended_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[217]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 798; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_29 = var_extended_attention_mask; - tmp_called_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_29, mod_consts[74]); - if (tmp_called_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 798; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_4 = mod_consts[68]; - CHECK_OBJECT(par_self); - tmp_expression_name_30 = par_self; - tmp_dict_value_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_30, mod_consts[68]); - if (tmp_dict_value_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_9); - - exception_lineno = 799; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_kwargs_name_6 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_4, tmp_dict_value_4); - Py_DECREF(tmp_dict_value_4); - assert(!(tmp_res != 0)); - frame_a5b726196dc433c291a911837adced9c->m_frame.f_lineno = 798; - tmp_assign_source_15 = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_9, tmp_kwargs_name_6); - Py_DECREF(tmp_called_name_9); - Py_DECREF(tmp_kwargs_name_6); - if (tmp_assign_source_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 798; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_extended_attention_mask; - var_extended_attention_mask = tmp_assign_source_15; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_16; - PyObject *tmp_left_name_3; - PyObject *tmp_left_name_4; - PyObject *tmp_right_name_3; - PyObject *tmp_right_name_4; - tmp_left_name_4 = mod_consts[218]; - CHECK_OBJECT(var_extended_attention_mask); - tmp_right_name_3 = var_extended_attention_mask; - tmp_left_name_3 = BINARY_OPERATION_SUB_OBJECT_FLOAT_OBJECT(tmp_left_name_4, tmp_right_name_3); - if (tmp_left_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 801; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - tmp_right_name_4 = mod_consts[219]; - tmp_assign_source_16 = BINARY_OPERATION_MULT_OBJECT_OBJECT_FLOAT(tmp_left_name_3, tmp_right_name_4); - Py_DECREF(tmp_left_name_3); - if (tmp_assign_source_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 801; - type_description_1 = "oooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_extended_attention_mask; - var_extended_attention_mask = tmp_assign_source_16; - Py_XDECREF(old); - } - - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_a5b726196dc433c291a911837adced9c); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_a5b726196dc433c291a911837adced9c); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_a5b726196dc433c291a911837adced9c, exception_lineno); - } else if (exception_tb->tb_frame != &frame_a5b726196dc433c291a911837adced9c->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_a5b726196dc433c291a911837adced9c, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_a5b726196dc433c291a911837adced9c, - type_description_1, - par_self, - par_attention_mask, - par_input_shape, - par_device, - par_is_decoder, - par_has_query, - var_extended_attention_mask, - var_batch_size, - var_seq_length, - var_seq_ids, - var_causal_mask, - var_prefix_seq_len - ); - - - // Release cached frame if used for exception. - if (frame_a5b726196dc433c291a911837adced9c == cache_frame_a5b726196dc433c291a911837adced9c) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_a5b726196dc433c291a911837adced9c); - cache_frame_a5b726196dc433c291a911837adced9c = NULL; - } - - assertFrameObject(frame_a5b726196dc433c291a911837adced9c); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - CHECK_OBJECT(var_extended_attention_mask); - tmp_return_value = var_extended_attention_mask; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_input_shape); - par_input_shape = NULL; - Py_XDECREF(par_device); - par_device = NULL; - CHECK_OBJECT(par_is_decoder); - Py_DECREF(par_is_decoder); - par_is_decoder = NULL; - CHECK_OBJECT(par_has_query); - Py_DECREF(par_has_query); - par_has_query = NULL; - CHECK_OBJECT(var_extended_attention_mask); - Py_DECREF(var_extended_attention_mask); - var_extended_attention_mask = NULL; - Py_XDECREF(var_batch_size); - var_batch_size = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_seq_ids); - var_seq_ids = NULL; - Py_XDECREF(var_causal_mask); - var_causal_mask = NULL; - Py_XDECREF(var_prefix_seq_len); - var_prefix_seq_len = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_3 = exception_type; - exception_keeper_value_3 = exception_value; - exception_keeper_tb_3 = exception_tb; - exception_keeper_lineno_3 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_input_shape); - par_input_shape = NULL; - Py_XDECREF(par_device); - par_device = NULL; - CHECK_OBJECT(par_is_decoder); - Py_DECREF(par_is_decoder); - par_is_decoder = NULL; - CHECK_OBJECT(par_has_query); - Py_DECREF(par_has_query); - par_has_query = NULL; - Py_XDECREF(var_extended_attention_mask); - var_extended_attention_mask = NULL; - Py_XDECREF(var_batch_size); - var_batch_size = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_seq_ids); - var_seq_ids = NULL; - Py_XDECREF(var_causal_mask); - var_causal_mask = NULL; - Py_XDECREF(var_prefix_seq_len); - var_prefix_seq_len = NULL; - // Re-raise. - exception_type = exception_keeper_type_3; - exception_value = exception_keeper_value_3; - exception_tb = exception_keeper_tb_3; - exception_lineno = exception_keeper_lineno_3; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__39_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_input_ids = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_position_ids = python_pars[3]; - PyObject *par_head_mask = python_pars[4]; - PyObject *par_query_embeds = python_pars[5]; - PyObject *par_encoder_hidden_states = python_pars[6]; - PyObject *par_encoder_attention_mask = python_pars[7]; - PyObject *par_past_key_values = python_pars[8]; - PyObject *par_use_cache = python_pars[9]; - PyObject *par_output_attentions = python_pars[10]; - PyObject *par_output_hidden_states = python_pars[11]; - PyObject *par_return_dict = python_pars[12]; - PyObject *par_is_decoder = python_pars[13]; - PyObject *var_past_key_values_length = NULL; - PyObject *var_query_length = NULL; - PyObject *var_embedding_output = NULL; - PyObject *var_input_shape = NULL; - PyObject *var_batch_size = NULL; - PyObject *var_seq_length = NULL; - PyObject *var_device = NULL; - PyObject *var_extended_attention_mask = NULL; - PyObject *var_encoder_batch_size = NULL; - PyObject *var_encoder_sequence_length = NULL; - PyObject *var__ = NULL; - PyObject *var_encoder_hidden_shape = NULL; - PyObject *var_encoder_extended_attention_mask = NULL; - PyObject *var_encoder_outputs = NULL; - PyObject *var_sequence_output = NULL; - PyObject *var_pooled_output = NULL; - PyObject *outline_0_var_mask = NULL; - PyObject *tmp_listcomp_1__$0 = NULL; - PyObject *tmp_listcomp_1__contraction = NULL; - PyObject *tmp_listcomp_1__iter_value_0 = NULL; - PyObject *tmp_tuple_unpack_1__element_1 = NULL; - PyObject *tmp_tuple_unpack_1__element_2 = NULL; - PyObject *tmp_tuple_unpack_1__source_iter = NULL; - PyObject *tmp_tuple_unpack_2__element_1 = NULL; - PyObject *tmp_tuple_unpack_2__element_2 = NULL; - PyObject *tmp_tuple_unpack_2__element_3 = NULL; - PyObject *tmp_tuple_unpack_2__source_iter = NULL; - PyObject *tmp_tuple_unpack_3__element_1 = NULL; - PyObject *tmp_tuple_unpack_3__element_2 = NULL; - PyObject *tmp_tuple_unpack_3__element_3 = NULL; - PyObject *tmp_tuple_unpack_3__source_iter = NULL; - struct Nuitka_FrameObject *frame_960ad736510918980c376a071f656626; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - PyObject *tmp_iterator_attempt; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - PyObject *exception_keeper_type_3; - PyObject *exception_keeper_value_3; - PyTracebackObject *exception_keeper_tb_3; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_3; - PyObject *exception_keeper_type_4; - PyObject *exception_keeper_value_4; - PyTracebackObject *exception_keeper_tb_4; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_4; - PyObject *exception_keeper_type_5; - PyObject *exception_keeper_value_5; - PyTracebackObject *exception_keeper_tb_5; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_5; - PyObject *exception_keeper_type_6; - PyObject *exception_keeper_value_6; - PyTracebackObject *exception_keeper_tb_6; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_6; - struct Nuitka_FrameObject *frame_3b8e99b3705bb48cdf88a9a082001f87_2; - NUITKA_MAY_BE_UNUSED char const *type_description_2 = NULL; - bool tmp_result; - PyObject *exception_keeper_type_7; - PyObject *exception_keeper_value_7; - PyTracebackObject *exception_keeper_tb_7; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_7; - static struct Nuitka_FrameObject *cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2 = NULL; - PyObject *exception_keeper_type_8; - PyObject *exception_keeper_value_8; - PyTracebackObject *exception_keeper_tb_8; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_8; - PyObject *tmp_return_value = NULL; - static struct Nuitka_FrameObject *cache_frame_960ad736510918980c376a071f656626 = NULL; - PyObject *exception_keeper_type_9; - PyObject *exception_keeper_value_9; - PyTracebackObject *exception_keeper_tb_9; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_9; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_960ad736510918980c376a071f656626)) { - Py_XDECREF(cache_frame_960ad736510918980c376a071f656626); - -#if _DEBUG_REFCOUNTS - if (cache_frame_960ad736510918980c376a071f656626 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_960ad736510918980c376a071f656626 = MAKE_FUNCTION_FRAME(codeobj_960ad736510918980c376a071f656626, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_960ad736510918980c376a071f656626->m_type_description == NULL); - frame_960ad736510918980c376a071f656626 = cache_frame_960ad736510918980c376a071f656626; - - // Push the new frame as the currently active one. - pushFrameStack(frame_960ad736510918980c376a071f656626); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_960ad736510918980c376a071f656626) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_output_attentions); - tmp_compexpr_left_1 = par_output_attentions; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - CHECK_OBJECT(par_output_attentions); - tmp_assign_source_1 = par_output_attentions; - Py_INCREF(tmp_assign_source_1); - goto condexpr_end_1; - condexpr_false_1:; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[5]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 841; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[123]); - Py_DECREF(tmp_expression_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 841; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - condexpr_end_1:; - { - PyObject *old = par_output_attentions; - assert(old != NULL); - par_output_attentions = tmp_assign_source_1; - Py_DECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_expression_name_4; - CHECK_OBJECT(par_output_hidden_states); - tmp_compexpr_left_2 = par_output_hidden_states; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_2 = (tmp_compexpr_left_2 != tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_2 != false) { - goto condexpr_true_2; - } else { - goto condexpr_false_2; - } - condexpr_true_2:; - CHECK_OBJECT(par_output_hidden_states); - tmp_assign_source_2 = par_output_hidden_states; - Py_INCREF(tmp_assign_source_2); - goto condexpr_end_2; - condexpr_false_2:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 846; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_4 = par_self; - tmp_expression_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_4, mod_consts[5]); - if (tmp_expression_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 846; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[142]); - Py_DECREF(tmp_expression_name_3); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 846; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - condexpr_end_2:; - { - PyObject *old = par_output_hidden_states; - assert(old != NULL); - par_output_hidden_states = tmp_assign_source_2; - Py_DECREF(old); - } - - } - { - PyObject *tmp_assign_source_3; - bool tmp_condition_result_3; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - PyObject *tmp_expression_name_5; - PyObject *tmp_expression_name_6; - CHECK_OBJECT(par_return_dict); - tmp_compexpr_left_3 = par_return_dict; - tmp_compexpr_right_3 = Py_None; - tmp_condition_result_3 = (tmp_compexpr_left_3 != tmp_compexpr_right_3) ? true : false; - if (tmp_condition_result_3 != false) { - goto condexpr_true_3; - } else { - goto condexpr_false_3; - } - condexpr_true_3:; - CHECK_OBJECT(par_return_dict); - tmp_assign_source_3 = par_return_dict; - Py_INCREF(tmp_assign_source_3); - goto condexpr_end_3; - condexpr_false_3:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 849; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_6 = par_self; - tmp_expression_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[5]); - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 849; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[221]); - Py_DECREF(tmp_expression_name_5); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 849; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - condexpr_end_3:; - { - PyObject *old = par_return_dict; - assert(old != NULL); - par_return_dict = tmp_assign_source_3; - Py_DECREF(old); - } - - } - { - bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - CHECK_OBJECT(par_input_ids); - tmp_compexpr_left_4 = par_input_ids; - tmp_compexpr_right_4 = Py_None; - tmp_condition_result_4 = (tmp_compexpr_left_4 == tmp_compexpr_right_4) ? true : false; - if (tmp_condition_result_4 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - bool tmp_condition_result_5; - PyObject *tmp_compexpr_left_5; - PyObject *tmp_compexpr_right_5; - CHECK_OBJECT(par_query_embeds); - tmp_compexpr_left_5 = par_query_embeds; - tmp_compexpr_right_5 = Py_None; - tmp_condition_result_5 = (tmp_compexpr_left_5 == tmp_compexpr_right_5) ? true : false; - if (tmp_condition_result_5 != false) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_raise_type_1; - PyObject *tmp_raise_value_1; - tmp_raise_type_1 = PyExc_AssertionError; - tmp_raise_value_1 = mod_consts[222]; - exception_type = tmp_raise_type_1; - Py_INCREF(tmp_raise_type_1); - exception_value = tmp_raise_value_1; - Py_INCREF(tmp_raise_value_1); - exception_lineno = 855; - RAISE_EXCEPTION_WITH_VALUE(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - branch_no_2:; - branch_no_1:; - { - PyObject *tmp_assign_source_4; - bool tmp_condition_result_6; - PyObject *tmp_compexpr_left_6; - PyObject *tmp_compexpr_right_6; - PyObject *tmp_left_name_1; - PyObject *tmp_expression_name_7; - PyObject *tmp_expression_name_8; - PyObject *tmp_expression_name_9; - PyObject *tmp_expression_name_10; - PyObject *tmp_subscript_name_1; - PyObject *tmp_subscript_name_2; - PyObject *tmp_subscript_name_3; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_11; - PyObject *tmp_expression_name_12; - CHECK_OBJECT(par_past_key_values); - tmp_compexpr_left_6 = par_past_key_values; - tmp_compexpr_right_6 = Py_None; - tmp_condition_result_6 = (tmp_compexpr_left_6 != tmp_compexpr_right_6) ? true : false; - if (tmp_condition_result_6 != false) { - goto condexpr_true_4; - } else { - goto condexpr_false_4; - } - condexpr_true_4:; - CHECK_OBJECT(par_past_key_values); - tmp_expression_name_10 = par_past_key_values; - tmp_subscript_name_1 = mod_consts[29]; - tmp_expression_name_9 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_10, tmp_subscript_name_1, 0); - if (tmp_expression_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_2 = mod_consts[29]; - tmp_expression_name_8 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_9, tmp_subscript_name_2, 0); - Py_DECREF(tmp_expression_name_9); - if (tmp_expression_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_expression_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[132]); - Py_DECREF(tmp_expression_name_8); - if (tmp_expression_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_3 = mod_consts[49]; - tmp_left_name_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_7, tmp_subscript_name_3, 2); - Py_DECREF(tmp_expression_name_7); - if (tmp_left_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (par_self == NULL) { - Py_DECREF(tmp_left_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_12 = par_self; - tmp_expression_name_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[5]); - if (tmp_expression_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_right_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[156]); - Py_DECREF(tmp_expression_name_11); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_4 = BINARY_OPERATION_SUB_OBJECT_OBJECT_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 861; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto condexpr_end_4; - condexpr_false_4:; - tmp_assign_source_4 = mod_consts[29]; - Py_INCREF(tmp_assign_source_4); - condexpr_end_4:; - assert(var_past_key_values_length == NULL); - var_past_key_values_length = tmp_assign_source_4; - } - { - PyObject *tmp_assign_source_5; - bool tmp_condition_result_7; - PyObject *tmp_compexpr_left_7; - PyObject *tmp_compexpr_right_7; - PyObject *tmp_expression_name_13; - PyObject *tmp_expression_name_14; - PyObject *tmp_subscript_name_4; - CHECK_OBJECT(par_query_embeds); - tmp_compexpr_left_7 = par_query_embeds; - tmp_compexpr_right_7 = Py_None; - tmp_condition_result_7 = (tmp_compexpr_left_7 != tmp_compexpr_right_7) ? true : false; - if (tmp_condition_result_7 != false) { - goto condexpr_true_5; - } else { - goto condexpr_false_5; - } - condexpr_true_5:; - CHECK_OBJECT(par_query_embeds); - tmp_expression_name_14 = par_query_embeds; - tmp_expression_name_13 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[132]); - if (tmp_expression_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 866; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_4 = mod_consts[28]; - tmp_assign_source_5 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_13, tmp_subscript_name_4, 1); - Py_DECREF(tmp_expression_name_13); - if (tmp_assign_source_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 866; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto condexpr_end_5; - condexpr_false_5:; - tmp_assign_source_5 = mod_consts[29]; - Py_INCREF(tmp_assign_source_5); - condexpr_end_5:; - assert(var_query_length == NULL); - var_query_length = tmp_assign_source_5; - } - { - PyObject *tmp_assign_source_6; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_15; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 868; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_15 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[35]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 868; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_1 = mod_consts[32]; - CHECK_OBJECT(par_input_ids); - tmp_dict_value_1 = par_input_ids; - tmp_kwargs_name_1 = _PyDict_NewPresized( 4 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[19]; - CHECK_OBJECT(par_position_ids); - tmp_dict_value_1 = par_position_ids; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[223]; - if (par_query_embeds == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 871; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_dict_value_1 = par_query_embeds; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[224]; - CHECK_OBJECT(var_past_key_values_length); - tmp_dict_value_1 = var_past_key_values_length; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_kwargs_name_1); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 868; - tmp_assign_source_6 = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 868; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_embedding_output == NULL); - var_embedding_output = tmp_assign_source_6; - } - { - PyObject *tmp_assign_source_7; - PyObject *tmp_expression_name_16; - PyObject *tmp_called_instance_1; - PyObject *tmp_subscript_name_5; - CHECK_OBJECT(var_embedding_output); - tmp_called_instance_1 = var_embedding_output; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 875; - tmp_expression_name_16 = CALL_METHOD_NO_ARGS(tmp_called_instance_1, mod_consts[27]); - if (tmp_expression_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 875; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_5 = mod_consts[54]; - tmp_assign_source_7 = LOOKUP_SUBSCRIPT(tmp_expression_name_16, tmp_subscript_name_5); - Py_DECREF(tmp_expression_name_16); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 875; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_input_shape == NULL); - var_input_shape = tmp_assign_source_7; - } - // Tried code: - { - PyObject *tmp_assign_source_8; - PyObject *tmp_iter_arg_1; - CHECK_OBJECT(var_input_shape); - tmp_iter_arg_1 = var_input_shape; - tmp_assign_source_8 = MAKE_UNPACK_ITERATOR(tmp_iter_arg_1); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 876; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_2; - } - assert(tmp_tuple_unpack_1__source_iter == NULL); - tmp_tuple_unpack_1__source_iter = tmp_assign_source_8; - } - // Tried code: - { - PyObject *tmp_assign_source_9; - PyObject *tmp_unpack_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_1 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_9 = UNPACK_NEXT(tmp_unpack_1, 0, 2); - if (tmp_assign_source_9 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 876; - goto try_except_handler_3; - } - assert(tmp_tuple_unpack_1__element_1 == NULL); - tmp_tuple_unpack_1__element_1 = tmp_assign_source_9; - } - { - PyObject *tmp_assign_source_10; - PyObject *tmp_unpack_2; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_unpack_2 = tmp_tuple_unpack_1__source_iter; - tmp_assign_source_10 = UNPACK_NEXT(tmp_unpack_2, 1, 2); - if (tmp_assign_source_10 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 876; - goto try_except_handler_3; - } - assert(tmp_tuple_unpack_1__element_2 == NULL); - tmp_tuple_unpack_1__element_2 = tmp_assign_source_10; - } - { - PyObject *tmp_iterator_name_1; - CHECK_OBJECT(tmp_tuple_unpack_1__source_iter); - tmp_iterator_name_1 = tmp_tuple_unpack_1__source_iter; - // Check if iterator has left-over elements. - CHECK_OBJECT(tmp_iterator_name_1); assert(HAS_ITERNEXT(tmp_iterator_name_1)); - - tmp_iterator_attempt = (*Py_TYPE(tmp_iterator_name_1)->tp_iternext)(tmp_iterator_name_1); - - if (likely(tmp_iterator_attempt == NULL)) { - PyObject *error = GET_ERROR_OCCURRED(); - - if (error != NULL) { - if (EXCEPTION_MATCH_BOOL_SINGLE(error, PyExc_StopIteration)) { - CLEAR_ERROR_OCCURRED(); - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 876; - goto try_except_handler_3; - } - } - } else { - Py_DECREF(tmp_iterator_attempt); - - exception_type = PyExc_ValueError; - Py_INCREF(PyExc_ValueError); - exception_value = mod_consts[99]; - Py_INCREF(exception_value); - exception_tb = NULL; - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 876; - goto try_except_handler_3; - } - } - goto try_end_1; - // Exception handler code: - try_except_handler_3:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto try_except_handler_2; - // End of try: - try_end_1:; - goto try_end_2; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto frame_exception_exit_1; - // End of try: - try_end_2:; - Py_XDECREF(tmp_tuple_unpack_1__source_iter); - tmp_tuple_unpack_1__source_iter = NULL; - { - PyObject *tmp_assign_source_11; - CHECK_OBJECT(tmp_tuple_unpack_1__element_1); - tmp_assign_source_11 = tmp_tuple_unpack_1__element_1; - assert(var_batch_size == NULL); - Py_INCREF(tmp_assign_source_11); - var_batch_size = tmp_assign_source_11; - } - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - - { - PyObject *tmp_assign_source_12; - CHECK_OBJECT(tmp_tuple_unpack_1__element_2); - tmp_assign_source_12 = tmp_tuple_unpack_1__element_2; - assert(var_seq_length == NULL); - Py_INCREF(tmp_assign_source_12); - var_seq_length = tmp_assign_source_12; - } - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - - Py_XDECREF(tmp_tuple_unpack_1__element_1); - tmp_tuple_unpack_1__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_1__element_2); - tmp_tuple_unpack_1__element_2 = NULL; - { - PyObject *tmp_assign_source_13; - PyObject *tmp_expression_name_17; - if (var_embedding_output == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[225]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 877; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_17 = var_embedding_output; - tmp_assign_source_13 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[70]); - if (tmp_assign_source_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 877; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_device == NULL); - var_device = tmp_assign_source_13; - } - { - bool tmp_condition_result_8; - PyObject *tmp_compexpr_left_8; - PyObject *tmp_compexpr_right_8; - CHECK_OBJECT(par_attention_mask); - tmp_compexpr_left_8 = par_attention_mask; - tmp_compexpr_right_8 = Py_None; - tmp_condition_result_8 = (tmp_compexpr_left_8 == tmp_compexpr_right_8) ? true : false; - if (tmp_condition_result_8 != false) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_assign_source_14; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_18; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_tuple_element_2; - PyObject *tmp_kwargs_name_2; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - tmp_expression_name_18 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_18 == NULL)) { - tmp_expression_name_18 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 880; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_18, mod_consts[211]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 880; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_batch_size); - tmp_tuple_element_2 = var_batch_size; - tmp_tuple_element_1 = PyTuple_New(2); - { - PyObject *tmp_left_name_2; - PyObject *tmp_right_name_2; - PyTuple_SET_ITEM0(tmp_tuple_element_1, 0, tmp_tuple_element_2); - CHECK_OBJECT(var_seq_length); - tmp_left_name_2 = var_seq_length; - if (var_past_key_values_length == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[224]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 881; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_right_name_2 = var_past_key_values_length; - tmp_tuple_element_2 = BINARY_OPERATION_ADD_OBJECT_OBJECT_OBJECT(tmp_left_name_2, tmp_right_name_2); - if (tmp_tuple_element_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 881; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_tuple_element_1, 1, tmp_tuple_element_2); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_tuple_element_1); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_2 = mod_consts[70]; - CHECK_OBJECT(var_device); - tmp_dict_value_2 = var_device; - tmp_kwargs_name_2 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 880; - tmp_assign_source_14 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_2); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 880; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_attention_mask; - assert(old != NULL); - par_attention_mask = tmp_assign_source_14; - Py_DECREF(old); - } - - } - branch_no_3:; - { - nuitka_bool tmp_condition_result_9; - int tmp_truth_name_1; - CHECK_OBJECT(par_is_decoder); - tmp_truth_name_1 = CHECK_IF_TRUE(par_is_decoder); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 886; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_9 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_9 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - } - branch_yes_4:; - { - PyObject *tmp_assign_source_15; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_19; - PyObject *tmp_args_name_2; - PyObject *tmp_tuple_element_3; - PyObject *tmp_kwargs_name_3; - PyObject *tmp_dict_key_3; - PyObject *tmp_dict_value_3; - PyObject *tmp_compexpr_left_9; - PyObject *tmp_compexpr_right_9; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 887; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_19 = par_self; - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[226]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 887; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_attention_mask); - tmp_tuple_element_3 = par_attention_mask; - tmp_args_name_2 = PyTuple_New(4); - { - PyObject *tmp_expression_name_20; - PyTuple_SET_ITEM0(tmp_args_name_2, 0, tmp_tuple_element_3); - if (par_input_ids == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 889; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto tuple_build_exception_2; - } - - tmp_expression_name_20 = par_input_ids; - tmp_tuple_element_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[132]); - if (tmp_tuple_element_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 889; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto tuple_build_exception_2; - } - PyTuple_SET_ITEM(tmp_args_name_2, 1, tmp_tuple_element_3); - if (var_device == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[70]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 890; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto tuple_build_exception_2; - } - - tmp_tuple_element_3 = var_device; - PyTuple_SET_ITEM0(tmp_args_name_2, 2, tmp_tuple_element_3); - CHECK_OBJECT(par_is_decoder); - tmp_tuple_element_3 = par_is_decoder; - PyTuple_SET_ITEM0(tmp_args_name_2, 3, tmp_tuple_element_3); - } - goto tuple_build_noexception_2; - // Exception handling pass through code for tuple_build: - tuple_build_exception_2:; - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_2:; - tmp_dict_key_3 = mod_consts[227]; - if (par_query_embeds == NULL) { - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 892; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_compexpr_left_9 = par_query_embeds; - tmp_compexpr_right_9 = Py_None; - tmp_dict_value_3 = (tmp_compexpr_left_9 != tmp_compexpr_right_9) ? Py_True : Py_False; - tmp_kwargs_name_3 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - assert(!(tmp_res != 0)); - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 887; - tmp_assign_source_15 = CALL_FUNCTION(tmp_called_name_3, tmp_args_name_2, tmp_kwargs_name_3); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_2); - Py_DECREF(tmp_kwargs_name_3); - if (tmp_assign_source_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 887; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_extended_attention_mask == NULL); - var_extended_attention_mask = tmp_assign_source_15; - } - goto branch_end_4; - branch_no_4:; - { - PyObject *tmp_assign_source_16; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_21; - PyObject *tmp_args_element_name_1; - PyObject *tmp_args_element_name_2; - PyObject *tmp_args_element_name_3; - PyObject *tmp_args_element_name_4; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 895; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_21 = par_self; - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_21, mod_consts[226]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 895; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_attention_mask); - tmp_args_element_name_1 = par_attention_mask; - if (var_input_shape == NULL) { - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[228]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 896; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_2 = var_input_shape; - if (var_device == NULL) { - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[70]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 896; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_3 = var_device; - CHECK_OBJECT(par_is_decoder); - tmp_args_element_name_4 = par_is_decoder; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 895; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2, tmp_args_element_name_3, tmp_args_element_name_4}; - tmp_assign_source_16 = CALL_FUNCTION_WITH_ARGS4(tmp_called_name_4, call_args); - } - - Py_DECREF(tmp_called_name_4); - if (tmp_assign_source_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 895; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_extended_attention_mask == NULL); - var_extended_attention_mask = tmp_assign_source_16; - } - branch_end_4:; - { - bool tmp_condition_result_10; - PyObject *tmp_compexpr_left_10; - PyObject *tmp_compexpr_right_10; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_compexpr_left_10 = par_encoder_hidden_states; - tmp_compexpr_right_10 = Py_None; - tmp_condition_result_10 = (tmp_compexpr_left_10 != tmp_compexpr_right_10) ? true : false; - if (tmp_condition_result_10 != false) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - { - nuitka_bool tmp_condition_result_11; - PyObject *tmp_compexpr_left_11; - PyObject *tmp_compexpr_right_11; - PyObject *tmp_type_arg_1; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_type_arg_1 = par_encoder_hidden_states; - tmp_compexpr_left_11 = BUILTIN_TYPE1(tmp_type_arg_1); - assert(!(tmp_compexpr_left_11 == NULL)); - tmp_compexpr_right_11 = (PyObject *)&PyList_Type; - tmp_condition_result_11 = RICH_COMPARE_EQ_NBOOL_OBJECT_OBJECT(tmp_compexpr_left_11, tmp_compexpr_right_11); - Py_DECREF(tmp_compexpr_left_11); - assert(!(tmp_condition_result_11 == NUITKA_BOOL_EXCEPTION)); - if (tmp_condition_result_11 == NUITKA_BOOL_TRUE) { - goto branch_yes_6; - } else { - goto branch_no_6; - } - assert(tmp_condition_result_11 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_6:; - // Tried code: - { - PyObject *tmp_assign_source_17; - PyObject *tmp_iter_arg_2; - PyObject *tmp_called_instance_2; - PyObject *tmp_expression_name_22; - PyObject *tmp_subscript_name_6; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_expression_name_22 = par_encoder_hidden_states; - tmp_subscript_name_6 = mod_consts[29]; - tmp_called_instance_2 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_22, tmp_subscript_name_6, 0); - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 903; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_4; - } - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 903; - tmp_iter_arg_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[27]); - Py_DECREF(tmp_called_instance_2); - if (tmp_iter_arg_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 903; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_4; - } - tmp_assign_source_17 = MAKE_UNPACK_ITERATOR(tmp_iter_arg_2); - Py_DECREF(tmp_iter_arg_2); - if (tmp_assign_source_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 903; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_4; - } - assert(tmp_tuple_unpack_2__source_iter == NULL); - tmp_tuple_unpack_2__source_iter = tmp_assign_source_17; - } - // Tried code: - { - PyObject *tmp_assign_source_18; - PyObject *tmp_unpack_3; - CHECK_OBJECT(tmp_tuple_unpack_2__source_iter); - tmp_unpack_3 = tmp_tuple_unpack_2__source_iter; - tmp_assign_source_18 = UNPACK_NEXT(tmp_unpack_3, 0, 3); - if (tmp_assign_source_18 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 903; - goto try_except_handler_5; - } - assert(tmp_tuple_unpack_2__element_1 == NULL); - tmp_tuple_unpack_2__element_1 = tmp_assign_source_18; - } - { - PyObject *tmp_assign_source_19; - PyObject *tmp_unpack_4; - CHECK_OBJECT(tmp_tuple_unpack_2__source_iter); - tmp_unpack_4 = tmp_tuple_unpack_2__source_iter; - tmp_assign_source_19 = UNPACK_NEXT(tmp_unpack_4, 1, 3); - if (tmp_assign_source_19 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 903; - goto try_except_handler_5; - } - assert(tmp_tuple_unpack_2__element_2 == NULL); - tmp_tuple_unpack_2__element_2 = tmp_assign_source_19; - } - { - PyObject *tmp_assign_source_20; - PyObject *tmp_unpack_5; - CHECK_OBJECT(tmp_tuple_unpack_2__source_iter); - tmp_unpack_5 = tmp_tuple_unpack_2__source_iter; - tmp_assign_source_20 = UNPACK_NEXT(tmp_unpack_5, 2, 3); - if (tmp_assign_source_20 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 903; - goto try_except_handler_5; - } - assert(tmp_tuple_unpack_2__element_3 == NULL); - tmp_tuple_unpack_2__element_3 = tmp_assign_source_20; - } - { - PyObject *tmp_iterator_name_2; - CHECK_OBJECT(tmp_tuple_unpack_2__source_iter); - tmp_iterator_name_2 = tmp_tuple_unpack_2__source_iter; - // Check if iterator has left-over elements. - CHECK_OBJECT(tmp_iterator_name_2); assert(HAS_ITERNEXT(tmp_iterator_name_2)); - - tmp_iterator_attempt = (*Py_TYPE(tmp_iterator_name_2)->tp_iternext)(tmp_iterator_name_2); - - if (likely(tmp_iterator_attempt == NULL)) { - PyObject *error = GET_ERROR_OCCURRED(); - - if (error != NULL) { - if (EXCEPTION_MATCH_BOOL_SINGLE(error, PyExc_StopIteration)) { - CLEAR_ERROR_OCCURRED(); - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 903; - goto try_except_handler_5; - } - } - } else { - Py_DECREF(tmp_iterator_attempt); - - exception_type = PyExc_ValueError; - Py_INCREF(PyExc_ValueError); - exception_value = mod_consts[229]; - Py_INCREF(exception_value); - exception_tb = NULL; - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 903; - goto try_except_handler_5; - } - } - goto try_end_3; - // Exception handler code: - try_except_handler_5:; - exception_keeper_type_3 = exception_type; - exception_keeper_value_3 = exception_value; - exception_keeper_tb_3 = exception_tb; - exception_keeper_lineno_3 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_2__source_iter); - tmp_tuple_unpack_2__source_iter = NULL; - // Re-raise. - exception_type = exception_keeper_type_3; - exception_value = exception_keeper_value_3; - exception_tb = exception_keeper_tb_3; - exception_lineno = exception_keeper_lineno_3; - - goto try_except_handler_4; - // End of try: - try_end_3:; - goto try_end_4; - // Exception handler code: - try_except_handler_4:; - exception_keeper_type_4 = exception_type; - exception_keeper_value_4 = exception_value; - exception_keeper_tb_4 = exception_tb; - exception_keeper_lineno_4 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_2__element_1); - tmp_tuple_unpack_2__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_2__element_2); - tmp_tuple_unpack_2__element_2 = NULL; - Py_XDECREF(tmp_tuple_unpack_2__element_3); - tmp_tuple_unpack_2__element_3 = NULL; - // Re-raise. - exception_type = exception_keeper_type_4; - exception_value = exception_keeper_value_4; - exception_tb = exception_keeper_tb_4; - exception_lineno = exception_keeper_lineno_4; - - goto frame_exception_exit_1; - // End of try: - try_end_4:; - Py_XDECREF(tmp_tuple_unpack_2__source_iter); - tmp_tuple_unpack_2__source_iter = NULL; - { - PyObject *tmp_assign_source_21; - CHECK_OBJECT(tmp_tuple_unpack_2__element_1); - tmp_assign_source_21 = tmp_tuple_unpack_2__element_1; - assert(var_encoder_batch_size == NULL); - Py_INCREF(tmp_assign_source_21); - var_encoder_batch_size = tmp_assign_source_21; - } - Py_XDECREF(tmp_tuple_unpack_2__element_1); - tmp_tuple_unpack_2__element_1 = NULL; - - { - PyObject *tmp_assign_source_22; - CHECK_OBJECT(tmp_tuple_unpack_2__element_2); - tmp_assign_source_22 = tmp_tuple_unpack_2__element_2; - assert(var_encoder_sequence_length == NULL); - Py_INCREF(tmp_assign_source_22); - var_encoder_sequence_length = tmp_assign_source_22; - } - Py_XDECREF(tmp_tuple_unpack_2__element_2); - tmp_tuple_unpack_2__element_2 = NULL; - - { - PyObject *tmp_assign_source_23; - CHECK_OBJECT(tmp_tuple_unpack_2__element_3); - tmp_assign_source_23 = tmp_tuple_unpack_2__element_3; - assert(var__ == NULL); - Py_INCREF(tmp_assign_source_23); - var__ = tmp_assign_source_23; - } - Py_XDECREF(tmp_tuple_unpack_2__element_3); - tmp_tuple_unpack_2__element_3 = NULL; - - Py_XDECREF(tmp_tuple_unpack_2__element_1); - tmp_tuple_unpack_2__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_2__element_2); - tmp_tuple_unpack_2__element_2 = NULL; - Py_XDECREF(tmp_tuple_unpack_2__element_3); - tmp_tuple_unpack_2__element_3 = NULL; - goto branch_end_6; - branch_no_6:; - // Tried code: - { - PyObject *tmp_assign_source_24; - PyObject *tmp_iter_arg_3; - PyObject *tmp_called_instance_3; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_called_instance_3 = par_encoder_hidden_states; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 911; - tmp_iter_arg_3 = CALL_METHOD_NO_ARGS(tmp_called_instance_3, mod_consts[27]); - if (tmp_iter_arg_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 911; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_6; - } - tmp_assign_source_24 = MAKE_UNPACK_ITERATOR(tmp_iter_arg_3); - Py_DECREF(tmp_iter_arg_3); - if (tmp_assign_source_24 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 907; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_6; - } - assert(tmp_tuple_unpack_3__source_iter == NULL); - tmp_tuple_unpack_3__source_iter = tmp_assign_source_24; - } - // Tried code: - { - PyObject *tmp_assign_source_25; - PyObject *tmp_unpack_6; - CHECK_OBJECT(tmp_tuple_unpack_3__source_iter); - tmp_unpack_6 = tmp_tuple_unpack_3__source_iter; - tmp_assign_source_25 = UNPACK_NEXT(tmp_unpack_6, 0, 3); - if (tmp_assign_source_25 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 907; - goto try_except_handler_7; - } - assert(tmp_tuple_unpack_3__element_1 == NULL); - tmp_tuple_unpack_3__element_1 = tmp_assign_source_25; - } - { - PyObject *tmp_assign_source_26; - PyObject *tmp_unpack_7; - CHECK_OBJECT(tmp_tuple_unpack_3__source_iter); - tmp_unpack_7 = tmp_tuple_unpack_3__source_iter; - tmp_assign_source_26 = UNPACK_NEXT(tmp_unpack_7, 1, 3); - if (tmp_assign_source_26 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 907; - goto try_except_handler_7; - } - assert(tmp_tuple_unpack_3__element_2 == NULL); - tmp_tuple_unpack_3__element_2 = tmp_assign_source_26; - } - { - PyObject *tmp_assign_source_27; - PyObject *tmp_unpack_8; - CHECK_OBJECT(tmp_tuple_unpack_3__source_iter); - tmp_unpack_8 = tmp_tuple_unpack_3__source_iter; - tmp_assign_source_27 = UNPACK_NEXT(tmp_unpack_8, 2, 3); - if (tmp_assign_source_27 == NULL) { - if (!ERROR_OCCURRED()) { - exception_type = PyExc_StopIteration; - Py_INCREF(exception_type); - exception_value = NULL; - exception_tb = NULL; - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - } - - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 907; - goto try_except_handler_7; - } - assert(tmp_tuple_unpack_3__element_3 == NULL); - tmp_tuple_unpack_3__element_3 = tmp_assign_source_27; - } - { - PyObject *tmp_iterator_name_3; - CHECK_OBJECT(tmp_tuple_unpack_3__source_iter); - tmp_iterator_name_3 = tmp_tuple_unpack_3__source_iter; - // Check if iterator has left-over elements. - CHECK_OBJECT(tmp_iterator_name_3); assert(HAS_ITERNEXT(tmp_iterator_name_3)); - - tmp_iterator_attempt = (*Py_TYPE(tmp_iterator_name_3)->tp_iternext)(tmp_iterator_name_3); - - if (likely(tmp_iterator_attempt == NULL)) { - PyObject *error = GET_ERROR_OCCURRED(); - - if (error != NULL) { - if (EXCEPTION_MATCH_BOOL_SINGLE(error, PyExc_StopIteration)) { - CLEAR_ERROR_OCCURRED(); - } else { - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 907; - goto try_except_handler_7; - } - } - } else { - Py_DECREF(tmp_iterator_attempt); - - exception_type = PyExc_ValueError; - Py_INCREF(PyExc_ValueError); - exception_value = mod_consts[229]; - Py_INCREF(exception_value); - exception_tb = NULL; - - type_description_1 = "oooooooooooooooooooooooooooooo"; - exception_lineno = 907; - goto try_except_handler_7; - } - } - goto try_end_5; - // Exception handler code: - try_except_handler_7:; - exception_keeper_type_5 = exception_type; - exception_keeper_value_5 = exception_value; - exception_keeper_tb_5 = exception_tb; - exception_keeper_lineno_5 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_3__source_iter); - tmp_tuple_unpack_3__source_iter = NULL; - // Re-raise. - exception_type = exception_keeper_type_5; - exception_value = exception_keeper_value_5; - exception_tb = exception_keeper_tb_5; - exception_lineno = exception_keeper_lineno_5; - - goto try_except_handler_6; - // End of try: - try_end_5:; - goto try_end_6; - // Exception handler code: - try_except_handler_6:; - exception_keeper_type_6 = exception_type; - exception_keeper_value_6 = exception_value; - exception_keeper_tb_6 = exception_tb; - exception_keeper_lineno_6 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_tuple_unpack_3__element_1); - tmp_tuple_unpack_3__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_3__element_2); - tmp_tuple_unpack_3__element_2 = NULL; - Py_XDECREF(tmp_tuple_unpack_3__element_3); - tmp_tuple_unpack_3__element_3 = NULL; - // Re-raise. - exception_type = exception_keeper_type_6; - exception_value = exception_keeper_value_6; - exception_tb = exception_keeper_tb_6; - exception_lineno = exception_keeper_lineno_6; - - goto frame_exception_exit_1; - // End of try: - try_end_6:; - Py_XDECREF(tmp_tuple_unpack_3__source_iter); - tmp_tuple_unpack_3__source_iter = NULL; - { - PyObject *tmp_assign_source_28; - CHECK_OBJECT(tmp_tuple_unpack_3__element_1); - tmp_assign_source_28 = tmp_tuple_unpack_3__element_1; - assert(var_encoder_batch_size == NULL); - Py_INCREF(tmp_assign_source_28); - var_encoder_batch_size = tmp_assign_source_28; - } - Py_XDECREF(tmp_tuple_unpack_3__element_1); - tmp_tuple_unpack_3__element_1 = NULL; - - { - PyObject *tmp_assign_source_29; - CHECK_OBJECT(tmp_tuple_unpack_3__element_2); - tmp_assign_source_29 = tmp_tuple_unpack_3__element_2; - assert(var_encoder_sequence_length == NULL); - Py_INCREF(tmp_assign_source_29); - var_encoder_sequence_length = tmp_assign_source_29; - } - Py_XDECREF(tmp_tuple_unpack_3__element_2); - tmp_tuple_unpack_3__element_2 = NULL; - - { - PyObject *tmp_assign_source_30; - CHECK_OBJECT(tmp_tuple_unpack_3__element_3); - tmp_assign_source_30 = tmp_tuple_unpack_3__element_3; - assert(var__ == NULL); - Py_INCREF(tmp_assign_source_30); - var__ = tmp_assign_source_30; - } - Py_XDECREF(tmp_tuple_unpack_3__element_3); - tmp_tuple_unpack_3__element_3 = NULL; - - Py_XDECREF(tmp_tuple_unpack_3__element_1); - tmp_tuple_unpack_3__element_1 = NULL; - Py_XDECREF(tmp_tuple_unpack_3__element_2); - tmp_tuple_unpack_3__element_2 = NULL; - Py_XDECREF(tmp_tuple_unpack_3__element_3); - tmp_tuple_unpack_3__element_3 = NULL; - branch_end_6:; - { - PyObject *tmp_assign_source_31; - PyObject *tmp_tuple_element_4; - CHECK_OBJECT(var_encoder_batch_size); - tmp_tuple_element_4 = var_encoder_batch_size; - tmp_assign_source_31 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_assign_source_31, 0, tmp_tuple_element_4); - CHECK_OBJECT(var_encoder_sequence_length); - tmp_tuple_element_4 = var_encoder_sequence_length; - PyTuple_SET_ITEM0(tmp_assign_source_31, 1, tmp_tuple_element_4); - assert(var_encoder_hidden_shape == NULL); - var_encoder_hidden_shape = tmp_assign_source_31; - } - { - nuitka_bool tmp_condition_result_12; - PyObject *tmp_compexpr_left_12; - PyObject *tmp_compexpr_right_12; - PyObject *tmp_type_arg_2; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_type_arg_2 = par_encoder_attention_mask; - tmp_compexpr_left_12 = BUILTIN_TYPE1(tmp_type_arg_2); - assert(!(tmp_compexpr_left_12 == NULL)); - tmp_compexpr_right_12 = (PyObject *)&PyList_Type; - tmp_condition_result_12 = RICH_COMPARE_EQ_NBOOL_OBJECT_OBJECT(tmp_compexpr_left_12, tmp_compexpr_right_12); - Py_DECREF(tmp_compexpr_left_12); - assert(!(tmp_condition_result_12 == NUITKA_BOOL_EXCEPTION)); - if (tmp_condition_result_12 == NUITKA_BOOL_TRUE) { - goto branch_yes_7; - } else { - goto branch_no_7; - } - assert(tmp_condition_result_12 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_7:; - { - PyObject *tmp_assign_source_32; - // Tried code: - { - PyObject *tmp_assign_source_33; - PyObject *tmp_iter_arg_4; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_iter_arg_4 = par_encoder_attention_mask; - tmp_assign_source_33 = MAKE_ITERATOR(tmp_iter_arg_4); - if (tmp_assign_source_33 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 915; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_8; - } - assert(tmp_listcomp_1__$0 == NULL); - tmp_listcomp_1__$0 = tmp_assign_source_33; - } - { - PyObject *tmp_assign_source_34; - tmp_assign_source_34 = PyList_New(0); - assert(tmp_listcomp_1__contraction == NULL); - tmp_listcomp_1__contraction = tmp_assign_source_34; - } - if (isFrameUnusable(cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2)) { - Py_XDECREF(cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2); - -#if _DEBUG_REFCOUNTS - if (cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2 = MAKE_FUNCTION_FRAME(codeobj_3b8e99b3705bb48cdf88a9a082001f87, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2->m_type_description == NULL); - frame_3b8e99b3705bb48cdf88a9a082001f87_2 = cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2; - - // Push the new frame as the currently active one. - pushFrameStack(frame_3b8e99b3705bb48cdf88a9a082001f87_2); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_3b8e99b3705bb48cdf88a9a082001f87_2) == 2); // Frame stack - - // Framed code: - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_35; - CHECK_OBJECT(tmp_listcomp_1__$0); - tmp_next_source_1 = tmp_listcomp_1__$0; - tmp_assign_source_35 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_35 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - type_description_2 = "oo"; - exception_lineno = 915; - goto try_except_handler_9; - } - } - - { - PyObject *old = tmp_listcomp_1__iter_value_0; - tmp_listcomp_1__iter_value_0 = tmp_assign_source_35; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_36; - CHECK_OBJECT(tmp_listcomp_1__iter_value_0); - tmp_assign_source_36 = tmp_listcomp_1__iter_value_0; - { - PyObject *old = outline_0_var_mask; - outline_0_var_mask = tmp_assign_source_36; - Py_INCREF(outline_0_var_mask); - Py_XDECREF(old); - } - - } - { - PyObject *tmp_append_list_1; - PyObject *tmp_append_value_1; - PyObject *tmp_called_instance_4; - PyObject *tmp_args_element_name_5; - CHECK_OBJECT(tmp_listcomp_1__contraction); - tmp_append_list_1 = tmp_listcomp_1__contraction; - if (par_self == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 916; - type_description_2 = "oo"; - goto try_except_handler_9; - } - - tmp_called_instance_4 = par_self; - CHECK_OBJECT(outline_0_var_mask); - tmp_args_element_name_5 = outline_0_var_mask; - frame_3b8e99b3705bb48cdf88a9a082001f87_2->m_frame.f_lineno = 916; - tmp_append_value_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_4, mod_consts[230], tmp_args_element_name_5); - if (tmp_append_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 916; - type_description_2 = "oo"; - goto try_except_handler_9; - } - assert(PyList_Check(tmp_append_list_1)); - tmp_result = LIST_APPEND1(tmp_append_list_1, tmp_append_value_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 915; - type_description_2 = "oo"; - goto try_except_handler_9; - } - } - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 915; - type_description_2 = "oo"; - goto try_except_handler_9; - } - goto loop_start_1; - loop_end_1:; - CHECK_OBJECT(tmp_listcomp_1__contraction); - tmp_assign_source_32 = tmp_listcomp_1__contraction; - Py_INCREF(tmp_assign_source_32); - goto try_return_handler_9; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_9:; - Py_XDECREF(tmp_listcomp_1__$0); - tmp_listcomp_1__$0 = NULL; - CHECK_OBJECT(tmp_listcomp_1__contraction); - Py_DECREF(tmp_listcomp_1__contraction); - tmp_listcomp_1__contraction = NULL; - Py_XDECREF(tmp_listcomp_1__iter_value_0); - tmp_listcomp_1__iter_value_0 = NULL; - goto frame_return_exit_2; - // Exception handler code: - try_except_handler_9:; - exception_keeper_type_7 = exception_type; - exception_keeper_value_7 = exception_value; - exception_keeper_tb_7 = exception_tb; - exception_keeper_lineno_7 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_listcomp_1__$0); - tmp_listcomp_1__$0 = NULL; - CHECK_OBJECT(tmp_listcomp_1__contraction); - Py_DECREF(tmp_listcomp_1__contraction); - tmp_listcomp_1__contraction = NULL; - Py_XDECREF(tmp_listcomp_1__iter_value_0); - tmp_listcomp_1__iter_value_0 = NULL; - // Re-raise. - exception_type = exception_keeper_type_7; - exception_value = exception_keeper_value_7; - exception_tb = exception_keeper_tb_7; - exception_lineno = exception_keeper_lineno_7; - - goto frame_exception_exit_2; - // End of try: - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3b8e99b3705bb48cdf88a9a082001f87_2); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_2:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3b8e99b3705bb48cdf88a9a082001f87_2); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_8; - - frame_exception_exit_2:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3b8e99b3705bb48cdf88a9a082001f87_2); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_3b8e99b3705bb48cdf88a9a082001f87_2, exception_lineno); - } else if (exception_tb->tb_frame != &frame_3b8e99b3705bb48cdf88a9a082001f87_2->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_3b8e99b3705bb48cdf88a9a082001f87_2, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_3b8e99b3705bb48cdf88a9a082001f87_2, - type_description_2, - outline_0_var_mask, - par_self - ); - - - // Release cached frame if used for exception. - if (frame_3b8e99b3705bb48cdf88a9a082001f87_2 == cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2); - cache_frame_3b8e99b3705bb48cdf88a9a082001f87_2 = NULL; - } - - assertFrameObject(frame_3b8e99b3705bb48cdf88a9a082001f87_2); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_1; - - frame_no_exception_1:; - goto skip_nested_handling_1; - nested_frame_exit_1:; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto try_except_handler_8; - skip_nested_handling_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_8:; - Py_XDECREF(outline_0_var_mask); - outline_0_var_mask = NULL; - goto outline_result_1; - // Exception handler code: - try_except_handler_8:; - exception_keeper_type_8 = exception_type; - exception_keeper_value_8 = exception_value; - exception_keeper_tb_8 = exception_tb; - exception_keeper_lineno_8 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(outline_0_var_mask); - outline_0_var_mask = NULL; - // Re-raise. - exception_type = exception_keeper_type_8; - exception_value = exception_keeper_value_8; - exception_tb = exception_keeper_tb_8; - exception_lineno = exception_keeper_lineno_8; - - goto outline_exception_1; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_1:; - exception_lineno = 915; - goto frame_exception_exit_1; - outline_result_1:; - assert(var_encoder_extended_attention_mask == NULL); - var_encoder_extended_attention_mask = tmp_assign_source_32; - } - goto branch_end_7; - branch_no_7:; - { - bool tmp_condition_result_13; - PyObject *tmp_compexpr_left_13; - PyObject *tmp_compexpr_right_13; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_compexpr_left_13 = par_encoder_attention_mask; - tmp_compexpr_right_13 = Py_None; - tmp_condition_result_13 = (tmp_compexpr_left_13 == tmp_compexpr_right_13) ? true : false; - if (tmp_condition_result_13 != false) { - goto branch_yes_8; - } else { - goto branch_no_8; - } - } - branch_yes_8:; - { - PyObject *tmp_assign_source_37; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_23; - PyObject *tmp_args_name_3; - PyObject *tmp_tuple_element_5; - PyObject *tmp_kwargs_name_4; - PyObject *tmp_dict_key_4; - PyObject *tmp_dict_value_4; - tmp_expression_name_23 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_23 == NULL)) { - tmp_expression_name_23 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 919; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[211]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 919; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_encoder_hidden_shape); - tmp_tuple_element_5 = var_encoder_hidden_shape; - tmp_args_name_3 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_3, 0, tmp_tuple_element_5); - tmp_dict_key_4 = mod_consts[70]; - if (var_device == NULL) { - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_name_3); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[70]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 919; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_4 = var_device; - tmp_kwargs_name_4 = _PyDict_NewPresized( 1 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_4, tmp_dict_key_4, tmp_dict_value_4); - assert(!(tmp_res != 0)); - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 919; - tmp_assign_source_37 = CALL_FUNCTION(tmp_called_name_5, tmp_args_name_3, tmp_kwargs_name_4); - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_name_3); - Py_DECREF(tmp_kwargs_name_4); - if (tmp_assign_source_37 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 919; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_encoder_attention_mask; - assert(old != NULL); - par_encoder_attention_mask = tmp_assign_source_37; - Py_DECREF(old); - } - - } - { - PyObject *tmp_assign_source_38; - PyObject *tmp_called_instance_5; - PyObject *tmp_args_element_name_6; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 920; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_5 = par_self; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_args_element_name_6 = par_encoder_attention_mask; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 920; - tmp_assign_source_38 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_5, mod_consts[230], tmp_args_element_name_6); - if (tmp_assign_source_38 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 920; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_encoder_extended_attention_mask == NULL); - var_encoder_extended_attention_mask = tmp_assign_source_38; - } - goto branch_end_8; - branch_no_8:; - { - PyObject *tmp_assign_source_39; - PyObject *tmp_called_instance_6; - PyObject *tmp_args_element_name_7; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 924; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_6 = par_self; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_args_element_name_7 = par_encoder_attention_mask; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 924; - tmp_assign_source_39 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_6, mod_consts[230], tmp_args_element_name_7); - if (tmp_assign_source_39 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 924; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_encoder_extended_attention_mask == NULL); - var_encoder_extended_attention_mask = tmp_assign_source_39; - } - branch_end_8:; - branch_end_7:; - goto branch_end_5; - branch_no_5:; - { - PyObject *tmp_assign_source_40; - tmp_assign_source_40 = Py_None; - assert(var_encoder_extended_attention_mask == NULL); - Py_INCREF(tmp_assign_source_40); - var_encoder_extended_attention_mask = tmp_assign_source_40; - } - branch_end_5:; - { - PyObject *tmp_assign_source_41; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_24; - PyObject *tmp_args_element_name_8; - PyObject *tmp_args_element_name_9; - PyObject *tmp_expression_name_25; - PyObject *tmp_expression_name_26; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 935; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_24 = par_self; - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_24, mod_consts[231]); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 935; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_head_mask); - tmp_args_element_name_8 = par_head_mask; - if (par_self == NULL) { - Py_DECREF(tmp_called_name_6); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 935; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_26 = par_self; - tmp_expression_name_25 = LOOKUP_ATTRIBUTE(tmp_expression_name_26, mod_consts[5]); - if (tmp_expression_name_25 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 935; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_25, mod_consts[138]); - Py_DECREF(tmp_expression_name_25); - if (tmp_args_element_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_6); - - exception_lineno = 935; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 935; - { - PyObject *call_args[] = {tmp_args_element_name_8, tmp_args_element_name_9}; - tmp_assign_source_41 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_6, call_args); - } - - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_args_element_name_9); - if (tmp_assign_source_41 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 935; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_head_mask; - par_head_mask = tmp_assign_source_41; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_42; - PyObject *tmp_called_name_7; - PyObject *tmp_expression_name_27; - PyObject *tmp_args_name_4; - PyObject *tmp_tuple_element_6; - PyObject *tmp_kwargs_name_5; - PyObject *tmp_dict_key_5; - PyObject *tmp_dict_value_5; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 937; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_27 = par_self; - tmp_called_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_27, mod_consts[195]); - if (tmp_called_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 937; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (var_embedding_output == NULL) { - Py_DECREF(tmp_called_name_7); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[225]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 938; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_6 = var_embedding_output; - tmp_args_name_4 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_4, 0, tmp_tuple_element_6); - tmp_dict_key_5 = mod_consts[128]; - CHECK_OBJECT(var_extended_attention_mask); - tmp_dict_value_5 = var_extended_attention_mask; - tmp_kwargs_name_5 = _PyDict_NewPresized( 10 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[129]; - CHECK_OBJECT(par_head_mask); - tmp_dict_value_5 = par_head_mask; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[60]; - if (par_encoder_hidden_states == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[60]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 941; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_2; - } - - tmp_dict_value_5 = par_encoder_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[155]; - if (var_encoder_extended_attention_mask == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[232]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 942; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_2; - } - - tmp_dict_value_5 = var_encoder_extended_attention_mask; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[144]; - CHECK_OBJECT(par_past_key_values); - tmp_dict_value_5 = par_past_key_values; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[147]; - CHECK_OBJECT(par_use_cache); - tmp_dict_value_5 = par_use_cache; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[123]; - CHECK_OBJECT(par_output_attentions); - tmp_dict_value_5 = par_output_attentions; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[142]; - CHECK_OBJECT(par_output_hidden_states); - tmp_dict_value_5 = par_output_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[233]; - CHECK_OBJECT(par_return_dict); - tmp_dict_value_5 = par_return_dict; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - tmp_dict_key_5 = mod_consts[156]; - CHECK_OBJECT(var_query_length); - tmp_dict_value_5 = var_query_length; - tmp_res = PyDict_SetItem(tmp_kwargs_name_5, tmp_dict_key_5, tmp_dict_value_5); - assert(!(tmp_res != 0)); - goto dict_build_noexception_2; - // Exception handling pass through code for dict_build: - dict_build_exception_2:; - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_name_4); - Py_DECREF(tmp_kwargs_name_5); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_2:; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 937; - tmp_assign_source_42 = CALL_FUNCTION(tmp_called_name_7, tmp_args_name_4, tmp_kwargs_name_5); - Py_DECREF(tmp_called_name_7); - Py_DECREF(tmp_args_name_4); - Py_DECREF(tmp_kwargs_name_5); - if (tmp_assign_source_42 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 937; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_encoder_outputs == NULL); - var_encoder_outputs = tmp_assign_source_42; - } - { - PyObject *tmp_assign_source_43; - PyObject *tmp_expression_name_28; - PyObject *tmp_subscript_name_7; - CHECK_OBJECT(var_encoder_outputs); - tmp_expression_name_28 = var_encoder_outputs; - tmp_subscript_name_7 = mod_consts[29]; - tmp_assign_source_43 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_28, tmp_subscript_name_7, 0); - if (tmp_assign_source_43 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 950; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_sequence_output == NULL); - var_sequence_output = tmp_assign_source_43; - } - { - PyObject *tmp_assign_source_44; - bool tmp_condition_result_14; - PyObject *tmp_compexpr_left_14; - PyObject *tmp_compexpr_right_14; - PyObject *tmp_expression_name_29; - PyObject *tmp_called_instance_7; - PyObject *tmp_args_element_name_10; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 952; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_29 = par_self; - tmp_compexpr_left_14 = LOOKUP_ATTRIBUTE(tmp_expression_name_29, mod_consts[197]); - if (tmp_compexpr_left_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 952; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_compexpr_right_14 = Py_None; - tmp_condition_result_14 = (tmp_compexpr_left_14 != tmp_compexpr_right_14) ? true : false; - Py_DECREF(tmp_compexpr_left_14); - if (tmp_condition_result_14 != false) { - goto condexpr_true_6; - } else { - goto condexpr_false_6; - } - condexpr_true_6:; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 952; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_7 = par_self; - CHECK_OBJECT(var_sequence_output); - tmp_args_element_name_10 = var_sequence_output; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 952; - tmp_assign_source_44 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_7, mod_consts[197], tmp_args_element_name_10); - if (tmp_assign_source_44 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 952; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto condexpr_end_6; - condexpr_false_6:; - tmp_assign_source_44 = Py_None; - Py_INCREF(tmp_assign_source_44); - condexpr_end_6:; - assert(var_pooled_output == NULL); - var_pooled_output = tmp_assign_source_44; - } - { - nuitka_bool tmp_condition_result_15; - PyObject *tmp_operand_name_1; - if (par_return_dict == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[233]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 955; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_operand_name_1 = par_return_dict; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 955; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_15 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_15 == NUITKA_BOOL_TRUE) { - goto branch_yes_9; - } else { - goto branch_no_9; - } - } - branch_yes_9:; - { - PyObject *tmp_left_name_3; - PyObject *tmp_tuple_element_7; - PyObject *tmp_right_name_3; - PyObject *tmp_expression_name_30; - PyObject *tmp_subscript_name_8; - if (var_sequence_output == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[234]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 956; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_7 = var_sequence_output; - tmp_left_name_3 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_left_name_3, 0, tmp_tuple_element_7); - CHECK_OBJECT(var_pooled_output); - tmp_tuple_element_7 = var_pooled_output; - PyTuple_SET_ITEM0(tmp_left_name_3, 1, tmp_tuple_element_7); - CHECK_OBJECT(var_encoder_outputs); - tmp_expression_name_30 = var_encoder_outputs; - tmp_subscript_name_8 = mod_consts[102]; - tmp_right_name_3 = LOOKUP_SUBSCRIPT(tmp_expression_name_30, tmp_subscript_name_8); - if (tmp_right_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_3); - - exception_lineno = 956; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_return_value = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_3, tmp_right_name_3); - Py_DECREF(tmp_left_name_3); - Py_DECREF(tmp_right_name_3); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 956; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - branch_no_9:; - { - PyObject *tmp_called_name_8; - PyObject *tmp_kwargs_name_6; - PyObject *tmp_dict_key_6; - PyObject *tmp_dict_value_6; - tmp_called_name_8 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[235]); - - if (unlikely(tmp_called_name_8 == NULL)) { - tmp_called_name_8 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[235]); - } - - if (tmp_called_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 958; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_6 = mod_consts[161]; - if (var_sequence_output == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[234]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 959; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_6 = var_sequence_output; - tmp_kwargs_name_6 = _PyDict_NewPresized( 6 ); - { - PyObject *tmp_expression_name_31; - PyObject *tmp_expression_name_32; - PyObject *tmp_expression_name_33; - PyObject *tmp_expression_name_34; - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_6, tmp_dict_value_6); - assert(!(tmp_res != 0)); - tmp_dict_key_6 = mod_consts[236]; - CHECK_OBJECT(var_pooled_output); - tmp_dict_value_6 = var_pooled_output; - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_6, tmp_dict_value_6); - assert(!(tmp_res != 0)); - tmp_dict_key_6 = mod_consts[144]; - CHECK_OBJECT(var_encoder_outputs); - tmp_expression_name_31 = var_encoder_outputs; - tmp_dict_value_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_31, mod_consts[144]); - if (tmp_dict_value_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 961; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_6, tmp_dict_value_6); - Py_DECREF(tmp_dict_value_6); - assert(!(tmp_res != 0)); - tmp_dict_key_6 = mod_consts[61]; - if (var_encoder_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[237]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 962; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - - tmp_expression_name_32 = var_encoder_outputs; - tmp_dict_value_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_32, mod_consts[61]); - if (tmp_dict_value_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 962; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_6, tmp_dict_value_6); - Py_DECREF(tmp_dict_value_6); - assert(!(tmp_res != 0)); - tmp_dict_key_6 = mod_consts[162]; - if (var_encoder_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[237]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 963; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - - tmp_expression_name_33 = var_encoder_outputs; - tmp_dict_value_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_33, mod_consts[162]); - if (tmp_dict_value_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 963; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_6, tmp_dict_value_6); - Py_DECREF(tmp_dict_value_6); - assert(!(tmp_res != 0)); - tmp_dict_key_6 = mod_consts[163]; - if (var_encoder_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[237]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 964; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - - tmp_expression_name_34 = var_encoder_outputs; - tmp_dict_value_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_34, mod_consts[163]); - if (tmp_dict_value_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 964; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto dict_build_exception_3; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_6, tmp_dict_key_6, tmp_dict_value_6); - Py_DECREF(tmp_dict_value_6); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_3; - // Exception handling pass through code for dict_build: - dict_build_exception_3:; - Py_DECREF(tmp_kwargs_name_6); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_3:; - frame_960ad736510918980c376a071f656626->m_frame.f_lineno = 958; - tmp_return_value = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_8, tmp_kwargs_name_6); - Py_DECREF(tmp_kwargs_name_6); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 958; - type_description_1 = "oooooooooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_960ad736510918980c376a071f656626); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_2; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_960ad736510918980c376a071f656626); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_960ad736510918980c376a071f656626); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_960ad736510918980c376a071f656626, exception_lineno); - } else if (exception_tb->tb_frame != &frame_960ad736510918980c376a071f656626->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_960ad736510918980c376a071f656626, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_960ad736510918980c376a071f656626, - type_description_1, - par_self, - par_input_ids, - par_attention_mask, - par_position_ids, - par_head_mask, - par_query_embeds, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_past_key_values, - par_use_cache, - par_output_attentions, - par_output_hidden_states, - par_return_dict, - par_is_decoder, - var_past_key_values_length, - var_query_length, - var_embedding_output, - var_input_shape, - var_batch_size, - var_seq_length, - var_device, - var_extended_attention_mask, - var_encoder_batch_size, - var_encoder_sequence_length, - var__, - var_encoder_hidden_shape, - var_encoder_extended_attention_mask, - var_encoder_outputs, - var_sequence_output, - var_pooled_output - ); - - - // Release cached frame if used for exception. - if (frame_960ad736510918980c376a071f656626 == cache_frame_960ad736510918980c376a071f656626) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_960ad736510918980c376a071f656626); - cache_frame_960ad736510918980c376a071f656626 = NULL; - } - - assertFrameObject(frame_960ad736510918980c376a071f656626); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_2:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_past_key_values); - par_past_key_values = NULL; - Py_XDECREF(par_use_cache); - par_use_cache = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - Py_XDECREF(par_return_dict); - par_return_dict = NULL; - Py_XDECREF(par_is_decoder); - par_is_decoder = NULL; - Py_XDECREF(var_past_key_values_length); - var_past_key_values_length = NULL; - Py_XDECREF(var_query_length); - var_query_length = NULL; - Py_XDECREF(var_embedding_output); - var_embedding_output = NULL; - Py_XDECREF(var_input_shape); - var_input_shape = NULL; - Py_XDECREF(var_batch_size); - var_batch_size = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_device); - var_device = NULL; - Py_XDECREF(var_extended_attention_mask); - var_extended_attention_mask = NULL; - Py_XDECREF(var_encoder_batch_size); - var_encoder_batch_size = NULL; - Py_XDECREF(var_encoder_sequence_length); - var_encoder_sequence_length = NULL; - Py_XDECREF(var__); - var__ = NULL; - Py_XDECREF(var_encoder_hidden_shape); - var_encoder_hidden_shape = NULL; - Py_XDECREF(var_encoder_extended_attention_mask); - var_encoder_extended_attention_mask = NULL; - Py_XDECREF(var_encoder_outputs); - var_encoder_outputs = NULL; - Py_XDECREF(var_sequence_output); - var_sequence_output = NULL; - CHECK_OBJECT(var_pooled_output); - Py_DECREF(var_pooled_output); - var_pooled_output = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_9 = exception_type; - exception_keeper_value_9 = exception_value; - exception_keeper_tb_9 = exception_tb; - exception_keeper_lineno_9 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_past_key_values); - par_past_key_values = NULL; - Py_XDECREF(par_use_cache); - par_use_cache = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - Py_XDECREF(par_return_dict); - par_return_dict = NULL; - Py_XDECREF(par_is_decoder); - par_is_decoder = NULL; - Py_XDECREF(var_past_key_values_length); - var_past_key_values_length = NULL; - Py_XDECREF(var_query_length); - var_query_length = NULL; - Py_XDECREF(var_embedding_output); - var_embedding_output = NULL; - Py_XDECREF(var_input_shape); - var_input_shape = NULL; - Py_XDECREF(var_batch_size); - var_batch_size = NULL; - Py_XDECREF(var_seq_length); - var_seq_length = NULL; - Py_XDECREF(var_device); - var_device = NULL; - Py_XDECREF(var_extended_attention_mask); - var_extended_attention_mask = NULL; - Py_XDECREF(var_encoder_batch_size); - var_encoder_batch_size = NULL; - Py_XDECREF(var_encoder_sequence_length); - var_encoder_sequence_length = NULL; - Py_XDECREF(var__); - var__ = NULL; - Py_XDECREF(var_encoder_hidden_shape); - var_encoder_hidden_shape = NULL; - Py_XDECREF(var_encoder_extended_attention_mask); - var_encoder_extended_attention_mask = NULL; - Py_XDECREF(var_encoder_outputs); - var_encoder_outputs = NULL; - Py_XDECREF(var_sequence_output); - var_sequence_output = NULL; - Py_XDECREF(var_pooled_output); - var_pooled_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_9; - exception_value = exception_keeper_value_9; - exception_tb = exception_keeper_tb_9; - exception_lineno = exception_keeper_lineno_9; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__40___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_3fed784111b2af0b6a6ffc26ac50d650; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_3fed784111b2af0b6a6ffc26ac50d650 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_3fed784111b2af0b6a6ffc26ac50d650)) { - Py_XDECREF(cache_frame_3fed784111b2af0b6a6ffc26ac50d650); - -#if _DEBUG_REFCOUNTS - if (cache_frame_3fed784111b2af0b6a6ffc26ac50d650 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_3fed784111b2af0b6a6ffc26ac50d650 = MAKE_FUNCTION_FRAME(codeobj_3fed784111b2af0b6a6ffc26ac50d650, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_3fed784111b2af0b6a6ffc26ac50d650->m_type_description == NULL); - frame_3fed784111b2af0b6a6ffc26ac50d650 = cache_frame_3fed784111b2af0b6a6ffc26ac50d650; - - // Push the new frame as the currently active one. - pushFrameStack(frame_3fed784111b2af0b6a6ffc26ac50d650); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_3fed784111b2af0b6a6ffc26ac50d650) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - PyObject *tmp_args_element_name_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 974; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 974; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_1 = par_config; - frame_3fed784111b2af0b6a6ffc26ac50d650->m_frame.f_lineno = 974; - tmp_call_result_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[1], tmp_args_element_name_1); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 974; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_assattr_target_1; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[239]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[239]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 976; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 976; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_1 = par_config; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[240]); - frame_3fed784111b2af0b6a6ffc26ac50d650->m_frame.f_lineno = 976; - tmp_assattr_name_1 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 976; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[241], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 976; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_assattr_target_2; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[242]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[242]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 977; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 977; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_2 = par_config; - frame_3fed784111b2af0b6a6ffc26ac50d650->m_frame.f_lineno = 977; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_2); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 977; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[243], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 977; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_called_instance_2; - PyObject *tmp_call_result_2; - CHECK_OBJECT(par_self); - tmp_called_instance_2 = par_self; - frame_3fed784111b2af0b6a6ffc26ac50d650->m_frame.f_lineno = 979; - tmp_call_result_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[198]); - if (tmp_call_result_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 979; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_2); - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3fed784111b2af0b6a6ffc26ac50d650); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_3fed784111b2af0b6a6ffc26ac50d650); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_3fed784111b2af0b6a6ffc26ac50d650, exception_lineno); - } else if (exception_tb->tb_frame != &frame_3fed784111b2af0b6a6ffc26ac50d650->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_3fed784111b2af0b6a6ffc26ac50d650, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_3fed784111b2af0b6a6ffc26ac50d650, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_3fed784111b2af0b6a6ffc26ac50d650 == cache_frame_3fed784111b2af0b6a6ffc26ac50d650) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_3fed784111b2af0b6a6ffc26ac50d650); - cache_frame_3fed784111b2af0b6a6ffc26ac50d650 = NULL; - } - - assertFrameObject(frame_3fed784111b2af0b6a6ffc26ac50d650); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__41_get_output_embeddings(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - struct Nuitka_FrameObject *frame_d801348fdc3b19f91ac75fd50193d3b0; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_d801348fdc3b19f91ac75fd50193d3b0 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_d801348fdc3b19f91ac75fd50193d3b0)) { - Py_XDECREF(cache_frame_d801348fdc3b19f91ac75fd50193d3b0); - -#if _DEBUG_REFCOUNTS - if (cache_frame_d801348fdc3b19f91ac75fd50193d3b0 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_d801348fdc3b19f91ac75fd50193d3b0 = MAKE_FUNCTION_FRAME(codeobj_d801348fdc3b19f91ac75fd50193d3b0, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_d801348fdc3b19f91ac75fd50193d3b0->m_type_description == NULL); - frame_d801348fdc3b19f91ac75fd50193d3b0 = cache_frame_d801348fdc3b19f91ac75fd50193d3b0; - - // Push the new frame as the currently active one. - pushFrameStack(frame_d801348fdc3b19f91ac75fd50193d3b0); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_d801348fdc3b19f91ac75fd50193d3b0) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_expression_name_3; - CHECK_OBJECT(par_self); - tmp_expression_name_3 = par_self; - tmp_expression_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[243]); - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 982; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[181]); - Py_DECREF(tmp_expression_name_2); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 982; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - tmp_return_value = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[176]); - Py_DECREF(tmp_expression_name_1); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 982; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d801348fdc3b19f91ac75fd50193d3b0); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d801348fdc3b19f91ac75fd50193d3b0); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d801348fdc3b19f91ac75fd50193d3b0); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_d801348fdc3b19f91ac75fd50193d3b0, exception_lineno); - } else if (exception_tb->tb_frame != &frame_d801348fdc3b19f91ac75fd50193d3b0->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_d801348fdc3b19f91ac75fd50193d3b0, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_d801348fdc3b19f91ac75fd50193d3b0, - type_description_1, - par_self - ); - - - // Release cached frame if used for exception. - if (frame_d801348fdc3b19f91ac75fd50193d3b0 == cache_frame_d801348fdc3b19f91ac75fd50193d3b0) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_d801348fdc3b19f91ac75fd50193d3b0); - cache_frame_d801348fdc3b19f91ac75fd50193d3b0 = NULL; - } - - assertFrameObject(frame_d801348fdc3b19f91ac75fd50193d3b0); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__42_set_output_embeddings(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_new_embeddings = python_pars[1]; - struct Nuitka_FrameObject *frame_74af6475e06de1d3e4323696e9d6b171; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_74af6475e06de1d3e4323696e9d6b171 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_74af6475e06de1d3e4323696e9d6b171)) { - Py_XDECREF(cache_frame_74af6475e06de1d3e4323696e9d6b171); - -#if _DEBUG_REFCOUNTS - if (cache_frame_74af6475e06de1d3e4323696e9d6b171 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_74af6475e06de1d3e4323696e9d6b171 = MAKE_FUNCTION_FRAME(codeobj_74af6475e06de1d3e4323696e9d6b171, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_74af6475e06de1d3e4323696e9d6b171->m_type_description == NULL); - frame_74af6475e06de1d3e4323696e9d6b171 = cache_frame_74af6475e06de1d3e4323696e9d6b171; - - // Push the new frame as the currently active one. - pushFrameStack(frame_74af6475e06de1d3e4323696e9d6b171); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_74af6475e06de1d3e4323696e9d6b171) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_new_embeddings); - tmp_assattr_name_1 = par_new_embeddings; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[243]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 985; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_assattr_target_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[181]); - Py_DECREF(tmp_expression_name_1); - if (tmp_assattr_target_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 985; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[176], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_target_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 985; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_74af6475e06de1d3e4323696e9d6b171); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_74af6475e06de1d3e4323696e9d6b171); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_74af6475e06de1d3e4323696e9d6b171, exception_lineno); - } else if (exception_tb->tb_frame != &frame_74af6475e06de1d3e4323696e9d6b171->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_74af6475e06de1d3e4323696e9d6b171, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_74af6475e06de1d3e4323696e9d6b171, - type_description_1, - par_self, - par_new_embeddings - ); - - - // Release cached frame if used for exception. - if (frame_74af6475e06de1d3e4323696e9d6b171 == cache_frame_74af6475e06de1d3e4323696e9d6b171) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_74af6475e06de1d3e4323696e9d6b171); - cache_frame_74af6475e06de1d3e4323696e9d6b171 = NULL; - } - - assertFrameObject(frame_74af6475e06de1d3e4323696e9d6b171); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_new_embeddings); - Py_DECREF(par_new_embeddings); - par_new_embeddings = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_new_embeddings); - Py_DECREF(par_new_embeddings); - par_new_embeddings = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__43_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_input_ids = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_position_ids = python_pars[3]; - PyObject *par_head_mask = python_pars[4]; - PyObject *par_query_embeds = python_pars[5]; - PyObject *par_encoder_hidden_states = python_pars[6]; - PyObject *par_encoder_attention_mask = python_pars[7]; - PyObject *par_labels = python_pars[8]; - PyObject *par_past_key_values = python_pars[9]; - PyObject *par_use_cache = python_pars[10]; - PyObject *par_output_attentions = python_pars[11]; - PyObject *par_output_hidden_states = python_pars[12]; - PyObject *par_return_dict = python_pars[13]; - PyObject *par_return_logits = python_pars[14]; - PyObject *par_is_decoder = python_pars[15]; - PyObject *par_reduction = python_pars[16]; - PyObject *var_outputs = NULL; - PyObject *var_sequence_output = NULL; - PyObject *var_prediction_scores = NULL; - PyObject *var_lm_loss = NULL; - PyObject *var_shifted_prediction_scores = NULL; - PyObject *var_loss_fct = NULL; - PyObject *var_output = NULL; - struct Nuitka_FrameObject *frame_7c295c83a4e918fa0e86389ee3693174; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - PyObject *tmp_return_value = NULL; - static struct Nuitka_FrameObject *cache_frame_7c295c83a4e918fa0e86389ee3693174 = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_7c295c83a4e918fa0e86389ee3693174)) { - Py_XDECREF(cache_frame_7c295c83a4e918fa0e86389ee3693174); - -#if _DEBUG_REFCOUNTS - if (cache_frame_7c295c83a4e918fa0e86389ee3693174 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_7c295c83a4e918fa0e86389ee3693174 = MAKE_FUNCTION_FRAME(codeobj_7c295c83a4e918fa0e86389ee3693174, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_7c295c83a4e918fa0e86389ee3693174->m_type_description == NULL); - frame_7c295c83a4e918fa0e86389ee3693174 = cache_frame_7c295c83a4e918fa0e86389ee3693174; - - // Push the new frame as the currently active one. - pushFrameStack(frame_7c295c83a4e918fa0e86389ee3693174); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_7c295c83a4e918fa0e86389ee3693174) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_return_dict); - tmp_compexpr_left_1 = par_return_dict; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - CHECK_OBJECT(par_return_dict); - tmp_assign_source_1 = par_return_dict; - Py_INCREF(tmp_assign_source_1); - goto condexpr_end_1; - condexpr_false_1:; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[5]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1039; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[221]); - Py_DECREF(tmp_expression_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1039; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - condexpr_end_1:; - { - PyObject *old = par_return_dict; - assert(old != NULL); - par_return_dict = tmp_assign_source_1; - Py_DECREF(old); - } - - } - { - bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - CHECK_OBJECT(par_labels); - tmp_compexpr_left_2 = par_labels; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_2 = (tmp_compexpr_left_2 != tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_2 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_2; - tmp_assign_source_2 = Py_False; - { - PyObject *old = par_use_cache; - assert(old != NULL); - par_use_cache = tmp_assign_source_2; - Py_INCREF(par_use_cache); - Py_DECREF(old); - } - - } - branch_no_1:; - { - bool tmp_condition_result_3; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - CHECK_OBJECT(par_past_key_values); - tmp_compexpr_left_3 = par_past_key_values; - tmp_compexpr_right_3 = Py_None; - tmp_condition_result_3 = (tmp_compexpr_left_3 != tmp_compexpr_right_3) ? true : false; - if (tmp_condition_result_3 != false) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_assign_source_3; - tmp_assign_source_3 = Py_None; - { - PyObject *old = par_query_embeds; - assert(old != NULL); - par_query_embeds = tmp_assign_source_3; - Py_INCREF(par_query_embeds); - Py_DECREF(old); - } - - } - branch_no_2:; - { - PyObject *tmp_assign_source_4; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1046; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[241]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1046; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_input_ids); - tmp_tuple_element_1 = par_input_ids; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[128]; - CHECK_OBJECT(par_attention_mask); - tmp_dict_value_1 = par_attention_mask; - tmp_kwargs_name_1 = _PyDict_NewPresized( 12 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[19]; - CHECK_OBJECT(par_position_ids); - tmp_dict_value_1 = par_position_ids; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[129]; - CHECK_OBJECT(par_head_mask); - tmp_dict_value_1 = par_head_mask; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[223]; - CHECK_OBJECT(par_query_embeds); - tmp_dict_value_1 = par_query_embeds; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[60]; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_dict_value_1 = par_encoder_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[155]; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_dict_value_1 = par_encoder_attention_mask; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[144]; - CHECK_OBJECT(par_past_key_values); - tmp_dict_value_1 = par_past_key_values; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[147]; - CHECK_OBJECT(par_use_cache); - tmp_dict_value_1 = par_use_cache; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[123]; - CHECK_OBJECT(par_output_attentions); - tmp_dict_value_1 = par_output_attentions; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[142]; - CHECK_OBJECT(par_output_hidden_states); - tmp_dict_value_1 = par_output_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[233]; - CHECK_OBJECT(par_return_dict); - tmp_dict_value_1 = par_return_dict; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[244]; - CHECK_OBJECT(par_is_decoder); - tmp_dict_value_1 = par_is_decoder; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1046; - tmp_assign_source_4 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1046; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_outputs == NULL); - var_outputs = tmp_assign_source_4; - } - { - PyObject *tmp_assign_source_5; - PyObject *tmp_expression_name_4; - PyObject *tmp_subscript_name_1; - CHECK_OBJECT(var_outputs); - tmp_expression_name_4 = var_outputs; - tmp_subscript_name_1 = mod_consts[29]; - tmp_assign_source_5 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_4, tmp_subscript_name_1, 0); - if (tmp_assign_source_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1062; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_sequence_output == NULL); - var_sequence_output = tmp_assign_source_5; - } - { - bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - if (par_query_embeds == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1063; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_compexpr_left_4 = par_query_embeds; - tmp_compexpr_right_4 = Py_None; - tmp_condition_result_4 = (tmp_compexpr_left_4 != tmp_compexpr_right_4) ? true : false; - if (tmp_condition_result_4 != false) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_assign_source_6; - PyObject *tmp_expression_name_5; - PyObject *tmp_expression_name_6; - PyObject *tmp_subscript_name_2; - PyObject *tmp_subscript_name_3; - PyObject *tmp_tuple_element_2; - CHECK_OBJECT(var_outputs); - tmp_expression_name_6 = var_outputs; - tmp_subscript_name_2 = mod_consts[29]; - tmp_expression_name_5 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_6, tmp_subscript_name_2, 0); - if (tmp_expression_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1064; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_2 = mod_consts[30]; - tmp_subscript_name_3 = PyTuple_New(3); - { - PyObject *tmp_start_name_1; - PyObject *tmp_expression_name_7; - PyObject *tmp_expression_name_8; - PyObject *tmp_subscript_name_4; - PyObject *tmp_stop_name_1; - PyTuple_SET_ITEM0(tmp_subscript_name_3, 0, tmp_tuple_element_2); - if (par_query_embeds == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1064; - type_description_1 = "oooooooooooooooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_expression_name_8 = par_query_embeds; - tmp_expression_name_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[132]); - if (tmp_expression_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1064; - type_description_1 = "oooooooooooooooooooooooo"; - goto tuple_build_exception_1; - } - tmp_subscript_name_4 = mod_consts[28]; - tmp_start_name_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_7, tmp_subscript_name_4, 1); - Py_DECREF(tmp_expression_name_7); - if (tmp_start_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1064; - type_description_1 = "oooooooooooooooooooooooo"; - goto tuple_build_exception_1; - } - tmp_stop_name_1 = Py_None; - tmp_tuple_element_2 = MAKE_SLICEOBJ2(tmp_start_name_1, tmp_stop_name_1); - Py_DECREF(tmp_start_name_1); - assert(!(tmp_tuple_element_2 == NULL)); - PyTuple_SET_ITEM(tmp_subscript_name_3, 1, tmp_tuple_element_2); - tmp_tuple_element_2 = mod_consts[30]; - PyTuple_SET_ITEM0(tmp_subscript_name_3, 2, tmp_tuple_element_2); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_expression_name_5); - Py_DECREF(tmp_subscript_name_3); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_assign_source_6 = LOOKUP_SUBSCRIPT(tmp_expression_name_5, tmp_subscript_name_3); - Py_DECREF(tmp_expression_name_5); - Py_DECREF(tmp_subscript_name_3); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1064; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_sequence_output; - assert(old != NULL); - var_sequence_output = tmp_assign_source_6; - Py_DECREF(old); - } - - } - branch_no_3:; - { - PyObject *tmp_assign_source_7; - PyObject *tmp_called_instance_1; - PyObject *tmp_args_element_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1066; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_called_instance_1 = par_self; - CHECK_OBJECT(var_sequence_output); - tmp_args_element_name_1 = var_sequence_output; - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1066; - tmp_assign_source_7 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[243], tmp_args_element_name_1); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1066; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_prediction_scores == NULL); - var_prediction_scores = tmp_assign_source_7; - } - { - nuitka_bool tmp_condition_result_5; - int tmp_truth_name_1; - CHECK_OBJECT(par_return_logits); - tmp_truth_name_1 = CHECK_IF_TRUE(par_return_logits); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1068; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_5 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - } - branch_yes_4:; - { - PyObject *tmp_called_instance_2; - PyObject *tmp_expression_name_9; - PyObject *tmp_subscript_name_5; - CHECK_OBJECT(var_prediction_scores); - tmp_expression_name_9 = var_prediction_scores; - tmp_subscript_name_5 = mod_consts[245]; - tmp_called_instance_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_9, tmp_subscript_name_5); - if (tmp_called_instance_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1069; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1069; - tmp_return_value = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[89]); - Py_DECREF(tmp_called_instance_2); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1069; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - branch_no_4:; - { - PyObject *tmp_assign_source_8; - tmp_assign_source_8 = Py_None; - assert(var_lm_loss == NULL); - Py_INCREF(tmp_assign_source_8); - var_lm_loss = tmp_assign_source_8; - } - { - bool tmp_condition_result_6; - PyObject *tmp_compexpr_left_5; - PyObject *tmp_compexpr_right_5; - CHECK_OBJECT(par_labels); - tmp_compexpr_left_5 = par_labels; - tmp_compexpr_right_5 = Py_None; - tmp_condition_result_6 = (tmp_compexpr_left_5 != tmp_compexpr_right_5) ? true : false; - if (tmp_condition_result_6 != false) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - { - PyObject *tmp_assign_source_9; - PyObject *tmp_called_instance_3; - PyObject *tmp_expression_name_10; - PyObject *tmp_subscript_name_6; - CHECK_OBJECT(var_prediction_scores); - tmp_expression_name_10 = var_prediction_scores; - tmp_subscript_name_6 = mod_consts[245]; - tmp_called_instance_3 = LOOKUP_SUBSCRIPT(tmp_expression_name_10, tmp_subscript_name_6); - if (tmp_called_instance_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1074; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1074; - tmp_assign_source_9 = CALL_METHOD_NO_ARGS(tmp_called_instance_3, mod_consts[89]); - Py_DECREF(tmp_called_instance_3); - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1074; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_shifted_prediction_scores == NULL); - var_shifted_prediction_scores = tmp_assign_source_9; - } - { - PyObject *tmp_assign_source_10; - PyObject *tmp_called_instance_4; - PyObject *tmp_expression_name_11; - PyObject *tmp_subscript_name_7; - CHECK_OBJECT(par_labels); - tmp_expression_name_11 = par_labels; - tmp_subscript_name_7 = mod_consts[246]; - tmp_called_instance_4 = LOOKUP_SUBSCRIPT(tmp_expression_name_11, tmp_subscript_name_7); - if (tmp_called_instance_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1075; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1075; - tmp_assign_source_10 = CALL_METHOD_NO_ARGS(tmp_called_instance_4, mod_consts[89]); - Py_DECREF(tmp_called_instance_4); - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1075; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_labels; - assert(old != NULL); - par_labels = tmp_assign_source_10; - Py_DECREF(old); - } - - } - { - PyObject *tmp_assign_source_11; - PyObject *tmp_called_name_2; - PyObject *tmp_kwargs_name_2; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[247]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[247]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1076; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_2 = mod_consts[248]; - CHECK_OBJECT(par_reduction); - tmp_dict_value_2 = par_reduction; - tmp_kwargs_name_2 = _PyDict_NewPresized( 2 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - tmp_dict_key_2 = mod_consts[249]; - tmp_dict_value_2 = mod_consts[250]; - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1076; - tmp_assign_source_11 = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_2, tmp_kwargs_name_2); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_assign_source_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1076; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_loss_fct == NULL); - var_loss_fct = tmp_assign_source_11; - } - { - PyObject *tmp_assign_source_12; - PyObject *tmp_called_name_3; - PyObject *tmp_args_element_name_2; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_12; - PyObject *tmp_args_element_name_3; - PyObject *tmp_args_element_name_4; - PyObject *tmp_expression_name_13; - PyObject *tmp_expression_name_14; - PyObject *tmp_args_element_name_5; - PyObject *tmp_called_instance_5; - CHECK_OBJECT(var_loss_fct); - tmp_called_name_3 = var_loss_fct; - CHECK_OBJECT(var_shifted_prediction_scores); - tmp_expression_name_12 = var_shifted_prediction_scores; - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_12, mod_consts[56]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1078; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_3 = mod_consts[126]; - if (par_self == NULL) { - Py_DECREF(tmp_called_name_4); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1078; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_14 = par_self; - tmp_expression_name_13 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[5]); - if (tmp_expression_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 1078; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[4]); - Py_DECREF(tmp_expression_name_13); - if (tmp_args_element_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_4); - - exception_lineno = 1078; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1078; - { - PyObject *call_args[] = {tmp_args_element_name_3, tmp_args_element_name_4}; - tmp_args_element_name_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_4, call_args); - } - - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_element_name_4); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1078; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_labels); - tmp_called_instance_5 = par_labels; - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1079; - tmp_args_element_name_5 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_5, - mod_consts[56], - &PyTuple_GET_ITEM(mod_consts[251], 0) - ); - - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_2); - - exception_lineno = 1079; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1077; - { - PyObject *call_args[] = {tmp_args_element_name_2, tmp_args_element_name_5}; - tmp_assign_source_12 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_3, call_args); - } - - Py_DECREF(tmp_args_element_name_2); - Py_DECREF(tmp_args_element_name_5); - if (tmp_assign_source_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1077; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_lm_loss; - assert(old != NULL); - var_lm_loss = tmp_assign_source_12; - Py_DECREF(old); - } - - } - { - nuitka_bool tmp_condition_result_7; - PyObject *tmp_compexpr_left_6; - PyObject *tmp_compexpr_right_6; - PyObject *tmp_tmp_condition_result_7_object_1; - int tmp_truth_name_2; - CHECK_OBJECT(par_reduction); - tmp_compexpr_left_6 = par_reduction; - tmp_compexpr_right_6 = mod_consts[252]; - tmp_tmp_condition_result_7_object_1 = RICH_COMPARE_EQ_OBJECT_OBJECT_OBJECT(tmp_compexpr_left_6, tmp_compexpr_right_6); - if (tmp_tmp_condition_result_7_object_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1081; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_truth_name_2 = CHECK_IF_TRUE(tmp_tmp_condition_result_7_object_1); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_tmp_condition_result_7_object_1); - - exception_lineno = 1081; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_7 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - Py_DECREF(tmp_tmp_condition_result_7_object_1); - if (tmp_condition_result_7 == NUITKA_BOOL_TRUE) { - goto branch_yes_6; - } else { - goto branch_no_6; - } - } - branch_yes_6:; - { - PyObject *tmp_assign_source_13; - PyObject *tmp_called_instance_6; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_15; - PyObject *tmp_args_element_name_6; - PyObject *tmp_called_instance_7; - PyObject *tmp_args_element_name_7; - CHECK_OBJECT(var_lm_loss); - tmp_expression_name_15 = var_lm_loss; - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_15, mod_consts[56]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1082; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_prediction_scores); - tmp_called_instance_7 = var_prediction_scores; - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1082; - tmp_args_element_name_6 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_7, - mod_consts[27], - &PyTuple_GET_ITEM(mod_consts[253], 0) - ); - - if (tmp_args_element_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 1082; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_7 = mod_consts[126]; - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1082; - { - PyObject *call_args[] = {tmp_args_element_name_6, tmp_args_element_name_7}; - tmp_called_instance_6 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_5, call_args); - } - - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_6); - if (tmp_called_instance_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1082; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1082; - tmp_assign_source_13 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_6, - mod_consts[254], - &PyTuple_GET_ITEM(mod_consts[255], 0) - ); - - Py_DECREF(tmp_called_instance_6); - if (tmp_assign_source_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1082; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_lm_loss; - var_lm_loss = tmp_assign_source_13; - Py_XDECREF(old); - } - - } - branch_no_6:; - branch_no_5:; - { - nuitka_bool tmp_condition_result_8; - PyObject *tmp_operand_name_1; - if (par_return_dict == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[233]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1084; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_operand_name_1 = par_return_dict; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1084; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_8 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_8 == NUITKA_BOOL_TRUE) { - goto branch_yes_7; - } else { - goto branch_no_7; - } - } - branch_yes_7:; - { - PyObject *tmp_assign_source_14; - PyObject *tmp_left_name_1; - PyObject *tmp_tuple_element_3; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_16; - PyObject *tmp_subscript_name_8; - if (var_prediction_scores == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[256]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1085; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_3 = var_prediction_scores; - tmp_left_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_left_name_1, 0, tmp_tuple_element_3); - CHECK_OBJECT(var_outputs); - tmp_expression_name_16 = var_outputs; - tmp_subscript_name_8 = mod_consts[257]; - tmp_right_name_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_16, tmp_subscript_name_8); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 1085; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_14 = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1085; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_output == NULL); - var_output = tmp_assign_source_14; - } - { - bool tmp_condition_result_9; - PyObject *tmp_compexpr_left_7; - PyObject *tmp_compexpr_right_7; - PyObject *tmp_left_name_2; - PyObject *tmp_tuple_element_4; - PyObject *tmp_right_name_2; - if (var_lm_loss == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[258]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1086; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_compexpr_left_7 = var_lm_loss; - tmp_compexpr_right_7 = Py_None; - tmp_condition_result_9 = (tmp_compexpr_left_7 != tmp_compexpr_right_7) ? true : false; - if (tmp_condition_result_9 != false) { - goto condexpr_true_2; - } else { - goto condexpr_false_2; - } - condexpr_true_2:; - if (var_lm_loss == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[258]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1086; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_4 = var_lm_loss; - tmp_left_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_left_name_2, 0, tmp_tuple_element_4); - CHECK_OBJECT(var_output); - tmp_right_name_2 = var_output; - tmp_return_value = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_left_name_2); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1086; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto condexpr_end_2; - condexpr_false_2:; - CHECK_OBJECT(var_output); - tmp_return_value = var_output; - Py_INCREF(tmp_return_value); - condexpr_end_2:; - goto frame_return_exit_1; - } - branch_no_7:; - { - PyObject *tmp_called_name_6; - PyObject *tmp_kwargs_name_3; - PyObject *tmp_dict_key_3; - PyObject *tmp_dict_value_3; - tmp_called_name_6 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[259]); - - if (unlikely(tmp_called_name_6 == NULL)) { - tmp_called_name_6 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[259]); - } - - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1088; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_3 = mod_consts[260]; - if (var_lm_loss == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[258]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1089; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_3 = var_lm_loss; - tmp_kwargs_name_3 = _PyDict_NewPresized( 6 ); - { - PyObject *tmp_expression_name_17; - PyObject *tmp_expression_name_18; - PyObject *tmp_expression_name_19; - PyObject *tmp_expression_name_20; - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - assert(!(tmp_res != 0)); - tmp_dict_key_3 = mod_consts[261]; - if (var_prediction_scores == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[256]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1090; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_dict_value_3 = var_prediction_scores; - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - assert(!(tmp_res != 0)); - tmp_dict_key_3 = mod_consts[144]; - CHECK_OBJECT(var_outputs); - tmp_expression_name_17 = var_outputs; - tmp_dict_value_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[144]); - if (tmp_dict_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1091; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - Py_DECREF(tmp_dict_value_3); - assert(!(tmp_res != 0)); - tmp_dict_key_3 = mod_consts[61]; - if (var_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[136]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1092; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_expression_name_18 = var_outputs; - tmp_dict_value_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_18, mod_consts[61]); - if (tmp_dict_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1092; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - Py_DECREF(tmp_dict_value_3); - assert(!(tmp_res != 0)); - tmp_dict_key_3 = mod_consts[162]; - if (var_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[136]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1093; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_expression_name_19 = var_outputs; - tmp_dict_value_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[162]); - if (tmp_dict_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1093; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - Py_DECREF(tmp_dict_value_3); - assert(!(tmp_res != 0)); - tmp_dict_key_3 = mod_consts[163]; - if (var_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[136]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1094; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_expression_name_20 = var_outputs; - tmp_dict_value_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[163]); - if (tmp_dict_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1094; - type_description_1 = "oooooooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_3, tmp_dict_key_3, tmp_dict_value_3); - Py_DECREF(tmp_dict_value_3); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_kwargs_name_3); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_7c295c83a4e918fa0e86389ee3693174->m_frame.f_lineno = 1088; - tmp_return_value = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_6, tmp_kwargs_name_3); - Py_DECREF(tmp_kwargs_name_3); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1088; - type_description_1 = "oooooooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7c295c83a4e918fa0e86389ee3693174); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7c295c83a4e918fa0e86389ee3693174); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7c295c83a4e918fa0e86389ee3693174); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_7c295c83a4e918fa0e86389ee3693174, exception_lineno); - } else if (exception_tb->tb_frame != &frame_7c295c83a4e918fa0e86389ee3693174->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_7c295c83a4e918fa0e86389ee3693174, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_7c295c83a4e918fa0e86389ee3693174, - type_description_1, - par_self, - par_input_ids, - par_attention_mask, - par_position_ids, - par_head_mask, - par_query_embeds, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_labels, - par_past_key_values, - par_use_cache, - par_output_attentions, - par_output_hidden_states, - par_return_dict, - par_return_logits, - par_is_decoder, - par_reduction, - var_outputs, - var_sequence_output, - var_prediction_scores, - var_lm_loss, - var_shifted_prediction_scores, - var_loss_fct, - var_output - ); - - - // Release cached frame if used for exception. - if (frame_7c295c83a4e918fa0e86389ee3693174 == cache_frame_7c295c83a4e918fa0e86389ee3693174) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_7c295c83a4e918fa0e86389ee3693174); - cache_frame_7c295c83a4e918fa0e86389ee3693174 = NULL; - } - - assertFrameObject(frame_7c295c83a4e918fa0e86389ee3693174); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_labels); - par_labels = NULL; - Py_XDECREF(par_past_key_values); - par_past_key_values = NULL; - Py_XDECREF(par_use_cache); - par_use_cache = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - Py_XDECREF(par_return_dict); - par_return_dict = NULL; - CHECK_OBJECT(par_return_logits); - Py_DECREF(par_return_logits); - par_return_logits = NULL; - Py_XDECREF(par_is_decoder); - par_is_decoder = NULL; - CHECK_OBJECT(par_reduction); - Py_DECREF(par_reduction); - par_reduction = NULL; - Py_XDECREF(var_outputs); - var_outputs = NULL; - Py_XDECREF(var_sequence_output); - var_sequence_output = NULL; - Py_XDECREF(var_prediction_scores); - var_prediction_scores = NULL; - Py_XDECREF(var_lm_loss); - var_lm_loss = NULL; - Py_XDECREF(var_shifted_prediction_scores); - var_shifted_prediction_scores = NULL; - Py_XDECREF(var_loss_fct); - var_loss_fct = NULL; - Py_XDECREF(var_output); - var_output = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_labels); - par_labels = NULL; - Py_XDECREF(par_past_key_values); - par_past_key_values = NULL; - Py_XDECREF(par_use_cache); - par_use_cache = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - Py_XDECREF(par_return_dict); - par_return_dict = NULL; - CHECK_OBJECT(par_return_logits); - Py_DECREF(par_return_logits); - par_return_logits = NULL; - Py_XDECREF(par_is_decoder); - par_is_decoder = NULL; - CHECK_OBJECT(par_reduction); - Py_DECREF(par_reduction); - par_reduction = NULL; - Py_XDECREF(var_outputs); - var_outputs = NULL; - Py_XDECREF(var_sequence_output); - var_sequence_output = NULL; - Py_XDECREF(var_prediction_scores); - var_prediction_scores = NULL; - Py_XDECREF(var_lm_loss); - var_lm_loss = NULL; - Py_XDECREF(var_shifted_prediction_scores); - var_shifted_prediction_scores = NULL; - Py_XDECREF(var_loss_fct); - var_loss_fct = NULL; - Py_XDECREF(var_output); - var_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__44_prepare_inputs_for_generation(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_input_ids = python_pars[1]; - PyObject *par_query_embeds = python_pars[2]; - PyObject *par_past = python_pars[3]; - PyObject *par_attention_mask = python_pars[4]; - PyObject *par_model_kwargs = python_pars[5]; - PyObject *var_query_mask = NULL; - struct Nuitka_FrameObject *frame_ded4b18b08a0de899e2560321c2271bc; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - PyObject *tmp_return_value = NULL; - int tmp_res; - static struct Nuitka_FrameObject *cache_frame_ded4b18b08a0de899e2560321c2271bc = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_ded4b18b08a0de899e2560321c2271bc)) { - Py_XDECREF(cache_frame_ded4b18b08a0de899e2560321c2271bc); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ded4b18b08a0de899e2560321c2271bc == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ded4b18b08a0de899e2560321c2271bc = MAKE_FUNCTION_FRAME(codeobj_ded4b18b08a0de899e2560321c2271bc, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ded4b18b08a0de899e2560321c2271bc->m_type_description == NULL); - frame_ded4b18b08a0de899e2560321c2271bc = cache_frame_ded4b18b08a0de899e2560321c2271bc; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ded4b18b08a0de899e2560321c2271bc); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ded4b18b08a0de899e2560321c2271bc) == 2); // Frame stack - - // Framed code: - { - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - CHECK_OBJECT(par_attention_mask); - tmp_compexpr_left_1 = par_attention_mask; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 == tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_input_ids); - tmp_expression_name_1 = par_input_ids; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[263]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1102; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - if (par_input_ids == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1102; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_2 = par_input_ids; - tmp_args_element_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[132]); - if (tmp_args_element_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_1); - - exception_lineno = 1102; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - frame_ded4b18b08a0de899e2560321c2271bc->m_frame.f_lineno = 1102; - tmp_assign_source_1 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_element_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1102; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_attention_mask; - assert(old != NULL); - par_attention_mask = tmp_assign_source_1; - Py_DECREF(old); - } - - } - branch_no_1:; - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_3; - PyObject *tmp_args_element_name_2; - PyObject *tmp_expression_name_4; - PyObject *tmp_expression_name_5; - PyObject *tmp_subscript_name_1; - if (par_input_ids == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1103; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_input_ids; - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[263]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1103; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_query_embeds); - tmp_expression_name_5 = par_query_embeds; - tmp_expression_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[132]); - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 1103; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - tmp_subscript_name_1 = mod_consts[54]; - tmp_args_element_name_2 = LOOKUP_SUBSCRIPT(tmp_expression_name_4, tmp_subscript_name_1); - Py_DECREF(tmp_expression_name_4); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_2); - - exception_lineno = 1103; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - frame_ded4b18b08a0de899e2560321c2271bc->m_frame.f_lineno = 1103; - tmp_assign_source_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_2); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_element_name_2); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1103; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - assert(var_query_mask == NULL); - var_query_mask = tmp_assign_source_2; - } - { - PyObject *tmp_assign_source_3; - PyObject *tmp_called_name_3; - PyObject *tmp_expression_name_6; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_list_element_1; - PyObject *tmp_kwargs_name_1; - tmp_expression_name_6 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20]); - - if (unlikely(tmp_expression_name_6 == NULL)) { - tmp_expression_name_6 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[20]); - } - - if (tmp_expression_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1104; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - tmp_called_name_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_6, mod_consts[33]); - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1104; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(var_query_mask); - tmp_list_element_1 = var_query_mask; - tmp_tuple_element_1 = PyList_New(2); - PyList_SET_ITEM0(tmp_tuple_element_1, 0, tmp_list_element_1); - CHECK_OBJECT(par_attention_mask); - tmp_list_element_1 = par_attention_mask; - PyList_SET_ITEM0(tmp_tuple_element_1, 1, tmp_list_element_1); - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[84]); - frame_ded4b18b08a0de899e2560321c2271bc->m_frame.f_lineno = 1104; - tmp_assign_source_3 = CALL_FUNCTION(tmp_called_name_3, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_3); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1104; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_attention_mask; - par_attention_mask = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - { - bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - CHECK_OBJECT(par_past); - tmp_compexpr_left_2 = par_past; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_2 = (tmp_compexpr_left_2 != tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_2 != false) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_assign_source_4; - PyObject *tmp_expression_name_7; - PyObject *tmp_subscript_name_2; - if (par_input_ids == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1108; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_7 = par_input_ids; - tmp_subscript_name_2 = mod_consts[264]; - tmp_assign_source_4 = LOOKUP_SUBSCRIPT(tmp_expression_name_7, tmp_subscript_name_2); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1108; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = par_input_ids; - par_input_ids = tmp_assign_source_4; - Py_XDECREF(old); - } - - } - branch_no_2:; - { - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - tmp_dict_key_1 = mod_consts[32]; - if (par_input_ids == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[32]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1111; - type_description_1 = "ooooooo"; - goto frame_exception_exit_1; - } - - tmp_dict_value_1 = par_input_ids; - tmp_return_value = _PyDict_NewPresized( 7 ); - { - PyObject *tmp_called_instance_1; - PyObject *tmp_called_instance_2; - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[223]; - if (par_query_embeds == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1112; - type_description_1 = "ooooooo"; - goto dict_build_exception_1; - } - - tmp_dict_value_1 = par_query_embeds; - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[128]; - CHECK_OBJECT(par_attention_mask); - tmp_dict_value_1 = par_attention_mask; - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[144]; - CHECK_OBJECT(par_past); - tmp_dict_value_1 = par_past; - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[60]; - CHECK_OBJECT(par_model_kwargs); - tmp_called_instance_1 = par_model_kwargs; - frame_ded4b18b08a0de899e2560321c2271bc->m_frame.f_lineno = 1115; - tmp_dict_value_1 = CALL_METHOD_WITH_ARGS2( - tmp_called_instance_1, - mod_consts[265], - &PyTuple_GET_ITEM(mod_consts[266], 0) - ); - - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1115; - type_description_1 = "ooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[155]; - if (par_model_kwargs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[267]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1116; - type_description_1 = "ooooooo"; - goto dict_build_exception_1; - } - - tmp_called_instance_2 = par_model_kwargs; - frame_ded4b18b08a0de899e2560321c2271bc->m_frame.f_lineno = 1116; - tmp_dict_value_1 = CALL_METHOD_WITH_ARGS2( - tmp_called_instance_2, - mod_consts[265], - &PyTuple_GET_ITEM(mod_consts[268], 0) - ); - - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1116; - type_description_1 = "ooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[244]; - tmp_dict_value_1 = Py_True; - tmp_res = PyDict_SetItem(tmp_return_value, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_return_value); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ded4b18b08a0de899e2560321c2271bc); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ded4b18b08a0de899e2560321c2271bc); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ded4b18b08a0de899e2560321c2271bc); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ded4b18b08a0de899e2560321c2271bc, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ded4b18b08a0de899e2560321c2271bc->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ded4b18b08a0de899e2560321c2271bc, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ded4b18b08a0de899e2560321c2271bc, - type_description_1, - par_self, - par_input_ids, - par_query_embeds, - par_past, - par_attention_mask, - par_model_kwargs, - var_query_mask - ); - - - // Release cached frame if used for exception. - if (frame_ded4b18b08a0de899e2560321c2271bc == cache_frame_ded4b18b08a0de899e2560321c2271bc) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ded4b18b08a0de899e2560321c2271bc); - cache_frame_ded4b18b08a0de899e2560321c2271bc = NULL; - } - - assertFrameObject(frame_ded4b18b08a0de899e2560321c2271bc); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - CHECK_OBJECT(par_past); - Py_DECREF(par_past); - par_past = NULL; - CHECK_OBJECT(par_attention_mask); - Py_DECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_model_kwargs); - par_model_kwargs = NULL; - Py_XDECREF(var_query_mask); - var_query_mask = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - CHECK_OBJECT(par_past); - Py_DECREF(par_past); - par_past = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_model_kwargs); - par_model_kwargs = NULL; - Py_XDECREF(var_query_mask); - var_query_mask = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__45__reorder_cache(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_past = python_pars[1]; - struct Nuitka_CellObject *par_beam_idx = Nuitka_Cell_New1(python_pars[2]); - PyObject *var_reordered_past = NULL; - PyObject *var_layer_past = NULL; - PyObject *tmp_for_loop_1__for_iterator = NULL; - PyObject *tmp_for_loop_1__iter_value = NULL; - PyObject *tmp_genexpr_1__$0 = NULL; - struct Nuitka_FrameObject *frame_be03d43782ce0c74a753536e9a4f0743; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - PyObject *tmp_return_value = NULL; - static struct Nuitka_FrameObject *cache_frame_be03d43782ce0c74a753536e9a4f0743 = NULL; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - - // Actual function body. - { - PyObject *tmp_assign_source_1; - tmp_assign_source_1 = mod_consts[141]; - assert(var_reordered_past == NULL); - Py_INCREF(tmp_assign_source_1); - var_reordered_past = tmp_assign_source_1; - } - // Tried code: - if (isFrameUnusable(cache_frame_be03d43782ce0c74a753536e9a4f0743)) { - Py_XDECREF(cache_frame_be03d43782ce0c74a753536e9a4f0743); - -#if _DEBUG_REFCOUNTS - if (cache_frame_be03d43782ce0c74a753536e9a4f0743 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_be03d43782ce0c74a753536e9a4f0743 = MAKE_FUNCTION_FRAME(codeobj_be03d43782ce0c74a753536e9a4f0743, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_be03d43782ce0c74a753536e9a4f0743->m_type_description == NULL); - frame_be03d43782ce0c74a753536e9a4f0743 = cache_frame_be03d43782ce0c74a753536e9a4f0743; - - // Push the new frame as the currently active one. - pushFrameStack(frame_be03d43782ce0c74a753536e9a4f0743); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_be03d43782ce0c74a753536e9a4f0743) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_2; - PyObject *tmp_iter_arg_1; - CHECK_OBJECT(par_past); - tmp_iter_arg_1 = par_past; - tmp_assign_source_2 = MAKE_ITERATOR(tmp_iter_arg_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1122; - type_description_1 = "oocoo"; - goto frame_exception_exit_1; - } - assert(tmp_for_loop_1__for_iterator == NULL); - tmp_for_loop_1__for_iterator = tmp_assign_source_2; - } - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_3; - CHECK_OBJECT(tmp_for_loop_1__for_iterator); - tmp_next_source_1 = tmp_for_loop_1__for_iterator; - tmp_assign_source_3 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_3 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - type_description_1 = "oocoo"; - exception_lineno = 1122; - goto try_except_handler_2; - } - } - - { - PyObject *old = tmp_for_loop_1__iter_value; - tmp_for_loop_1__iter_value = tmp_assign_source_3; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_4; - CHECK_OBJECT(tmp_for_loop_1__iter_value); - tmp_assign_source_4 = tmp_for_loop_1__iter_value; - { - PyObject *old = var_layer_past; - var_layer_past = tmp_assign_source_4; - Py_INCREF(var_layer_past); - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_5; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_tuple_arg_1; - if (var_reordered_past == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[269]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1123; - type_description_1 = "oocoo"; - goto try_except_handler_2; - } - - tmp_left_name_1 = var_reordered_past; - { - PyObject *tmp_assign_source_6; - PyObject *tmp_iter_arg_2; - CHECK_OBJECT(var_layer_past); - tmp_iter_arg_2 = var_layer_past; - tmp_assign_source_6 = MAKE_ITERATOR(tmp_iter_arg_2); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1124; - type_description_1 = "oocoo"; - goto try_except_handler_2; - } - { - PyObject *old = tmp_genexpr_1__$0; - tmp_genexpr_1__$0 = tmp_assign_source_6; - Py_XDECREF(old); - } - - } - // Tried code: - { - struct Nuitka_CellObject *tmp_closure_1[2]; - - tmp_closure_1[0] = par_beam_idx; - Py_INCREF(tmp_closure_1[0]); - tmp_closure_1[1] = Nuitka_Cell_New0(tmp_genexpr_1__$0); - - tmp_tuple_arg_1 = MAKE_GENERATOR_models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr(tmp_closure_1); - - goto try_return_handler_3; - } - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_3:; - CHECK_OBJECT(tmp_genexpr_1__$0); - Py_DECREF(tmp_genexpr_1__$0); - tmp_genexpr_1__$0 = NULL; - goto outline_result_1; - // End of try: - CHECK_OBJECT(tmp_genexpr_1__$0); - Py_DECREF(tmp_genexpr_1__$0); - tmp_genexpr_1__$0 = NULL; - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_result_1:; - tmp_tuple_element_1 = PySequence_Tuple(tmp_tuple_arg_1); - Py_DECREF(tmp_tuple_arg_1); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1124; - type_description_1 = "oocoo"; - goto try_except_handler_2; - } - tmp_right_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_right_name_1, 0, tmp_tuple_element_1); - tmp_result = BINARY_OPERATION_ADD_TUPLE_TUPLE_INPLACE(&tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_right_name_1); - assert(!(tmp_result == false)); - tmp_assign_source_5 = tmp_left_name_1; - var_reordered_past = tmp_assign_source_5; - - } - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1122; - type_description_1 = "oocoo"; - goto try_except_handler_2; - } - goto loop_start_1; - loop_end_1:; - goto try_end_1; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_for_loop_1__iter_value); - tmp_for_loop_1__iter_value = NULL; - Py_XDECREF(tmp_for_loop_1__for_iterator); - tmp_for_loop_1__for_iterator = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto frame_exception_exit_1; - // End of try: - try_end_1:; - Py_XDECREF(tmp_for_loop_1__iter_value); - tmp_for_loop_1__iter_value = NULL; - Py_XDECREF(tmp_for_loop_1__for_iterator); - tmp_for_loop_1__for_iterator = NULL; - if (var_reordered_past == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[269]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1128; - type_description_1 = "oocoo"; - goto frame_exception_exit_1; - } - - tmp_return_value = var_reordered_past; - Py_INCREF(tmp_return_value); - goto frame_return_exit_1; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_be03d43782ce0c74a753536e9a4f0743); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_be03d43782ce0c74a753536e9a4f0743); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_be03d43782ce0c74a753536e9a4f0743); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_be03d43782ce0c74a753536e9a4f0743, exception_lineno); - } else if (exception_tb->tb_frame != &frame_be03d43782ce0c74a753536e9a4f0743->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_be03d43782ce0c74a753536e9a4f0743, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_be03d43782ce0c74a753536e9a4f0743, - type_description_1, - par_self, - par_past, - par_beam_idx, - var_reordered_past, - var_layer_past - ); - - - // Release cached frame if used for exception. - if (frame_be03d43782ce0c74a753536e9a4f0743 == cache_frame_be03d43782ce0c74a753536e9a4f0743) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_be03d43782ce0c74a753536e9a4f0743); - cache_frame_be03d43782ce0c74a753536e9a4f0743 = NULL; - } - - assertFrameObject(frame_be03d43782ce0c74a753536e9a4f0743); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_past); - par_past = NULL; - CHECK_OBJECT(par_beam_idx); - Py_DECREF(par_beam_idx); - par_beam_idx = NULL; - Py_XDECREF(var_reordered_past); - var_reordered_past = NULL; - Py_XDECREF(var_layer_past); - var_layer_past = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(par_self); - Py_DECREF(par_self); - par_self = NULL; - Py_XDECREF(par_past); - par_past = NULL; - CHECK_OBJECT(par_beam_idx); - Py_DECREF(par_beam_idx); - par_beam_idx = NULL; - Py_XDECREF(var_reordered_past); - var_reordered_past = NULL; - Py_XDECREF(var_layer_past); - var_layer_past = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - - -struct models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr_locals { - PyObject *var_past_state; - PyObject *tmp_iter_value_0; - char const *type_description_1; - PyObject *exception_type; - PyObject *exception_value; - PyTracebackObject *exception_tb; - int exception_lineno; - char yield_tmps[1024]; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - int exception_keeper_lineno_2; -}; - -static PyObject *models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr_context(struct Nuitka_GeneratorObject *generator, PyObject *yield_return_value) { - CHECK_OBJECT(generator); - assert(Nuitka_Generator_Check((PyObject *)generator)); - CHECK_OBJECT_X(yield_return_value); - - // Heap access if used. - struct models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr_locals *generator_heap = (struct models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr_locals *)generator->m_heap_storage; - - // Dispatch to yield based on return label index: - switch(generator->m_yield_return_index) { - case 1: goto yield_return_1; - } - - // Local variable initialization - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - static struct Nuitka_FrameObject *cache_m_frame = NULL; - generator_heap->var_past_state = NULL; - generator_heap->tmp_iter_value_0 = NULL; - generator_heap->type_description_1 = NULL; - generator_heap->exception_type = NULL; - generator_heap->exception_value = NULL; - generator_heap->exception_tb = NULL; - generator_heap->exception_lineno = 0; - - // Actual generator function body. - // Tried code: - if (isFrameUnusable(cache_m_frame)) { - Py_XDECREF(cache_m_frame); - -#if _DEBUG_REFCOUNTS - if (cache_m_frame == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_m_frame = MAKE_FUNCTION_FRAME(codeobj_1a1e9c3c58d7ea5e2798e2bba549af89, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - generator->m_frame = cache_m_frame; - - // Mark the frame object as in use, ref count 1 will be up for reuse. - Py_INCREF(generator->m_frame); - assert(Py_REFCNT(generator->m_frame) == 2); // Frame stack - -#if PYTHON_VERSION >= 0x340 - generator->m_frame->m_frame.f_gen = (PyObject *)generator; -#endif - - assert(generator->m_frame->m_frame.f_back == NULL); - Py_CLEAR(generator->m_frame->m_frame.f_back); - - generator->m_frame->m_frame.f_back = PyThreadState_GET()->frame; - Py_INCREF(generator->m_frame->m_frame.f_back); - - PyThreadState_GET()->frame = &generator->m_frame->m_frame; - Py_INCREF(generator->m_frame); - - Nuitka_Frame_MarkAsExecuting(generator->m_frame); - -#if PYTHON_VERSION >= 0x300 - // Accept currently existing exception as the one to publish again when we - // yield or yield from. - { - PyThreadState *thread_state = PyThreadState_GET(); - - EXC_TYPE_F(generator) = EXC_TYPE(thread_state); - if (EXC_TYPE_F(generator) == Py_None) EXC_TYPE_F(generator) = NULL; - Py_XINCREF(EXC_TYPE_F(generator)); - EXC_VALUE_F(generator) = EXC_VALUE(thread_state); - Py_XINCREF(EXC_VALUE_F(generator)); - EXC_TRACEBACK_F(generator) = EXC_TRACEBACK(thread_state); - Py_XINCREF(EXC_TRACEBACK_F(generator)); - } - -#endif - - // Framed code: - // Tried code: - loop_start_1:; - { - PyObject *tmp_next_source_1; - PyObject *tmp_assign_source_1; - CHECK_OBJECT(Nuitka_Cell_GET(generator->m_closure[1])); - tmp_next_source_1 = Nuitka_Cell_GET(generator->m_closure[1]); - tmp_assign_source_1 = ITERATOR_NEXT(tmp_next_source_1); - if (tmp_assign_source_1 == NULL) { - if (CHECK_AND_CLEAR_STOP_ITERATION_OCCURRED()) { - - goto loop_end_1; - } else { - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - generator_heap->type_description_1 = "Noc"; - generator_heap->exception_lineno = 1124; - goto try_except_handler_2; - } - } - - { - PyObject *old = generator_heap->tmp_iter_value_0; - generator_heap->tmp_iter_value_0 = tmp_assign_source_1; - Py_XDECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - CHECK_OBJECT(generator_heap->tmp_iter_value_0); - tmp_assign_source_2 = generator_heap->tmp_iter_value_0; - { - PyObject *old = generator_heap->var_past_state; - generator_heap->var_past_state = tmp_assign_source_2; - Py_INCREF(generator_heap->var_past_state); - Py_XDECREF(old); - } - - } - { - PyObject *tmp_expression_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_args_element_name_1; - PyObject *tmp_args_element_name_2; - NUITKA_MAY_BE_UNUSED PyObject *tmp_yield_result_1; - CHECK_OBJECT(generator_heap->var_past_state); - tmp_expression_name_2 = generator_heap->var_past_state; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[270]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - - - generator_heap->exception_lineno = 1125; - generator_heap->type_description_1 = "Noc"; - goto try_except_handler_2; - } - tmp_args_element_name_1 = mod_consts[29]; - if (Nuitka_Cell_GET(generator->m_closure[0]) == NULL) { - Py_DECREF(tmp_called_name_1); - FORMAT_UNBOUND_CLOSURE_ERROR(&generator_heap->exception_type, &generator_heap->exception_value, mod_consts[271]); - generator_heap->exception_tb = NULL; - NORMALIZE_EXCEPTION(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - CHAIN_EXCEPTION(generator_heap->exception_value); - - generator_heap->exception_lineno = 1125; - generator_heap->type_description_1 = "Noc"; - goto try_except_handler_2; - } - - tmp_args_element_name_2 = Nuitka_Cell_GET(generator->m_closure[0]); - generator->m_frame->m_frame.f_lineno = 1125; - { - PyObject *call_args[] = {tmp_args_element_name_1, tmp_args_element_name_2}; - tmp_expression_name_1 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_1, call_args); - } - - Py_DECREF(tmp_called_name_1); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - - - generator_heap->exception_lineno = 1125; - generator_heap->type_description_1 = "Noc"; - goto try_except_handler_2; - } - Nuitka_PreserveHeap(generator_heap->yield_tmps, &tmp_called_name_1, sizeof(PyObject *), &tmp_expression_name_2, sizeof(PyObject *), &tmp_args_element_name_1, sizeof(PyObject *), &tmp_args_element_name_2, sizeof(PyObject *), NULL); - generator->m_yield_return_index = 1; - return tmp_expression_name_1; - yield_return_1: - Nuitka_RestoreHeap(generator_heap->yield_tmps, &tmp_called_name_1, sizeof(PyObject *), &tmp_expression_name_2, sizeof(PyObject *), &tmp_args_element_name_1, sizeof(PyObject *), &tmp_args_element_name_2, sizeof(PyObject *), NULL); - if (yield_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - - - generator_heap->exception_lineno = 1124; - generator_heap->type_description_1 = "Noc"; - goto try_except_handler_2; - } - tmp_yield_result_1 = yield_return_value; - } - if (CONSIDER_THREADING() == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb); - - - generator_heap->exception_lineno = 1124; - generator_heap->type_description_1 = "Noc"; - goto try_except_handler_2; - } - goto loop_start_1; - loop_end_1:; - goto try_end_1; - // Exception handler code: - try_except_handler_2:; - generator_heap->exception_keeper_type_1 = generator_heap->exception_type; - generator_heap->exception_keeper_value_1 = generator_heap->exception_value; - generator_heap->exception_keeper_tb_1 = generator_heap->exception_tb; - generator_heap->exception_keeper_lineno_1 = generator_heap->exception_lineno; - generator_heap->exception_type = NULL; - generator_heap->exception_value = NULL; - generator_heap->exception_tb = NULL; - generator_heap->exception_lineno = 0; - - Py_XDECREF(generator_heap->tmp_iter_value_0); - generator_heap->tmp_iter_value_0 = NULL; - // Re-raise. - generator_heap->exception_type = generator_heap->exception_keeper_type_1; - generator_heap->exception_value = generator_heap->exception_keeper_value_1; - generator_heap->exception_tb = generator_heap->exception_keeper_tb_1; - generator_heap->exception_lineno = generator_heap->exception_keeper_lineno_1; - - goto frame_exception_exit_1; - // End of try: - try_end_1:; - - Nuitka_Frame_MarkAsNotExecuting(generator->m_frame); - -#if PYTHON_VERSION >= 0x300 - Py_CLEAR(EXC_TYPE_F(generator)); - Py_CLEAR(EXC_VALUE_F(generator)); - Py_CLEAR(EXC_TRACEBACK_F(generator)); -#endif - - // Allow re-use of the frame again. - Py_DECREF(generator->m_frame); - goto frame_no_exception_1; - - frame_exception_exit_1:; - - // If it's not an exit exception, consider and create a traceback for it. - if (!EXCEPTION_MATCH_GENERATOR(generator_heap->exception_type)) { - if (generator_heap->exception_tb == NULL) { - generator_heap->exception_tb = MAKE_TRACEBACK(generator->m_frame, generator_heap->exception_lineno); - } else if (generator_heap->exception_tb->tb_frame != &generator->m_frame->m_frame) { - generator_heap->exception_tb = ADD_TRACEBACK(generator_heap->exception_tb, generator->m_frame, generator_heap->exception_lineno); - } - - Nuitka_Frame_AttachLocals( - generator->m_frame, - generator_heap->type_description_1, - NULL, - generator_heap->var_past_state, - generator->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (generator->m_frame == cache_m_frame) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_m_frame); - cache_m_frame = NULL; - } - - assertFrameObject(generator->m_frame); - } - -#if PYTHON_VERSION >= 0x300 - Py_CLEAR(EXC_TYPE_F(generator)); - Py_CLEAR(EXC_VALUE_F(generator)); - Py_CLEAR(EXC_TRACEBACK_F(generator)); -#endif - - Py_DECREF(generator->m_frame); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - goto try_end_2; - // Exception handler code: - try_except_handler_1:; - generator_heap->exception_keeper_type_2 = generator_heap->exception_type; - generator_heap->exception_keeper_value_2 = generator_heap->exception_value; - generator_heap->exception_keeper_tb_2 = generator_heap->exception_tb; - generator_heap->exception_keeper_lineno_2 = generator_heap->exception_lineno; - generator_heap->exception_type = NULL; - generator_heap->exception_value = NULL; - generator_heap->exception_tb = NULL; - generator_heap->exception_lineno = 0; - - Py_XDECREF(generator_heap->var_past_state); - generator_heap->var_past_state = NULL; - // Re-raise. - generator_heap->exception_type = generator_heap->exception_keeper_type_2; - generator_heap->exception_value = generator_heap->exception_keeper_value_2; - generator_heap->exception_tb = generator_heap->exception_keeper_tb_2; - generator_heap->exception_lineno = generator_heap->exception_keeper_lineno_2; - - goto function_exception_exit; - // End of try: - try_end_2:; - Py_XDECREF(generator_heap->tmp_iter_value_0); - generator_heap->tmp_iter_value_0 = NULL; - Py_XDECREF(generator_heap->var_past_state); - generator_heap->var_past_state = NULL; - - - return NULL; - - function_exception_exit: - assert(generator_heap->exception_type); - RESTORE_ERROR_OCCURRED(generator_heap->exception_type, generator_heap->exception_value, generator_heap->exception_tb); - - return NULL; - -} - -static PyObject *MAKE_GENERATOR_models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr(struct Nuitka_CellObject **closure) { - return Nuitka_Generator_New( - models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr_context, - module_models$Qformer, - mod_consts[167], -#if PYTHON_VERSION >= 0x350 - mod_consts[272], -#endif - codeobj_1a1e9c3c58d7ea5e2798e2bba549af89, - closure, - 2, - sizeof(struct models$Qformer$$$function__45__reorder_cache$$$genexpr__1_genexpr_locals) - ); -} - - -static PyObject *impl_models$Qformer$$$function__46___init__(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_config = python_pars[1]; - struct Nuitka_FrameObject *frame_e2b0deaa42e6635507b21870f60576c4; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - NUITKA_MAY_BE_UNUSED nuitka_void tmp_unused; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_e2b0deaa42e6635507b21870f60576c4 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_e2b0deaa42e6635507b21870f60576c4)) { - Py_XDECREF(cache_frame_e2b0deaa42e6635507b21870f60576c4); - -#if _DEBUG_REFCOUNTS - if (cache_frame_e2b0deaa42e6635507b21870f60576c4 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_e2b0deaa42e6635507b21870f60576c4 = MAKE_FUNCTION_FRAME(codeobj_e2b0deaa42e6635507b21870f60576c4, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_e2b0deaa42e6635507b21870f60576c4->m_type_description == NULL); - frame_e2b0deaa42e6635507b21870f60576c4 = cache_frame_e2b0deaa42e6635507b21870f60576c4; - - // Push the new frame as the currently active one. - pushFrameStack(frame_e2b0deaa42e6635507b21870f60576c4); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_e2b0deaa42e6635507b21870f60576c4) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_called_instance_1; - PyObject *tmp_type_arg_name_1; - PyObject *tmp_object_arg_name_1; - PyObject *tmp_call_result_1; - PyObject *tmp_args_element_name_1; - if (Nuitka_Cell_GET(self->m_closure[0]) == NULL) { - - FORMAT_UNBOUND_CLOSURE_ERROR(&exception_type, &exception_value, mod_consts[0]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1137; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_type_arg_name_1 = Nuitka_Cell_GET(self->m_closure[0]); - CHECK_OBJECT(par_self); - tmp_object_arg_name_1 = par_self; - tmp_called_instance_1 = BUILTIN_SUPER0(tmp_type_arg_name_1, tmp_object_arg_name_1); - if (tmp_called_instance_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1137; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_config); - tmp_args_element_name_1 = par_config; - frame_e2b0deaa42e6635507b21870f60576c4->m_frame.f_lineno = 1137; - tmp_call_result_1 = CALL_METHOD_WITH_SINGLE_ARG(tmp_called_instance_1, mod_consts[1], tmp_args_element_name_1); - Py_DECREF(tmp_called_instance_1); - if (tmp_call_result_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1137; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_1); - } - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_called_name_1; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_assattr_target_1; - tmp_called_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[239]); - - if (unlikely(tmp_called_name_1 == NULL)) { - tmp_called_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[239]); - } - - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1139; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1139; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_1 = par_config; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_kwargs_name_1 = PyDict_Copy(mod_consts[240]); - frame_e2b0deaa42e6635507b21870f60576c4->m_frame.f_lineno = 1139; - tmp_assattr_name_1 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assattr_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1139; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_1 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[241], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1139; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_called_name_2; - PyObject *tmp_args_element_name_2; - PyObject *tmp_assattr_target_2; - tmp_called_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[242]); - - if (unlikely(tmp_called_name_2 == NULL)) { - tmp_called_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[242]); - } - - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1140; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - if (par_config == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[5]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1140; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_2 = par_config; - frame_e2b0deaa42e6635507b21870f60576c4->m_frame.f_lineno = 1140; - tmp_assattr_name_2 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_2); - if (tmp_assattr_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1140; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_self); - tmp_assattr_target_2 = par_self; - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[243], tmp_assattr_name_2); - Py_DECREF(tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1140; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_called_instance_2; - PyObject *tmp_call_result_2; - CHECK_OBJECT(par_self); - tmp_called_instance_2 = par_self; - frame_e2b0deaa42e6635507b21870f60576c4->m_frame.f_lineno = 1142; - tmp_call_result_2 = CALL_METHOD_NO_ARGS(tmp_called_instance_2, mod_consts[198]); - if (tmp_call_result_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1142; - type_description_1 = "ooc"; - goto frame_exception_exit_1; - } - Py_DECREF(tmp_call_result_2); - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e2b0deaa42e6635507b21870f60576c4); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e2b0deaa42e6635507b21870f60576c4); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_e2b0deaa42e6635507b21870f60576c4, exception_lineno); - } else if (exception_tb->tb_frame != &frame_e2b0deaa42e6635507b21870f60576c4->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_e2b0deaa42e6635507b21870f60576c4, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_e2b0deaa42e6635507b21870f60576c4, - type_description_1, - par_self, - par_config, - self->m_closure[0] - ); - - - // Release cached frame if used for exception. - if (frame_e2b0deaa42e6635507b21870f60576c4 == cache_frame_e2b0deaa42e6635507b21870f60576c4) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_e2b0deaa42e6635507b21870f60576c4); - cache_frame_e2b0deaa42e6635507b21870f60576c4 = NULL; - } - - assertFrameObject(frame_e2b0deaa42e6635507b21870f60576c4); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_config); - par_config = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__47_get_output_embeddings(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - struct Nuitka_FrameObject *frame_ca38f33a6576fe8e2962a38a6c08a7da; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - static struct Nuitka_FrameObject *cache_frame_ca38f33a6576fe8e2962a38a6c08a7da = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_ca38f33a6576fe8e2962a38a6c08a7da)) { - Py_XDECREF(cache_frame_ca38f33a6576fe8e2962a38a6c08a7da); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ca38f33a6576fe8e2962a38a6c08a7da == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ca38f33a6576fe8e2962a38a6c08a7da = MAKE_FUNCTION_FRAME(codeobj_ca38f33a6576fe8e2962a38a6c08a7da, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ca38f33a6576fe8e2962a38a6c08a7da->m_type_description == NULL); - frame_ca38f33a6576fe8e2962a38a6c08a7da = cache_frame_ca38f33a6576fe8e2962a38a6c08a7da; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ca38f33a6576fe8e2962a38a6c08a7da); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ca38f33a6576fe8e2962a38a6c08a7da) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - PyObject *tmp_expression_name_3; - CHECK_OBJECT(par_self); - tmp_expression_name_3 = par_self; - tmp_expression_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[243]); - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1145; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[181]); - Py_DECREF(tmp_expression_name_2); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1145; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - tmp_return_value = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[176]); - Py_DECREF(tmp_expression_name_1); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1145; - type_description_1 = "o"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ca38f33a6576fe8e2962a38a6c08a7da); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ca38f33a6576fe8e2962a38a6c08a7da); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ca38f33a6576fe8e2962a38a6c08a7da); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ca38f33a6576fe8e2962a38a6c08a7da, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ca38f33a6576fe8e2962a38a6c08a7da->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ca38f33a6576fe8e2962a38a6c08a7da, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ca38f33a6576fe8e2962a38a6c08a7da, - type_description_1, - par_self - ); - - - // Release cached frame if used for exception. - if (frame_ca38f33a6576fe8e2962a38a6c08a7da == cache_frame_ca38f33a6576fe8e2962a38a6c08a7da) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ca38f33a6576fe8e2962a38a6c08a7da); - cache_frame_ca38f33a6576fe8e2962a38a6c08a7da = NULL; - } - - assertFrameObject(frame_ca38f33a6576fe8e2962a38a6c08a7da); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__48_set_output_embeddings(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_new_embeddings = python_pars[1]; - struct Nuitka_FrameObject *frame_0fd009d1dbe4c7c46c53f9bdc210148d; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - bool tmp_result; - static struct Nuitka_FrameObject *cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d = NULL; - PyObject *tmp_return_value = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d)) { - Py_XDECREF(cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d); - -#if _DEBUG_REFCOUNTS - if (cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d = MAKE_FUNCTION_FRAME(codeobj_0fd009d1dbe4c7c46c53f9bdc210148d, module_models$Qformer, sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d->m_type_description == NULL); - frame_0fd009d1dbe4c7c46c53f9bdc210148d = cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d; - - // Push the new frame as the currently active one. - pushFrameStack(frame_0fd009d1dbe4c7c46c53f9bdc210148d); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_0fd009d1dbe4c7c46c53f9bdc210148d) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_new_embeddings); - tmp_assattr_name_1 = par_new_embeddings; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[243]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1148; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_assattr_target_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[181]); - Py_DECREF(tmp_expression_name_1); - if (tmp_assattr_target_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1148; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[176], tmp_assattr_name_1); - Py_DECREF(tmp_assattr_target_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1148; - type_description_1 = "oo"; - goto frame_exception_exit_1; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0fd009d1dbe4c7c46c53f9bdc210148d); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0fd009d1dbe4c7c46c53f9bdc210148d); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_0fd009d1dbe4c7c46c53f9bdc210148d, exception_lineno); - } else if (exception_tb->tb_frame != &frame_0fd009d1dbe4c7c46c53f9bdc210148d->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_0fd009d1dbe4c7c46c53f9bdc210148d, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_0fd009d1dbe4c7c46c53f9bdc210148d, - type_description_1, - par_self, - par_new_embeddings - ); - - - // Release cached frame if used for exception. - if (frame_0fd009d1dbe4c7c46c53f9bdc210148d == cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d); - cache_frame_0fd009d1dbe4c7c46c53f9bdc210148d = NULL; - } - - assertFrameObject(frame_0fd009d1dbe4c7c46c53f9bdc210148d); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - tmp_return_value = Py_None; - Py_INCREF(tmp_return_value); - goto try_return_handler_1; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_new_embeddings); - Py_DECREF(par_new_embeddings); - par_new_embeddings = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - CHECK_OBJECT(par_new_embeddings); - Py_DECREF(par_new_embeddings); - par_new_embeddings = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - -static PyObject *impl_models$Qformer$$$function__49_forward(struct Nuitka_FunctionObject const *self, PyObject **python_pars) { - // Preserve error status for checks -#ifndef __NUITKA_NO_ASSERT__ - NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); -#endif - - // Local variable declarations. - PyObject *par_self = python_pars[0]; - PyObject *par_input_ids = python_pars[1]; - PyObject *par_attention_mask = python_pars[2]; - PyObject *par_position_ids = python_pars[3]; - PyObject *par_head_mask = python_pars[4]; - PyObject *par_query_embeds = python_pars[5]; - PyObject *par_encoder_hidden_states = python_pars[6]; - PyObject *par_encoder_attention_mask = python_pars[7]; - PyObject *par_labels = python_pars[8]; - PyObject *par_output_attentions = python_pars[9]; - PyObject *par_output_hidden_states = python_pars[10]; - PyObject *par_return_dict = python_pars[11]; - PyObject *par_return_logits = python_pars[12]; - PyObject *par_is_decoder = python_pars[13]; - PyObject *var_outputs = NULL; - PyObject *var_sequence_output = NULL; - PyObject *var_prediction_scores = NULL; - PyObject *var_masked_lm_loss = NULL; - PyObject *var_loss_fct = NULL; - PyObject *var_output = NULL; - struct Nuitka_FrameObject *frame_d74dc7aa09a16c42b6aa4ce3077a906f; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - int tmp_res; - PyObject *tmp_return_value = NULL; - static struct Nuitka_FrameObject *cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f = NULL; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - - // Actual function body. - // Tried code: - if (isFrameUnusable(cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f)) { - Py_XDECREF(cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f); - -#if _DEBUG_REFCOUNTS - if (cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f = MAKE_FUNCTION_FRAME(codeobj_d74dc7aa09a16c42b6aa4ce3077a906f, module_models$Qformer, sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)+sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_type_description == NULL); - frame_d74dc7aa09a16c42b6aa4ce3077a906f = cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f; - - // Push the new frame as the currently active one. - pushFrameStack(frame_d74dc7aa09a16c42b6aa4ce3077a906f); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_d74dc7aa09a16c42b6aa4ce3077a906f) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_assign_source_1; - bool tmp_condition_result_1; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_expression_name_2; - CHECK_OBJECT(par_return_dict); - tmp_compexpr_left_1 = par_return_dict; - tmp_compexpr_right_1 = Py_None; - tmp_condition_result_1 = (tmp_compexpr_left_1 != tmp_compexpr_right_1) ? true : false; - if (tmp_condition_result_1 != false) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - CHECK_OBJECT(par_return_dict); - tmp_assign_source_1 = par_return_dict; - Py_INCREF(tmp_assign_source_1); - goto condexpr_end_1; - condexpr_false_1:; - CHECK_OBJECT(par_self); - tmp_expression_name_2 = par_self; - tmp_expression_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[5]); - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1174; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[221]); - Py_DECREF(tmp_expression_name_1); - if (tmp_assign_source_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1174; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - condexpr_end_1:; - { - PyObject *old = par_return_dict; - assert(old != NULL); - par_return_dict = tmp_assign_source_1; - Py_DECREF(old); - } - - } - { - PyObject *tmp_assign_source_2; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_1; - PyObject *tmp_kwargs_name_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1177; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_3 = par_self; - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_3, mod_consts[241]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1177; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_input_ids); - tmp_tuple_element_1 = par_input_ids; - tmp_args_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_1); - tmp_dict_key_1 = mod_consts[128]; - CHECK_OBJECT(par_attention_mask); - tmp_dict_value_1 = par_attention_mask; - tmp_kwargs_name_1 = _PyDict_NewPresized( 10 ); - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[19]; - CHECK_OBJECT(par_position_ids); - tmp_dict_value_1 = par_position_ids; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[129]; - CHECK_OBJECT(par_head_mask); - tmp_dict_value_1 = par_head_mask; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[223]; - CHECK_OBJECT(par_query_embeds); - tmp_dict_value_1 = par_query_embeds; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[60]; - CHECK_OBJECT(par_encoder_hidden_states); - tmp_dict_value_1 = par_encoder_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[155]; - CHECK_OBJECT(par_encoder_attention_mask); - tmp_dict_value_1 = par_encoder_attention_mask; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[123]; - CHECK_OBJECT(par_output_attentions); - tmp_dict_value_1 = par_output_attentions; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[142]; - CHECK_OBJECT(par_output_hidden_states); - tmp_dict_value_1 = par_output_hidden_states; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[233]; - CHECK_OBJECT(par_return_dict); - tmp_dict_value_1 = par_return_dict; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[244]; - CHECK_OBJECT(par_is_decoder); - tmp_dict_value_1 = par_is_decoder; - tmp_res = PyDict_SetItem(tmp_kwargs_name_1, tmp_dict_key_1, tmp_dict_value_1); - assert(!(tmp_res != 0)); - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1177; - tmp_assign_source_2 = CALL_FUNCTION(tmp_called_name_1, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_1); - Py_DECREF(tmp_args_name_1); - Py_DECREF(tmp_kwargs_name_1); - if (tmp_assign_source_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1177; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_outputs == NULL); - var_outputs = tmp_assign_source_2; - } - { - bool tmp_condition_result_2; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - if (par_query_embeds == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1191; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_compexpr_left_2 = par_query_embeds; - tmp_compexpr_right_2 = Py_None; - tmp_condition_result_2 = (tmp_compexpr_left_2 != tmp_compexpr_right_2) ? true : false; - if (tmp_condition_result_2 != false) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - { - PyObject *tmp_assign_source_3; - PyObject *tmp_expression_name_4; - PyObject *tmp_expression_name_5; - PyObject *tmp_subscript_name_1; - PyObject *tmp_subscript_name_2; - PyObject *tmp_tuple_element_2; - CHECK_OBJECT(var_outputs); - tmp_expression_name_5 = var_outputs; - tmp_subscript_name_1 = mod_consts[29]; - tmp_expression_name_4 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_5, tmp_subscript_name_1, 0); - if (tmp_expression_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1192; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_tuple_element_2 = mod_consts[30]; - tmp_subscript_name_2 = PyTuple_New(3); - { - PyObject *tmp_start_name_1; - PyObject *tmp_expression_name_6; - PyObject *tmp_expression_name_7; - PyObject *tmp_subscript_name_3; - PyObject *tmp_stop_name_1; - PyTuple_SET_ITEM0(tmp_subscript_name_2, 0, tmp_tuple_element_2); - if (par_query_embeds == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[223]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1192; - type_description_1 = "oooooooooooooooooooo"; - goto tuple_build_exception_1; - } - - tmp_expression_name_7 = par_query_embeds; - tmp_expression_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[132]); - if (tmp_expression_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1192; - type_description_1 = "oooooooooooooooooooo"; - goto tuple_build_exception_1; - } - tmp_subscript_name_3 = mod_consts[28]; - tmp_start_name_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_6, tmp_subscript_name_3, 1); - Py_DECREF(tmp_expression_name_6); - if (tmp_start_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1192; - type_description_1 = "oooooooooooooooooooo"; - goto tuple_build_exception_1; - } - tmp_stop_name_1 = Py_None; - tmp_tuple_element_2 = MAKE_SLICEOBJ2(tmp_start_name_1, tmp_stop_name_1); - Py_DECREF(tmp_start_name_1); - assert(!(tmp_tuple_element_2 == NULL)); - PyTuple_SET_ITEM(tmp_subscript_name_2, 1, tmp_tuple_element_2); - tmp_tuple_element_2 = mod_consts[30]; - PyTuple_SET_ITEM0(tmp_subscript_name_2, 2, tmp_tuple_element_2); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_expression_name_4); - Py_DECREF(tmp_subscript_name_2); - goto frame_exception_exit_1; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_assign_source_3 = LOOKUP_SUBSCRIPT(tmp_expression_name_4, tmp_subscript_name_2); - Py_DECREF(tmp_expression_name_4); - Py_DECREF(tmp_subscript_name_2); - if (tmp_assign_source_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1192; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_sequence_output == NULL); - var_sequence_output = tmp_assign_source_3; - } - branch_no_1:; - { - PyObject *tmp_assign_source_4; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_8; - PyObject *tmp_args_element_name_1; - if (par_self == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1193; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_8 = par_self; - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[243]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1193; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - if (var_sequence_output == NULL) { - Py_DECREF(tmp_called_name_2); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[234]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1193; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_args_element_name_1 = var_sequence_output; - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1193; - tmp_assign_source_4 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_2, tmp_args_element_name_1); - Py_DECREF(tmp_called_name_2); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1193; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_prediction_scores == NULL); - var_prediction_scores = tmp_assign_source_4; - } - { - nuitka_bool tmp_condition_result_3; - int tmp_truth_name_1; - CHECK_OBJECT(par_return_logits); - tmp_truth_name_1 = CHECK_IF_TRUE(par_return_logits); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1195; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_3 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - CHECK_OBJECT(var_prediction_scores); - tmp_return_value = var_prediction_scores; - Py_INCREF(tmp_return_value); - goto frame_return_exit_1; - branch_no_2:; - { - PyObject *tmp_assign_source_5; - tmp_assign_source_5 = Py_None; - assert(var_masked_lm_loss == NULL); - Py_INCREF(tmp_assign_source_5); - var_masked_lm_loss = tmp_assign_source_5; - } - { - bool tmp_condition_result_4; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - CHECK_OBJECT(par_labels); - tmp_compexpr_left_3 = par_labels; - tmp_compexpr_right_3 = Py_None; - tmp_condition_result_4 = (tmp_compexpr_left_3 != tmp_compexpr_right_3) ? true : false; - if (tmp_condition_result_4 != false) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_assign_source_6; - PyObject *tmp_called_name_3; - tmp_called_name_3 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[247]); - - if (unlikely(tmp_called_name_3 == NULL)) { - tmp_called_name_3 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[247]); - } - - if (tmp_called_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1200; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1200; - tmp_assign_source_6 = CALL_FUNCTION_NO_ARGS(tmp_called_name_3); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1200; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_loss_fct == NULL); - var_loss_fct = tmp_assign_source_6; - } - { - PyObject *tmp_assign_source_7; - PyObject *tmp_called_name_4; - PyObject *tmp_args_element_name_2; - PyObject *tmp_called_name_5; - PyObject *tmp_expression_name_9; - PyObject *tmp_args_element_name_3; - PyObject *tmp_args_element_name_4; - PyObject *tmp_expression_name_10; - PyObject *tmp_expression_name_11; - PyObject *tmp_args_element_name_5; - PyObject *tmp_called_instance_1; - CHECK_OBJECT(var_loss_fct); - tmp_called_name_4 = var_loss_fct; - CHECK_OBJECT(var_prediction_scores); - tmp_expression_name_9 = var_prediction_scores; - tmp_called_name_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_9, mod_consts[56]); - if (tmp_called_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1202; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_3 = mod_consts[126]; - if (par_self == NULL) { - Py_DECREF(tmp_called_name_5); - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[26]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1202; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_expression_name_11 = par_self; - tmp_expression_name_10 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[5]); - if (tmp_expression_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 1202; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_args_element_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_10, mod_consts[4]); - Py_DECREF(tmp_expression_name_10); - if (tmp_args_element_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_called_name_5); - - exception_lineno = 1202; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1202; - { - PyObject *call_args[] = {tmp_args_element_name_3, tmp_args_element_name_4}; - tmp_args_element_name_2 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_5, call_args); - } - - Py_DECREF(tmp_called_name_5); - Py_DECREF(tmp_args_element_name_4); - if (tmp_args_element_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1202; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - CHECK_OBJECT(par_labels); - tmp_called_instance_1 = par_labels; - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1202; - tmp_args_element_name_5 = CALL_METHOD_WITH_ARGS1( - tmp_called_instance_1, - mod_consts[56], - &PyTuple_GET_ITEM(mod_consts[251], 0) - ); - - if (tmp_args_element_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_args_element_name_2); - - exception_lineno = 1202; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1201; - { - PyObject *call_args[] = {tmp_args_element_name_2, tmp_args_element_name_5}; - tmp_assign_source_7 = CALL_FUNCTION_WITH_ARGS2(tmp_called_name_4, call_args); - } - - Py_DECREF(tmp_args_element_name_2); - Py_DECREF(tmp_args_element_name_5); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1201; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - { - PyObject *old = var_masked_lm_loss; - assert(old != NULL); - var_masked_lm_loss = tmp_assign_source_7; - Py_DECREF(old); - } - - } - branch_no_3:; - { - nuitka_bool tmp_condition_result_5; - PyObject *tmp_operand_name_1; - if (par_return_dict == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[233]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1205; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_operand_name_1 = par_return_dict; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1205; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_condition_result_5 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - } - branch_yes_4:; - { - PyObject *tmp_assign_source_8; - PyObject *tmp_left_name_1; - PyObject *tmp_tuple_element_3; - PyObject *tmp_right_name_1; - PyObject *tmp_expression_name_12; - PyObject *tmp_subscript_name_4; - if (var_prediction_scores == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[256]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1206; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - - tmp_tuple_element_3 = var_prediction_scores; - tmp_left_name_1 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_left_name_1, 0, tmp_tuple_element_3); - CHECK_OBJECT(var_outputs); - tmp_expression_name_12 = var_outputs; - tmp_subscript_name_4 = mod_consts[257]; - tmp_right_name_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_12, tmp_subscript_name_4); - if (tmp_right_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - Py_DECREF(tmp_left_name_1); - - exception_lineno = 1206; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_assign_source_8 = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_left_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1206; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - assert(var_output == NULL); - var_output = tmp_assign_source_8; - } - { - bool tmp_condition_result_6; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - PyObject *tmp_left_name_2; - PyObject *tmp_tuple_element_4; - PyObject *tmp_right_name_2; - CHECK_OBJECT(var_masked_lm_loss); - tmp_compexpr_left_4 = var_masked_lm_loss; - tmp_compexpr_right_4 = Py_None; - tmp_condition_result_6 = (tmp_compexpr_left_4 != tmp_compexpr_right_4) ? true : false; - if (tmp_condition_result_6 != false) { - goto condexpr_true_2; - } else { - goto condexpr_false_2; - } - condexpr_true_2:; - CHECK_OBJECT(var_masked_lm_loss); - tmp_tuple_element_4 = var_masked_lm_loss; - tmp_left_name_2 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_left_name_2, 0, tmp_tuple_element_4); - CHECK_OBJECT(var_output); - tmp_right_name_2 = var_output; - tmp_return_value = BINARY_OPERATION_ADD_OBJECT_TUPLE_OBJECT(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_left_name_2); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1208; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto condexpr_end_2; - condexpr_false_2:; - CHECK_OBJECT(var_output); - tmp_return_value = var_output; - Py_INCREF(tmp_return_value); - condexpr_end_2:; - goto frame_return_exit_1; - } - branch_no_4:; - { - PyObject *tmp_called_name_6; - PyObject *tmp_kwargs_name_2; - PyObject *tmp_dict_key_2; - PyObject *tmp_dict_value_2; - tmp_called_name_6 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[273]); - - if (unlikely(tmp_called_name_6 == NULL)) { - tmp_called_name_6 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[273]); - } - - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1211; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - tmp_dict_key_2 = mod_consts[260]; - CHECK_OBJECT(var_masked_lm_loss); - tmp_dict_value_2 = var_masked_lm_loss; - tmp_kwargs_name_2 = _PyDict_NewPresized( 4 ); - { - PyObject *tmp_expression_name_13; - PyObject *tmp_expression_name_14; - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - tmp_dict_key_2 = mod_consts[261]; - if (var_prediction_scores == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[256]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1213; - type_description_1 = "oooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_dict_value_2 = var_prediction_scores; - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - assert(!(tmp_res != 0)); - tmp_dict_key_2 = mod_consts[61]; - CHECK_OBJECT(var_outputs); - tmp_expression_name_13 = var_outputs; - tmp_dict_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[61]); - if (tmp_dict_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1214; - type_description_1 = "oooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - Py_DECREF(tmp_dict_value_2); - assert(!(tmp_res != 0)); - tmp_dict_key_2 = mod_consts[162]; - if (var_outputs == NULL) { - - FORMAT_UNBOUND_LOCAL_ERROR(&exception_type, &exception_value, mod_consts[136]); - exception_tb = NULL; - NORMALIZE_EXCEPTION(&exception_type, &exception_value, &exception_tb); - CHAIN_EXCEPTION(exception_value); - - exception_lineno = 1215; - type_description_1 = "oooooooooooooooooooo"; - goto dict_build_exception_1; - } - - tmp_expression_name_14 = var_outputs; - tmp_dict_value_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[162]); - if (tmp_dict_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1215; - type_description_1 = "oooooooooooooooooooo"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_kwargs_name_2, tmp_dict_key_2, tmp_dict_value_2); - Py_DECREF(tmp_dict_value_2); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_kwargs_name_2); - goto frame_exception_exit_1; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame.f_lineno = 1211; - tmp_return_value = CALL_FUNCTION_WITH_KEYARGS(tmp_called_name_6, tmp_kwargs_name_2); - Py_DECREF(tmp_kwargs_name_2); - if (tmp_return_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1211; - type_description_1 = "oooooooooooooooooooo"; - goto frame_exception_exit_1; - } - goto frame_return_exit_1; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d74dc7aa09a16c42b6aa4ce3077a906f); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_return_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d74dc7aa09a16c42b6aa4ce3077a906f); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto try_return_handler_1; - - frame_exception_exit_1:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_d74dc7aa09a16c42b6aa4ce3077a906f); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_d74dc7aa09a16c42b6aa4ce3077a906f, exception_lineno); - } else if (exception_tb->tb_frame != &frame_d74dc7aa09a16c42b6aa4ce3077a906f->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_d74dc7aa09a16c42b6aa4ce3077a906f, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_d74dc7aa09a16c42b6aa4ce3077a906f, - type_description_1, - par_self, - par_input_ids, - par_attention_mask, - par_position_ids, - par_head_mask, - par_query_embeds, - par_encoder_hidden_states, - par_encoder_attention_mask, - par_labels, - par_output_attentions, - par_output_hidden_states, - par_return_dict, - par_return_logits, - par_is_decoder, - var_outputs, - var_sequence_output, - var_prediction_scores, - var_masked_lm_loss, - var_loss_fct, - var_output - ); - - - // Release cached frame if used for exception. - if (frame_d74dc7aa09a16c42b6aa4ce3077a906f == cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f); - cache_frame_d74dc7aa09a16c42b6aa4ce3077a906f = NULL; - } - - assertFrameObject(frame_d74dc7aa09a16c42b6aa4ce3077a906f); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto try_except_handler_1; - - frame_no_exception_1:; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_1:; - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_labels); - par_labels = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - Py_XDECREF(par_return_dict); - par_return_dict = NULL; - CHECK_OBJECT(par_return_logits); - Py_DECREF(par_return_logits); - par_return_logits = NULL; - Py_XDECREF(par_is_decoder); - par_is_decoder = NULL; - Py_XDECREF(var_outputs); - var_outputs = NULL; - Py_XDECREF(var_sequence_output); - var_sequence_output = NULL; - Py_XDECREF(var_prediction_scores); - var_prediction_scores = NULL; - Py_XDECREF(var_masked_lm_loss); - var_masked_lm_loss = NULL; - Py_XDECREF(var_loss_fct); - var_loss_fct = NULL; - Py_XDECREF(var_output); - var_output = NULL; - goto function_return_exit; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(par_self); - par_self = NULL; - Py_XDECREF(par_input_ids); - par_input_ids = NULL; - Py_XDECREF(par_attention_mask); - par_attention_mask = NULL; - Py_XDECREF(par_position_ids); - par_position_ids = NULL; - Py_XDECREF(par_head_mask); - par_head_mask = NULL; - Py_XDECREF(par_query_embeds); - par_query_embeds = NULL; - Py_XDECREF(par_encoder_hidden_states); - par_encoder_hidden_states = NULL; - Py_XDECREF(par_encoder_attention_mask); - par_encoder_attention_mask = NULL; - Py_XDECREF(par_labels); - par_labels = NULL; - Py_XDECREF(par_output_attentions); - par_output_attentions = NULL; - Py_XDECREF(par_output_hidden_states); - par_output_hidden_states = NULL; - Py_XDECREF(par_return_dict); - par_return_dict = NULL; - CHECK_OBJECT(par_return_logits); - Py_DECREF(par_return_logits); - par_return_logits = NULL; - Py_XDECREF(par_is_decoder); - par_is_decoder = NULL; - Py_XDECREF(var_outputs); - var_outputs = NULL; - Py_XDECREF(var_sequence_output); - var_sequence_output = NULL; - Py_XDECREF(var_prediction_scores); - var_prediction_scores = NULL; - Py_XDECREF(var_masked_lm_loss); - var_masked_lm_loss = NULL; - Py_XDECREF(var_loss_fct); - var_loss_fct = NULL; - Py_XDECREF(var_output); - var_output = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto function_exception_exit; - // End of try: - - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - -function_exception_exit: - assert(exception_type); - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - - return NULL; - -function_return_exit: - // Function cleanup code if any. - - - // Actual function exit with return value, making sure we did not make - // the error status worse despite non-NULL return. - CHECK_OBJECT(tmp_return_value); - assert(had_error || !ERROR_OCCURRED()); - return tmp_return_value; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__10___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__10___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[349], -#endif - codeobj_3ffa23d628f575a2f740dcb6fe8c1a15, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__11_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__11_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[350], -#endif - codeobj_e2c151c9b0676788eee114d75e2c1886, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__12___init__(PyObject *defaults, struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__12___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[352], -#endif - codeobj_269652cb22803d15cde90d439879a1a2, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__13_prune_heads() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__13_prune_heads, - mod_consts[200], -#if PYTHON_VERSION >= 0x300 - mod_consts[353], -#endif - codeobj_0b0b36faf8277ec302d6c6695f619e8c, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__14_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__14_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[354], -#endif - codeobj_02c26eebaf2303eb7380395e131d8a5e, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__15___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__15___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[355], -#endif - codeobj_bc386502a8ad779e82b56ce3a01a046c, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__16_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__16_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[356], -#endif - codeobj_ef7df7f2aae603ea3cb921a91d68b297, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__17___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__17___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[357], -#endif - codeobj_da381dec774f92fc3fdec9b27fb9d857, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__18_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__18_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[358], -#endif - codeobj_ac223922169c79b32778e1fea6b86d12, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__19___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__19___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[359], -#endif - codeobj_9044624cc871cfe54b3607752fe57f1c, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__1___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__1___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[334], -#endif - codeobj_5cc68962f3dad1def9ff2c335252cee0, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__20_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__20_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[361], -#endif - codeobj_38c0c92910efd854dc73aa8a49f61b57, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__21_feed_forward_chunk() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__21_feed_forward_chunk, - mod_consts[133], -#if PYTHON_VERSION >= 0x300 - mod_consts[362], -#endif - codeobj_c4755f7ecaad447ef5e0ea80f9a42013, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__22_feed_forward_chunk_query() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__22_feed_forward_chunk_query, - mod_consts[131], -#if PYTHON_VERSION >= 0x300 - mod_consts[363], -#endif - codeobj_bc4467ccc7610a81a2b180cada5c22ef, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__23___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__23___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[364], -#endif - codeobj_dbb5244b0ee9d68abb3ae7983cb8df4b, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__24_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__24_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[366], -#endif - codeobj_fb4ac8ca5f5c6cf5999268c801f1a60e, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward, - mod_consts[151], -#if PYTHON_VERSION >= 0x300 - mod_consts[152], -#endif - codeobj_9bc2c26bc51f7651d0836f8203f94193, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 3 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward$$$function__1_custom_forward(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward$$$function__1_custom_forward, - mod_consts[164], -#if PYTHON_VERSION >= 0x300 - mod_consts[165], -#endif - codeobj_340e4e883925405252be80b1c8cda477, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 4 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__25___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__25___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[367], -#endif - codeobj_3183350d90f44f69878dab33e80e4921, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__26_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__26_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[368], -#endif - codeobj_efe9f30d4ed10b98b0f8cc575424636a, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__27___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__27___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[369], -#endif - codeobj_ca40fb07238f33d953447de3e31806fd, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__28_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__28_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[370], -#endif - codeobj_ef32505124b25b3c551fd3017e359336, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__29___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__29___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[371], -#endif - codeobj_9c6e6b2c3e0641a7465eeb0788b5b6dd, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__2_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__2_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[337], -#endif - codeobj_0d13c366fa26a472a6b7f1562ae363de, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__30_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__30_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[372], -#endif - codeobj_e5d530bc114f61caefcc8e7e58348d97, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__31___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__31___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[373], -#endif - codeobj_fa49026615d06e8f214b8591603bbecd, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__32_forward() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__32_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[374], -#endif - codeobj_0eb4b4b7e57523c96bf4c60654493887, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__33__init_weights() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__33__init_weights, - mod_consts[381], -#if PYTHON_VERSION >= 0x300 - mod_consts[382], -#endif - codeobj_4147f3aad460337a90fc69f511dba483, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - mod_consts[192], - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__34___init__(PyObject *defaults, struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__34___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[384], -#endif - codeobj_8e16adea762727bda11361e993d1476d, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__35_get_input_embeddings() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__35_get_input_embeddings, - mod_consts[385], -#if PYTHON_VERSION >= 0x300 - mod_consts[386], -#endif - codeobj_64584954755a32f374a421edcbab9154, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__36_set_input_embeddings() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__36_set_input_embeddings, - mod_consts[387], -#if PYTHON_VERSION >= 0x300 - mod_consts[388], -#endif - codeobj_721775a04cb45ee2837ea767c0780001, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__37__prune_heads() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__37__prune_heads, - mod_consts[389], -#if PYTHON_VERSION >= 0x300 - mod_consts[390], -#endif - codeobj_99e6e0fbfb9cc4282b3a8f4787f1fc90, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - mod_consts[201], - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__38_get_extended_attention_mask(PyObject *defaults, PyObject *annotations) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__38_get_extended_attention_mask, - mod_consts[226], -#if PYTHON_VERSION >= 0x300 - mod_consts[394], -#endif - codeobj_a5b726196dc433c291a911837adced9c, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - annotations, -#endif - module_models$Qformer, - mod_consts[220], - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__39_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__39_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[396], -#endif - codeobj_960ad736510918980c376a071f656626, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - mod_consts[238], - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__3___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__3___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[339], -#endif - codeobj_df9ac5d0a974d8e6803dbf3d6f292953, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__40___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__40___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[401], -#endif - codeobj_3fed784111b2af0b6a6ffc26ac50d650, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__41_get_output_embeddings() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__41_get_output_embeddings, - mod_consts[402], -#if PYTHON_VERSION >= 0x300 - mod_consts[403], -#endif - codeobj_d801348fdc3b19f91ac75fd50193d3b0, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__42_set_output_embeddings() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__42_set_output_embeddings, - mod_consts[404], -#if PYTHON_VERSION >= 0x300 - mod_consts[405], -#endif - codeobj_74af6475e06de1d3e4323696e9d6b171, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__43_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__43_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[407], -#endif - codeobj_7c295c83a4e918fa0e86389ee3693174, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - mod_consts[262], - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__44_prepare_inputs_for_generation(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__44_prepare_inputs_for_generation, - mod_consts[409], -#if PYTHON_VERSION >= 0x300 - mod_consts[410], -#endif - codeobj_ded4b18b08a0de899e2560321c2271bc, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__45__reorder_cache() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__45__reorder_cache, - mod_consts[411], -#if PYTHON_VERSION >= 0x300 - mod_consts[412], -#endif - codeobj_be03d43782ce0c74a753536e9a4f0743, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__46___init__(struct Nuitka_CellObject **closure) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__46___init__, - mod_consts[1], -#if PYTHON_VERSION >= 0x300 - mod_consts[414], -#endif - codeobj_e2b0deaa42e6635507b21870f60576c4, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - closure, - 1 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__47_get_output_embeddings() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__47_get_output_embeddings, - mod_consts[402], -#if PYTHON_VERSION >= 0x300 - mod_consts[415], -#endif - codeobj_ca38f33a6576fe8e2962a38a6c08a7da, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__48_set_output_embeddings() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__48_set_output_embeddings, - mod_consts[404], -#if PYTHON_VERSION >= 0x300 - mod_consts[416], -#endif - codeobj_0fd009d1dbe4c7c46c53f9bdc210148d, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__49_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__49_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[418], -#endif - codeobj_d74dc7aa09a16c42b6aa4ce3077a906f, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - mod_consts[274], - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__4_save_attn_gradients() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__4_save_attn_gradients, - mod_consts[88], -#if PYTHON_VERSION >= 0x300 - mod_consts[340], -#endif - codeobj_45b23ddb210e7fae6e94b686bdca3187, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__5_get_attn_gradients() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__5_get_attn_gradients, - mod_consts[341], -#if PYTHON_VERSION >= 0x300 - mod_consts[342], -#endif - codeobj_527cb4fbc9a5e67eae366d93117b1142, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__6_save_attention_map() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__6_save_attention_map, - mod_consts[85], -#if PYTHON_VERSION >= 0x300 - mod_consts[343], -#endif - codeobj_7dc435c7821988f8361240f6dacceca5, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__7_get_attention_map() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__7_get_attention_map, - mod_consts[344], -#if PYTHON_VERSION >= 0x300 - mod_consts[345], -#endif - codeobj_00cbf7e5232472b130db964e018f1f81, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__8_transpose_for_scores() { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__8_transpose_for_scores, - mod_consts[59], -#if PYTHON_VERSION >= 0x300 - mod_consts[346], -#endif - codeobj_d1badd3898339991bfdc4579ffa91ae1, - NULL, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - - -static PyObject *MAKE_FUNCTION_models$Qformer$$$function__9_forward(PyObject *defaults) { - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - impl_models$Qformer$$$function__9_forward, - mod_consts[336], -#if PYTHON_VERSION >= 0x300 - mod_consts[348], -#endif - codeobj_222d3cb8bbe72424730d64c2fb38796b, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, - NULL, -#endif - module_models$Qformer, - NULL, - NULL, - 0 - ); - - - return (PyObject *)result; -} - - -extern void _initCompiledCellType(); -extern void _initCompiledGeneratorType(); -extern void _initCompiledFunctionType(); -extern void _initCompiledMethodType(); -extern void _initCompiledFrameType(); - -extern PyTypeObject Nuitka_Loader_Type; - -#ifdef _NUITKA_PLUGIN_DILL_ENABLED -// Provide a way to create find a function via its C code and create it back -// in another process, useful for multiprocessing extensions like dill -extern void registerDillPluginTables(char const *module_name, PyMethodDef *reduce_compiled_function, PyMethodDef *create_compiled_function); - -function_impl_code functable_models$Qformer[] = { - impl_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward, - impl_models$Qformer$$$function__24_forward$$$function__1_create_custom_forward$$$function__1_custom_forward, - impl_models$Qformer$$$function__1___init__, - impl_models$Qformer$$$function__2_forward, - impl_models$Qformer$$$function__3___init__, - impl_models$Qformer$$$function__4_save_attn_gradients, - impl_models$Qformer$$$function__5_get_attn_gradients, - impl_models$Qformer$$$function__6_save_attention_map, - impl_models$Qformer$$$function__7_get_attention_map, - impl_models$Qformer$$$function__8_transpose_for_scores, - impl_models$Qformer$$$function__9_forward, - impl_models$Qformer$$$function__10___init__, - impl_models$Qformer$$$function__11_forward, - impl_models$Qformer$$$function__12___init__, - impl_models$Qformer$$$function__13_prune_heads, - impl_models$Qformer$$$function__14_forward, - impl_models$Qformer$$$function__15___init__, - impl_models$Qformer$$$function__16_forward, - impl_models$Qformer$$$function__17___init__, - impl_models$Qformer$$$function__18_forward, - impl_models$Qformer$$$function__19___init__, - impl_models$Qformer$$$function__20_forward, - impl_models$Qformer$$$function__21_feed_forward_chunk, - impl_models$Qformer$$$function__22_feed_forward_chunk_query, - impl_models$Qformer$$$function__23___init__, - impl_models$Qformer$$$function__24_forward, - impl_models$Qformer$$$function__25___init__, - impl_models$Qformer$$$function__26_forward, - impl_models$Qformer$$$function__27___init__, - impl_models$Qformer$$$function__28_forward, - impl_models$Qformer$$$function__29___init__, - impl_models$Qformer$$$function__30_forward, - impl_models$Qformer$$$function__31___init__, - impl_models$Qformer$$$function__32_forward, - impl_models$Qformer$$$function__33__init_weights, - impl_models$Qformer$$$function__34___init__, - impl_models$Qformer$$$function__35_get_input_embeddings, - impl_models$Qformer$$$function__36_set_input_embeddings, - impl_models$Qformer$$$function__37__prune_heads, - impl_models$Qformer$$$function__38_get_extended_attention_mask, - impl_models$Qformer$$$function__39_forward, - impl_models$Qformer$$$function__40___init__, - impl_models$Qformer$$$function__41_get_output_embeddings, - impl_models$Qformer$$$function__42_set_output_embeddings, - impl_models$Qformer$$$function__43_forward, - impl_models$Qformer$$$function__44_prepare_inputs_for_generation, - impl_models$Qformer$$$function__45__reorder_cache, - impl_models$Qformer$$$function__46___init__, - impl_models$Qformer$$$function__47_get_output_embeddings, - impl_models$Qformer$$$function__48_set_output_embeddings, - impl_models$Qformer$$$function__49_forward, - NULL -}; - -static char const *_reduce_compiled_function_argnames[] = { - "func", - NULL -}; - -static PyObject *_reduce_compiled_function(PyObject *self, PyObject *args, PyObject *kwds) { - PyObject *func; - - if (!PyArg_ParseTupleAndKeywords(args, kwds, "O:reduce_compiled_function", (char **)_reduce_compiled_function_argnames, &func, NULL)) { - return NULL; - } - - if (Nuitka_Function_Check(func) == false) { - SET_CURRENT_EXCEPTION_TYPE0_STR(PyExc_TypeError, "not a compiled function"); - return NULL; - } - - struct Nuitka_FunctionObject *function = (struct Nuitka_FunctionObject *)func; - - function_impl_code *current = functable_models$Qformer; - int offset = 0; - - while (*current != NULL) { - if (*current == function->m_c_code) { - break; - } - - current += 1; - offset += 1; - } - - if (*current == NULL) { - SET_CURRENT_EXCEPTION_TYPE0_STR(PyExc_TypeError, "Cannot find compiled function in module."); - return NULL; - } - - PyObject *code_object_desc = PyTuple_New(6); - PyTuple_SET_ITEM0(code_object_desc, 0, function->m_code_object->co_filename); - PyTuple_SET_ITEM0(code_object_desc, 1, function->m_code_object->co_name); - PyTuple_SET_ITEM(code_object_desc, 2, PyLong_FromLong(function->m_code_object->co_firstlineno)); - PyTuple_SET_ITEM0(code_object_desc, 3, function->m_code_object->co_varnames); - PyTuple_SET_ITEM(code_object_desc, 4, PyLong_FromLong(function->m_code_object->co_argcount)); - PyTuple_SET_ITEM(code_object_desc, 5, PyLong_FromLong(function->m_code_object->co_flags)); - - CHECK_OBJECT_DEEP(code_object_desc); - - PyObject *result = PyTuple_New(4); - PyTuple_SET_ITEM(result, 0, PyLong_FromLong(offset)); - PyTuple_SET_ITEM(result, 1, code_object_desc); - PyTuple_SET_ITEM0(result, 2, function->m_defaults); - PyTuple_SET_ITEM0(result, 3, function->m_doc != NULL ? function->m_doc : Py_None); - - CHECK_OBJECT_DEEP(result); - - return result; -} - -static PyMethodDef _method_def_reduce_compiled_function = {"reduce_compiled_function", (PyCFunction)_reduce_compiled_function, - METH_VARARGS | METH_KEYWORDS, NULL}; - -static char const *_create_compiled_function_argnames[] = { - "func", - "code_object_desc", - "defaults", - "doc", - NULL -}; - - -static PyObject *_create_compiled_function(PyObject *self, PyObject *args, PyObject *kwds) { - CHECK_OBJECT_DEEP(args); - - PyObject *func; - PyObject *code_object_desc; - PyObject *defaults; - PyObject *doc; - - if (!PyArg_ParseTupleAndKeywords(args, kwds, "OOOO:create_compiled_function", (char **)_create_compiled_function_argnames, &func, &code_object_desc, &defaults, &doc, NULL)) { - return NULL; - } - - int offset = PyLong_AsLong(func); - - if (offset == -1 && ERROR_OCCURRED()) { - return NULL; - } - - if (offset > sizeof(functable_models$Qformer) || offset < 0) { - SET_CURRENT_EXCEPTION_TYPE0_STR(PyExc_TypeError, "Wrong offset for compiled function."); - return NULL; - } - - PyObject *filename = PyTuple_GET_ITEM(code_object_desc, 0); - PyObject *function_name = PyTuple_GET_ITEM(code_object_desc, 1); - PyObject *line = PyTuple_GET_ITEM(code_object_desc, 2); - int line_int = PyLong_AsLong(line); - assert(!ERROR_OCCURRED()); - - PyObject *argnames = PyTuple_GET_ITEM(code_object_desc, 3); - PyObject *arg_count = PyTuple_GET_ITEM(code_object_desc, 4); - int arg_count_int = PyLong_AsLong(arg_count); - assert(!ERROR_OCCURRED()); - PyObject *flags = PyTuple_GET_ITEM(code_object_desc, 5); - int flags_int = PyLong_AsLong(flags); - assert(!ERROR_OCCURRED()); - - PyCodeObject *code_object = MAKE_CODEOBJECT( - filename, - line_int, - flags_int, - function_name, - argnames, - NULL, // freevars - arg_count_int, - 0, // TODO: Missing kw_only_count - 0 // TODO: Missing pos_only_count - ); - - struct Nuitka_FunctionObject *result = Nuitka_Function_New( - functable_models$Qformer[offset], - code_object->co_name, -#if PYTHON_VERSION >= 0x300 - NULL, // TODO: Not transferring qualname yet -#endif - code_object, - defaults, -#if PYTHON_VERSION >= 0x300 - NULL, // kwdefaults are done on the outside currently - NULL, // TODO: Not transferring annotations -#endif - module_models$Qformer, - doc, - NULL, - 0 - ); - - return (PyObject *)result; -} - -static PyMethodDef _method_def_create_compiled_function = { - "create_compiled_function", - (PyCFunction)_create_compiled_function, - METH_VARARGS | METH_KEYWORDS, NULL -}; - - -#endif - -// Internal entry point for module code. -PyObject *modulecode_models$Qformer(PyObject *module, struct Nuitka_MetaPathBasedLoaderEntry const *module_entry) { - module_models$Qformer = module; - -#ifdef _NUITKA_MODULE - // In case of a stand alone extension module, need to call initialization - // the init here because that's the first and only time we are going to get - // called here. - - // Initialize the constant values used. - _initBuiltinModule(); - createGlobalConstants(); - - /* Initialize the compiled types of Nuitka. */ - _initCompiledCellType(); - _initCompiledGeneratorType(); - _initCompiledFunctionType(); - _initCompiledMethodType(); - _initCompiledFrameType(); - -#if PYTHON_VERSION < 0x300 - _initSlotCompare(); -#endif -#if PYTHON_VERSION >= 0x270 - _initSlotIternext(); -#endif - - patchBuiltinModule(); - patchTypeComparison(); - - // Enable meta path based loader if not already done. -#ifdef _NUITKA_TRACE - PRINT_STRING("models.Qformer: Calling setupMetaPathBasedLoader().\n"); -#endif - setupMetaPathBasedLoader(); - -#if PYTHON_VERSION >= 0x300 - patchInspectModule(); -#endif - -#endif - - /* The constants only used by this module are created now. */ -#ifdef _NUITKA_TRACE - PRINT_STRING("models.Qformer: Calling createModuleConstants().\n"); -#endif - createModuleConstants(); - - /* The code objects used by this module are created now. */ -#ifdef _NUITKA_TRACE - PRINT_STRING("models.Qformer: Calling createModuleCodeObjects().\n"); -#endif - createModuleCodeObjects(); - - // PRINT_STRING("in initmodels$Qformer\n"); - - // Create the module object first. There are no methods initially, all are - // added dynamically in actual code only. Also no "__doc__" is initially - // set at this time, as it could not contain NUL characters this way, they - // are instead set in early module code. No "self" for modules, we have no - // use for it. - - moduledict_models$Qformer = MODULE_DICT(module_models$Qformer); - -#ifdef _NUITKA_PLUGIN_DILL_ENABLED - registerDillPluginTables(module_entry->name, &_method_def_reduce_compiled_function, &_method_def_create_compiled_function); -#endif - - // Set "__compiled__" to what version information we have. - UPDATE_STRING_DICT0( - moduledict_models$Qformer, - (Nuitka_StringObject *)const_str_plain___compiled__, - Nuitka_dunder_compiled_value - ); - - // Update "__package__" value to what it ought to be. - { -#if 0 - UPDATE_STRING_DICT0( - moduledict_models$Qformer, - (Nuitka_StringObject *)const_str_plain___package__, - const_str_empty - ); -#elif 0 - PyObject *module_name = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___name__); - - UPDATE_STRING_DICT0( - moduledict_models$Qformer, - (Nuitka_StringObject *)const_str_plain___package__, - module_name - ); -#else - -#if PYTHON_VERSION < 0x300 - PyObject *module_name = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___name__); - char const *module_name_cstr = PyString_AS_STRING(module_name); - - char const *last_dot = strrchr(module_name_cstr, '.'); - - if (last_dot != NULL) { - UPDATE_STRING_DICT1( - moduledict_models$Qformer, - (Nuitka_StringObject *)const_str_plain___package__, - PyString_FromStringAndSize(module_name_cstr, last_dot - module_name_cstr) - ); - } -#else - PyObject *module_name = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___name__); - Py_ssize_t dot_index = PyUnicode_Find(module_name, const_str_dot, 0, PyUnicode_GetLength(module_name), -1); - - if (dot_index != -1) { - UPDATE_STRING_DICT1( - moduledict_models$Qformer, - (Nuitka_StringObject *)const_str_plain___package__, - PyUnicode_Substring(module_name, 0, dot_index) - ); - } -#endif -#endif - } - - CHECK_OBJECT(module_models$Qformer); - - // For deep importing of a module we need to have "__builtins__", so we set - // it ourselves in the same way than CPython does. Note: This must be done - // before the frame object is allocated, or else it may fail. - - if (GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___builtins__) == NULL) { - PyObject *value = (PyObject *)builtin_module; - - // Check if main module, not a dict then but the module itself. -#if !defined(_NUITKA_EXE) || !0 - value = PyModule_GetDict(value); -#endif - - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___builtins__, value); - } - -#if PYTHON_VERSION >= 0x300 - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___loader__, (PyObject *)&Nuitka_Loader_Type); -#endif - -#if PYTHON_VERSION >= 0x340 -// Set the "__spec__" value - -#if 0 - // Main modules just get "None" as spec. - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___spec__, Py_None); -#else - // Other modules get a "ModuleSpec" from the standard mechanism. - { - PyObject *bootstrap_module = getImportLibBootstrapModule(); - CHECK_OBJECT(bootstrap_module); - - PyObject *_spec_from_module = PyObject_GetAttrString(bootstrap_module, "_spec_from_module"); - CHECK_OBJECT(_spec_from_module); - - PyObject *spec_value = CALL_FUNCTION_WITH_SINGLE_ARG(_spec_from_module, module_models$Qformer); - Py_DECREF(_spec_from_module); - - // We can assume this to never fail, or else we are in trouble anyway. - // CHECK_OBJECT(spec_value); - - if (spec_value == NULL) { - PyErr_PrintEx(0); - abort(); - } - -// Mark the execution in the "__spec__" value. - SET_ATTRIBUTE(spec_value, const_str_plain__initializing, Py_True); - - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)const_str_plain___spec__, spec_value); - } -#endif -#endif - - // Temp variables if any - struct Nuitka_CellObject *outline_0_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_1_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_2_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_3_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_4_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_5_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_6_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_7_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_8_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_9_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_10_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_11_var___class__ = Nuitka_Cell_Empty(); - PyObject *outline_12_var___class__ = NULL; - struct Nuitka_CellObject *outline_13_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_14_var___class__ = Nuitka_Cell_Empty(); - struct Nuitka_CellObject *outline_15_var___class__ = Nuitka_Cell_Empty(); - PyObject *tmp_class_creation_10__bases = NULL; - PyObject *tmp_class_creation_10__bases_orig = NULL; - PyObject *tmp_class_creation_10__class_decl_dict = NULL; - PyObject *tmp_class_creation_10__metaclass = NULL; - PyObject *tmp_class_creation_10__prepared = NULL; - PyObject *tmp_class_creation_11__bases = NULL; - PyObject *tmp_class_creation_11__bases_orig = NULL; - PyObject *tmp_class_creation_11__class_decl_dict = NULL; - PyObject *tmp_class_creation_11__metaclass = NULL; - PyObject *tmp_class_creation_11__prepared = NULL; - PyObject *tmp_class_creation_12__bases = NULL; - PyObject *tmp_class_creation_12__bases_orig = NULL; - PyObject *tmp_class_creation_12__class_decl_dict = NULL; - PyObject *tmp_class_creation_12__metaclass = NULL; - PyObject *tmp_class_creation_12__prepared = NULL; - PyObject *tmp_class_creation_13__bases = NULL; - PyObject *tmp_class_creation_13__bases_orig = NULL; - PyObject *tmp_class_creation_13__class_decl_dict = NULL; - PyObject *tmp_class_creation_13__metaclass = NULL; - PyObject *tmp_class_creation_13__prepared = NULL; - PyObject *tmp_class_creation_14__bases = NULL; - PyObject *tmp_class_creation_14__bases_orig = NULL; - PyObject *tmp_class_creation_14__class_decl_dict = NULL; - PyObject *tmp_class_creation_14__metaclass = NULL; - PyObject *tmp_class_creation_14__prepared = NULL; - PyObject *tmp_class_creation_15__bases = NULL; - PyObject *tmp_class_creation_15__bases_orig = NULL; - PyObject *tmp_class_creation_15__class_decl_dict = NULL; - PyObject *tmp_class_creation_15__metaclass = NULL; - PyObject *tmp_class_creation_15__prepared = NULL; - PyObject *tmp_class_creation_16__bases = NULL; - PyObject *tmp_class_creation_16__bases_orig = NULL; - PyObject *tmp_class_creation_16__class_decl_dict = NULL; - PyObject *tmp_class_creation_16__metaclass = NULL; - PyObject *tmp_class_creation_16__prepared = NULL; - PyObject *tmp_class_creation_1__bases = NULL; - PyObject *tmp_class_creation_1__bases_orig = NULL; - PyObject *tmp_class_creation_1__class_decl_dict = NULL; - PyObject *tmp_class_creation_1__metaclass = NULL; - PyObject *tmp_class_creation_1__prepared = NULL; - PyObject *tmp_class_creation_2__bases = NULL; - PyObject *tmp_class_creation_2__bases_orig = NULL; - PyObject *tmp_class_creation_2__class_decl_dict = NULL; - PyObject *tmp_class_creation_2__metaclass = NULL; - PyObject *tmp_class_creation_2__prepared = NULL; - PyObject *tmp_class_creation_3__bases = NULL; - PyObject *tmp_class_creation_3__bases_orig = NULL; - PyObject *tmp_class_creation_3__class_decl_dict = NULL; - PyObject *tmp_class_creation_3__metaclass = NULL; - PyObject *tmp_class_creation_3__prepared = NULL; - PyObject *tmp_class_creation_4__bases = NULL; - PyObject *tmp_class_creation_4__bases_orig = NULL; - PyObject *tmp_class_creation_4__class_decl_dict = NULL; - PyObject *tmp_class_creation_4__metaclass = NULL; - PyObject *tmp_class_creation_4__prepared = NULL; - PyObject *tmp_class_creation_5__bases = NULL; - PyObject *tmp_class_creation_5__bases_orig = NULL; - PyObject *tmp_class_creation_5__class_decl_dict = NULL; - PyObject *tmp_class_creation_5__metaclass = NULL; - PyObject *tmp_class_creation_5__prepared = NULL; - PyObject *tmp_class_creation_6__bases = NULL; - PyObject *tmp_class_creation_6__bases_orig = NULL; - PyObject *tmp_class_creation_6__class_decl_dict = NULL; - PyObject *tmp_class_creation_6__metaclass = NULL; - PyObject *tmp_class_creation_6__prepared = NULL; - PyObject *tmp_class_creation_7__bases = NULL; - PyObject *tmp_class_creation_7__bases_orig = NULL; - PyObject *tmp_class_creation_7__class_decl_dict = NULL; - PyObject *tmp_class_creation_7__metaclass = NULL; - PyObject *tmp_class_creation_7__prepared = NULL; - PyObject *tmp_class_creation_8__bases = NULL; - PyObject *tmp_class_creation_8__bases_orig = NULL; - PyObject *tmp_class_creation_8__class_decl_dict = NULL; - PyObject *tmp_class_creation_8__metaclass = NULL; - PyObject *tmp_class_creation_8__prepared = NULL; - PyObject *tmp_class_creation_9__bases = NULL; - PyObject *tmp_class_creation_9__bases_orig = NULL; - PyObject *tmp_class_creation_9__class_decl_dict = NULL; - PyObject *tmp_class_creation_9__metaclass = NULL; - PyObject *tmp_class_creation_9__prepared = NULL; - PyObject *tmp_import_from_1__module = NULL; - PyObject *tmp_import_from_2__module = NULL; - PyObject *tmp_import_from_3__module = NULL; - PyObject *tmp_import_from_4__module = NULL; - struct Nuitka_FrameObject *frame_2bb9003dfff85549a8e8392e723ec6c8; - NUITKA_MAY_BE_UNUSED char const *type_description_1 = NULL; - bool tmp_result; - PyObject *exception_type = NULL; - PyObject *exception_value = NULL; - PyTracebackObject *exception_tb = NULL; - NUITKA_MAY_BE_UNUSED int exception_lineno = 0; - PyObject *exception_keeper_type_1; - PyObject *exception_keeper_value_1; - PyTracebackObject *exception_keeper_tb_1; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_1; - PyObject *exception_keeper_type_2; - PyObject *exception_keeper_value_2; - PyTracebackObject *exception_keeper_tb_2; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_2; - PyObject *exception_keeper_type_3; - PyObject *exception_keeper_value_3; - PyTracebackObject *exception_keeper_tb_3; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_3; - PyObject *exception_keeper_type_4; - PyObject *exception_keeper_value_4; - PyTracebackObject *exception_keeper_tb_4; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_4; - int tmp_res; - PyObject *tmp_dictdel_dict; - PyObject *tmp_dictdel_key; - PyObject *locals_models$Qformer$$$class__1_BertEmbeddings_51 = NULL; - PyObject *tmp_dictset_value; - struct Nuitka_FrameObject *frame_0c0a0597d4b4257046a86687ff948770_2; - NUITKA_MAY_BE_UNUSED char const *type_description_2 = NULL; - static struct Nuitka_FrameObject *cache_frame_0c0a0597d4b4257046a86687ff948770_2 = NULL; - PyObject *exception_keeper_type_5; - PyObject *exception_keeper_value_5; - PyTracebackObject *exception_keeper_tb_5; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_5; - PyObject *exception_keeper_type_6; - PyObject *exception_keeper_value_6; - PyTracebackObject *exception_keeper_tb_6; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_6; - PyObject *exception_keeper_type_7; - PyObject *exception_keeper_value_7; - PyTracebackObject *exception_keeper_tb_7; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_7; - PyObject *locals_models$Qformer$$$class__2_BertSelfAttention_111 = NULL; - struct Nuitka_FrameObject *frame_39fcb37e2c2b36c20e772de986f100d1_3; - NUITKA_MAY_BE_UNUSED char const *type_description_3 = NULL; - static struct Nuitka_FrameObject *cache_frame_39fcb37e2c2b36c20e772de986f100d1_3 = NULL; - PyObject *exception_keeper_type_8; - PyObject *exception_keeper_value_8; - PyTracebackObject *exception_keeper_tb_8; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_8; - PyObject *exception_keeper_type_9; - PyObject *exception_keeper_value_9; - PyTracebackObject *exception_keeper_tb_9; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_9; - PyObject *exception_keeper_type_10; - PyObject *exception_keeper_value_10; - PyTracebackObject *exception_keeper_tb_10; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_10; - PyObject *locals_models$Qformer$$$class__3_BertSelfOutput_278 = NULL; - struct Nuitka_FrameObject *frame_cc56a3d4cf1124558e66a811713c588d_4; - NUITKA_MAY_BE_UNUSED char const *type_description_4 = NULL; - static struct Nuitka_FrameObject *cache_frame_cc56a3d4cf1124558e66a811713c588d_4 = NULL; - PyObject *exception_keeper_type_11; - PyObject *exception_keeper_value_11; - PyTracebackObject *exception_keeper_tb_11; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_11; - PyObject *exception_keeper_type_12; - PyObject *exception_keeper_value_12; - PyTracebackObject *exception_keeper_tb_12; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_12; - PyObject *exception_keeper_type_13; - PyObject *exception_keeper_value_13; - PyTracebackObject *exception_keeper_tb_13; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_13; - PyObject *locals_models$Qformer$$$class__4_BertAttention_292 = NULL; - struct Nuitka_FrameObject *frame_5bfea05f5a06871ae56cfaab6dbe57ba_5; - NUITKA_MAY_BE_UNUSED char const *type_description_5 = NULL; - static struct Nuitka_FrameObject *cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5 = NULL; - PyObject *exception_keeper_type_14; - PyObject *exception_keeper_value_14; - PyTracebackObject *exception_keeper_tb_14; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_14; - PyObject *exception_keeper_type_15; - PyObject *exception_keeper_value_15; - PyTracebackObject *exception_keeper_tb_15; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_15; - PyObject *exception_keeper_type_16; - PyObject *exception_keeper_value_16; - PyTracebackObject *exception_keeper_tb_16; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_16; - PyObject *locals_models$Qformer$$$class__5_BertIntermediate_349 = NULL; - struct Nuitka_FrameObject *frame_7007713779c26360c0f6632cb2047835_6; - NUITKA_MAY_BE_UNUSED char const *type_description_6 = NULL; - static struct Nuitka_FrameObject *cache_frame_7007713779c26360c0f6632cb2047835_6 = NULL; - PyObject *exception_keeper_type_17; - PyObject *exception_keeper_value_17; - PyTracebackObject *exception_keeper_tb_17; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_17; - PyObject *exception_keeper_type_18; - PyObject *exception_keeper_value_18; - PyTracebackObject *exception_keeper_tb_18; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_18; - PyObject *exception_keeper_type_19; - PyObject *exception_keeper_value_19; - PyTracebackObject *exception_keeper_tb_19; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_19; - PyObject *locals_models$Qformer$$$class__6_BertOutput_364 = NULL; - struct Nuitka_FrameObject *frame_2997152d8a9cec4ec6825b911abbb306_7; - NUITKA_MAY_BE_UNUSED char const *type_description_7 = NULL; - static struct Nuitka_FrameObject *cache_frame_2997152d8a9cec4ec6825b911abbb306_7 = NULL; - PyObject *exception_keeper_type_20; - PyObject *exception_keeper_value_20; - PyTracebackObject *exception_keeper_tb_20; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_20; - PyObject *exception_keeper_type_21; - PyObject *exception_keeper_value_21; - PyTracebackObject *exception_keeper_tb_21; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_21; - PyObject *exception_keeper_type_22; - PyObject *exception_keeper_value_22; - PyTracebackObject *exception_keeper_tb_22; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_22; - PyObject *locals_models$Qformer$$$class__7_BertLayer_378 = NULL; - struct Nuitka_FrameObject *frame_a081438c9da0f662f5a4de30a72f53eb_8; - NUITKA_MAY_BE_UNUSED char const *type_description_8 = NULL; - static struct Nuitka_FrameObject *cache_frame_a081438c9da0f662f5a4de30a72f53eb_8 = NULL; - PyObject *exception_keeper_type_23; - PyObject *exception_keeper_value_23; - PyTracebackObject *exception_keeper_tb_23; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_23; - PyObject *exception_keeper_type_24; - PyObject *exception_keeper_value_24; - PyTracebackObject *exception_keeper_tb_24; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_24; - PyObject *exception_keeper_type_25; - PyObject *exception_keeper_value_25; - PyTracebackObject *exception_keeper_tb_25; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_25; - PyObject *locals_models$Qformer$$$class__8_BertEncoder_487 = NULL; - struct Nuitka_FrameObject *frame_e1623af249db2190f4f0a833e30e71e3_9; - NUITKA_MAY_BE_UNUSED char const *type_description_9 = NULL; - static struct Nuitka_FrameObject *cache_frame_e1623af249db2190f4f0a833e30e71e3_9 = NULL; - PyObject *exception_keeper_type_26; - PyObject *exception_keeper_value_26; - PyTracebackObject *exception_keeper_tb_26; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_26; - PyObject *exception_keeper_type_27; - PyObject *exception_keeper_value_27; - PyTracebackObject *exception_keeper_tb_27; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_27; - PyObject *exception_keeper_type_28; - PyObject *exception_keeper_value_28; - PyTracebackObject *exception_keeper_tb_28; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_28; - PyObject *locals_models$Qformer$$$class__9_BertPooler_592 = NULL; - struct Nuitka_FrameObject *frame_ab5a99313f9b6e1e298f4606848400d8_10; - NUITKA_MAY_BE_UNUSED char const *type_description_10 = NULL; - static struct Nuitka_FrameObject *cache_frame_ab5a99313f9b6e1e298f4606848400d8_10 = NULL; - PyObject *exception_keeper_type_29; - PyObject *exception_keeper_value_29; - PyTracebackObject *exception_keeper_tb_29; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_29; - PyObject *exception_keeper_type_30; - PyObject *exception_keeper_value_30; - PyTracebackObject *exception_keeper_tb_30; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_30; - PyObject *exception_keeper_type_31; - PyObject *exception_keeper_value_31; - PyTracebackObject *exception_keeper_tb_31; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_31; - PyObject *locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607 = NULL; - struct Nuitka_FrameObject *frame_1e694c28c1cb7b88d842a0230f304b37_11; - NUITKA_MAY_BE_UNUSED char const *type_description_11 = NULL; - static struct Nuitka_FrameObject *cache_frame_1e694c28c1cb7b88d842a0230f304b37_11 = NULL; - PyObject *exception_keeper_type_32; - PyObject *exception_keeper_value_32; - PyTracebackObject *exception_keeper_tb_32; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_32; - PyObject *exception_keeper_type_33; - PyObject *exception_keeper_value_33; - PyTracebackObject *exception_keeper_tb_33; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_33; - PyObject *exception_keeper_type_34; - PyObject *exception_keeper_value_34; - PyTracebackObject *exception_keeper_tb_34; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_34; - PyObject *locals_models$Qformer$$$class__11_BertLMPredictionHead_624 = NULL; - struct Nuitka_FrameObject *frame_6e22728e3deba4360239f923eb721087_12; - NUITKA_MAY_BE_UNUSED char const *type_description_12 = NULL; - static struct Nuitka_FrameObject *cache_frame_6e22728e3deba4360239f923eb721087_12 = NULL; - PyObject *exception_keeper_type_35; - PyObject *exception_keeper_value_35; - PyTracebackObject *exception_keeper_tb_35; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_35; - PyObject *exception_keeper_type_36; - PyObject *exception_keeper_value_36; - PyTracebackObject *exception_keeper_tb_36; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_36; - PyObject *exception_keeper_type_37; - PyObject *exception_keeper_value_37; - PyTracebackObject *exception_keeper_tb_37; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_37; - PyObject *locals_models$Qformer$$$class__12_BertOnlyMLMHead_644 = NULL; - struct Nuitka_FrameObject *frame_2f024c1c2781aa4346c9360dc9ca9c37_13; - NUITKA_MAY_BE_UNUSED char const *type_description_13 = NULL; - static struct Nuitka_FrameObject *cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13 = NULL; - PyObject *exception_keeper_type_38; - PyObject *exception_keeper_value_38; - PyTracebackObject *exception_keeper_tb_38; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_38; - PyObject *exception_keeper_type_39; - PyObject *exception_keeper_value_39; - PyTracebackObject *exception_keeper_tb_39; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_39; - PyObject *exception_keeper_type_40; - PyObject *exception_keeper_value_40; - PyTracebackObject *exception_keeper_tb_40; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_40; - PyObject *locals_models$Qformer$$$class__13_BertPreTrainedModel_654 = NULL; - struct Nuitka_FrameObject *frame_2ba10c444d39cd9fbc64d82f9cd4789e_14; - NUITKA_MAY_BE_UNUSED char const *type_description_14 = NULL; - static struct Nuitka_FrameObject *cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14 = NULL; - PyObject *exception_keeper_type_41; - PyObject *exception_keeper_value_41; - PyTracebackObject *exception_keeper_tb_41; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_41; - PyObject *exception_keeper_type_42; - PyObject *exception_keeper_value_42; - PyTracebackObject *exception_keeper_tb_42; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_42; - PyObject *exception_keeper_type_43; - PyObject *exception_keeper_value_43; - PyTracebackObject *exception_keeper_tb_43; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_43; - PyObject *locals_models$Qformer$$$class__14_BertModel_677 = NULL; - struct Nuitka_FrameObject *frame_25865ea0df4a3f86bdd137c22518ab84_15; - NUITKA_MAY_BE_UNUSED char const *type_description_15 = NULL; - static struct Nuitka_FrameObject *cache_frame_25865ea0df4a3f86bdd137c22518ab84_15 = NULL; - PyObject *exception_keeper_type_44; - PyObject *exception_keeper_value_44; - PyTracebackObject *exception_keeper_tb_44; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_44; - PyObject *exception_keeper_type_45; - PyObject *exception_keeper_value_45; - PyTracebackObject *exception_keeper_tb_45; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_45; - PyObject *exception_keeper_type_46; - PyObject *exception_keeper_value_46; - PyTracebackObject *exception_keeper_tb_46; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_46; - PyObject *locals_models$Qformer$$$class__15_BertLMHeadModel_968 = NULL; - struct Nuitka_FrameObject *frame_aa454e092d5abc9f5e4553a289907508_16; - NUITKA_MAY_BE_UNUSED char const *type_description_16 = NULL; - static struct Nuitka_FrameObject *cache_frame_aa454e092d5abc9f5e4553a289907508_16 = NULL; - PyObject *exception_keeper_type_47; - PyObject *exception_keeper_value_47; - PyTracebackObject *exception_keeper_tb_47; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_47; - PyObject *exception_keeper_type_48; - PyObject *exception_keeper_value_48; - PyTracebackObject *exception_keeper_tb_48; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_48; - PyObject *exception_keeper_type_49; - PyObject *exception_keeper_value_49; - PyTracebackObject *exception_keeper_tb_49; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_49; - PyObject *locals_models$Qformer$$$class__16_BertForMaskedLM_1131 = NULL; - struct Nuitka_FrameObject *frame_e5264d356d902ef78943e91fb87114a1_17; - NUITKA_MAY_BE_UNUSED char const *type_description_17 = NULL; - static struct Nuitka_FrameObject *cache_frame_e5264d356d902ef78943e91fb87114a1_17 = NULL; - PyObject *exception_keeper_type_50; - PyObject *exception_keeper_value_50; - PyTracebackObject *exception_keeper_tb_50; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_50; - PyObject *exception_keeper_type_51; - PyObject *exception_keeper_value_51; - PyTracebackObject *exception_keeper_tb_51; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_51; - PyObject *exception_keeper_type_52; - PyObject *exception_keeper_value_52; - PyTracebackObject *exception_keeper_tb_52; - NUITKA_MAY_BE_UNUSED int exception_keeper_lineno_52; - - // Module code. - { - PyObject *tmp_assign_source_1; - tmp_assign_source_1 = mod_consts[275]; - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[276], tmp_assign_source_1); - } - { - PyObject *tmp_assign_source_2; - tmp_assign_source_2 = module_filename_obj; - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[277], tmp_assign_source_2); - } - // Frame without reuse. - frame_2bb9003dfff85549a8e8392e723ec6c8 = MAKE_MODULE_FRAME(codeobj_2bb9003dfff85549a8e8392e723ec6c8, module_models$Qformer); - - // Push the new frame as the currently active one, and we should be exclusively - // owning it. - pushFrameStack(frame_2bb9003dfff85549a8e8392e723ec6c8); - assert(Py_REFCNT(frame_2bb9003dfff85549a8e8392e723ec6c8) == 2); - - // Framed code: - { - PyObject *tmp_assattr_name_1; - PyObject *tmp_assattr_target_1; - tmp_assattr_name_1 = module_filename_obj; - tmp_assattr_target_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[278]); - - if (unlikely(tmp_assattr_target_1 == NULL)) { - tmp_assattr_target_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[278]); - } - - assert(!(tmp_assattr_target_1 == NULL)); - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_1, mod_consts[279], tmp_assattr_name_1); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1; - - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assattr_name_2; - PyObject *tmp_assattr_target_2; - tmp_assattr_name_2 = Py_True; - tmp_assattr_target_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[278]); - - if (unlikely(tmp_assattr_target_2 == NULL)) { - tmp_assattr_target_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[278]); - } - - assert(!(tmp_assattr_target_2 == NULL)); - tmp_result = SET_ATTRIBUTE(tmp_assattr_target_2, mod_consts[280], tmp_assattr_name_2); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1; - - goto frame_exception_exit_1; - } - } - { - PyObject *tmp_assign_source_3; - tmp_assign_source_3 = Py_None; - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[281], tmp_assign_source_3); - } - { - PyObject *tmp_assign_source_4; - PyObject *tmp_name_name_1; - PyObject *tmp_globals_arg_name_1; - PyObject *tmp_locals_arg_name_1; - PyObject *tmp_fromlist_name_1; - PyObject *tmp_level_name_1; - tmp_name_name_1 = mod_consts[81]; - tmp_globals_arg_name_1 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_1 = Py_None; - tmp_fromlist_name_1 = Py_None; - tmp_level_name_1 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 11; - tmp_assign_source_4 = IMPORT_MODULE5(tmp_name_name_1, tmp_globals_arg_name_1, tmp_locals_arg_name_1, tmp_fromlist_name_1, tmp_level_name_1); - if (tmp_assign_source_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 11; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[81], tmp_assign_source_4); - } - { - PyObject *tmp_assign_source_5; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 12; - tmp_assign_source_5 = IMPORT_HARD_OS(); - assert(!(tmp_assign_source_5 == NULL)); - UPDATE_STRING_DICT0(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[282], tmp_assign_source_5); - } - { - PyObject *tmp_assign_source_6; - PyObject *tmp_name_name_2; - PyObject *tmp_globals_arg_name_2; - PyObject *tmp_locals_arg_name_2; - PyObject *tmp_fromlist_name_2; - PyObject *tmp_level_name_2; - tmp_name_name_2 = mod_consts[283]; - tmp_globals_arg_name_2 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_2 = Py_None; - tmp_fromlist_name_2 = Py_None; - tmp_level_name_2 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 13; - tmp_assign_source_6 = IMPORT_MODULE5(tmp_name_name_2, tmp_globals_arg_name_2, tmp_locals_arg_name_2, tmp_fromlist_name_2, tmp_level_name_2); - if (tmp_assign_source_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 13; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[283], tmp_assign_source_6); - } - { - PyObject *tmp_assign_source_7; - PyObject *tmp_import_name_from_1; - PyObject *tmp_name_name_3; - PyObject *tmp_globals_arg_name_3; - PyObject *tmp_locals_arg_name_3; - PyObject *tmp_fromlist_name_3; - PyObject *tmp_level_name_3; - tmp_name_name_3 = mod_consts[284]; - tmp_globals_arg_name_3 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_3 = Py_None; - tmp_fromlist_name_3 = mod_consts[285]; - tmp_level_name_3 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 14; - tmp_import_name_from_1 = IMPORT_MODULE5(tmp_name_name_3, tmp_globals_arg_name_3, tmp_locals_arg_name_3, tmp_fromlist_name_3, tmp_level_name_3); - if (tmp_import_name_from_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 14; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_1)) { - tmp_assign_source_7 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_1, - (PyObject *)moduledict_models$Qformer, - mod_consts[286], - mod_consts[29] - ); - } else { - tmp_assign_source_7 = IMPORT_NAME(tmp_import_name_from_1, mod_consts[286]); - } - - Py_DECREF(tmp_import_name_from_1); - if (tmp_assign_source_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 14; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[286], tmp_assign_source_7); - } - { - PyObject *tmp_assign_source_8; - PyObject *tmp_name_name_4; - PyObject *tmp_globals_arg_name_4; - PyObject *tmp_locals_arg_name_4; - PyObject *tmp_fromlist_name_4; - PyObject *tmp_level_name_4; - tmp_name_name_4 = mod_consts[287]; - tmp_globals_arg_name_4 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_4 = Py_None; - tmp_fromlist_name_4 = mod_consts[288]; - tmp_level_name_4 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 15; - tmp_assign_source_8 = IMPORT_MODULE5(tmp_name_name_4, tmp_globals_arg_name_4, tmp_locals_arg_name_4, tmp_fromlist_name_4, tmp_level_name_4); - if (tmp_assign_source_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 15; - - goto frame_exception_exit_1; - } - assert(tmp_import_from_1__module == NULL); - tmp_import_from_1__module = tmp_assign_source_8; - } - // Tried code: - { - PyObject *tmp_assign_source_9; - PyObject *tmp_import_name_from_2; - CHECK_OBJECT(tmp_import_from_1__module); - tmp_import_name_from_2 = tmp_import_from_1__module; - if (PyModule_Check(tmp_import_name_from_2)) { - tmp_assign_source_9 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_2, - (PyObject *)moduledict_models$Qformer, - mod_consts[289], - mod_consts[29] - ); - } else { - tmp_assign_source_9 = IMPORT_NAME(tmp_import_name_from_2, mod_consts[289]); - } - - if (tmp_assign_source_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 15; - - goto try_except_handler_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[289], tmp_assign_source_9); - } - { - PyObject *tmp_assign_source_10; - PyObject *tmp_import_name_from_3; - CHECK_OBJECT(tmp_import_from_1__module); - tmp_import_name_from_3 = tmp_import_from_1__module; - if (PyModule_Check(tmp_import_name_from_3)) { - tmp_assign_source_10 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_3, - (PyObject *)moduledict_models$Qformer, - mod_consts[290], - mod_consts[29] - ); - } else { - tmp_assign_source_10 = IMPORT_NAME(tmp_import_name_from_3, mod_consts[290]); - } - - if (tmp_assign_source_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 15; - - goto try_except_handler_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[290], tmp_assign_source_10); - } - { - PyObject *tmp_assign_source_11; - PyObject *tmp_import_name_from_4; - CHECK_OBJECT(tmp_import_from_1__module); - tmp_import_name_from_4 = tmp_import_from_1__module; - if (PyModule_Check(tmp_import_name_from_4)) { - tmp_assign_source_11 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_4, - (PyObject *)moduledict_models$Qformer, - mod_consts[291], - mod_consts[29] - ); - } else { - tmp_assign_source_11 = IMPORT_NAME(tmp_import_name_from_4, mod_consts[291]); - } - - if (tmp_assign_source_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 15; - - goto try_except_handler_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[291], tmp_assign_source_11); - } - { - PyObject *tmp_assign_source_12; - PyObject *tmp_import_name_from_5; - CHECK_OBJECT(tmp_import_from_1__module); - tmp_import_name_from_5 = tmp_import_from_1__module; - if (PyModule_Check(tmp_import_name_from_5)) { - tmp_assign_source_12 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_5, - (PyObject *)moduledict_models$Qformer, - mod_consts[292], - mod_consts[29] - ); - } else { - tmp_assign_source_12 = IMPORT_NAME(tmp_import_name_from_5, mod_consts[292]); - } - - if (tmp_assign_source_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 15; - - goto try_except_handler_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[292], tmp_assign_source_12); - } - goto try_end_1; - // Exception handler code: - try_except_handler_1:; - exception_keeper_type_1 = exception_type; - exception_keeper_value_1 = exception_value; - exception_keeper_tb_1 = exception_tb; - exception_keeper_lineno_1 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(tmp_import_from_1__module); - Py_DECREF(tmp_import_from_1__module); - tmp_import_from_1__module = NULL; - // Re-raise. - exception_type = exception_keeper_type_1; - exception_value = exception_keeper_value_1; - exception_tb = exception_keeper_tb_1; - exception_lineno = exception_keeper_lineno_1; - - goto frame_exception_exit_1; - // End of try: - try_end_1:; - CHECK_OBJECT(tmp_import_from_1__module); - Py_DECREF(tmp_import_from_1__module); - tmp_import_from_1__module = NULL; - { - PyObject *tmp_assign_source_13; - PyObject *tmp_name_name_5; - PyObject *tmp_globals_arg_name_5; - PyObject *tmp_locals_arg_name_5; - PyObject *tmp_fromlist_name_5; - PyObject *tmp_level_name_5; - tmp_name_name_5 = mod_consts[20]; - tmp_globals_arg_name_5 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_5 = Py_None; - tmp_fromlist_name_5 = Py_None; - tmp_level_name_5 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 17; - tmp_assign_source_13 = IMPORT_MODULE5(tmp_name_name_5, tmp_globals_arg_name_5, tmp_locals_arg_name_5, tmp_fromlist_name_5, tmp_level_name_5); - if (tmp_assign_source_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 17; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20], tmp_assign_source_13); - } - { - PyObject *tmp_assign_source_14; - PyObject *tmp_name_name_6; - PyObject *tmp_globals_arg_name_6; - PyObject *tmp_locals_arg_name_6; - PyObject *tmp_fromlist_name_6; - PyObject *tmp_level_name_6; - tmp_name_name_6 = mod_consts[20]; - tmp_globals_arg_name_6 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_6 = Py_None; - tmp_fromlist_name_6 = mod_consts[293]; - tmp_level_name_6 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 18; - tmp_assign_source_14 = IMPORT_MODULE5(tmp_name_name_6, tmp_globals_arg_name_6, tmp_locals_arg_name_6, tmp_fromlist_name_6, tmp_level_name_6); - if (tmp_assign_source_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 18; - - goto frame_exception_exit_1; - } - assert(tmp_import_from_2__module == NULL); - tmp_import_from_2__module = tmp_assign_source_14; - } - // Tried code: - { - PyObject *tmp_assign_source_15; - PyObject *tmp_import_name_from_6; - CHECK_OBJECT(tmp_import_from_2__module); - tmp_import_name_from_6 = tmp_import_from_2__module; - if (PyModule_Check(tmp_import_name_from_6)) { - tmp_assign_source_15 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_6, - (PyObject *)moduledict_models$Qformer, - mod_consts[294], - mod_consts[29] - ); - } else { - tmp_assign_source_15 = IMPORT_NAME(tmp_import_name_from_6, mod_consts[294]); - } - - if (tmp_assign_source_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 18; - - goto try_except_handler_2; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[294], tmp_assign_source_15); - } - { - PyObject *tmp_assign_source_16; - PyObject *tmp_import_name_from_7; - CHECK_OBJECT(tmp_import_from_2__module); - tmp_import_name_from_7 = tmp_import_from_2__module; - if (PyModule_Check(tmp_import_name_from_7)) { - tmp_assign_source_16 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_7, - (PyObject *)moduledict_models$Qformer, - mod_consts[70], - mod_consts[29] - ); - } else { - tmp_assign_source_16 = IMPORT_NAME(tmp_import_name_from_7, mod_consts[70]); - } - - if (tmp_assign_source_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 18; - - goto try_except_handler_2; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[70], tmp_assign_source_16); - } - { - PyObject *tmp_assign_source_17; - PyObject *tmp_import_name_from_8; - CHECK_OBJECT(tmp_import_from_2__module); - tmp_import_name_from_8 = tmp_import_from_2__module; - if (PyModule_Check(tmp_import_name_from_8)) { - tmp_assign_source_17 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_8, - (PyObject *)moduledict_models$Qformer, - mod_consts[68], - mod_consts[29] - ); - } else { - tmp_assign_source_17 = IMPORT_NAME(tmp_import_name_from_8, mod_consts[68]); - } - - if (tmp_assign_source_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 18; - - goto try_except_handler_2; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[68], tmp_assign_source_17); - } - { - PyObject *tmp_assign_source_18; - PyObject *tmp_import_name_from_9; - CHECK_OBJECT(tmp_import_from_2__module); - tmp_import_name_from_9 = tmp_import_from_2__module; - if (PyModule_Check(tmp_import_name_from_9)) { - tmp_assign_source_18 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_9, - (PyObject *)moduledict_models$Qformer, - mod_consts[2], - mod_consts[29] - ); - } else { - tmp_assign_source_18 = IMPORT_NAME(tmp_import_name_from_9, mod_consts[2]); - } - - if (tmp_assign_source_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 18; - - goto try_except_handler_2; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2], tmp_assign_source_18); - } - goto try_end_2; - // Exception handler code: - try_except_handler_2:; - exception_keeper_type_2 = exception_type; - exception_keeper_value_2 = exception_value; - exception_keeper_tb_2 = exception_tb; - exception_keeper_lineno_2 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(tmp_import_from_2__module); - Py_DECREF(tmp_import_from_2__module); - tmp_import_from_2__module = NULL; - // Re-raise. - exception_type = exception_keeper_type_2; - exception_value = exception_keeper_value_2; - exception_tb = exception_keeper_tb_2; - exception_lineno = exception_keeper_lineno_2; - - goto frame_exception_exit_1; - // End of try: - try_end_2:; - CHECK_OBJECT(tmp_import_from_2__module); - Py_DECREF(tmp_import_from_2__module); - tmp_import_from_2__module = NULL; - { - PyObject *tmp_assign_source_19; - PyObject *tmp_name_name_7; - PyObject *tmp_globals_arg_name_7; - PyObject *tmp_locals_arg_name_7; - PyObject *tmp_fromlist_name_7; - PyObject *tmp_level_name_7; - tmp_name_name_7 = mod_consts[295]; - tmp_globals_arg_name_7 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_7 = Py_None; - tmp_fromlist_name_7 = Py_None; - tmp_level_name_7 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 19; - tmp_assign_source_19 = IMPORT_MODULE5(tmp_name_name_7, tmp_globals_arg_name_7, tmp_locals_arg_name_7, tmp_fromlist_name_7, tmp_level_name_7); - if (tmp_assign_source_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 19; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[20], tmp_assign_source_19); - } - { - PyObject *tmp_assign_source_20; - PyObject *tmp_import_name_from_10; - PyObject *tmp_name_name_8; - PyObject *tmp_globals_arg_name_8; - PyObject *tmp_locals_arg_name_8; - PyObject *tmp_fromlist_name_8; - PyObject *tmp_level_name_8; - tmp_name_name_8 = mod_consts[20]; - tmp_globals_arg_name_8 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_8 = Py_None; - tmp_fromlist_name_8 = mod_consts[296]; - tmp_level_name_8 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 20; - tmp_import_name_from_10 = IMPORT_MODULE5(tmp_name_name_8, tmp_globals_arg_name_8, tmp_locals_arg_name_8, tmp_fromlist_name_8, tmp_level_name_8); - if (tmp_import_name_from_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 20; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_10)) { - tmp_assign_source_20 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_10, - (PyObject *)moduledict_models$Qformer, - mod_consts[2], - mod_consts[29] - ); - } else { - tmp_assign_source_20 = IMPORT_NAME(tmp_import_name_from_10, mod_consts[2]); - } - - Py_DECREF(tmp_import_name_from_10); - if (tmp_assign_source_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 20; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2], tmp_assign_source_20); - } - { - PyObject *tmp_assign_source_21; - PyObject *tmp_import_name_from_11; - PyObject *tmp_name_name_9; - PyObject *tmp_globals_arg_name_9; - PyObject *tmp_locals_arg_name_9; - PyObject *tmp_fromlist_name_9; - PyObject *tmp_level_name_9; - tmp_name_name_9 = mod_consts[297]; - tmp_globals_arg_name_9 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_9 = Py_None; - tmp_fromlist_name_9 = mod_consts[298]; - tmp_level_name_9 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 21; - tmp_import_name_from_11 = IMPORT_MODULE5(tmp_name_name_9, tmp_globals_arg_name_9, tmp_locals_arg_name_9, tmp_fromlist_name_9, tmp_level_name_9); - if (tmp_import_name_from_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 21; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_11)) { - tmp_assign_source_21 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_11, - (PyObject *)moduledict_models$Qformer, - mod_consts[247], - mod_consts[29] - ); - } else { - tmp_assign_source_21 = IMPORT_NAME(tmp_import_name_from_11, mod_consts[247]); - } - - Py_DECREF(tmp_import_name_from_11); - if (tmp_assign_source_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 21; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[247], tmp_assign_source_21); - } - { - PyObject *tmp_assign_source_22; - PyObject *tmp_import_name_from_12; - PyObject *tmp_import_name_from_13; - PyObject *tmp_name_name_10; - PyObject *tmp_globals_arg_name_10; - PyObject *tmp_locals_arg_name_10; - PyObject *tmp_fromlist_name_10; - PyObject *tmp_level_name_10; - tmp_name_name_10 = mod_consts[299]; - tmp_globals_arg_name_10 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_10 = Py_None; - tmp_fromlist_name_10 = Py_None; - tmp_level_name_10 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 22; - tmp_import_name_from_13 = IMPORT_MODULE5(tmp_name_name_10, tmp_globals_arg_name_10, tmp_locals_arg_name_10, tmp_fromlist_name_10, tmp_level_name_10); - if (tmp_import_name_from_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 22; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_13)) { - tmp_import_name_from_12 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_13, - (PyObject *)moduledict_models$Qformer, - mod_consts[2], - mod_consts[29] - ); - } else { - tmp_import_name_from_12 = IMPORT_NAME(tmp_import_name_from_13, mod_consts[2]); - } - - Py_DECREF(tmp_import_name_from_13); - if (tmp_import_name_from_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 22; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_12)) { - tmp_assign_source_22 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_12, - (PyObject *)moduledict_models$Qformer, - mod_consts[300], - mod_consts[29] - ); - } else { - tmp_assign_source_22 = IMPORT_NAME(tmp_import_name_from_12, mod_consts[300]); - } - - Py_DECREF(tmp_import_name_from_12); - if (tmp_assign_source_22 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 22; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[301], tmp_assign_source_22); - } - { - PyObject *tmp_assign_source_23; - PyObject *tmp_import_name_from_14; - PyObject *tmp_name_name_11; - PyObject *tmp_globals_arg_name_11; - PyObject *tmp_locals_arg_name_11; - PyObject *tmp_fromlist_name_11; - PyObject *tmp_level_name_11; - tmp_name_name_11 = mod_consts[302]; - tmp_globals_arg_name_11 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_11 = Py_None; - tmp_fromlist_name_11 = mod_consts[303]; - tmp_level_name_11 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 24; - tmp_import_name_from_14 = IMPORT_MODULE5(tmp_name_name_11, tmp_globals_arg_name_11, tmp_locals_arg_name_11, tmp_fromlist_name_11, tmp_level_name_11); - if (tmp_import_name_from_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 24; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_14)) { - tmp_assign_source_23 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_14, - (PyObject *)moduledict_models$Qformer, - mod_consts[105], - mod_consts[29] - ); - } else { - tmp_assign_source_23 = IMPORT_NAME(tmp_import_name_from_14, mod_consts[105]); - } - - Py_DECREF(tmp_import_name_from_14); - if (tmp_assign_source_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 24; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[105], tmp_assign_source_23); - } - { - PyObject *tmp_assign_source_24; - PyObject *tmp_import_name_from_15; - PyObject *tmp_name_name_12; - PyObject *tmp_globals_arg_name_12; - PyObject *tmp_locals_arg_name_12; - PyObject *tmp_fromlist_name_12; - PyObject *tmp_level_name_12; - tmp_name_name_12 = mod_consts[304]; - tmp_globals_arg_name_12 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_12 = Py_None; - tmp_fromlist_name_12 = mod_consts[305]; - tmp_level_name_12 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 25; - tmp_import_name_from_15 = IMPORT_MODULE5(tmp_name_name_12, tmp_globals_arg_name_12, tmp_locals_arg_name_12, tmp_fromlist_name_12, tmp_level_name_12); - if (tmp_import_name_from_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 25; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_15)) { - tmp_assign_source_24 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_15, - (PyObject *)moduledict_models$Qformer, - mod_consts[306], - mod_consts[29] - ); - } else { - tmp_assign_source_24 = IMPORT_NAME(tmp_import_name_from_15, mod_consts[306]); - } - - Py_DECREF(tmp_import_name_from_15); - if (tmp_assign_source_24 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 25; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[306], tmp_assign_source_24); - } - { - PyObject *tmp_assign_source_25; - PyObject *tmp_name_name_13; - PyObject *tmp_globals_arg_name_13; - PyObject *tmp_locals_arg_name_13; - PyObject *tmp_fromlist_name_13; - PyObject *tmp_level_name_13; - tmp_name_name_13 = mod_consts[307]; - tmp_globals_arg_name_13 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_13 = Py_None; - tmp_fromlist_name_13 = mod_consts[308]; - tmp_level_name_13 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 28; - tmp_assign_source_25 = IMPORT_MODULE5(tmp_name_name_13, tmp_globals_arg_name_13, tmp_locals_arg_name_13, tmp_fromlist_name_13, tmp_level_name_13); - if (tmp_assign_source_25 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto frame_exception_exit_1; - } - assert(tmp_import_from_3__module == NULL); - tmp_import_from_3__module = tmp_assign_source_25; - } - // Tried code: - { - PyObject *tmp_assign_source_26; - PyObject *tmp_import_name_from_16; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_16 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_16)) { - tmp_assign_source_26 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_16, - (PyObject *)moduledict_models$Qformer, - mod_consts[160], - mod_consts[29] - ); - } else { - tmp_assign_source_26 = IMPORT_NAME(tmp_import_name_from_16, mod_consts[160]); - } - - if (tmp_assign_source_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[160], tmp_assign_source_26); - } - { - PyObject *tmp_assign_source_27; - PyObject *tmp_import_name_from_17; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_17 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_17)) { - tmp_assign_source_27 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_17, - (PyObject *)moduledict_models$Qformer, - mod_consts[235], - mod_consts[29] - ); - } else { - tmp_assign_source_27 = IMPORT_NAME(tmp_import_name_from_17, mod_consts[235]); - } - - if (tmp_assign_source_27 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[235], tmp_assign_source_27); - } - { - PyObject *tmp_assign_source_28; - PyObject *tmp_import_name_from_18; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_18 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_18)) { - tmp_assign_source_28 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_18, - (PyObject *)moduledict_models$Qformer, - mod_consts[259], - mod_consts[29] - ); - } else { - tmp_assign_source_28 = IMPORT_NAME(tmp_import_name_from_18, mod_consts[259]); - } - - if (tmp_assign_source_28 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[259], tmp_assign_source_28); - } - { - PyObject *tmp_assign_source_29; - PyObject *tmp_import_name_from_19; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_19 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_19)) { - tmp_assign_source_29 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_19, - (PyObject *)moduledict_models$Qformer, - mod_consts[273], - mod_consts[29] - ); - } else { - tmp_assign_source_29 = IMPORT_NAME(tmp_import_name_from_19, mod_consts[273]); - } - - if (tmp_assign_source_29 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[273], tmp_assign_source_29); - } - { - PyObject *tmp_assign_source_30; - PyObject *tmp_import_name_from_20; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_20 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_20)) { - tmp_assign_source_30 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_20, - (PyObject *)moduledict_models$Qformer, - mod_consts[309], - mod_consts[29] - ); - } else { - tmp_assign_source_30 = IMPORT_NAME(tmp_import_name_from_20, mod_consts[309]); - } - - if (tmp_assign_source_30 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[309], tmp_assign_source_30); - } - { - PyObject *tmp_assign_source_31; - PyObject *tmp_import_name_from_21; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_21 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_21)) { - tmp_assign_source_31 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_21, - (PyObject *)moduledict_models$Qformer, - mod_consts[310], - mod_consts[29] - ); - } else { - tmp_assign_source_31 = IMPORT_NAME(tmp_import_name_from_21, mod_consts[310]); - } - - if (tmp_assign_source_31 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[310], tmp_assign_source_31); - } - { - PyObject *tmp_assign_source_32; - PyObject *tmp_import_name_from_22; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_22 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_22)) { - tmp_assign_source_32 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_22, - (PyObject *)moduledict_models$Qformer, - mod_consts[311], - mod_consts[29] - ); - } else { - tmp_assign_source_32 = IMPORT_NAME(tmp_import_name_from_22, mod_consts[311]); - } - - if (tmp_assign_source_32 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[311], tmp_assign_source_32); - } - { - PyObject *tmp_assign_source_33; - PyObject *tmp_import_name_from_23; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_23 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_23)) { - tmp_assign_source_33 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_23, - (PyObject *)moduledict_models$Qformer, - mod_consts[312], - mod_consts[29] - ); - } else { - tmp_assign_source_33 = IMPORT_NAME(tmp_import_name_from_23, mod_consts[312]); - } - - if (tmp_assign_source_33 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[312], tmp_assign_source_33); - } - { - PyObject *tmp_assign_source_34; - PyObject *tmp_import_name_from_24; - CHECK_OBJECT(tmp_import_from_3__module); - tmp_import_name_from_24 = tmp_import_from_3__module; - if (PyModule_Check(tmp_import_name_from_24)) { - tmp_assign_source_34 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_24, - (PyObject *)moduledict_models$Qformer, - mod_consts[313], - mod_consts[29] - ); - } else { - tmp_assign_source_34 = IMPORT_NAME(tmp_import_name_from_24, mod_consts[313]); - } - - if (tmp_assign_source_34 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 28; - - goto try_except_handler_3; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[313], tmp_assign_source_34); - } - goto try_end_3; - // Exception handler code: - try_except_handler_3:; - exception_keeper_type_3 = exception_type; - exception_keeper_value_3 = exception_value; - exception_keeper_tb_3 = exception_tb; - exception_keeper_lineno_3 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(tmp_import_from_3__module); - Py_DECREF(tmp_import_from_3__module); - tmp_import_from_3__module = NULL; - // Re-raise. - exception_type = exception_keeper_type_3; - exception_value = exception_keeper_value_3; - exception_tb = exception_keeper_tb_3; - exception_lineno = exception_keeper_lineno_3; - - goto frame_exception_exit_1; - // End of try: - try_end_3:; - CHECK_OBJECT(tmp_import_from_3__module); - Py_DECREF(tmp_import_from_3__module); - tmp_import_from_3__module = NULL; - { - PyObject *tmp_assign_source_35; - PyObject *tmp_name_name_14; - PyObject *tmp_globals_arg_name_14; - PyObject *tmp_locals_arg_name_14; - PyObject *tmp_fromlist_name_14; - PyObject *tmp_level_name_14; - tmp_name_name_14 = mod_consts[314]; - tmp_globals_arg_name_14 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_14 = Py_None; - tmp_fromlist_name_14 = mod_consts[315]; - tmp_level_name_14 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 39; - tmp_assign_source_35 = IMPORT_MODULE5(tmp_name_name_14, tmp_globals_arg_name_14, tmp_locals_arg_name_14, tmp_fromlist_name_14, tmp_level_name_14); - if (tmp_assign_source_35 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 39; - - goto frame_exception_exit_1; - } - assert(tmp_import_from_4__module == NULL); - tmp_import_from_4__module = tmp_assign_source_35; - } - // Tried code: - { - PyObject *tmp_assign_source_36; - PyObject *tmp_import_name_from_25; - CHECK_OBJECT(tmp_import_from_4__module); - tmp_import_name_from_25 = tmp_import_from_4__module; - if (PyModule_Check(tmp_import_name_from_25)) { - tmp_assign_source_36 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_25, - (PyObject *)moduledict_models$Qformer, - mod_consts[316], - mod_consts[29] - ); - } else { - tmp_assign_source_36 = IMPORT_NAME(tmp_import_name_from_25, mod_consts[316]); - } - - if (tmp_assign_source_36 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 39; - - goto try_except_handler_4; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[316], tmp_assign_source_36); - } - { - PyObject *tmp_assign_source_37; - PyObject *tmp_import_name_from_26; - CHECK_OBJECT(tmp_import_from_4__module); - tmp_import_name_from_26 = tmp_import_from_4__module; - if (PyModule_Check(tmp_import_name_from_26)) { - tmp_assign_source_37 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_26, - (PyObject *)moduledict_models$Qformer, - mod_consts[130], - mod_consts[29] - ); - } else { - tmp_assign_source_37 = IMPORT_NAME(tmp_import_name_from_26, mod_consts[130]); - } - - if (tmp_assign_source_37 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 39; - - goto try_except_handler_4; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[130], tmp_assign_source_37); - } - { - PyObject *tmp_assign_source_38; - PyObject *tmp_import_name_from_27; - CHECK_OBJECT(tmp_import_from_4__module); - tmp_import_name_from_27 = tmp_import_from_4__module; - if (PyModule_Check(tmp_import_name_from_27)) { - tmp_assign_source_38 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_27, - (PyObject *)moduledict_models$Qformer, - mod_consts[97], - mod_consts[29] - ); - } else { - tmp_assign_source_38 = IMPORT_NAME(tmp_import_name_from_27, mod_consts[97]); - } - - if (tmp_assign_source_38 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 39; - - goto try_except_handler_4; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[97], tmp_assign_source_38); - } - { - PyObject *tmp_assign_source_39; - PyObject *tmp_import_name_from_28; - CHECK_OBJECT(tmp_import_from_4__module); - tmp_import_name_from_28 = tmp_import_from_4__module; - if (PyModule_Check(tmp_import_name_from_28)) { - tmp_assign_source_39 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_28, - (PyObject *)moduledict_models$Qformer, - mod_consts[100], - mod_consts[29] - ); - } else { - tmp_assign_source_39 = IMPORT_NAME(tmp_import_name_from_28, mod_consts[100]); - } - - if (tmp_assign_source_39 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 39; - - goto try_except_handler_4; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[100], tmp_assign_source_39); - } - goto try_end_4; - // Exception handler code: - try_except_handler_4:; - exception_keeper_type_4 = exception_type; - exception_keeper_value_4 = exception_value; - exception_keeper_tb_4 = exception_tb; - exception_keeper_lineno_4 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(tmp_import_from_4__module); - Py_DECREF(tmp_import_from_4__module); - tmp_import_from_4__module = NULL; - // Re-raise. - exception_type = exception_keeper_type_4; - exception_value = exception_keeper_value_4; - exception_tb = exception_keeper_tb_4; - exception_lineno = exception_keeper_lineno_4; - - goto frame_exception_exit_1; - // End of try: - try_end_4:; - CHECK_OBJECT(tmp_import_from_4__module); - Py_DECREF(tmp_import_from_4__module); - tmp_import_from_4__module = NULL; - { - PyObject *tmp_assign_source_40; - PyObject *tmp_import_name_from_29; - PyObject *tmp_name_name_15; - PyObject *tmp_globals_arg_name_15; - PyObject *tmp_locals_arg_name_15; - PyObject *tmp_fromlist_name_15; - PyObject *tmp_level_name_15; - tmp_name_name_15 = mod_consts[317]; - tmp_globals_arg_name_15 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_15 = Py_None; - tmp_fromlist_name_15 = mod_consts[318]; - tmp_level_name_15 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 45; - tmp_import_name_from_29 = IMPORT_MODULE5(tmp_name_name_15, tmp_globals_arg_name_15, tmp_locals_arg_name_15, tmp_fromlist_name_15, tmp_level_name_15); - if (tmp_import_name_from_29 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 45; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_29)) { - tmp_assign_source_40 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_29, - (PyObject *)moduledict_models$Qformer, - mod_consts[319], - mod_consts[29] - ); - } else { - tmp_assign_source_40 = IMPORT_NAME(tmp_import_name_from_29, mod_consts[319]); - } - - Py_DECREF(tmp_import_name_from_29); - if (tmp_assign_source_40 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 45; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[319], tmp_assign_source_40); - } - { - PyObject *tmp_assign_source_41; - PyObject *tmp_import_name_from_30; - PyObject *tmp_name_name_16; - PyObject *tmp_globals_arg_name_16; - PyObject *tmp_locals_arg_name_16; - PyObject *tmp_fromlist_name_16; - PyObject *tmp_level_name_16; - tmp_name_name_16 = mod_consts[320]; - tmp_globals_arg_name_16 = (PyObject *)moduledict_models$Qformer; - tmp_locals_arg_name_16 = Py_None; - tmp_fromlist_name_16 = mod_consts[321]; - tmp_level_name_16 = mod_consts[29]; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 46; - tmp_import_name_from_30 = IMPORT_MODULE5(tmp_name_name_16, tmp_globals_arg_name_16, tmp_locals_arg_name_16, tmp_fromlist_name_16, tmp_level_name_16); - if (tmp_import_name_from_30 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 46; - - goto frame_exception_exit_1; - } - if (PyModule_Check(tmp_import_name_from_30)) { - tmp_assign_source_41 = IMPORT_NAME_OR_MODULE( - tmp_import_name_from_30, - (PyObject *)moduledict_models$Qformer, - mod_consts[322], - mod_consts[29] - ); - } else { - tmp_assign_source_41 = IMPORT_NAME(tmp_import_name_from_30, mod_consts[322]); - } - - Py_DECREF(tmp_import_name_from_30); - if (tmp_assign_source_41 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 46; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[322], tmp_assign_source_41); - } - { - PyObject *tmp_assign_source_42; - PyObject *tmp_called_name_1; - PyObject *tmp_expression_name_1; - PyObject *tmp_args_element_name_1; - tmp_expression_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[319]); - - if (unlikely(tmp_expression_name_1 == NULL)) { - tmp_expression_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[319]); - } - - if (tmp_expression_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 48; - - goto frame_exception_exit_1; - } - tmp_called_name_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_1, mod_consts[323]); - if (tmp_called_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 48; - - goto frame_exception_exit_1; - } - tmp_args_element_name_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_args_element_name_1 == NULL)) { - tmp_args_element_name_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_args_element_name_1 == NULL)); - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 48; - tmp_assign_source_42 = CALL_FUNCTION_WITH_SINGLE_ARG(tmp_called_name_1, tmp_args_element_name_1); - Py_DECREF(tmp_called_name_1); - if (tmp_assign_source_42 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 48; - - goto frame_exception_exit_1; - } - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[148], tmp_assign_source_42); - } - // Tried code: - { - PyObject *tmp_assign_source_43; - PyObject *tmp_tuple_element_1; - PyObject *tmp_expression_name_2; - tmp_expression_name_2 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_2 == NULL)) { - tmp_expression_name_2 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_tuple_element_1 = LOOKUP_ATTRIBUTE(tmp_expression_name_2, mod_consts[325]); - if (tmp_tuple_element_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_assign_source_43 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_43, 0, tmp_tuple_element_1); - assert(tmp_class_creation_1__bases_orig == NULL); - tmp_class_creation_1__bases_orig = tmp_assign_source_43; - } - { - PyObject *tmp_assign_source_44; - PyObject *tmp_dircall_arg1_1; - CHECK_OBJECT(tmp_class_creation_1__bases_orig); - tmp_dircall_arg1_1 = tmp_class_creation_1__bases_orig; - Py_INCREF(tmp_dircall_arg1_1); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_1}; - tmp_assign_source_44 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_44 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - assert(tmp_class_creation_1__bases == NULL); - tmp_class_creation_1__bases = tmp_assign_source_44; - } - { - PyObject *tmp_assign_source_45; - tmp_assign_source_45 = PyDict_New(); - assert(tmp_class_creation_1__class_decl_dict == NULL); - tmp_class_creation_1__class_decl_dict = tmp_assign_source_45; - } - { - PyObject *tmp_assign_source_46; - PyObject *tmp_metaclass_name_1; - nuitka_bool tmp_condition_result_1; - PyObject *tmp_key_name_1; - PyObject *tmp_dict_arg_name_1; - PyObject *tmp_dict_arg_name_2; - PyObject *tmp_key_name_2; - nuitka_bool tmp_condition_result_2; - int tmp_truth_name_1; - PyObject *tmp_type_arg_1; - PyObject *tmp_expression_name_3; - PyObject *tmp_subscript_name_1; - PyObject *tmp_bases_name_1; - tmp_key_name_1 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_1__class_decl_dict); - tmp_dict_arg_name_1 = tmp_class_creation_1__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_1, tmp_key_name_1); - assert(!(tmp_res == -1)); - tmp_condition_result_1 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_1 == NUITKA_BOOL_TRUE) { - goto condexpr_true_1; - } else { - goto condexpr_false_1; - } - condexpr_true_1:; - CHECK_OBJECT(tmp_class_creation_1__class_decl_dict); - tmp_dict_arg_name_2 = tmp_class_creation_1__class_decl_dict; - tmp_key_name_2 = mod_consts[326]; - tmp_metaclass_name_1 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_2, tmp_key_name_2); - if (tmp_metaclass_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - goto condexpr_end_1; - condexpr_false_1:; - CHECK_OBJECT(tmp_class_creation_1__bases); - tmp_truth_name_1 = CHECK_IF_TRUE(tmp_class_creation_1__bases); - if (tmp_truth_name_1 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_condition_result_2 = tmp_truth_name_1 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_2 == NUITKA_BOOL_TRUE) { - goto condexpr_true_2; - } else { - goto condexpr_false_2; - } - condexpr_true_2:; - CHECK_OBJECT(tmp_class_creation_1__bases); - tmp_expression_name_3 = tmp_class_creation_1__bases; - tmp_subscript_name_1 = mod_consts[29]; - tmp_type_arg_1 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_3, tmp_subscript_name_1, 0); - if (tmp_type_arg_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_metaclass_name_1 = BUILTIN_TYPE1(tmp_type_arg_1); - Py_DECREF(tmp_type_arg_1); - if (tmp_metaclass_name_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - goto condexpr_end_2; - condexpr_false_2:; - tmp_metaclass_name_1 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_1); - condexpr_end_2:; - condexpr_end_1:; - CHECK_OBJECT(tmp_class_creation_1__bases); - tmp_bases_name_1 = tmp_class_creation_1__bases; - tmp_assign_source_46 = SELECT_METACLASS(tmp_metaclass_name_1, tmp_bases_name_1); - Py_DECREF(tmp_metaclass_name_1); - if (tmp_assign_source_46 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - assert(tmp_class_creation_1__metaclass == NULL); - tmp_class_creation_1__metaclass = tmp_assign_source_46; - } - { - nuitka_bool tmp_condition_result_3; - PyObject *tmp_key_name_3; - PyObject *tmp_dict_arg_name_3; - tmp_key_name_3 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_1__class_decl_dict); - tmp_dict_arg_name_3 = tmp_class_creation_1__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_3, tmp_key_name_3); - assert(!(tmp_res == -1)); - tmp_condition_result_3 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_3 == NUITKA_BOOL_TRUE) { - goto branch_yes_1; - } else { - goto branch_no_1; - } - } - branch_yes_1:; - CHECK_OBJECT(tmp_class_creation_1__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_1__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - branch_no_1:; - { - nuitka_bool tmp_condition_result_4; - PyObject *tmp_expression_name_4; - CHECK_OBJECT(tmp_class_creation_1__metaclass); - tmp_expression_name_4 = tmp_class_creation_1__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_4, mod_consts[327]); - tmp_condition_result_4 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_4 == NUITKA_BOOL_TRUE) { - goto branch_yes_2; - } else { - goto branch_no_2; - } - } - branch_yes_2:; - { - PyObject *tmp_assign_source_47; - PyObject *tmp_called_name_2; - PyObject *tmp_expression_name_5; - PyObject *tmp_args_name_1; - PyObject *tmp_tuple_element_2; - PyObject *tmp_kwargs_name_1; - CHECK_OBJECT(tmp_class_creation_1__metaclass); - tmp_expression_name_5 = tmp_class_creation_1__metaclass; - tmp_called_name_2 = LOOKUP_ATTRIBUTE(tmp_expression_name_5, mod_consts[327]); - if (tmp_called_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_tuple_element_2 = mod_consts[193]; - tmp_args_name_1 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_1, 0, tmp_tuple_element_2); - CHECK_OBJECT(tmp_class_creation_1__bases); - tmp_tuple_element_2 = tmp_class_creation_1__bases; - PyTuple_SET_ITEM0(tmp_args_name_1, 1, tmp_tuple_element_2); - CHECK_OBJECT(tmp_class_creation_1__class_decl_dict); - tmp_kwargs_name_1 = tmp_class_creation_1__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 51; - tmp_assign_source_47 = CALL_FUNCTION(tmp_called_name_2, tmp_args_name_1, tmp_kwargs_name_1); - Py_DECREF(tmp_called_name_2); - Py_DECREF(tmp_args_name_1); - if (tmp_assign_source_47 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - assert(tmp_class_creation_1__prepared == NULL); - tmp_class_creation_1__prepared = tmp_assign_source_47; - } - { - nuitka_bool tmp_condition_result_5; - PyObject *tmp_operand_name_1; - PyObject *tmp_expression_name_6; - CHECK_OBJECT(tmp_class_creation_1__prepared); - tmp_expression_name_6 = tmp_class_creation_1__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_6, mod_consts[328]); - tmp_operand_name_1 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_1); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_condition_result_5 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_5 == NUITKA_BOOL_TRUE) { - goto branch_yes_3; - } else { - goto branch_no_3; - } - } - branch_yes_3:; - { - PyObject *tmp_raise_type_1; - PyObject *tmp_raise_value_1; - PyObject *tmp_left_name_1; - PyObject *tmp_right_name_1; - PyObject *tmp_tuple_element_3; - PyObject *tmp_getattr_target_1; - PyObject *tmp_getattr_attr_1; - PyObject *tmp_getattr_default_1; - tmp_raise_type_1 = PyExc_TypeError; - tmp_left_name_1 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_1__metaclass); - tmp_getattr_target_1 = tmp_class_creation_1__metaclass; - tmp_getattr_attr_1 = mod_consts[324]; - tmp_getattr_default_1 = mod_consts[330]; - tmp_tuple_element_3 = BUILTIN_GETATTR(tmp_getattr_target_1, tmp_getattr_attr_1, tmp_getattr_default_1); - if (tmp_tuple_element_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - tmp_right_name_1 = PyTuple_New(2); - { - PyObject *tmp_expression_name_7; - PyObject *tmp_type_arg_2; - PyTuple_SET_ITEM(tmp_right_name_1, 0, tmp_tuple_element_3); - CHECK_OBJECT(tmp_class_creation_1__prepared); - tmp_type_arg_2 = tmp_class_creation_1__prepared; - tmp_expression_name_7 = BUILTIN_TYPE1(tmp_type_arg_2); - assert(!(tmp_expression_name_7 == NULL)); - tmp_tuple_element_3 = LOOKUP_ATTRIBUTE(tmp_expression_name_7, mod_consts[324]); - Py_DECREF(tmp_expression_name_7); - if (tmp_tuple_element_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto tuple_build_exception_1; - } - PyTuple_SET_ITEM(tmp_right_name_1, 1, tmp_tuple_element_3); - } - goto tuple_build_noexception_1; - // Exception handling pass through code for tuple_build: - tuple_build_exception_1:; - Py_DECREF(tmp_right_name_1); - goto try_except_handler_5; - // Finished with no exception for tuple_build: - tuple_build_noexception_1:; - tmp_raise_value_1 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_1, tmp_right_name_1); - Py_DECREF(tmp_right_name_1); - if (tmp_raise_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_5; - } - exception_type = tmp_raise_type_1; - Py_INCREF(tmp_raise_type_1); - exception_value = tmp_raise_value_1; - exception_lineno = 51; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_5; - } - branch_no_3:; - goto branch_end_2; - branch_no_2:; - { - PyObject *tmp_assign_source_48; - tmp_assign_source_48 = PyDict_New(); - assert(tmp_class_creation_1__prepared == NULL); - tmp_class_creation_1__prepared = tmp_assign_source_48; - } - branch_end_2:; - { - PyObject *tmp_assign_source_49; - { - PyObject *tmp_set_locals_1; - CHECK_OBJECT(tmp_class_creation_1__prepared); - tmp_set_locals_1 = tmp_class_creation_1__prepared; - locals_models$Qformer$$$class__1_BertEmbeddings_51 = tmp_set_locals_1; - Py_INCREF(tmp_set_locals_1); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__1_BertEmbeddings_51, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_7; - } - tmp_dictset_value = mod_consts[332]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__1_BertEmbeddings_51, mod_consts[276], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_7; - } - tmp_dictset_value = mod_consts[193]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__1_BertEmbeddings_51, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_7; - } - if (isFrameUnusable(cache_frame_0c0a0597d4b4257046a86687ff948770_2)) { - Py_XDECREF(cache_frame_0c0a0597d4b4257046a86687ff948770_2); - -#if _DEBUG_REFCOUNTS - if (cache_frame_0c0a0597d4b4257046a86687ff948770_2 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_0c0a0597d4b4257046a86687ff948770_2 = MAKE_FUNCTION_FRAME(codeobj_0c0a0597d4b4257046a86687ff948770, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_0c0a0597d4b4257046a86687ff948770_2->m_type_description == NULL); - frame_0c0a0597d4b4257046a86687ff948770_2 = cache_frame_0c0a0597d4b4257046a86687ff948770_2; - - // Push the new frame as the currently active one. - pushFrameStack(frame_0c0a0597d4b4257046a86687ff948770_2); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_0c0a0597d4b4257046a86687ff948770_2) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_1[1]; - - tmp_closure_1[0] = outline_0_var___class__; - Py_INCREF(tmp_closure_1[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__1___init__(tmp_closure_1); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__1_BertEmbeddings_51, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 54; - type_description_2 = "c"; - goto frame_exception_exit_2; - } - } - { - PyObject *tmp_defaults_1; - tmp_defaults_1 = mod_consts[335]; - Py_INCREF(tmp_defaults_1); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__2_forward(tmp_defaults_1); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__1_BertEmbeddings_51, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 78; - type_description_2 = "c"; - goto frame_exception_exit_2; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0c0a0597d4b4257046a86687ff948770_2); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_1; - - frame_exception_exit_2:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_0c0a0597d4b4257046a86687ff948770_2); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_0c0a0597d4b4257046a86687ff948770_2, exception_lineno); - } else if (exception_tb->tb_frame != &frame_0c0a0597d4b4257046a86687ff948770_2->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_0c0a0597d4b4257046a86687ff948770_2, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_0c0a0597d4b4257046a86687ff948770_2, - type_description_2, - outline_0_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_0c0a0597d4b4257046a86687ff948770_2 == cache_frame_0c0a0597d4b4257046a86687ff948770_2) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_0c0a0597d4b4257046a86687ff948770_2); - cache_frame_0c0a0597d4b4257046a86687ff948770_2 = NULL; - } - - assertFrameObject(frame_0c0a0597d4b4257046a86687ff948770_2); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_1; - - frame_no_exception_1:; - goto skip_nested_handling_1; - nested_frame_exit_1:; - - goto try_except_handler_7; - skip_nested_handling_1:; - { - nuitka_bool tmp_condition_result_6; - PyObject *tmp_compexpr_left_1; - PyObject *tmp_compexpr_right_1; - CHECK_OBJECT(tmp_class_creation_1__bases); - tmp_compexpr_left_1 = tmp_class_creation_1__bases; - CHECK_OBJECT(tmp_class_creation_1__bases_orig); - tmp_compexpr_right_1 = tmp_class_creation_1__bases_orig; - tmp_condition_result_6 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_1, tmp_compexpr_right_1); - if (tmp_condition_result_6 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_7; - } - if (tmp_condition_result_6 == NUITKA_BOOL_TRUE) { - goto branch_yes_4; - } else { - goto branch_no_4; - } - assert(tmp_condition_result_6 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_4:; - CHECK_OBJECT(tmp_class_creation_1__bases_orig); - tmp_dictset_value = tmp_class_creation_1__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__1_BertEmbeddings_51, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_7; - } - branch_no_4:; - { - PyObject *tmp_assign_source_50; - PyObject *tmp_called_name_3; - PyObject *tmp_args_name_2; - PyObject *tmp_tuple_element_4; - PyObject *tmp_kwargs_name_2; - CHECK_OBJECT(tmp_class_creation_1__metaclass); - tmp_called_name_3 = tmp_class_creation_1__metaclass; - tmp_tuple_element_4 = mod_consts[193]; - tmp_args_name_2 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_2, 0, tmp_tuple_element_4); - CHECK_OBJECT(tmp_class_creation_1__bases); - tmp_tuple_element_4 = tmp_class_creation_1__bases; - PyTuple_SET_ITEM0(tmp_args_name_2, 1, tmp_tuple_element_4); - tmp_tuple_element_4 = locals_models$Qformer$$$class__1_BertEmbeddings_51; - PyTuple_SET_ITEM0(tmp_args_name_2, 2, tmp_tuple_element_4); - CHECK_OBJECT(tmp_class_creation_1__class_decl_dict); - tmp_kwargs_name_2 = tmp_class_creation_1__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 51; - tmp_assign_source_50 = CALL_FUNCTION(tmp_called_name_3, tmp_args_name_2, tmp_kwargs_name_2); - Py_DECREF(tmp_args_name_2); - if (tmp_assign_source_50 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 51; - - goto try_except_handler_7; - } - { - PyObject *old = Nuitka_Cell_GET(outline_0_var___class__); - PyCell_SET(outline_0_var___class__, tmp_assign_source_50); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_0_var___class__)); - tmp_assign_source_49 = Nuitka_Cell_GET(outline_0_var___class__); - Py_INCREF(tmp_assign_source_49); - goto try_return_handler_7; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_7:; - Py_DECREF(locals_models$Qformer$$$class__1_BertEmbeddings_51); - locals_models$Qformer$$$class__1_BertEmbeddings_51 = NULL; - goto try_return_handler_6; - // Exception handler code: - try_except_handler_7:; - exception_keeper_type_5 = exception_type; - exception_keeper_value_5 = exception_value; - exception_keeper_tb_5 = exception_tb; - exception_keeper_lineno_5 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__1_BertEmbeddings_51); - locals_models$Qformer$$$class__1_BertEmbeddings_51 = NULL; - // Re-raise. - exception_type = exception_keeper_type_5; - exception_value = exception_keeper_value_5; - exception_tb = exception_keeper_tb_5; - exception_lineno = exception_keeper_lineno_5; - - goto try_except_handler_6; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_6:; - CHECK_OBJECT(outline_0_var___class__); - Py_DECREF(outline_0_var___class__); - outline_0_var___class__ = NULL; - goto outline_result_1; - // Exception handler code: - try_except_handler_6:; - exception_keeper_type_6 = exception_type; - exception_keeper_value_6 = exception_value; - exception_keeper_tb_6 = exception_tb; - exception_keeper_lineno_6 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_0_var___class__); - Py_DECREF(outline_0_var___class__); - outline_0_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_6; - exception_value = exception_keeper_value_6; - exception_tb = exception_keeper_tb_6; - exception_lineno = exception_keeper_lineno_6; - - goto outline_exception_1; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_1:; - exception_lineno = 51; - goto try_except_handler_5; - outline_result_1:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[193], tmp_assign_source_49); - } - goto try_end_5; - // Exception handler code: - try_except_handler_5:; - exception_keeper_type_7 = exception_type; - exception_keeper_value_7 = exception_value; - exception_keeper_tb_7 = exception_tb; - exception_keeper_lineno_7 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_1__bases_orig); - tmp_class_creation_1__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_1__bases); - tmp_class_creation_1__bases = NULL; - Py_XDECREF(tmp_class_creation_1__class_decl_dict); - tmp_class_creation_1__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_1__metaclass); - tmp_class_creation_1__metaclass = NULL; - Py_XDECREF(tmp_class_creation_1__prepared); - tmp_class_creation_1__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_7; - exception_value = exception_keeper_value_7; - exception_tb = exception_keeper_tb_7; - exception_lineno = exception_keeper_lineno_7; - - goto frame_exception_exit_1; - // End of try: - try_end_5:; - CHECK_OBJECT(tmp_class_creation_1__bases_orig); - Py_DECREF(tmp_class_creation_1__bases_orig); - tmp_class_creation_1__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_1__bases); - tmp_class_creation_1__bases = NULL; - Py_XDECREF(tmp_class_creation_1__class_decl_dict); - tmp_class_creation_1__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_1__metaclass); - tmp_class_creation_1__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_1__prepared); - Py_DECREF(tmp_class_creation_1__prepared); - tmp_class_creation_1__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_51; - PyObject *tmp_tuple_element_5; - PyObject *tmp_expression_name_8; - tmp_expression_name_8 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_8 == NULL)) { - tmp_expression_name_8 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_tuple_element_5 = LOOKUP_ATTRIBUTE(tmp_expression_name_8, mod_consts[325]); - if (tmp_tuple_element_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_assign_source_51 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_51, 0, tmp_tuple_element_5); - assert(tmp_class_creation_2__bases_orig == NULL); - tmp_class_creation_2__bases_orig = tmp_assign_source_51; - } - { - PyObject *tmp_assign_source_52; - PyObject *tmp_dircall_arg1_2; - CHECK_OBJECT(tmp_class_creation_2__bases_orig); - tmp_dircall_arg1_2 = tmp_class_creation_2__bases_orig; - Py_INCREF(tmp_dircall_arg1_2); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_2}; - tmp_assign_source_52 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_52 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - assert(tmp_class_creation_2__bases == NULL); - tmp_class_creation_2__bases = tmp_assign_source_52; - } - { - PyObject *tmp_assign_source_53; - tmp_assign_source_53 = PyDict_New(); - assert(tmp_class_creation_2__class_decl_dict == NULL); - tmp_class_creation_2__class_decl_dict = tmp_assign_source_53; - } - { - PyObject *tmp_assign_source_54; - PyObject *tmp_metaclass_name_2; - nuitka_bool tmp_condition_result_7; - PyObject *tmp_key_name_4; - PyObject *tmp_dict_arg_name_4; - PyObject *tmp_dict_arg_name_5; - PyObject *tmp_key_name_5; - nuitka_bool tmp_condition_result_8; - int tmp_truth_name_2; - PyObject *tmp_type_arg_3; - PyObject *tmp_expression_name_9; - PyObject *tmp_subscript_name_2; - PyObject *tmp_bases_name_2; - tmp_key_name_4 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_2__class_decl_dict); - tmp_dict_arg_name_4 = tmp_class_creation_2__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_4, tmp_key_name_4); - assert(!(tmp_res == -1)); - tmp_condition_result_7 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_7 == NUITKA_BOOL_TRUE) { - goto condexpr_true_3; - } else { - goto condexpr_false_3; - } - condexpr_true_3:; - CHECK_OBJECT(tmp_class_creation_2__class_decl_dict); - tmp_dict_arg_name_5 = tmp_class_creation_2__class_decl_dict; - tmp_key_name_5 = mod_consts[326]; - tmp_metaclass_name_2 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_5, tmp_key_name_5); - if (tmp_metaclass_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - goto condexpr_end_3; - condexpr_false_3:; - CHECK_OBJECT(tmp_class_creation_2__bases); - tmp_truth_name_2 = CHECK_IF_TRUE(tmp_class_creation_2__bases); - if (tmp_truth_name_2 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_condition_result_8 = tmp_truth_name_2 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_8 == NUITKA_BOOL_TRUE) { - goto condexpr_true_4; - } else { - goto condexpr_false_4; - } - condexpr_true_4:; - CHECK_OBJECT(tmp_class_creation_2__bases); - tmp_expression_name_9 = tmp_class_creation_2__bases; - tmp_subscript_name_2 = mod_consts[29]; - tmp_type_arg_3 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_9, tmp_subscript_name_2, 0); - if (tmp_type_arg_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_metaclass_name_2 = BUILTIN_TYPE1(tmp_type_arg_3); - Py_DECREF(tmp_type_arg_3); - if (tmp_metaclass_name_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - goto condexpr_end_4; - condexpr_false_4:; - tmp_metaclass_name_2 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_2); - condexpr_end_4:; - condexpr_end_3:; - CHECK_OBJECT(tmp_class_creation_2__bases); - tmp_bases_name_2 = tmp_class_creation_2__bases; - tmp_assign_source_54 = SELECT_METACLASS(tmp_metaclass_name_2, tmp_bases_name_2); - Py_DECREF(tmp_metaclass_name_2); - if (tmp_assign_source_54 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - assert(tmp_class_creation_2__metaclass == NULL); - tmp_class_creation_2__metaclass = tmp_assign_source_54; - } - { - nuitka_bool tmp_condition_result_9; - PyObject *tmp_key_name_6; - PyObject *tmp_dict_arg_name_6; - tmp_key_name_6 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_2__class_decl_dict); - tmp_dict_arg_name_6 = tmp_class_creation_2__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_6, tmp_key_name_6); - assert(!(tmp_res == -1)); - tmp_condition_result_9 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_9 == NUITKA_BOOL_TRUE) { - goto branch_yes_5; - } else { - goto branch_no_5; - } - } - branch_yes_5:; - CHECK_OBJECT(tmp_class_creation_2__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_2__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - branch_no_5:; - { - nuitka_bool tmp_condition_result_10; - PyObject *tmp_expression_name_10; - CHECK_OBJECT(tmp_class_creation_2__metaclass); - tmp_expression_name_10 = tmp_class_creation_2__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_10, mod_consts[327]); - tmp_condition_result_10 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_10 == NUITKA_BOOL_TRUE) { - goto branch_yes_6; - } else { - goto branch_no_6; - } - } - branch_yes_6:; - { - PyObject *tmp_assign_source_55; - PyObject *tmp_called_name_4; - PyObject *tmp_expression_name_11; - PyObject *tmp_args_name_3; - PyObject *tmp_tuple_element_6; - PyObject *tmp_kwargs_name_3; - CHECK_OBJECT(tmp_class_creation_2__metaclass); - tmp_expression_name_11 = tmp_class_creation_2__metaclass; - tmp_called_name_4 = LOOKUP_ATTRIBUTE(tmp_expression_name_11, mod_consts[327]); - if (tmp_called_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_tuple_element_6 = mod_consts[93]; - tmp_args_name_3 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_3, 0, tmp_tuple_element_6); - CHECK_OBJECT(tmp_class_creation_2__bases); - tmp_tuple_element_6 = tmp_class_creation_2__bases; - PyTuple_SET_ITEM0(tmp_args_name_3, 1, tmp_tuple_element_6); - CHECK_OBJECT(tmp_class_creation_2__class_decl_dict); - tmp_kwargs_name_3 = tmp_class_creation_2__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 111; - tmp_assign_source_55 = CALL_FUNCTION(tmp_called_name_4, tmp_args_name_3, tmp_kwargs_name_3); - Py_DECREF(tmp_called_name_4); - Py_DECREF(tmp_args_name_3); - if (tmp_assign_source_55 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - assert(tmp_class_creation_2__prepared == NULL); - tmp_class_creation_2__prepared = tmp_assign_source_55; - } - { - nuitka_bool tmp_condition_result_11; - PyObject *tmp_operand_name_2; - PyObject *tmp_expression_name_12; - CHECK_OBJECT(tmp_class_creation_2__prepared); - tmp_expression_name_12 = tmp_class_creation_2__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_12, mod_consts[328]); - tmp_operand_name_2 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_2); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_condition_result_11 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_11 == NUITKA_BOOL_TRUE) { - goto branch_yes_7; - } else { - goto branch_no_7; - } - } - branch_yes_7:; - { - PyObject *tmp_raise_type_2; - PyObject *tmp_raise_value_2; - PyObject *tmp_left_name_2; - PyObject *tmp_right_name_2; - PyObject *tmp_tuple_element_7; - PyObject *tmp_getattr_target_2; - PyObject *tmp_getattr_attr_2; - PyObject *tmp_getattr_default_2; - tmp_raise_type_2 = PyExc_TypeError; - tmp_left_name_2 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_2__metaclass); - tmp_getattr_target_2 = tmp_class_creation_2__metaclass; - tmp_getattr_attr_2 = mod_consts[324]; - tmp_getattr_default_2 = mod_consts[330]; - tmp_tuple_element_7 = BUILTIN_GETATTR(tmp_getattr_target_2, tmp_getattr_attr_2, tmp_getattr_default_2); - if (tmp_tuple_element_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - tmp_right_name_2 = PyTuple_New(2); - { - PyObject *tmp_expression_name_13; - PyObject *tmp_type_arg_4; - PyTuple_SET_ITEM(tmp_right_name_2, 0, tmp_tuple_element_7); - CHECK_OBJECT(tmp_class_creation_2__prepared); - tmp_type_arg_4 = tmp_class_creation_2__prepared; - tmp_expression_name_13 = BUILTIN_TYPE1(tmp_type_arg_4); - assert(!(tmp_expression_name_13 == NULL)); - tmp_tuple_element_7 = LOOKUP_ATTRIBUTE(tmp_expression_name_13, mod_consts[324]); - Py_DECREF(tmp_expression_name_13); - if (tmp_tuple_element_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto tuple_build_exception_2; - } - PyTuple_SET_ITEM(tmp_right_name_2, 1, tmp_tuple_element_7); - } - goto tuple_build_noexception_2; - // Exception handling pass through code for tuple_build: - tuple_build_exception_2:; - Py_DECREF(tmp_right_name_2); - goto try_except_handler_8; - // Finished with no exception for tuple_build: - tuple_build_noexception_2:; - tmp_raise_value_2 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_2, tmp_right_name_2); - Py_DECREF(tmp_right_name_2); - if (tmp_raise_value_2 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_8; - } - exception_type = tmp_raise_type_2; - Py_INCREF(tmp_raise_type_2); - exception_value = tmp_raise_value_2; - exception_lineno = 111; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_8; - } - branch_no_7:; - goto branch_end_6; - branch_no_6:; - { - PyObject *tmp_assign_source_56; - tmp_assign_source_56 = PyDict_New(); - assert(tmp_class_creation_2__prepared == NULL); - tmp_class_creation_2__prepared = tmp_assign_source_56; - } - branch_end_6:; - { - PyObject *tmp_assign_source_57; - { - PyObject *tmp_set_locals_2; - CHECK_OBJECT(tmp_class_creation_2__prepared); - tmp_set_locals_2 = tmp_class_creation_2__prepared; - locals_models$Qformer$$$class__2_BertSelfAttention_111 = tmp_set_locals_2; - Py_INCREF(tmp_set_locals_2); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_10; - } - tmp_dictset_value = mod_consts[93]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_10; - } - if (isFrameUnusable(cache_frame_39fcb37e2c2b36c20e772de986f100d1_3)) { - Py_XDECREF(cache_frame_39fcb37e2c2b36c20e772de986f100d1_3); - -#if _DEBUG_REFCOUNTS - if (cache_frame_39fcb37e2c2b36c20e772de986f100d1_3 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_39fcb37e2c2b36c20e772de986f100d1_3 = MAKE_FUNCTION_FRAME(codeobj_39fcb37e2c2b36c20e772de986f100d1, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_39fcb37e2c2b36c20e772de986f100d1_3->m_type_description == NULL); - frame_39fcb37e2c2b36c20e772de986f100d1_3 = cache_frame_39fcb37e2c2b36c20e772de986f100d1_3; - - // Push the new frame as the currently active one. - pushFrameStack(frame_39fcb37e2c2b36c20e772de986f100d1_3); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_39fcb37e2c2b36c20e772de986f100d1_3) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_2[1]; - - tmp_closure_2[0] = outline_1_var___class__; - Py_INCREF(tmp_closure_2[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__3___init__(tmp_closure_2); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 112; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__4_save_attn_gradients(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[88], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 149; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__5_get_attn_gradients(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[341], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 152; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__6_save_attention_map(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[85], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 155; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__7_get_attention_map(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[344], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 158; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__8_transpose_for_scores(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[59], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 161; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - { - PyObject *tmp_defaults_2; - tmp_defaults_2 = mod_consts[347]; - Py_INCREF(tmp_defaults_2); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__9_forward(tmp_defaults_2); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 169; - type_description_2 = "c"; - goto frame_exception_exit_3; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_39fcb37e2c2b36c20e772de986f100d1_3); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_2; - - frame_exception_exit_3:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_39fcb37e2c2b36c20e772de986f100d1_3); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_39fcb37e2c2b36c20e772de986f100d1_3, exception_lineno); - } else if (exception_tb->tb_frame != &frame_39fcb37e2c2b36c20e772de986f100d1_3->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_39fcb37e2c2b36c20e772de986f100d1_3, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_39fcb37e2c2b36c20e772de986f100d1_3, - type_description_2, - outline_1_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_39fcb37e2c2b36c20e772de986f100d1_3 == cache_frame_39fcb37e2c2b36c20e772de986f100d1_3) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_39fcb37e2c2b36c20e772de986f100d1_3); - cache_frame_39fcb37e2c2b36c20e772de986f100d1_3 = NULL; - } - - assertFrameObject(frame_39fcb37e2c2b36c20e772de986f100d1_3); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_2; - - frame_no_exception_2:; - goto skip_nested_handling_2; - nested_frame_exit_2:; - - goto try_except_handler_10; - skip_nested_handling_2:; - { - nuitka_bool tmp_condition_result_12; - PyObject *tmp_compexpr_left_2; - PyObject *tmp_compexpr_right_2; - CHECK_OBJECT(tmp_class_creation_2__bases); - tmp_compexpr_left_2 = tmp_class_creation_2__bases; - CHECK_OBJECT(tmp_class_creation_2__bases_orig); - tmp_compexpr_right_2 = tmp_class_creation_2__bases_orig; - tmp_condition_result_12 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_2, tmp_compexpr_right_2); - if (tmp_condition_result_12 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_10; - } - if (tmp_condition_result_12 == NUITKA_BOOL_TRUE) { - goto branch_yes_8; - } else { - goto branch_no_8; - } - assert(tmp_condition_result_12 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_8:; - CHECK_OBJECT(tmp_class_creation_2__bases_orig); - tmp_dictset_value = tmp_class_creation_2__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__2_BertSelfAttention_111, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_10; - } - branch_no_8:; - { - PyObject *tmp_assign_source_58; - PyObject *tmp_called_name_5; - PyObject *tmp_args_name_4; - PyObject *tmp_tuple_element_8; - PyObject *tmp_kwargs_name_4; - CHECK_OBJECT(tmp_class_creation_2__metaclass); - tmp_called_name_5 = tmp_class_creation_2__metaclass; - tmp_tuple_element_8 = mod_consts[93]; - tmp_args_name_4 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_4, 0, tmp_tuple_element_8); - CHECK_OBJECT(tmp_class_creation_2__bases); - tmp_tuple_element_8 = tmp_class_creation_2__bases; - PyTuple_SET_ITEM0(tmp_args_name_4, 1, tmp_tuple_element_8); - tmp_tuple_element_8 = locals_models$Qformer$$$class__2_BertSelfAttention_111; - PyTuple_SET_ITEM0(tmp_args_name_4, 2, tmp_tuple_element_8); - CHECK_OBJECT(tmp_class_creation_2__class_decl_dict); - tmp_kwargs_name_4 = tmp_class_creation_2__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 111; - tmp_assign_source_58 = CALL_FUNCTION(tmp_called_name_5, tmp_args_name_4, tmp_kwargs_name_4); - Py_DECREF(tmp_args_name_4); - if (tmp_assign_source_58 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 111; - - goto try_except_handler_10; - } - { - PyObject *old = Nuitka_Cell_GET(outline_1_var___class__); - PyCell_SET(outline_1_var___class__, tmp_assign_source_58); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_1_var___class__)); - tmp_assign_source_57 = Nuitka_Cell_GET(outline_1_var___class__); - Py_INCREF(tmp_assign_source_57); - goto try_return_handler_10; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_10:; - Py_DECREF(locals_models$Qformer$$$class__2_BertSelfAttention_111); - locals_models$Qformer$$$class__2_BertSelfAttention_111 = NULL; - goto try_return_handler_9; - // Exception handler code: - try_except_handler_10:; - exception_keeper_type_8 = exception_type; - exception_keeper_value_8 = exception_value; - exception_keeper_tb_8 = exception_tb; - exception_keeper_lineno_8 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__2_BertSelfAttention_111); - locals_models$Qformer$$$class__2_BertSelfAttention_111 = NULL; - // Re-raise. - exception_type = exception_keeper_type_8; - exception_value = exception_keeper_value_8; - exception_tb = exception_keeper_tb_8; - exception_lineno = exception_keeper_lineno_8; - - goto try_except_handler_9; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_9:; - CHECK_OBJECT(outline_1_var___class__); - Py_DECREF(outline_1_var___class__); - outline_1_var___class__ = NULL; - goto outline_result_2; - // Exception handler code: - try_except_handler_9:; - exception_keeper_type_9 = exception_type; - exception_keeper_value_9 = exception_value; - exception_keeper_tb_9 = exception_tb; - exception_keeper_lineno_9 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_1_var___class__); - Py_DECREF(outline_1_var___class__); - outline_1_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_9; - exception_value = exception_keeper_value_9; - exception_tb = exception_keeper_tb_9; - exception_lineno = exception_keeper_lineno_9; - - goto outline_exception_2; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_2:; - exception_lineno = 111; - goto try_except_handler_8; - outline_result_2:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[93], tmp_assign_source_57); - } - goto try_end_6; - // Exception handler code: - try_except_handler_8:; - exception_keeper_type_10 = exception_type; - exception_keeper_value_10 = exception_value; - exception_keeper_tb_10 = exception_tb; - exception_keeper_lineno_10 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_2__bases_orig); - tmp_class_creation_2__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_2__bases); - tmp_class_creation_2__bases = NULL; - Py_XDECREF(tmp_class_creation_2__class_decl_dict); - tmp_class_creation_2__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_2__metaclass); - tmp_class_creation_2__metaclass = NULL; - Py_XDECREF(tmp_class_creation_2__prepared); - tmp_class_creation_2__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_10; - exception_value = exception_keeper_value_10; - exception_tb = exception_keeper_tb_10; - exception_lineno = exception_keeper_lineno_10; - - goto frame_exception_exit_1; - // End of try: - try_end_6:; - CHECK_OBJECT(tmp_class_creation_2__bases_orig); - Py_DECREF(tmp_class_creation_2__bases_orig); - tmp_class_creation_2__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_2__bases); - tmp_class_creation_2__bases = NULL; - Py_XDECREF(tmp_class_creation_2__class_decl_dict); - tmp_class_creation_2__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_2__metaclass); - tmp_class_creation_2__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_2__prepared); - Py_DECREF(tmp_class_creation_2__prepared); - tmp_class_creation_2__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_59; - PyObject *tmp_tuple_element_9; - PyObject *tmp_expression_name_14; - tmp_expression_name_14 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_14 == NULL)) { - tmp_expression_name_14 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_tuple_element_9 = LOOKUP_ATTRIBUTE(tmp_expression_name_14, mod_consts[325]); - if (tmp_tuple_element_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_assign_source_59 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_59, 0, tmp_tuple_element_9); - assert(tmp_class_creation_3__bases_orig == NULL); - tmp_class_creation_3__bases_orig = tmp_assign_source_59; - } - { - PyObject *tmp_assign_source_60; - PyObject *tmp_dircall_arg1_3; - CHECK_OBJECT(tmp_class_creation_3__bases_orig); - tmp_dircall_arg1_3 = tmp_class_creation_3__bases_orig; - Py_INCREF(tmp_dircall_arg1_3); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_3}; - tmp_assign_source_60 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_60 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - assert(tmp_class_creation_3__bases == NULL); - tmp_class_creation_3__bases = tmp_assign_source_60; - } - { - PyObject *tmp_assign_source_61; - tmp_assign_source_61 = PyDict_New(); - assert(tmp_class_creation_3__class_decl_dict == NULL); - tmp_class_creation_3__class_decl_dict = tmp_assign_source_61; - } - { - PyObject *tmp_assign_source_62; - PyObject *tmp_metaclass_name_3; - nuitka_bool tmp_condition_result_13; - PyObject *tmp_key_name_7; - PyObject *tmp_dict_arg_name_7; - PyObject *tmp_dict_arg_name_8; - PyObject *tmp_key_name_8; - nuitka_bool tmp_condition_result_14; - int tmp_truth_name_3; - PyObject *tmp_type_arg_5; - PyObject *tmp_expression_name_15; - PyObject *tmp_subscript_name_3; - PyObject *tmp_bases_name_3; - tmp_key_name_7 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_3__class_decl_dict); - tmp_dict_arg_name_7 = tmp_class_creation_3__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_7, tmp_key_name_7); - assert(!(tmp_res == -1)); - tmp_condition_result_13 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_13 == NUITKA_BOOL_TRUE) { - goto condexpr_true_5; - } else { - goto condexpr_false_5; - } - condexpr_true_5:; - CHECK_OBJECT(tmp_class_creation_3__class_decl_dict); - tmp_dict_arg_name_8 = tmp_class_creation_3__class_decl_dict; - tmp_key_name_8 = mod_consts[326]; - tmp_metaclass_name_3 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_8, tmp_key_name_8); - if (tmp_metaclass_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - goto condexpr_end_5; - condexpr_false_5:; - CHECK_OBJECT(tmp_class_creation_3__bases); - tmp_truth_name_3 = CHECK_IF_TRUE(tmp_class_creation_3__bases); - if (tmp_truth_name_3 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_condition_result_14 = tmp_truth_name_3 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_14 == NUITKA_BOOL_TRUE) { - goto condexpr_true_6; - } else { - goto condexpr_false_6; - } - condexpr_true_6:; - CHECK_OBJECT(tmp_class_creation_3__bases); - tmp_expression_name_15 = tmp_class_creation_3__bases; - tmp_subscript_name_3 = mod_consts[29]; - tmp_type_arg_5 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_15, tmp_subscript_name_3, 0); - if (tmp_type_arg_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_metaclass_name_3 = BUILTIN_TYPE1(tmp_type_arg_5); - Py_DECREF(tmp_type_arg_5); - if (tmp_metaclass_name_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - goto condexpr_end_6; - condexpr_false_6:; - tmp_metaclass_name_3 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_3); - condexpr_end_6:; - condexpr_end_5:; - CHECK_OBJECT(tmp_class_creation_3__bases); - tmp_bases_name_3 = tmp_class_creation_3__bases; - tmp_assign_source_62 = SELECT_METACLASS(tmp_metaclass_name_3, tmp_bases_name_3); - Py_DECREF(tmp_metaclass_name_3); - if (tmp_assign_source_62 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - assert(tmp_class_creation_3__metaclass == NULL); - tmp_class_creation_3__metaclass = tmp_assign_source_62; - } - { - nuitka_bool tmp_condition_result_15; - PyObject *tmp_key_name_9; - PyObject *tmp_dict_arg_name_9; - tmp_key_name_9 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_3__class_decl_dict); - tmp_dict_arg_name_9 = tmp_class_creation_3__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_9, tmp_key_name_9); - assert(!(tmp_res == -1)); - tmp_condition_result_15 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_15 == NUITKA_BOOL_TRUE) { - goto branch_yes_9; - } else { - goto branch_no_9; - } - } - branch_yes_9:; - CHECK_OBJECT(tmp_class_creation_3__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_3__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - branch_no_9:; - { - nuitka_bool tmp_condition_result_16; - PyObject *tmp_expression_name_16; - CHECK_OBJECT(tmp_class_creation_3__metaclass); - tmp_expression_name_16 = tmp_class_creation_3__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_16, mod_consts[327]); - tmp_condition_result_16 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_16 == NUITKA_BOOL_TRUE) { - goto branch_yes_10; - } else { - goto branch_no_10; - } - } - branch_yes_10:; - { - PyObject *tmp_assign_source_63; - PyObject *tmp_called_name_6; - PyObject *tmp_expression_name_17; - PyObject *tmp_args_name_5; - PyObject *tmp_tuple_element_10; - PyObject *tmp_kwargs_name_5; - CHECK_OBJECT(tmp_class_creation_3__metaclass); - tmp_expression_name_17 = tmp_class_creation_3__metaclass; - tmp_called_name_6 = LOOKUP_ATTRIBUTE(tmp_expression_name_17, mod_consts[327]); - if (tmp_called_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_tuple_element_10 = mod_consts[94]; - tmp_args_name_5 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_5, 0, tmp_tuple_element_10); - CHECK_OBJECT(tmp_class_creation_3__bases); - tmp_tuple_element_10 = tmp_class_creation_3__bases; - PyTuple_SET_ITEM0(tmp_args_name_5, 1, tmp_tuple_element_10); - CHECK_OBJECT(tmp_class_creation_3__class_decl_dict); - tmp_kwargs_name_5 = tmp_class_creation_3__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 278; - tmp_assign_source_63 = CALL_FUNCTION(tmp_called_name_6, tmp_args_name_5, tmp_kwargs_name_5); - Py_DECREF(tmp_called_name_6); - Py_DECREF(tmp_args_name_5); - if (tmp_assign_source_63 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - assert(tmp_class_creation_3__prepared == NULL); - tmp_class_creation_3__prepared = tmp_assign_source_63; - } - { - nuitka_bool tmp_condition_result_17; - PyObject *tmp_operand_name_3; - PyObject *tmp_expression_name_18; - CHECK_OBJECT(tmp_class_creation_3__prepared); - tmp_expression_name_18 = tmp_class_creation_3__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_18, mod_consts[328]); - tmp_operand_name_3 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_3); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_condition_result_17 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_17 == NUITKA_BOOL_TRUE) { - goto branch_yes_11; - } else { - goto branch_no_11; - } - } - branch_yes_11:; - { - PyObject *tmp_raise_type_3; - PyObject *tmp_raise_value_3; - PyObject *tmp_left_name_3; - PyObject *tmp_right_name_3; - PyObject *tmp_tuple_element_11; - PyObject *tmp_getattr_target_3; - PyObject *tmp_getattr_attr_3; - PyObject *tmp_getattr_default_3; - tmp_raise_type_3 = PyExc_TypeError; - tmp_left_name_3 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_3__metaclass); - tmp_getattr_target_3 = tmp_class_creation_3__metaclass; - tmp_getattr_attr_3 = mod_consts[324]; - tmp_getattr_default_3 = mod_consts[330]; - tmp_tuple_element_11 = BUILTIN_GETATTR(tmp_getattr_target_3, tmp_getattr_attr_3, tmp_getattr_default_3); - if (tmp_tuple_element_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - tmp_right_name_3 = PyTuple_New(2); - { - PyObject *tmp_expression_name_19; - PyObject *tmp_type_arg_6; - PyTuple_SET_ITEM(tmp_right_name_3, 0, tmp_tuple_element_11); - CHECK_OBJECT(tmp_class_creation_3__prepared); - tmp_type_arg_6 = tmp_class_creation_3__prepared; - tmp_expression_name_19 = BUILTIN_TYPE1(tmp_type_arg_6); - assert(!(tmp_expression_name_19 == NULL)); - tmp_tuple_element_11 = LOOKUP_ATTRIBUTE(tmp_expression_name_19, mod_consts[324]); - Py_DECREF(tmp_expression_name_19); - if (tmp_tuple_element_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto tuple_build_exception_3; - } - PyTuple_SET_ITEM(tmp_right_name_3, 1, tmp_tuple_element_11); - } - goto tuple_build_noexception_3; - // Exception handling pass through code for tuple_build: - tuple_build_exception_3:; - Py_DECREF(tmp_right_name_3); - goto try_except_handler_11; - // Finished with no exception for tuple_build: - tuple_build_noexception_3:; - tmp_raise_value_3 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_3, tmp_right_name_3); - Py_DECREF(tmp_right_name_3); - if (tmp_raise_value_3 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_11; - } - exception_type = tmp_raise_type_3; - Py_INCREF(tmp_raise_type_3); - exception_value = tmp_raise_value_3; - exception_lineno = 278; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_11; - } - branch_no_11:; - goto branch_end_10; - branch_no_10:; - { - PyObject *tmp_assign_source_64; - tmp_assign_source_64 = PyDict_New(); - assert(tmp_class_creation_3__prepared == NULL); - tmp_class_creation_3__prepared = tmp_assign_source_64; - } - branch_end_10:; - { - PyObject *tmp_assign_source_65; - { - PyObject *tmp_set_locals_3; - CHECK_OBJECT(tmp_class_creation_3__prepared); - tmp_set_locals_3 = tmp_class_creation_3__prepared; - locals_models$Qformer$$$class__3_BertSelfOutput_278 = tmp_set_locals_3; - Py_INCREF(tmp_set_locals_3); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__3_BertSelfOutput_278, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_13; - } - tmp_dictset_value = mod_consts[94]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__3_BertSelfOutput_278, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_13; - } - if (isFrameUnusable(cache_frame_cc56a3d4cf1124558e66a811713c588d_4)) { - Py_XDECREF(cache_frame_cc56a3d4cf1124558e66a811713c588d_4); - -#if _DEBUG_REFCOUNTS - if (cache_frame_cc56a3d4cf1124558e66a811713c588d_4 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_cc56a3d4cf1124558e66a811713c588d_4 = MAKE_FUNCTION_FRAME(codeobj_cc56a3d4cf1124558e66a811713c588d, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_cc56a3d4cf1124558e66a811713c588d_4->m_type_description == NULL); - frame_cc56a3d4cf1124558e66a811713c588d_4 = cache_frame_cc56a3d4cf1124558e66a811713c588d_4; - - // Push the new frame as the currently active one. - pushFrameStack(frame_cc56a3d4cf1124558e66a811713c588d_4); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_cc56a3d4cf1124558e66a811713c588d_4) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_3[1]; - - tmp_closure_3[0] = outline_2_var___class__; - Py_INCREF(tmp_closure_3[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__10___init__(tmp_closure_3); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__3_BertSelfOutput_278, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 279; - type_description_2 = "c"; - goto frame_exception_exit_4; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__11_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__3_BertSelfOutput_278, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 285; - type_description_2 = "c"; - goto frame_exception_exit_4; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_cc56a3d4cf1124558e66a811713c588d_4); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_3; - - frame_exception_exit_4:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_cc56a3d4cf1124558e66a811713c588d_4); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_cc56a3d4cf1124558e66a811713c588d_4, exception_lineno); - } else if (exception_tb->tb_frame != &frame_cc56a3d4cf1124558e66a811713c588d_4->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_cc56a3d4cf1124558e66a811713c588d_4, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_cc56a3d4cf1124558e66a811713c588d_4, - type_description_2, - outline_2_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_cc56a3d4cf1124558e66a811713c588d_4 == cache_frame_cc56a3d4cf1124558e66a811713c588d_4) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_cc56a3d4cf1124558e66a811713c588d_4); - cache_frame_cc56a3d4cf1124558e66a811713c588d_4 = NULL; - } - - assertFrameObject(frame_cc56a3d4cf1124558e66a811713c588d_4); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_3; - - frame_no_exception_3:; - goto skip_nested_handling_3; - nested_frame_exit_3:; - - goto try_except_handler_13; - skip_nested_handling_3:; - { - nuitka_bool tmp_condition_result_18; - PyObject *tmp_compexpr_left_3; - PyObject *tmp_compexpr_right_3; - CHECK_OBJECT(tmp_class_creation_3__bases); - tmp_compexpr_left_3 = tmp_class_creation_3__bases; - CHECK_OBJECT(tmp_class_creation_3__bases_orig); - tmp_compexpr_right_3 = tmp_class_creation_3__bases_orig; - tmp_condition_result_18 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_3, tmp_compexpr_right_3); - if (tmp_condition_result_18 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_13; - } - if (tmp_condition_result_18 == NUITKA_BOOL_TRUE) { - goto branch_yes_12; - } else { - goto branch_no_12; - } - assert(tmp_condition_result_18 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_12:; - CHECK_OBJECT(tmp_class_creation_3__bases_orig); - tmp_dictset_value = tmp_class_creation_3__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__3_BertSelfOutput_278, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_13; - } - branch_no_12:; - { - PyObject *tmp_assign_source_66; - PyObject *tmp_called_name_7; - PyObject *tmp_args_name_6; - PyObject *tmp_tuple_element_12; - PyObject *tmp_kwargs_name_6; - CHECK_OBJECT(tmp_class_creation_3__metaclass); - tmp_called_name_7 = tmp_class_creation_3__metaclass; - tmp_tuple_element_12 = mod_consts[94]; - tmp_args_name_6 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_6, 0, tmp_tuple_element_12); - CHECK_OBJECT(tmp_class_creation_3__bases); - tmp_tuple_element_12 = tmp_class_creation_3__bases; - PyTuple_SET_ITEM0(tmp_args_name_6, 1, tmp_tuple_element_12); - tmp_tuple_element_12 = locals_models$Qformer$$$class__3_BertSelfOutput_278; - PyTuple_SET_ITEM0(tmp_args_name_6, 2, tmp_tuple_element_12); - CHECK_OBJECT(tmp_class_creation_3__class_decl_dict); - tmp_kwargs_name_6 = tmp_class_creation_3__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 278; - tmp_assign_source_66 = CALL_FUNCTION(tmp_called_name_7, tmp_args_name_6, tmp_kwargs_name_6); - Py_DECREF(tmp_args_name_6); - if (tmp_assign_source_66 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 278; - - goto try_except_handler_13; - } - { - PyObject *old = Nuitka_Cell_GET(outline_2_var___class__); - PyCell_SET(outline_2_var___class__, tmp_assign_source_66); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_2_var___class__)); - tmp_assign_source_65 = Nuitka_Cell_GET(outline_2_var___class__); - Py_INCREF(tmp_assign_source_65); - goto try_return_handler_13; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_13:; - Py_DECREF(locals_models$Qformer$$$class__3_BertSelfOutput_278); - locals_models$Qformer$$$class__3_BertSelfOutput_278 = NULL; - goto try_return_handler_12; - // Exception handler code: - try_except_handler_13:; - exception_keeper_type_11 = exception_type; - exception_keeper_value_11 = exception_value; - exception_keeper_tb_11 = exception_tb; - exception_keeper_lineno_11 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__3_BertSelfOutput_278); - locals_models$Qformer$$$class__3_BertSelfOutput_278 = NULL; - // Re-raise. - exception_type = exception_keeper_type_11; - exception_value = exception_keeper_value_11; - exception_tb = exception_keeper_tb_11; - exception_lineno = exception_keeper_lineno_11; - - goto try_except_handler_12; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_12:; - CHECK_OBJECT(outline_2_var___class__); - Py_DECREF(outline_2_var___class__); - outline_2_var___class__ = NULL; - goto outline_result_3; - // Exception handler code: - try_except_handler_12:; - exception_keeper_type_12 = exception_type; - exception_keeper_value_12 = exception_value; - exception_keeper_tb_12 = exception_tb; - exception_keeper_lineno_12 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_2_var___class__); - Py_DECREF(outline_2_var___class__); - outline_2_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_12; - exception_value = exception_keeper_value_12; - exception_tb = exception_keeper_tb_12; - exception_lineno = exception_keeper_lineno_12; - - goto outline_exception_3; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_3:; - exception_lineno = 278; - goto try_except_handler_11; - outline_result_3:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[94], tmp_assign_source_65); - } - goto try_end_7; - // Exception handler code: - try_except_handler_11:; - exception_keeper_type_13 = exception_type; - exception_keeper_value_13 = exception_value; - exception_keeper_tb_13 = exception_tb; - exception_keeper_lineno_13 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_3__bases_orig); - tmp_class_creation_3__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_3__bases); - tmp_class_creation_3__bases = NULL; - Py_XDECREF(tmp_class_creation_3__class_decl_dict); - tmp_class_creation_3__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_3__metaclass); - tmp_class_creation_3__metaclass = NULL; - Py_XDECREF(tmp_class_creation_3__prepared); - tmp_class_creation_3__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_13; - exception_value = exception_keeper_value_13; - exception_tb = exception_keeper_tb_13; - exception_lineno = exception_keeper_lineno_13; - - goto frame_exception_exit_1; - // End of try: - try_end_7:; - CHECK_OBJECT(tmp_class_creation_3__bases_orig); - Py_DECREF(tmp_class_creation_3__bases_orig); - tmp_class_creation_3__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_3__bases); - tmp_class_creation_3__bases = NULL; - Py_XDECREF(tmp_class_creation_3__class_decl_dict); - tmp_class_creation_3__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_3__metaclass); - tmp_class_creation_3__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_3__prepared); - Py_DECREF(tmp_class_creation_3__prepared); - tmp_class_creation_3__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_67; - PyObject *tmp_tuple_element_13; - PyObject *tmp_expression_name_20; - tmp_expression_name_20 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_20 == NULL)) { - tmp_expression_name_20 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_tuple_element_13 = LOOKUP_ATTRIBUTE(tmp_expression_name_20, mod_consts[325]); - if (tmp_tuple_element_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_assign_source_67 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_67, 0, tmp_tuple_element_13); - assert(tmp_class_creation_4__bases_orig == NULL); - tmp_class_creation_4__bases_orig = tmp_assign_source_67; - } - { - PyObject *tmp_assign_source_68; - PyObject *tmp_dircall_arg1_4; - CHECK_OBJECT(tmp_class_creation_4__bases_orig); - tmp_dircall_arg1_4 = tmp_class_creation_4__bases_orig; - Py_INCREF(tmp_dircall_arg1_4); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_4}; - tmp_assign_source_68 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_68 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - assert(tmp_class_creation_4__bases == NULL); - tmp_class_creation_4__bases = tmp_assign_source_68; - } - { - PyObject *tmp_assign_source_69; - tmp_assign_source_69 = PyDict_New(); - assert(tmp_class_creation_4__class_decl_dict == NULL); - tmp_class_creation_4__class_decl_dict = tmp_assign_source_69; - } - { - PyObject *tmp_assign_source_70; - PyObject *tmp_metaclass_name_4; - nuitka_bool tmp_condition_result_19; - PyObject *tmp_key_name_10; - PyObject *tmp_dict_arg_name_10; - PyObject *tmp_dict_arg_name_11; - PyObject *tmp_key_name_11; - nuitka_bool tmp_condition_result_20; - int tmp_truth_name_4; - PyObject *tmp_type_arg_7; - PyObject *tmp_expression_name_21; - PyObject *tmp_subscript_name_4; - PyObject *tmp_bases_name_4; - tmp_key_name_10 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_4__class_decl_dict); - tmp_dict_arg_name_10 = tmp_class_creation_4__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_10, tmp_key_name_10); - assert(!(tmp_res == -1)); - tmp_condition_result_19 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_19 == NUITKA_BOOL_TRUE) { - goto condexpr_true_7; - } else { - goto condexpr_false_7; - } - condexpr_true_7:; - CHECK_OBJECT(tmp_class_creation_4__class_decl_dict); - tmp_dict_arg_name_11 = tmp_class_creation_4__class_decl_dict; - tmp_key_name_11 = mod_consts[326]; - tmp_metaclass_name_4 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_11, tmp_key_name_11); - if (tmp_metaclass_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - goto condexpr_end_7; - condexpr_false_7:; - CHECK_OBJECT(tmp_class_creation_4__bases); - tmp_truth_name_4 = CHECK_IF_TRUE(tmp_class_creation_4__bases); - if (tmp_truth_name_4 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_condition_result_20 = tmp_truth_name_4 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_20 == NUITKA_BOOL_TRUE) { - goto condexpr_true_8; - } else { - goto condexpr_false_8; - } - condexpr_true_8:; - CHECK_OBJECT(tmp_class_creation_4__bases); - tmp_expression_name_21 = tmp_class_creation_4__bases; - tmp_subscript_name_4 = mod_consts[29]; - tmp_type_arg_7 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_21, tmp_subscript_name_4, 0); - if (tmp_type_arg_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_metaclass_name_4 = BUILTIN_TYPE1(tmp_type_arg_7); - Py_DECREF(tmp_type_arg_7); - if (tmp_metaclass_name_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - goto condexpr_end_8; - condexpr_false_8:; - tmp_metaclass_name_4 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_4); - condexpr_end_8:; - condexpr_end_7:; - CHECK_OBJECT(tmp_class_creation_4__bases); - tmp_bases_name_4 = tmp_class_creation_4__bases; - tmp_assign_source_70 = SELECT_METACLASS(tmp_metaclass_name_4, tmp_bases_name_4); - Py_DECREF(tmp_metaclass_name_4); - if (tmp_assign_source_70 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - assert(tmp_class_creation_4__metaclass == NULL); - tmp_class_creation_4__metaclass = tmp_assign_source_70; - } - { - nuitka_bool tmp_condition_result_21; - PyObject *tmp_key_name_12; - PyObject *tmp_dict_arg_name_12; - tmp_key_name_12 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_4__class_decl_dict); - tmp_dict_arg_name_12 = tmp_class_creation_4__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_12, tmp_key_name_12); - assert(!(tmp_res == -1)); - tmp_condition_result_21 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_21 == NUITKA_BOOL_TRUE) { - goto branch_yes_13; - } else { - goto branch_no_13; - } - } - branch_yes_13:; - CHECK_OBJECT(tmp_class_creation_4__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_4__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - branch_no_13:; - { - nuitka_bool tmp_condition_result_22; - PyObject *tmp_expression_name_22; - CHECK_OBJECT(tmp_class_creation_4__metaclass); - tmp_expression_name_22 = tmp_class_creation_4__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_22, mod_consts[327]); - tmp_condition_result_22 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_22 == NUITKA_BOOL_TRUE) { - goto branch_yes_14; - } else { - goto branch_no_14; - } - } - branch_yes_14:; - { - PyObject *tmp_assign_source_71; - PyObject *tmp_called_name_8; - PyObject *tmp_expression_name_23; - PyObject *tmp_args_name_7; - PyObject *tmp_tuple_element_14; - PyObject *tmp_kwargs_name_7; - CHECK_OBJECT(tmp_class_creation_4__metaclass); - tmp_expression_name_23 = tmp_class_creation_4__metaclass; - tmp_called_name_8 = LOOKUP_ATTRIBUTE(tmp_expression_name_23, mod_consts[327]); - if (tmp_called_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_tuple_element_14 = mod_consts[109]; - tmp_args_name_7 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_7, 0, tmp_tuple_element_14); - CHECK_OBJECT(tmp_class_creation_4__bases); - tmp_tuple_element_14 = tmp_class_creation_4__bases; - PyTuple_SET_ITEM0(tmp_args_name_7, 1, tmp_tuple_element_14); - CHECK_OBJECT(tmp_class_creation_4__class_decl_dict); - tmp_kwargs_name_7 = tmp_class_creation_4__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 292; - tmp_assign_source_71 = CALL_FUNCTION(tmp_called_name_8, tmp_args_name_7, tmp_kwargs_name_7); - Py_DECREF(tmp_called_name_8); - Py_DECREF(tmp_args_name_7); - if (tmp_assign_source_71 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - assert(tmp_class_creation_4__prepared == NULL); - tmp_class_creation_4__prepared = tmp_assign_source_71; - } - { - nuitka_bool tmp_condition_result_23; - PyObject *tmp_operand_name_4; - PyObject *tmp_expression_name_24; - CHECK_OBJECT(tmp_class_creation_4__prepared); - tmp_expression_name_24 = tmp_class_creation_4__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_24, mod_consts[328]); - tmp_operand_name_4 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_4); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_condition_result_23 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_23 == NUITKA_BOOL_TRUE) { - goto branch_yes_15; - } else { - goto branch_no_15; - } - } - branch_yes_15:; - { - PyObject *tmp_raise_type_4; - PyObject *tmp_raise_value_4; - PyObject *tmp_left_name_4; - PyObject *tmp_right_name_4; - PyObject *tmp_tuple_element_15; - PyObject *tmp_getattr_target_4; - PyObject *tmp_getattr_attr_4; - PyObject *tmp_getattr_default_4; - tmp_raise_type_4 = PyExc_TypeError; - tmp_left_name_4 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_4__metaclass); - tmp_getattr_target_4 = tmp_class_creation_4__metaclass; - tmp_getattr_attr_4 = mod_consts[324]; - tmp_getattr_default_4 = mod_consts[330]; - tmp_tuple_element_15 = BUILTIN_GETATTR(tmp_getattr_target_4, tmp_getattr_attr_4, tmp_getattr_default_4); - if (tmp_tuple_element_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - tmp_right_name_4 = PyTuple_New(2); - { - PyObject *tmp_expression_name_25; - PyObject *tmp_type_arg_8; - PyTuple_SET_ITEM(tmp_right_name_4, 0, tmp_tuple_element_15); - CHECK_OBJECT(tmp_class_creation_4__prepared); - tmp_type_arg_8 = tmp_class_creation_4__prepared; - tmp_expression_name_25 = BUILTIN_TYPE1(tmp_type_arg_8); - assert(!(tmp_expression_name_25 == NULL)); - tmp_tuple_element_15 = LOOKUP_ATTRIBUTE(tmp_expression_name_25, mod_consts[324]); - Py_DECREF(tmp_expression_name_25); - if (tmp_tuple_element_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto tuple_build_exception_4; - } - PyTuple_SET_ITEM(tmp_right_name_4, 1, tmp_tuple_element_15); - } - goto tuple_build_noexception_4; - // Exception handling pass through code for tuple_build: - tuple_build_exception_4:; - Py_DECREF(tmp_right_name_4); - goto try_except_handler_14; - // Finished with no exception for tuple_build: - tuple_build_noexception_4:; - tmp_raise_value_4 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_4, tmp_right_name_4); - Py_DECREF(tmp_right_name_4); - if (tmp_raise_value_4 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_14; - } - exception_type = tmp_raise_type_4; - Py_INCREF(tmp_raise_type_4); - exception_value = tmp_raise_value_4; - exception_lineno = 292; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_14; - } - branch_no_15:; - goto branch_end_14; - branch_no_14:; - { - PyObject *tmp_assign_source_72; - tmp_assign_source_72 = PyDict_New(); - assert(tmp_class_creation_4__prepared == NULL); - tmp_class_creation_4__prepared = tmp_assign_source_72; - } - branch_end_14:; - { - PyObject *tmp_assign_source_73; - { - PyObject *tmp_set_locals_4; - CHECK_OBJECT(tmp_class_creation_4__prepared); - tmp_set_locals_4 = tmp_class_creation_4__prepared; - locals_models$Qformer$$$class__4_BertAttention_292 = tmp_set_locals_4; - Py_INCREF(tmp_set_locals_4); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__4_BertAttention_292, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_16; - } - tmp_dictset_value = mod_consts[109]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__4_BertAttention_292, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_16; - } - if (isFrameUnusable(cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5)) { - Py_XDECREF(cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5); - -#if _DEBUG_REFCOUNTS - if (cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5 = MAKE_FUNCTION_FRAME(codeobj_5bfea05f5a06871ae56cfaab6dbe57ba, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5->m_type_description == NULL); - frame_5bfea05f5a06871ae56cfaab6dbe57ba_5 = cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5; - - // Push the new frame as the currently active one. - pushFrameStack(frame_5bfea05f5a06871ae56cfaab6dbe57ba_5); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_5bfea05f5a06871ae56cfaab6dbe57ba_5) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_defaults_3; - struct Nuitka_CellObject *tmp_closure_4[1]; - tmp_defaults_3 = mod_consts[351]; - Py_INCREF(tmp_defaults_3); - - tmp_closure_4[0] = outline_3_var___class__; - Py_INCREF(tmp_closure_4[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__12___init__(tmp_defaults_3, tmp_closure_4); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__4_BertAttention_292, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 293; - type_description_2 = "c"; - goto frame_exception_exit_5; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__13_prune_heads(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__4_BertAttention_292, mod_consts[200], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 299; - type_description_2 = "c"; - goto frame_exception_exit_5; - } - { - PyObject *tmp_defaults_4; - tmp_defaults_4 = mod_consts[347]; - Py_INCREF(tmp_defaults_4); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__14_forward(tmp_defaults_4); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__4_BertAttention_292, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 322; - type_description_2 = "c"; - goto frame_exception_exit_5; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_5bfea05f5a06871ae56cfaab6dbe57ba_5); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_4; - - frame_exception_exit_5:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_5bfea05f5a06871ae56cfaab6dbe57ba_5); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_5bfea05f5a06871ae56cfaab6dbe57ba_5, exception_lineno); - } else if (exception_tb->tb_frame != &frame_5bfea05f5a06871ae56cfaab6dbe57ba_5->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_5bfea05f5a06871ae56cfaab6dbe57ba_5, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_5bfea05f5a06871ae56cfaab6dbe57ba_5, - type_description_2, - outline_3_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_5bfea05f5a06871ae56cfaab6dbe57ba_5 == cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5); - cache_frame_5bfea05f5a06871ae56cfaab6dbe57ba_5 = NULL; - } - - assertFrameObject(frame_5bfea05f5a06871ae56cfaab6dbe57ba_5); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_4; - - frame_no_exception_4:; - goto skip_nested_handling_4; - nested_frame_exit_4:; - - goto try_except_handler_16; - skip_nested_handling_4:; - { - nuitka_bool tmp_condition_result_24; - PyObject *tmp_compexpr_left_4; - PyObject *tmp_compexpr_right_4; - CHECK_OBJECT(tmp_class_creation_4__bases); - tmp_compexpr_left_4 = tmp_class_creation_4__bases; - CHECK_OBJECT(tmp_class_creation_4__bases_orig); - tmp_compexpr_right_4 = tmp_class_creation_4__bases_orig; - tmp_condition_result_24 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_4, tmp_compexpr_right_4); - if (tmp_condition_result_24 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_16; - } - if (tmp_condition_result_24 == NUITKA_BOOL_TRUE) { - goto branch_yes_16; - } else { - goto branch_no_16; - } - assert(tmp_condition_result_24 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_16:; - CHECK_OBJECT(tmp_class_creation_4__bases_orig); - tmp_dictset_value = tmp_class_creation_4__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__4_BertAttention_292, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_16; - } - branch_no_16:; - { - PyObject *tmp_assign_source_74; - PyObject *tmp_called_name_9; - PyObject *tmp_args_name_8; - PyObject *tmp_tuple_element_16; - PyObject *tmp_kwargs_name_8; - CHECK_OBJECT(tmp_class_creation_4__metaclass); - tmp_called_name_9 = tmp_class_creation_4__metaclass; - tmp_tuple_element_16 = mod_consts[109]; - tmp_args_name_8 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_8, 0, tmp_tuple_element_16); - CHECK_OBJECT(tmp_class_creation_4__bases); - tmp_tuple_element_16 = tmp_class_creation_4__bases; - PyTuple_SET_ITEM0(tmp_args_name_8, 1, tmp_tuple_element_16); - tmp_tuple_element_16 = locals_models$Qformer$$$class__4_BertAttention_292; - PyTuple_SET_ITEM0(tmp_args_name_8, 2, tmp_tuple_element_16); - CHECK_OBJECT(tmp_class_creation_4__class_decl_dict); - tmp_kwargs_name_8 = tmp_class_creation_4__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 292; - tmp_assign_source_74 = CALL_FUNCTION(tmp_called_name_9, tmp_args_name_8, tmp_kwargs_name_8); - Py_DECREF(tmp_args_name_8); - if (tmp_assign_source_74 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 292; - - goto try_except_handler_16; - } - { - PyObject *old = Nuitka_Cell_GET(outline_3_var___class__); - PyCell_SET(outline_3_var___class__, tmp_assign_source_74); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_3_var___class__)); - tmp_assign_source_73 = Nuitka_Cell_GET(outline_3_var___class__); - Py_INCREF(tmp_assign_source_73); - goto try_return_handler_16; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_16:; - Py_DECREF(locals_models$Qformer$$$class__4_BertAttention_292); - locals_models$Qformer$$$class__4_BertAttention_292 = NULL; - goto try_return_handler_15; - // Exception handler code: - try_except_handler_16:; - exception_keeper_type_14 = exception_type; - exception_keeper_value_14 = exception_value; - exception_keeper_tb_14 = exception_tb; - exception_keeper_lineno_14 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__4_BertAttention_292); - locals_models$Qformer$$$class__4_BertAttention_292 = NULL; - // Re-raise. - exception_type = exception_keeper_type_14; - exception_value = exception_keeper_value_14; - exception_tb = exception_keeper_tb_14; - exception_lineno = exception_keeper_lineno_14; - - goto try_except_handler_15; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_15:; - CHECK_OBJECT(outline_3_var___class__); - Py_DECREF(outline_3_var___class__); - outline_3_var___class__ = NULL; - goto outline_result_4; - // Exception handler code: - try_except_handler_15:; - exception_keeper_type_15 = exception_type; - exception_keeper_value_15 = exception_value; - exception_keeper_tb_15 = exception_tb; - exception_keeper_lineno_15 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_3_var___class__); - Py_DECREF(outline_3_var___class__); - outline_3_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_15; - exception_value = exception_keeper_value_15; - exception_tb = exception_keeper_tb_15; - exception_lineno = exception_keeper_lineno_15; - - goto outline_exception_4; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_4:; - exception_lineno = 292; - goto try_except_handler_14; - outline_result_4:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[109], tmp_assign_source_73); - } - goto try_end_8; - // Exception handler code: - try_except_handler_14:; - exception_keeper_type_16 = exception_type; - exception_keeper_value_16 = exception_value; - exception_keeper_tb_16 = exception_tb; - exception_keeper_lineno_16 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_4__bases_orig); - tmp_class_creation_4__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_4__bases); - tmp_class_creation_4__bases = NULL; - Py_XDECREF(tmp_class_creation_4__class_decl_dict); - tmp_class_creation_4__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_4__metaclass); - tmp_class_creation_4__metaclass = NULL; - Py_XDECREF(tmp_class_creation_4__prepared); - tmp_class_creation_4__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_16; - exception_value = exception_keeper_value_16; - exception_tb = exception_keeper_tb_16; - exception_lineno = exception_keeper_lineno_16; - - goto frame_exception_exit_1; - // End of try: - try_end_8:; - CHECK_OBJECT(tmp_class_creation_4__bases_orig); - Py_DECREF(tmp_class_creation_4__bases_orig); - tmp_class_creation_4__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_4__bases); - tmp_class_creation_4__bases = NULL; - Py_XDECREF(tmp_class_creation_4__class_decl_dict); - tmp_class_creation_4__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_4__metaclass); - tmp_class_creation_4__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_4__prepared); - Py_DECREF(tmp_class_creation_4__prepared); - tmp_class_creation_4__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_75; - PyObject *tmp_tuple_element_17; - PyObject *tmp_expression_name_26; - tmp_expression_name_26 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_26 == NULL)) { - tmp_expression_name_26 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_tuple_element_17 = LOOKUP_ATTRIBUTE(tmp_expression_name_26, mod_consts[325]); - if (tmp_tuple_element_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_assign_source_75 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_75, 0, tmp_tuple_element_17); - assert(tmp_class_creation_5__bases_orig == NULL); - tmp_class_creation_5__bases_orig = tmp_assign_source_75; - } - { - PyObject *tmp_assign_source_76; - PyObject *tmp_dircall_arg1_5; - CHECK_OBJECT(tmp_class_creation_5__bases_orig); - tmp_dircall_arg1_5 = tmp_class_creation_5__bases_orig; - Py_INCREF(tmp_dircall_arg1_5); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_5}; - tmp_assign_source_76 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_76 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - assert(tmp_class_creation_5__bases == NULL); - tmp_class_creation_5__bases = tmp_assign_source_76; - } - { - PyObject *tmp_assign_source_77; - tmp_assign_source_77 = PyDict_New(); - assert(tmp_class_creation_5__class_decl_dict == NULL); - tmp_class_creation_5__class_decl_dict = tmp_assign_source_77; - } - { - PyObject *tmp_assign_source_78; - PyObject *tmp_metaclass_name_5; - nuitka_bool tmp_condition_result_25; - PyObject *tmp_key_name_13; - PyObject *tmp_dict_arg_name_13; - PyObject *tmp_dict_arg_name_14; - PyObject *tmp_key_name_14; - nuitka_bool tmp_condition_result_26; - int tmp_truth_name_5; - PyObject *tmp_type_arg_9; - PyObject *tmp_expression_name_27; - PyObject *tmp_subscript_name_5; - PyObject *tmp_bases_name_5; - tmp_key_name_13 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_5__class_decl_dict); - tmp_dict_arg_name_13 = tmp_class_creation_5__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_13, tmp_key_name_13); - assert(!(tmp_res == -1)); - tmp_condition_result_25 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_25 == NUITKA_BOOL_TRUE) { - goto condexpr_true_9; - } else { - goto condexpr_false_9; - } - condexpr_true_9:; - CHECK_OBJECT(tmp_class_creation_5__class_decl_dict); - tmp_dict_arg_name_14 = tmp_class_creation_5__class_decl_dict; - tmp_key_name_14 = mod_consts[326]; - tmp_metaclass_name_5 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_14, tmp_key_name_14); - if (tmp_metaclass_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - goto condexpr_end_9; - condexpr_false_9:; - CHECK_OBJECT(tmp_class_creation_5__bases); - tmp_truth_name_5 = CHECK_IF_TRUE(tmp_class_creation_5__bases); - if (tmp_truth_name_5 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_condition_result_26 = tmp_truth_name_5 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_26 == NUITKA_BOOL_TRUE) { - goto condexpr_true_10; - } else { - goto condexpr_false_10; - } - condexpr_true_10:; - CHECK_OBJECT(tmp_class_creation_5__bases); - tmp_expression_name_27 = tmp_class_creation_5__bases; - tmp_subscript_name_5 = mod_consts[29]; - tmp_type_arg_9 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_27, tmp_subscript_name_5, 0); - if (tmp_type_arg_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_metaclass_name_5 = BUILTIN_TYPE1(tmp_type_arg_9); - Py_DECREF(tmp_type_arg_9); - if (tmp_metaclass_name_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - goto condexpr_end_10; - condexpr_false_10:; - tmp_metaclass_name_5 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_5); - condexpr_end_10:; - condexpr_end_9:; - CHECK_OBJECT(tmp_class_creation_5__bases); - tmp_bases_name_5 = tmp_class_creation_5__bases; - tmp_assign_source_78 = SELECT_METACLASS(tmp_metaclass_name_5, tmp_bases_name_5); - Py_DECREF(tmp_metaclass_name_5); - if (tmp_assign_source_78 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - assert(tmp_class_creation_5__metaclass == NULL); - tmp_class_creation_5__metaclass = tmp_assign_source_78; - } - { - nuitka_bool tmp_condition_result_27; - PyObject *tmp_key_name_15; - PyObject *tmp_dict_arg_name_15; - tmp_key_name_15 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_5__class_decl_dict); - tmp_dict_arg_name_15 = tmp_class_creation_5__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_15, tmp_key_name_15); - assert(!(tmp_res == -1)); - tmp_condition_result_27 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_27 == NUITKA_BOOL_TRUE) { - goto branch_yes_17; - } else { - goto branch_no_17; - } - } - branch_yes_17:; - CHECK_OBJECT(tmp_class_creation_5__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_5__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - branch_no_17:; - { - nuitka_bool tmp_condition_result_28; - PyObject *tmp_expression_name_28; - CHECK_OBJECT(tmp_class_creation_5__metaclass); - tmp_expression_name_28 = tmp_class_creation_5__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_28, mod_consts[327]); - tmp_condition_result_28 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_28 == NUITKA_BOOL_TRUE) { - goto branch_yes_18; - } else { - goto branch_no_18; - } - } - branch_yes_18:; - { - PyObject *tmp_assign_source_79; - PyObject *tmp_called_name_10; - PyObject *tmp_expression_name_29; - PyObject *tmp_args_name_9; - PyObject *tmp_tuple_element_18; - PyObject *tmp_kwargs_name_9; - CHECK_OBJECT(tmp_class_creation_5__metaclass); - tmp_expression_name_29 = tmp_class_creation_5__metaclass; - tmp_called_name_10 = LOOKUP_ATTRIBUTE(tmp_expression_name_29, mod_consts[327]); - if (tmp_called_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_tuple_element_18 = mod_consts[117]; - tmp_args_name_9 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_9, 0, tmp_tuple_element_18); - CHECK_OBJECT(tmp_class_creation_5__bases); - tmp_tuple_element_18 = tmp_class_creation_5__bases; - PyTuple_SET_ITEM0(tmp_args_name_9, 1, tmp_tuple_element_18); - CHECK_OBJECT(tmp_class_creation_5__class_decl_dict); - tmp_kwargs_name_9 = tmp_class_creation_5__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 349; - tmp_assign_source_79 = CALL_FUNCTION(tmp_called_name_10, tmp_args_name_9, tmp_kwargs_name_9); - Py_DECREF(tmp_called_name_10); - Py_DECREF(tmp_args_name_9); - if (tmp_assign_source_79 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - assert(tmp_class_creation_5__prepared == NULL); - tmp_class_creation_5__prepared = tmp_assign_source_79; - } - { - nuitka_bool tmp_condition_result_29; - PyObject *tmp_operand_name_5; - PyObject *tmp_expression_name_30; - CHECK_OBJECT(tmp_class_creation_5__prepared); - tmp_expression_name_30 = tmp_class_creation_5__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_30, mod_consts[328]); - tmp_operand_name_5 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_5); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_condition_result_29 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_29 == NUITKA_BOOL_TRUE) { - goto branch_yes_19; - } else { - goto branch_no_19; - } - } - branch_yes_19:; - { - PyObject *tmp_raise_type_5; - PyObject *tmp_raise_value_5; - PyObject *tmp_left_name_5; - PyObject *tmp_right_name_5; - PyObject *tmp_tuple_element_19; - PyObject *tmp_getattr_target_5; - PyObject *tmp_getattr_attr_5; - PyObject *tmp_getattr_default_5; - tmp_raise_type_5 = PyExc_TypeError; - tmp_left_name_5 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_5__metaclass); - tmp_getattr_target_5 = tmp_class_creation_5__metaclass; - tmp_getattr_attr_5 = mod_consts[324]; - tmp_getattr_default_5 = mod_consts[330]; - tmp_tuple_element_19 = BUILTIN_GETATTR(tmp_getattr_target_5, tmp_getattr_attr_5, tmp_getattr_default_5); - if (tmp_tuple_element_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - tmp_right_name_5 = PyTuple_New(2); - { - PyObject *tmp_expression_name_31; - PyObject *tmp_type_arg_10; - PyTuple_SET_ITEM(tmp_right_name_5, 0, tmp_tuple_element_19); - CHECK_OBJECT(tmp_class_creation_5__prepared); - tmp_type_arg_10 = tmp_class_creation_5__prepared; - tmp_expression_name_31 = BUILTIN_TYPE1(tmp_type_arg_10); - assert(!(tmp_expression_name_31 == NULL)); - tmp_tuple_element_19 = LOOKUP_ATTRIBUTE(tmp_expression_name_31, mod_consts[324]); - Py_DECREF(tmp_expression_name_31); - if (tmp_tuple_element_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto tuple_build_exception_5; - } - PyTuple_SET_ITEM(tmp_right_name_5, 1, tmp_tuple_element_19); - } - goto tuple_build_noexception_5; - // Exception handling pass through code for tuple_build: - tuple_build_exception_5:; - Py_DECREF(tmp_right_name_5); - goto try_except_handler_17; - // Finished with no exception for tuple_build: - tuple_build_noexception_5:; - tmp_raise_value_5 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_5, tmp_right_name_5); - Py_DECREF(tmp_right_name_5); - if (tmp_raise_value_5 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_17; - } - exception_type = tmp_raise_type_5; - Py_INCREF(tmp_raise_type_5); - exception_value = tmp_raise_value_5; - exception_lineno = 349; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_17; - } - branch_no_19:; - goto branch_end_18; - branch_no_18:; - { - PyObject *tmp_assign_source_80; - tmp_assign_source_80 = PyDict_New(); - assert(tmp_class_creation_5__prepared == NULL); - tmp_class_creation_5__prepared = tmp_assign_source_80; - } - branch_end_18:; - { - PyObject *tmp_assign_source_81; - { - PyObject *tmp_set_locals_5; - CHECK_OBJECT(tmp_class_creation_5__prepared); - tmp_set_locals_5 = tmp_class_creation_5__prepared; - locals_models$Qformer$$$class__5_BertIntermediate_349 = tmp_set_locals_5; - Py_INCREF(tmp_set_locals_5); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__5_BertIntermediate_349, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_19; - } - tmp_dictset_value = mod_consts[117]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__5_BertIntermediate_349, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_19; - } - if (isFrameUnusable(cache_frame_7007713779c26360c0f6632cb2047835_6)) { - Py_XDECREF(cache_frame_7007713779c26360c0f6632cb2047835_6); - -#if _DEBUG_REFCOUNTS - if (cache_frame_7007713779c26360c0f6632cb2047835_6 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_7007713779c26360c0f6632cb2047835_6 = MAKE_FUNCTION_FRAME(codeobj_7007713779c26360c0f6632cb2047835, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_7007713779c26360c0f6632cb2047835_6->m_type_description == NULL); - frame_7007713779c26360c0f6632cb2047835_6 = cache_frame_7007713779c26360c0f6632cb2047835_6; - - // Push the new frame as the currently active one. - pushFrameStack(frame_7007713779c26360c0f6632cb2047835_6); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_7007713779c26360c0f6632cb2047835_6) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_5[1]; - - tmp_closure_5[0] = outline_4_var___class__; - Py_INCREF(tmp_closure_5[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__15___init__(tmp_closure_5); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__5_BertIntermediate_349, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 350; - type_description_2 = "c"; - goto frame_exception_exit_6; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__16_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__5_BertIntermediate_349, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 358; - type_description_2 = "c"; - goto frame_exception_exit_6; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7007713779c26360c0f6632cb2047835_6); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_5; - - frame_exception_exit_6:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_7007713779c26360c0f6632cb2047835_6); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_7007713779c26360c0f6632cb2047835_6, exception_lineno); - } else if (exception_tb->tb_frame != &frame_7007713779c26360c0f6632cb2047835_6->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_7007713779c26360c0f6632cb2047835_6, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_7007713779c26360c0f6632cb2047835_6, - type_description_2, - outline_4_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_7007713779c26360c0f6632cb2047835_6 == cache_frame_7007713779c26360c0f6632cb2047835_6) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_7007713779c26360c0f6632cb2047835_6); - cache_frame_7007713779c26360c0f6632cb2047835_6 = NULL; - } - - assertFrameObject(frame_7007713779c26360c0f6632cb2047835_6); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_5; - - frame_no_exception_5:; - goto skip_nested_handling_5; - nested_frame_exit_5:; - - goto try_except_handler_19; - skip_nested_handling_5:; - { - nuitka_bool tmp_condition_result_30; - PyObject *tmp_compexpr_left_5; - PyObject *tmp_compexpr_right_5; - CHECK_OBJECT(tmp_class_creation_5__bases); - tmp_compexpr_left_5 = tmp_class_creation_5__bases; - CHECK_OBJECT(tmp_class_creation_5__bases_orig); - tmp_compexpr_right_5 = tmp_class_creation_5__bases_orig; - tmp_condition_result_30 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_5, tmp_compexpr_right_5); - if (tmp_condition_result_30 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_19; - } - if (tmp_condition_result_30 == NUITKA_BOOL_TRUE) { - goto branch_yes_20; - } else { - goto branch_no_20; - } - assert(tmp_condition_result_30 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_20:; - CHECK_OBJECT(tmp_class_creation_5__bases_orig); - tmp_dictset_value = tmp_class_creation_5__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__5_BertIntermediate_349, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_19; - } - branch_no_20:; - { - PyObject *tmp_assign_source_82; - PyObject *tmp_called_name_11; - PyObject *tmp_args_name_10; - PyObject *tmp_tuple_element_20; - PyObject *tmp_kwargs_name_10; - CHECK_OBJECT(tmp_class_creation_5__metaclass); - tmp_called_name_11 = tmp_class_creation_5__metaclass; - tmp_tuple_element_20 = mod_consts[117]; - tmp_args_name_10 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_10, 0, tmp_tuple_element_20); - CHECK_OBJECT(tmp_class_creation_5__bases); - tmp_tuple_element_20 = tmp_class_creation_5__bases; - PyTuple_SET_ITEM0(tmp_args_name_10, 1, tmp_tuple_element_20); - tmp_tuple_element_20 = locals_models$Qformer$$$class__5_BertIntermediate_349; - PyTuple_SET_ITEM0(tmp_args_name_10, 2, tmp_tuple_element_20); - CHECK_OBJECT(tmp_class_creation_5__class_decl_dict); - tmp_kwargs_name_10 = tmp_class_creation_5__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 349; - tmp_assign_source_82 = CALL_FUNCTION(tmp_called_name_11, tmp_args_name_10, tmp_kwargs_name_10); - Py_DECREF(tmp_args_name_10); - if (tmp_assign_source_82 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 349; - - goto try_except_handler_19; - } - { - PyObject *old = Nuitka_Cell_GET(outline_4_var___class__); - PyCell_SET(outline_4_var___class__, tmp_assign_source_82); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_4_var___class__)); - tmp_assign_source_81 = Nuitka_Cell_GET(outline_4_var___class__); - Py_INCREF(tmp_assign_source_81); - goto try_return_handler_19; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_19:; - Py_DECREF(locals_models$Qformer$$$class__5_BertIntermediate_349); - locals_models$Qformer$$$class__5_BertIntermediate_349 = NULL; - goto try_return_handler_18; - // Exception handler code: - try_except_handler_19:; - exception_keeper_type_17 = exception_type; - exception_keeper_value_17 = exception_value; - exception_keeper_tb_17 = exception_tb; - exception_keeper_lineno_17 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__5_BertIntermediate_349); - locals_models$Qformer$$$class__5_BertIntermediate_349 = NULL; - // Re-raise. - exception_type = exception_keeper_type_17; - exception_value = exception_keeper_value_17; - exception_tb = exception_keeper_tb_17; - exception_lineno = exception_keeper_lineno_17; - - goto try_except_handler_18; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_18:; - CHECK_OBJECT(outline_4_var___class__); - Py_DECREF(outline_4_var___class__); - outline_4_var___class__ = NULL; - goto outline_result_5; - // Exception handler code: - try_except_handler_18:; - exception_keeper_type_18 = exception_type; - exception_keeper_value_18 = exception_value; - exception_keeper_tb_18 = exception_tb; - exception_keeper_lineno_18 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_4_var___class__); - Py_DECREF(outline_4_var___class__); - outline_4_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_18; - exception_value = exception_keeper_value_18; - exception_tb = exception_keeper_tb_18; - exception_lineno = exception_keeper_lineno_18; - - goto outline_exception_5; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_5:; - exception_lineno = 349; - goto try_except_handler_17; - outline_result_5:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[117], tmp_assign_source_81); - } - goto try_end_9; - // Exception handler code: - try_except_handler_17:; - exception_keeper_type_19 = exception_type; - exception_keeper_value_19 = exception_value; - exception_keeper_tb_19 = exception_tb; - exception_keeper_lineno_19 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_5__bases_orig); - tmp_class_creation_5__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_5__bases); - tmp_class_creation_5__bases = NULL; - Py_XDECREF(tmp_class_creation_5__class_decl_dict); - tmp_class_creation_5__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_5__metaclass); - tmp_class_creation_5__metaclass = NULL; - Py_XDECREF(tmp_class_creation_5__prepared); - tmp_class_creation_5__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_19; - exception_value = exception_keeper_value_19; - exception_tb = exception_keeper_tb_19; - exception_lineno = exception_keeper_lineno_19; - - goto frame_exception_exit_1; - // End of try: - try_end_9:; - CHECK_OBJECT(tmp_class_creation_5__bases_orig); - Py_DECREF(tmp_class_creation_5__bases_orig); - tmp_class_creation_5__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_5__bases); - tmp_class_creation_5__bases = NULL; - Py_XDECREF(tmp_class_creation_5__class_decl_dict); - tmp_class_creation_5__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_5__metaclass); - tmp_class_creation_5__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_5__prepared); - Py_DECREF(tmp_class_creation_5__prepared); - tmp_class_creation_5__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_83; - PyObject *tmp_tuple_element_21; - PyObject *tmp_expression_name_32; - tmp_expression_name_32 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_32 == NULL)) { - tmp_expression_name_32 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_32 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_tuple_element_21 = LOOKUP_ATTRIBUTE(tmp_expression_name_32, mod_consts[325]); - if (tmp_tuple_element_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_assign_source_83 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_83, 0, tmp_tuple_element_21); - assert(tmp_class_creation_6__bases_orig == NULL); - tmp_class_creation_6__bases_orig = tmp_assign_source_83; - } - { - PyObject *tmp_assign_source_84; - PyObject *tmp_dircall_arg1_6; - CHECK_OBJECT(tmp_class_creation_6__bases_orig); - tmp_dircall_arg1_6 = tmp_class_creation_6__bases_orig; - Py_INCREF(tmp_dircall_arg1_6); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_6}; - tmp_assign_source_84 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_84 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - assert(tmp_class_creation_6__bases == NULL); - tmp_class_creation_6__bases = tmp_assign_source_84; - } - { - PyObject *tmp_assign_source_85; - tmp_assign_source_85 = PyDict_New(); - assert(tmp_class_creation_6__class_decl_dict == NULL); - tmp_class_creation_6__class_decl_dict = tmp_assign_source_85; - } - { - PyObject *tmp_assign_source_86; - PyObject *tmp_metaclass_name_6; - nuitka_bool tmp_condition_result_31; - PyObject *tmp_key_name_16; - PyObject *tmp_dict_arg_name_16; - PyObject *tmp_dict_arg_name_17; - PyObject *tmp_key_name_17; - nuitka_bool tmp_condition_result_32; - int tmp_truth_name_6; - PyObject *tmp_type_arg_11; - PyObject *tmp_expression_name_33; - PyObject *tmp_subscript_name_6; - PyObject *tmp_bases_name_6; - tmp_key_name_16 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_6__class_decl_dict); - tmp_dict_arg_name_16 = tmp_class_creation_6__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_16, tmp_key_name_16); - assert(!(tmp_res == -1)); - tmp_condition_result_31 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_31 == NUITKA_BOOL_TRUE) { - goto condexpr_true_11; - } else { - goto condexpr_false_11; - } - condexpr_true_11:; - CHECK_OBJECT(tmp_class_creation_6__class_decl_dict); - tmp_dict_arg_name_17 = tmp_class_creation_6__class_decl_dict; - tmp_key_name_17 = mod_consts[326]; - tmp_metaclass_name_6 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_17, tmp_key_name_17); - if (tmp_metaclass_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - goto condexpr_end_11; - condexpr_false_11:; - CHECK_OBJECT(tmp_class_creation_6__bases); - tmp_truth_name_6 = CHECK_IF_TRUE(tmp_class_creation_6__bases); - if (tmp_truth_name_6 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_condition_result_32 = tmp_truth_name_6 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_32 == NUITKA_BOOL_TRUE) { - goto condexpr_true_12; - } else { - goto condexpr_false_12; - } - condexpr_true_12:; - CHECK_OBJECT(tmp_class_creation_6__bases); - tmp_expression_name_33 = tmp_class_creation_6__bases; - tmp_subscript_name_6 = mod_consts[29]; - tmp_type_arg_11 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_33, tmp_subscript_name_6, 0); - if (tmp_type_arg_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_metaclass_name_6 = BUILTIN_TYPE1(tmp_type_arg_11); - Py_DECREF(tmp_type_arg_11); - if (tmp_metaclass_name_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - goto condexpr_end_12; - condexpr_false_12:; - tmp_metaclass_name_6 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_6); - condexpr_end_12:; - condexpr_end_11:; - CHECK_OBJECT(tmp_class_creation_6__bases); - tmp_bases_name_6 = tmp_class_creation_6__bases; - tmp_assign_source_86 = SELECT_METACLASS(tmp_metaclass_name_6, tmp_bases_name_6); - Py_DECREF(tmp_metaclass_name_6); - if (tmp_assign_source_86 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - assert(tmp_class_creation_6__metaclass == NULL); - tmp_class_creation_6__metaclass = tmp_assign_source_86; - } - { - nuitka_bool tmp_condition_result_33; - PyObject *tmp_key_name_18; - PyObject *tmp_dict_arg_name_18; - tmp_key_name_18 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_6__class_decl_dict); - tmp_dict_arg_name_18 = tmp_class_creation_6__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_18, tmp_key_name_18); - assert(!(tmp_res == -1)); - tmp_condition_result_33 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_33 == NUITKA_BOOL_TRUE) { - goto branch_yes_21; - } else { - goto branch_no_21; - } - } - branch_yes_21:; - CHECK_OBJECT(tmp_class_creation_6__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_6__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - branch_no_21:; - { - nuitka_bool tmp_condition_result_34; - PyObject *tmp_expression_name_34; - CHECK_OBJECT(tmp_class_creation_6__metaclass); - tmp_expression_name_34 = tmp_class_creation_6__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_34, mod_consts[327]); - tmp_condition_result_34 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_34 == NUITKA_BOOL_TRUE) { - goto branch_yes_22; - } else { - goto branch_no_22; - } - } - branch_yes_22:; - { - PyObject *tmp_assign_source_87; - PyObject *tmp_called_name_12; - PyObject *tmp_expression_name_35; - PyObject *tmp_args_name_11; - PyObject *tmp_tuple_element_22; - PyObject *tmp_kwargs_name_11; - CHECK_OBJECT(tmp_class_creation_6__metaclass); - tmp_expression_name_35 = tmp_class_creation_6__metaclass; - tmp_called_name_12 = LOOKUP_ATTRIBUTE(tmp_expression_name_35, mod_consts[327]); - if (tmp_called_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_tuple_element_22 = mod_consts[119]; - tmp_args_name_11 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_11, 0, tmp_tuple_element_22); - CHECK_OBJECT(tmp_class_creation_6__bases); - tmp_tuple_element_22 = tmp_class_creation_6__bases; - PyTuple_SET_ITEM0(tmp_args_name_11, 1, tmp_tuple_element_22); - CHECK_OBJECT(tmp_class_creation_6__class_decl_dict); - tmp_kwargs_name_11 = tmp_class_creation_6__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 364; - tmp_assign_source_87 = CALL_FUNCTION(tmp_called_name_12, tmp_args_name_11, tmp_kwargs_name_11); - Py_DECREF(tmp_called_name_12); - Py_DECREF(tmp_args_name_11); - if (tmp_assign_source_87 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - assert(tmp_class_creation_6__prepared == NULL); - tmp_class_creation_6__prepared = tmp_assign_source_87; - } - { - nuitka_bool tmp_condition_result_35; - PyObject *tmp_operand_name_6; - PyObject *tmp_expression_name_36; - CHECK_OBJECT(tmp_class_creation_6__prepared); - tmp_expression_name_36 = tmp_class_creation_6__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_36, mod_consts[328]); - tmp_operand_name_6 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_6); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_condition_result_35 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_35 == NUITKA_BOOL_TRUE) { - goto branch_yes_23; - } else { - goto branch_no_23; - } - } - branch_yes_23:; - { - PyObject *tmp_raise_type_6; - PyObject *tmp_raise_value_6; - PyObject *tmp_left_name_6; - PyObject *tmp_right_name_6; - PyObject *tmp_tuple_element_23; - PyObject *tmp_getattr_target_6; - PyObject *tmp_getattr_attr_6; - PyObject *tmp_getattr_default_6; - tmp_raise_type_6 = PyExc_TypeError; - tmp_left_name_6 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_6__metaclass); - tmp_getattr_target_6 = tmp_class_creation_6__metaclass; - tmp_getattr_attr_6 = mod_consts[324]; - tmp_getattr_default_6 = mod_consts[330]; - tmp_tuple_element_23 = BUILTIN_GETATTR(tmp_getattr_target_6, tmp_getattr_attr_6, tmp_getattr_default_6); - if (tmp_tuple_element_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - tmp_right_name_6 = PyTuple_New(2); - { - PyObject *tmp_expression_name_37; - PyObject *tmp_type_arg_12; - PyTuple_SET_ITEM(tmp_right_name_6, 0, tmp_tuple_element_23); - CHECK_OBJECT(tmp_class_creation_6__prepared); - tmp_type_arg_12 = tmp_class_creation_6__prepared; - tmp_expression_name_37 = BUILTIN_TYPE1(tmp_type_arg_12); - assert(!(tmp_expression_name_37 == NULL)); - tmp_tuple_element_23 = LOOKUP_ATTRIBUTE(tmp_expression_name_37, mod_consts[324]); - Py_DECREF(tmp_expression_name_37); - if (tmp_tuple_element_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto tuple_build_exception_6; - } - PyTuple_SET_ITEM(tmp_right_name_6, 1, tmp_tuple_element_23); - } - goto tuple_build_noexception_6; - // Exception handling pass through code for tuple_build: - tuple_build_exception_6:; - Py_DECREF(tmp_right_name_6); - goto try_except_handler_20; - // Finished with no exception for tuple_build: - tuple_build_noexception_6:; - tmp_raise_value_6 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_6, tmp_right_name_6); - Py_DECREF(tmp_right_name_6); - if (tmp_raise_value_6 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_20; - } - exception_type = tmp_raise_type_6; - Py_INCREF(tmp_raise_type_6); - exception_value = tmp_raise_value_6; - exception_lineno = 364; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_20; - } - branch_no_23:; - goto branch_end_22; - branch_no_22:; - { - PyObject *tmp_assign_source_88; - tmp_assign_source_88 = PyDict_New(); - assert(tmp_class_creation_6__prepared == NULL); - tmp_class_creation_6__prepared = tmp_assign_source_88; - } - branch_end_22:; - { - PyObject *tmp_assign_source_89; - { - PyObject *tmp_set_locals_6; - CHECK_OBJECT(tmp_class_creation_6__prepared); - tmp_set_locals_6 = tmp_class_creation_6__prepared; - locals_models$Qformer$$$class__6_BertOutput_364 = tmp_set_locals_6; - Py_INCREF(tmp_set_locals_6); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__6_BertOutput_364, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_22; - } - tmp_dictset_value = mod_consts[119]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__6_BertOutput_364, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_22; - } - if (isFrameUnusable(cache_frame_2997152d8a9cec4ec6825b911abbb306_7)) { - Py_XDECREF(cache_frame_2997152d8a9cec4ec6825b911abbb306_7); - -#if _DEBUG_REFCOUNTS - if (cache_frame_2997152d8a9cec4ec6825b911abbb306_7 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_2997152d8a9cec4ec6825b911abbb306_7 = MAKE_FUNCTION_FRAME(codeobj_2997152d8a9cec4ec6825b911abbb306, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_2997152d8a9cec4ec6825b911abbb306_7->m_type_description == NULL); - frame_2997152d8a9cec4ec6825b911abbb306_7 = cache_frame_2997152d8a9cec4ec6825b911abbb306_7; - - // Push the new frame as the currently active one. - pushFrameStack(frame_2997152d8a9cec4ec6825b911abbb306_7); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_2997152d8a9cec4ec6825b911abbb306_7) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_6[1]; - - tmp_closure_6[0] = outline_5_var___class__; - Py_INCREF(tmp_closure_6[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__17___init__(tmp_closure_6); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__6_BertOutput_364, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 365; - type_description_2 = "c"; - goto frame_exception_exit_7; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__18_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__6_BertOutput_364, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 371; - type_description_2 = "c"; - goto frame_exception_exit_7; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2997152d8a9cec4ec6825b911abbb306_7); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_6; - - frame_exception_exit_7:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2997152d8a9cec4ec6825b911abbb306_7); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_2997152d8a9cec4ec6825b911abbb306_7, exception_lineno); - } else if (exception_tb->tb_frame != &frame_2997152d8a9cec4ec6825b911abbb306_7->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_2997152d8a9cec4ec6825b911abbb306_7, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_2997152d8a9cec4ec6825b911abbb306_7, - type_description_2, - outline_5_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_2997152d8a9cec4ec6825b911abbb306_7 == cache_frame_2997152d8a9cec4ec6825b911abbb306_7) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_2997152d8a9cec4ec6825b911abbb306_7); - cache_frame_2997152d8a9cec4ec6825b911abbb306_7 = NULL; - } - - assertFrameObject(frame_2997152d8a9cec4ec6825b911abbb306_7); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_6; - - frame_no_exception_6:; - goto skip_nested_handling_6; - nested_frame_exit_6:; - - goto try_except_handler_22; - skip_nested_handling_6:; - { - nuitka_bool tmp_condition_result_36; - PyObject *tmp_compexpr_left_6; - PyObject *tmp_compexpr_right_6; - CHECK_OBJECT(tmp_class_creation_6__bases); - tmp_compexpr_left_6 = tmp_class_creation_6__bases; - CHECK_OBJECT(tmp_class_creation_6__bases_orig); - tmp_compexpr_right_6 = tmp_class_creation_6__bases_orig; - tmp_condition_result_36 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_6, tmp_compexpr_right_6); - if (tmp_condition_result_36 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_22; - } - if (tmp_condition_result_36 == NUITKA_BOOL_TRUE) { - goto branch_yes_24; - } else { - goto branch_no_24; - } - assert(tmp_condition_result_36 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_24:; - CHECK_OBJECT(tmp_class_creation_6__bases_orig); - tmp_dictset_value = tmp_class_creation_6__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__6_BertOutput_364, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_22; - } - branch_no_24:; - { - PyObject *tmp_assign_source_90; - PyObject *tmp_called_name_13; - PyObject *tmp_args_name_12; - PyObject *tmp_tuple_element_24; - PyObject *tmp_kwargs_name_12; - CHECK_OBJECT(tmp_class_creation_6__metaclass); - tmp_called_name_13 = tmp_class_creation_6__metaclass; - tmp_tuple_element_24 = mod_consts[119]; - tmp_args_name_12 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_12, 0, tmp_tuple_element_24); - CHECK_OBJECT(tmp_class_creation_6__bases); - tmp_tuple_element_24 = tmp_class_creation_6__bases; - PyTuple_SET_ITEM0(tmp_args_name_12, 1, tmp_tuple_element_24); - tmp_tuple_element_24 = locals_models$Qformer$$$class__6_BertOutput_364; - PyTuple_SET_ITEM0(tmp_args_name_12, 2, tmp_tuple_element_24); - CHECK_OBJECT(tmp_class_creation_6__class_decl_dict); - tmp_kwargs_name_12 = tmp_class_creation_6__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 364; - tmp_assign_source_90 = CALL_FUNCTION(tmp_called_name_13, tmp_args_name_12, tmp_kwargs_name_12); - Py_DECREF(tmp_args_name_12); - if (tmp_assign_source_90 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 364; - - goto try_except_handler_22; - } - { - PyObject *old = Nuitka_Cell_GET(outline_5_var___class__); - PyCell_SET(outline_5_var___class__, tmp_assign_source_90); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_5_var___class__)); - tmp_assign_source_89 = Nuitka_Cell_GET(outline_5_var___class__); - Py_INCREF(tmp_assign_source_89); - goto try_return_handler_22; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_22:; - Py_DECREF(locals_models$Qformer$$$class__6_BertOutput_364); - locals_models$Qformer$$$class__6_BertOutput_364 = NULL; - goto try_return_handler_21; - // Exception handler code: - try_except_handler_22:; - exception_keeper_type_20 = exception_type; - exception_keeper_value_20 = exception_value; - exception_keeper_tb_20 = exception_tb; - exception_keeper_lineno_20 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__6_BertOutput_364); - locals_models$Qformer$$$class__6_BertOutput_364 = NULL; - // Re-raise. - exception_type = exception_keeper_type_20; - exception_value = exception_keeper_value_20; - exception_tb = exception_keeper_tb_20; - exception_lineno = exception_keeper_lineno_20; - - goto try_except_handler_21; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_21:; - CHECK_OBJECT(outline_5_var___class__); - Py_DECREF(outline_5_var___class__); - outline_5_var___class__ = NULL; - goto outline_result_6; - // Exception handler code: - try_except_handler_21:; - exception_keeper_type_21 = exception_type; - exception_keeper_value_21 = exception_value; - exception_keeper_tb_21 = exception_tb; - exception_keeper_lineno_21 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_5_var___class__); - Py_DECREF(outline_5_var___class__); - outline_5_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_21; - exception_value = exception_keeper_value_21; - exception_tb = exception_keeper_tb_21; - exception_lineno = exception_keeper_lineno_21; - - goto outline_exception_6; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_6:; - exception_lineno = 364; - goto try_except_handler_20; - outline_result_6:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[119], tmp_assign_source_89); - } - goto try_end_10; - // Exception handler code: - try_except_handler_20:; - exception_keeper_type_22 = exception_type; - exception_keeper_value_22 = exception_value; - exception_keeper_tb_22 = exception_tb; - exception_keeper_lineno_22 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_6__bases_orig); - tmp_class_creation_6__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_6__bases); - tmp_class_creation_6__bases = NULL; - Py_XDECREF(tmp_class_creation_6__class_decl_dict); - tmp_class_creation_6__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_6__metaclass); - tmp_class_creation_6__metaclass = NULL; - Py_XDECREF(tmp_class_creation_6__prepared); - tmp_class_creation_6__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_22; - exception_value = exception_keeper_value_22; - exception_tb = exception_keeper_tb_22; - exception_lineno = exception_keeper_lineno_22; - - goto frame_exception_exit_1; - // End of try: - try_end_10:; - CHECK_OBJECT(tmp_class_creation_6__bases_orig); - Py_DECREF(tmp_class_creation_6__bases_orig); - tmp_class_creation_6__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_6__bases); - tmp_class_creation_6__bases = NULL; - Py_XDECREF(tmp_class_creation_6__class_decl_dict); - tmp_class_creation_6__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_6__metaclass); - tmp_class_creation_6__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_6__prepared); - Py_DECREF(tmp_class_creation_6__prepared); - tmp_class_creation_6__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_91; - PyObject *tmp_tuple_element_25; - PyObject *tmp_expression_name_38; - tmp_expression_name_38 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_38 == NULL)) { - tmp_expression_name_38 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_38 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_tuple_element_25 = LOOKUP_ATTRIBUTE(tmp_expression_name_38, mod_consts[325]); - if (tmp_tuple_element_25 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_assign_source_91 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_91, 0, tmp_tuple_element_25); - assert(tmp_class_creation_7__bases_orig == NULL); - tmp_class_creation_7__bases_orig = tmp_assign_source_91; - } - { - PyObject *tmp_assign_source_92; - PyObject *tmp_dircall_arg1_7; - CHECK_OBJECT(tmp_class_creation_7__bases_orig); - tmp_dircall_arg1_7 = tmp_class_creation_7__bases_orig; - Py_INCREF(tmp_dircall_arg1_7); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_7}; - tmp_assign_source_92 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_92 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - assert(tmp_class_creation_7__bases == NULL); - tmp_class_creation_7__bases = tmp_assign_source_92; - } - { - PyObject *tmp_assign_source_93; - tmp_assign_source_93 = PyDict_New(); - assert(tmp_class_creation_7__class_decl_dict == NULL); - tmp_class_creation_7__class_decl_dict = tmp_assign_source_93; - } - { - PyObject *tmp_assign_source_94; - PyObject *tmp_metaclass_name_7; - nuitka_bool tmp_condition_result_37; - PyObject *tmp_key_name_19; - PyObject *tmp_dict_arg_name_19; - PyObject *tmp_dict_arg_name_20; - PyObject *tmp_key_name_20; - nuitka_bool tmp_condition_result_38; - int tmp_truth_name_7; - PyObject *tmp_type_arg_13; - PyObject *tmp_expression_name_39; - PyObject *tmp_subscript_name_7; - PyObject *tmp_bases_name_7; - tmp_key_name_19 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_7__class_decl_dict); - tmp_dict_arg_name_19 = tmp_class_creation_7__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_19, tmp_key_name_19); - assert(!(tmp_res == -1)); - tmp_condition_result_37 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_37 == NUITKA_BOOL_TRUE) { - goto condexpr_true_13; - } else { - goto condexpr_false_13; - } - condexpr_true_13:; - CHECK_OBJECT(tmp_class_creation_7__class_decl_dict); - tmp_dict_arg_name_20 = tmp_class_creation_7__class_decl_dict; - tmp_key_name_20 = mod_consts[326]; - tmp_metaclass_name_7 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_20, tmp_key_name_20); - if (tmp_metaclass_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - goto condexpr_end_13; - condexpr_false_13:; - CHECK_OBJECT(tmp_class_creation_7__bases); - tmp_truth_name_7 = CHECK_IF_TRUE(tmp_class_creation_7__bases); - if (tmp_truth_name_7 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_condition_result_38 = tmp_truth_name_7 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_38 == NUITKA_BOOL_TRUE) { - goto condexpr_true_14; - } else { - goto condexpr_false_14; - } - condexpr_true_14:; - CHECK_OBJECT(tmp_class_creation_7__bases); - tmp_expression_name_39 = tmp_class_creation_7__bases; - tmp_subscript_name_7 = mod_consts[29]; - tmp_type_arg_13 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_39, tmp_subscript_name_7, 0); - if (tmp_type_arg_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_metaclass_name_7 = BUILTIN_TYPE1(tmp_type_arg_13); - Py_DECREF(tmp_type_arg_13); - if (tmp_metaclass_name_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - goto condexpr_end_14; - condexpr_false_14:; - tmp_metaclass_name_7 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_7); - condexpr_end_14:; - condexpr_end_13:; - CHECK_OBJECT(tmp_class_creation_7__bases); - tmp_bases_name_7 = tmp_class_creation_7__bases; - tmp_assign_source_94 = SELECT_METACLASS(tmp_metaclass_name_7, tmp_bases_name_7); - Py_DECREF(tmp_metaclass_name_7); - if (tmp_assign_source_94 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - assert(tmp_class_creation_7__metaclass == NULL); - tmp_class_creation_7__metaclass = tmp_assign_source_94; - } - { - nuitka_bool tmp_condition_result_39; - PyObject *tmp_key_name_21; - PyObject *tmp_dict_arg_name_21; - tmp_key_name_21 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_7__class_decl_dict); - tmp_dict_arg_name_21 = tmp_class_creation_7__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_21, tmp_key_name_21); - assert(!(tmp_res == -1)); - tmp_condition_result_39 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_39 == NUITKA_BOOL_TRUE) { - goto branch_yes_25; - } else { - goto branch_no_25; - } - } - branch_yes_25:; - CHECK_OBJECT(tmp_class_creation_7__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_7__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - branch_no_25:; - { - nuitka_bool tmp_condition_result_40; - PyObject *tmp_expression_name_40; - CHECK_OBJECT(tmp_class_creation_7__metaclass); - tmp_expression_name_40 = tmp_class_creation_7__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_40, mod_consts[327]); - tmp_condition_result_40 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_40 == NUITKA_BOOL_TRUE) { - goto branch_yes_26; - } else { - goto branch_no_26; - } - } - branch_yes_26:; - { - PyObject *tmp_assign_source_95; - PyObject *tmp_called_name_14; - PyObject *tmp_expression_name_41; - PyObject *tmp_args_name_13; - PyObject *tmp_tuple_element_26; - PyObject *tmp_kwargs_name_13; - CHECK_OBJECT(tmp_class_creation_7__metaclass); - tmp_expression_name_41 = tmp_class_creation_7__metaclass; - tmp_called_name_14 = LOOKUP_ATTRIBUTE(tmp_expression_name_41, mod_consts[327]); - if (tmp_called_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_tuple_element_26 = mod_consts[139]; - tmp_args_name_13 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_13, 0, tmp_tuple_element_26); - CHECK_OBJECT(tmp_class_creation_7__bases); - tmp_tuple_element_26 = tmp_class_creation_7__bases; - PyTuple_SET_ITEM0(tmp_args_name_13, 1, tmp_tuple_element_26); - CHECK_OBJECT(tmp_class_creation_7__class_decl_dict); - tmp_kwargs_name_13 = tmp_class_creation_7__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 378; - tmp_assign_source_95 = CALL_FUNCTION(tmp_called_name_14, tmp_args_name_13, tmp_kwargs_name_13); - Py_DECREF(tmp_called_name_14); - Py_DECREF(tmp_args_name_13); - if (tmp_assign_source_95 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - assert(tmp_class_creation_7__prepared == NULL); - tmp_class_creation_7__prepared = tmp_assign_source_95; - } - { - nuitka_bool tmp_condition_result_41; - PyObject *tmp_operand_name_7; - PyObject *tmp_expression_name_42; - CHECK_OBJECT(tmp_class_creation_7__prepared); - tmp_expression_name_42 = tmp_class_creation_7__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_42, mod_consts[328]); - tmp_operand_name_7 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_7); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_condition_result_41 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_41 == NUITKA_BOOL_TRUE) { - goto branch_yes_27; - } else { - goto branch_no_27; - } - } - branch_yes_27:; - { - PyObject *tmp_raise_type_7; - PyObject *tmp_raise_value_7; - PyObject *tmp_left_name_7; - PyObject *tmp_right_name_7; - PyObject *tmp_tuple_element_27; - PyObject *tmp_getattr_target_7; - PyObject *tmp_getattr_attr_7; - PyObject *tmp_getattr_default_7; - tmp_raise_type_7 = PyExc_TypeError; - tmp_left_name_7 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_7__metaclass); - tmp_getattr_target_7 = tmp_class_creation_7__metaclass; - tmp_getattr_attr_7 = mod_consts[324]; - tmp_getattr_default_7 = mod_consts[330]; - tmp_tuple_element_27 = BUILTIN_GETATTR(tmp_getattr_target_7, tmp_getattr_attr_7, tmp_getattr_default_7); - if (tmp_tuple_element_27 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - tmp_right_name_7 = PyTuple_New(2); - { - PyObject *tmp_expression_name_43; - PyObject *tmp_type_arg_14; - PyTuple_SET_ITEM(tmp_right_name_7, 0, tmp_tuple_element_27); - CHECK_OBJECT(tmp_class_creation_7__prepared); - tmp_type_arg_14 = tmp_class_creation_7__prepared; - tmp_expression_name_43 = BUILTIN_TYPE1(tmp_type_arg_14); - assert(!(tmp_expression_name_43 == NULL)); - tmp_tuple_element_27 = LOOKUP_ATTRIBUTE(tmp_expression_name_43, mod_consts[324]); - Py_DECREF(tmp_expression_name_43); - if (tmp_tuple_element_27 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto tuple_build_exception_7; - } - PyTuple_SET_ITEM(tmp_right_name_7, 1, tmp_tuple_element_27); - } - goto tuple_build_noexception_7; - // Exception handling pass through code for tuple_build: - tuple_build_exception_7:; - Py_DECREF(tmp_right_name_7); - goto try_except_handler_23; - // Finished with no exception for tuple_build: - tuple_build_noexception_7:; - tmp_raise_value_7 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_7, tmp_right_name_7); - Py_DECREF(tmp_right_name_7); - if (tmp_raise_value_7 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_23; - } - exception_type = tmp_raise_type_7; - Py_INCREF(tmp_raise_type_7); - exception_value = tmp_raise_value_7; - exception_lineno = 378; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_23; - } - branch_no_27:; - goto branch_end_26; - branch_no_26:; - { - PyObject *tmp_assign_source_96; - tmp_assign_source_96 = PyDict_New(); - assert(tmp_class_creation_7__prepared == NULL); - tmp_class_creation_7__prepared = tmp_assign_source_96; - } - branch_end_26:; - { - PyObject *tmp_assign_source_97; - { - PyObject *tmp_set_locals_7; - CHECK_OBJECT(tmp_class_creation_7__prepared); - tmp_set_locals_7 = tmp_class_creation_7__prepared; - locals_models$Qformer$$$class__7_BertLayer_378 = tmp_set_locals_7; - Py_INCREF(tmp_set_locals_7); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_25; - } - tmp_dictset_value = mod_consts[139]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_25; - } - if (isFrameUnusable(cache_frame_a081438c9da0f662f5a4de30a72f53eb_8)) { - Py_XDECREF(cache_frame_a081438c9da0f662f5a4de30a72f53eb_8); - -#if _DEBUG_REFCOUNTS - if (cache_frame_a081438c9da0f662f5a4de30a72f53eb_8 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_a081438c9da0f662f5a4de30a72f53eb_8 = MAKE_FUNCTION_FRAME(codeobj_a081438c9da0f662f5a4de30a72f53eb, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_a081438c9da0f662f5a4de30a72f53eb_8->m_type_description == NULL); - frame_a081438c9da0f662f5a4de30a72f53eb_8 = cache_frame_a081438c9da0f662f5a4de30a72f53eb_8; - - // Push the new frame as the currently active one. - pushFrameStack(frame_a081438c9da0f662f5a4de30a72f53eb_8); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_a081438c9da0f662f5a4de30a72f53eb_8) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_7[1]; - - tmp_closure_7[0] = outline_6_var___class__; - Py_INCREF(tmp_closure_7[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__19___init__(tmp_closure_7); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 379; - type_description_2 = "c"; - goto frame_exception_exit_8; - } - } - { - PyObject *tmp_defaults_5; - tmp_defaults_5 = mod_consts[360]; - Py_INCREF(tmp_defaults_5); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__20_forward(tmp_defaults_5); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 402; - type_description_2 = "c"; - goto frame_exception_exit_8; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__21_feed_forward_chunk(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[133], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 476; - type_description_2 = "c"; - goto frame_exception_exit_8; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__22_feed_forward_chunk_query(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[131], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 481; - type_description_2 = "c"; - goto frame_exception_exit_8; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_a081438c9da0f662f5a4de30a72f53eb_8); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_7; - - frame_exception_exit_8:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_a081438c9da0f662f5a4de30a72f53eb_8); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_a081438c9da0f662f5a4de30a72f53eb_8, exception_lineno); - } else if (exception_tb->tb_frame != &frame_a081438c9da0f662f5a4de30a72f53eb_8->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_a081438c9da0f662f5a4de30a72f53eb_8, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_a081438c9da0f662f5a4de30a72f53eb_8, - type_description_2, - outline_6_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_a081438c9da0f662f5a4de30a72f53eb_8 == cache_frame_a081438c9da0f662f5a4de30a72f53eb_8) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_a081438c9da0f662f5a4de30a72f53eb_8); - cache_frame_a081438c9da0f662f5a4de30a72f53eb_8 = NULL; - } - - assertFrameObject(frame_a081438c9da0f662f5a4de30a72f53eb_8); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_7; - - frame_no_exception_7:; - goto skip_nested_handling_7; - nested_frame_exit_7:; - - goto try_except_handler_25; - skip_nested_handling_7:; - { - nuitka_bool tmp_condition_result_42; - PyObject *tmp_compexpr_left_7; - PyObject *tmp_compexpr_right_7; - CHECK_OBJECT(tmp_class_creation_7__bases); - tmp_compexpr_left_7 = tmp_class_creation_7__bases; - CHECK_OBJECT(tmp_class_creation_7__bases_orig); - tmp_compexpr_right_7 = tmp_class_creation_7__bases_orig; - tmp_condition_result_42 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_7, tmp_compexpr_right_7); - if (tmp_condition_result_42 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_25; - } - if (tmp_condition_result_42 == NUITKA_BOOL_TRUE) { - goto branch_yes_28; - } else { - goto branch_no_28; - } - assert(tmp_condition_result_42 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_28:; - CHECK_OBJECT(tmp_class_creation_7__bases_orig); - tmp_dictset_value = tmp_class_creation_7__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__7_BertLayer_378, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_25; - } - branch_no_28:; - { - PyObject *tmp_assign_source_98; - PyObject *tmp_called_name_15; - PyObject *tmp_args_name_14; - PyObject *tmp_tuple_element_28; - PyObject *tmp_kwargs_name_14; - CHECK_OBJECT(tmp_class_creation_7__metaclass); - tmp_called_name_15 = tmp_class_creation_7__metaclass; - tmp_tuple_element_28 = mod_consts[139]; - tmp_args_name_14 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_14, 0, tmp_tuple_element_28); - CHECK_OBJECT(tmp_class_creation_7__bases); - tmp_tuple_element_28 = tmp_class_creation_7__bases; - PyTuple_SET_ITEM0(tmp_args_name_14, 1, tmp_tuple_element_28); - tmp_tuple_element_28 = locals_models$Qformer$$$class__7_BertLayer_378; - PyTuple_SET_ITEM0(tmp_args_name_14, 2, tmp_tuple_element_28); - CHECK_OBJECT(tmp_class_creation_7__class_decl_dict); - tmp_kwargs_name_14 = tmp_class_creation_7__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 378; - tmp_assign_source_98 = CALL_FUNCTION(tmp_called_name_15, tmp_args_name_14, tmp_kwargs_name_14); - Py_DECREF(tmp_args_name_14); - if (tmp_assign_source_98 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 378; - - goto try_except_handler_25; - } - { - PyObject *old = Nuitka_Cell_GET(outline_6_var___class__); - PyCell_SET(outline_6_var___class__, tmp_assign_source_98); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_6_var___class__)); - tmp_assign_source_97 = Nuitka_Cell_GET(outline_6_var___class__); - Py_INCREF(tmp_assign_source_97); - goto try_return_handler_25; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_25:; - Py_DECREF(locals_models$Qformer$$$class__7_BertLayer_378); - locals_models$Qformer$$$class__7_BertLayer_378 = NULL; - goto try_return_handler_24; - // Exception handler code: - try_except_handler_25:; - exception_keeper_type_23 = exception_type; - exception_keeper_value_23 = exception_value; - exception_keeper_tb_23 = exception_tb; - exception_keeper_lineno_23 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__7_BertLayer_378); - locals_models$Qformer$$$class__7_BertLayer_378 = NULL; - // Re-raise. - exception_type = exception_keeper_type_23; - exception_value = exception_keeper_value_23; - exception_tb = exception_keeper_tb_23; - exception_lineno = exception_keeper_lineno_23; - - goto try_except_handler_24; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_24:; - CHECK_OBJECT(outline_6_var___class__); - Py_DECREF(outline_6_var___class__); - outline_6_var___class__ = NULL; - goto outline_result_7; - // Exception handler code: - try_except_handler_24:; - exception_keeper_type_24 = exception_type; - exception_keeper_value_24 = exception_value; - exception_keeper_tb_24 = exception_tb; - exception_keeper_lineno_24 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_6_var___class__); - Py_DECREF(outline_6_var___class__); - outline_6_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_24; - exception_value = exception_keeper_value_24; - exception_tb = exception_keeper_tb_24; - exception_lineno = exception_keeper_lineno_24; - - goto outline_exception_7; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_7:; - exception_lineno = 378; - goto try_except_handler_23; - outline_result_7:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[139], tmp_assign_source_97); - } - goto try_end_11; - // Exception handler code: - try_except_handler_23:; - exception_keeper_type_25 = exception_type; - exception_keeper_value_25 = exception_value; - exception_keeper_tb_25 = exception_tb; - exception_keeper_lineno_25 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_7__bases_orig); - tmp_class_creation_7__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_7__bases); - tmp_class_creation_7__bases = NULL; - Py_XDECREF(tmp_class_creation_7__class_decl_dict); - tmp_class_creation_7__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_7__metaclass); - tmp_class_creation_7__metaclass = NULL; - Py_XDECREF(tmp_class_creation_7__prepared); - tmp_class_creation_7__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_25; - exception_value = exception_keeper_value_25; - exception_tb = exception_keeper_tb_25; - exception_lineno = exception_keeper_lineno_25; - - goto frame_exception_exit_1; - // End of try: - try_end_11:; - CHECK_OBJECT(tmp_class_creation_7__bases_orig); - Py_DECREF(tmp_class_creation_7__bases_orig); - tmp_class_creation_7__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_7__bases); - tmp_class_creation_7__bases = NULL; - Py_XDECREF(tmp_class_creation_7__class_decl_dict); - tmp_class_creation_7__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_7__metaclass); - tmp_class_creation_7__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_7__prepared); - Py_DECREF(tmp_class_creation_7__prepared); - tmp_class_creation_7__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_99; - PyObject *tmp_tuple_element_29; - PyObject *tmp_expression_name_44; - tmp_expression_name_44 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_44 == NULL)) { - tmp_expression_name_44 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_44 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_tuple_element_29 = LOOKUP_ATTRIBUTE(tmp_expression_name_44, mod_consts[325]); - if (tmp_tuple_element_29 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_assign_source_99 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_99, 0, tmp_tuple_element_29); - assert(tmp_class_creation_8__bases_orig == NULL); - tmp_class_creation_8__bases_orig = tmp_assign_source_99; - } - { - PyObject *tmp_assign_source_100; - PyObject *tmp_dircall_arg1_8; - CHECK_OBJECT(tmp_class_creation_8__bases_orig); - tmp_dircall_arg1_8 = tmp_class_creation_8__bases_orig; - Py_INCREF(tmp_dircall_arg1_8); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_8}; - tmp_assign_source_100 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_100 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - assert(tmp_class_creation_8__bases == NULL); - tmp_class_creation_8__bases = tmp_assign_source_100; - } - { - PyObject *tmp_assign_source_101; - tmp_assign_source_101 = PyDict_New(); - assert(tmp_class_creation_8__class_decl_dict == NULL); - tmp_class_creation_8__class_decl_dict = tmp_assign_source_101; - } - { - PyObject *tmp_assign_source_102; - PyObject *tmp_metaclass_name_8; - nuitka_bool tmp_condition_result_43; - PyObject *tmp_key_name_22; - PyObject *tmp_dict_arg_name_22; - PyObject *tmp_dict_arg_name_23; - PyObject *tmp_key_name_23; - nuitka_bool tmp_condition_result_44; - int tmp_truth_name_8; - PyObject *tmp_type_arg_15; - PyObject *tmp_expression_name_45; - PyObject *tmp_subscript_name_8; - PyObject *tmp_bases_name_8; - tmp_key_name_22 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_8__class_decl_dict); - tmp_dict_arg_name_22 = tmp_class_creation_8__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_22, tmp_key_name_22); - assert(!(tmp_res == -1)); - tmp_condition_result_43 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_43 == NUITKA_BOOL_TRUE) { - goto condexpr_true_15; - } else { - goto condexpr_false_15; - } - condexpr_true_15:; - CHECK_OBJECT(tmp_class_creation_8__class_decl_dict); - tmp_dict_arg_name_23 = tmp_class_creation_8__class_decl_dict; - tmp_key_name_23 = mod_consts[326]; - tmp_metaclass_name_8 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_23, tmp_key_name_23); - if (tmp_metaclass_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - goto condexpr_end_15; - condexpr_false_15:; - CHECK_OBJECT(tmp_class_creation_8__bases); - tmp_truth_name_8 = CHECK_IF_TRUE(tmp_class_creation_8__bases); - if (tmp_truth_name_8 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_condition_result_44 = tmp_truth_name_8 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_44 == NUITKA_BOOL_TRUE) { - goto condexpr_true_16; - } else { - goto condexpr_false_16; - } - condexpr_true_16:; - CHECK_OBJECT(tmp_class_creation_8__bases); - tmp_expression_name_45 = tmp_class_creation_8__bases; - tmp_subscript_name_8 = mod_consts[29]; - tmp_type_arg_15 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_45, tmp_subscript_name_8, 0); - if (tmp_type_arg_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_metaclass_name_8 = BUILTIN_TYPE1(tmp_type_arg_15); - Py_DECREF(tmp_type_arg_15); - if (tmp_metaclass_name_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - goto condexpr_end_16; - condexpr_false_16:; - tmp_metaclass_name_8 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_8); - condexpr_end_16:; - condexpr_end_15:; - CHECK_OBJECT(tmp_class_creation_8__bases); - tmp_bases_name_8 = tmp_class_creation_8__bases; - tmp_assign_source_102 = SELECT_METACLASS(tmp_metaclass_name_8, tmp_bases_name_8); - Py_DECREF(tmp_metaclass_name_8); - if (tmp_assign_source_102 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - assert(tmp_class_creation_8__metaclass == NULL); - tmp_class_creation_8__metaclass = tmp_assign_source_102; - } - { - nuitka_bool tmp_condition_result_45; - PyObject *tmp_key_name_24; - PyObject *tmp_dict_arg_name_24; - tmp_key_name_24 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_8__class_decl_dict); - tmp_dict_arg_name_24 = tmp_class_creation_8__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_24, tmp_key_name_24); - assert(!(tmp_res == -1)); - tmp_condition_result_45 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_45 == NUITKA_BOOL_TRUE) { - goto branch_yes_29; - } else { - goto branch_no_29; - } - } - branch_yes_29:; - CHECK_OBJECT(tmp_class_creation_8__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_8__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - branch_no_29:; - { - nuitka_bool tmp_condition_result_46; - PyObject *tmp_expression_name_46; - CHECK_OBJECT(tmp_class_creation_8__metaclass); - tmp_expression_name_46 = tmp_class_creation_8__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_46, mod_consts[327]); - tmp_condition_result_46 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_46 == NUITKA_BOOL_TRUE) { - goto branch_yes_30; - } else { - goto branch_no_30; - } - } - branch_yes_30:; - { - PyObject *tmp_assign_source_103; - PyObject *tmp_called_name_16; - PyObject *tmp_expression_name_47; - PyObject *tmp_args_name_15; - PyObject *tmp_tuple_element_30; - PyObject *tmp_kwargs_name_15; - CHECK_OBJECT(tmp_class_creation_8__metaclass); - tmp_expression_name_47 = tmp_class_creation_8__metaclass; - tmp_called_name_16 = LOOKUP_ATTRIBUTE(tmp_expression_name_47, mod_consts[327]); - if (tmp_called_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_tuple_element_30 = mod_consts[194]; - tmp_args_name_15 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_15, 0, tmp_tuple_element_30); - CHECK_OBJECT(tmp_class_creation_8__bases); - tmp_tuple_element_30 = tmp_class_creation_8__bases; - PyTuple_SET_ITEM0(tmp_args_name_15, 1, tmp_tuple_element_30); - CHECK_OBJECT(tmp_class_creation_8__class_decl_dict); - tmp_kwargs_name_15 = tmp_class_creation_8__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 487; - tmp_assign_source_103 = CALL_FUNCTION(tmp_called_name_16, tmp_args_name_15, tmp_kwargs_name_15); - Py_DECREF(tmp_called_name_16); - Py_DECREF(tmp_args_name_15); - if (tmp_assign_source_103 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - assert(tmp_class_creation_8__prepared == NULL); - tmp_class_creation_8__prepared = tmp_assign_source_103; - } - { - nuitka_bool tmp_condition_result_47; - PyObject *tmp_operand_name_8; - PyObject *tmp_expression_name_48; - CHECK_OBJECT(tmp_class_creation_8__prepared); - tmp_expression_name_48 = tmp_class_creation_8__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_48, mod_consts[328]); - tmp_operand_name_8 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_8); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_condition_result_47 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_47 == NUITKA_BOOL_TRUE) { - goto branch_yes_31; - } else { - goto branch_no_31; - } - } - branch_yes_31:; - { - PyObject *tmp_raise_type_8; - PyObject *tmp_raise_value_8; - PyObject *tmp_left_name_8; - PyObject *tmp_right_name_8; - PyObject *tmp_tuple_element_31; - PyObject *tmp_getattr_target_8; - PyObject *tmp_getattr_attr_8; - PyObject *tmp_getattr_default_8; - tmp_raise_type_8 = PyExc_TypeError; - tmp_left_name_8 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_8__metaclass); - tmp_getattr_target_8 = tmp_class_creation_8__metaclass; - tmp_getattr_attr_8 = mod_consts[324]; - tmp_getattr_default_8 = mod_consts[330]; - tmp_tuple_element_31 = BUILTIN_GETATTR(tmp_getattr_target_8, tmp_getattr_attr_8, tmp_getattr_default_8); - if (tmp_tuple_element_31 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - tmp_right_name_8 = PyTuple_New(2); - { - PyObject *tmp_expression_name_49; - PyObject *tmp_type_arg_16; - PyTuple_SET_ITEM(tmp_right_name_8, 0, tmp_tuple_element_31); - CHECK_OBJECT(tmp_class_creation_8__prepared); - tmp_type_arg_16 = tmp_class_creation_8__prepared; - tmp_expression_name_49 = BUILTIN_TYPE1(tmp_type_arg_16); - assert(!(tmp_expression_name_49 == NULL)); - tmp_tuple_element_31 = LOOKUP_ATTRIBUTE(tmp_expression_name_49, mod_consts[324]); - Py_DECREF(tmp_expression_name_49); - if (tmp_tuple_element_31 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto tuple_build_exception_8; - } - PyTuple_SET_ITEM(tmp_right_name_8, 1, tmp_tuple_element_31); - } - goto tuple_build_noexception_8; - // Exception handling pass through code for tuple_build: - tuple_build_exception_8:; - Py_DECREF(tmp_right_name_8); - goto try_except_handler_26; - // Finished with no exception for tuple_build: - tuple_build_noexception_8:; - tmp_raise_value_8 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_8, tmp_right_name_8); - Py_DECREF(tmp_right_name_8); - if (tmp_raise_value_8 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_26; - } - exception_type = tmp_raise_type_8; - Py_INCREF(tmp_raise_type_8); - exception_value = tmp_raise_value_8; - exception_lineno = 487; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_26; - } - branch_no_31:; - goto branch_end_30; - branch_no_30:; - { - PyObject *tmp_assign_source_104; - tmp_assign_source_104 = PyDict_New(); - assert(tmp_class_creation_8__prepared == NULL); - tmp_class_creation_8__prepared = tmp_assign_source_104; - } - branch_end_30:; - { - PyObject *tmp_assign_source_105; - { - PyObject *tmp_set_locals_8; - CHECK_OBJECT(tmp_class_creation_8__prepared); - tmp_set_locals_8 = tmp_class_creation_8__prepared; - locals_models$Qformer$$$class__8_BertEncoder_487 = tmp_set_locals_8; - Py_INCREF(tmp_set_locals_8); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__8_BertEncoder_487, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_28; - } - tmp_dictset_value = mod_consts[194]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__8_BertEncoder_487, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_28; - } - if (isFrameUnusable(cache_frame_e1623af249db2190f4f0a833e30e71e3_9)) { - Py_XDECREF(cache_frame_e1623af249db2190f4f0a833e30e71e3_9); - -#if _DEBUG_REFCOUNTS - if (cache_frame_e1623af249db2190f4f0a833e30e71e3_9 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_e1623af249db2190f4f0a833e30e71e3_9 = MAKE_FUNCTION_FRAME(codeobj_e1623af249db2190f4f0a833e30e71e3, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_e1623af249db2190f4f0a833e30e71e3_9->m_type_description == NULL); - frame_e1623af249db2190f4f0a833e30e71e3_9 = cache_frame_e1623af249db2190f4f0a833e30e71e3_9; - - // Push the new frame as the currently active one. - pushFrameStack(frame_e1623af249db2190f4f0a833e30e71e3_9); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_e1623af249db2190f4f0a833e30e71e3_9) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_8[1]; - - tmp_closure_8[0] = outline_7_var___class__; - Py_INCREF(tmp_closure_8[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__23___init__(tmp_closure_8); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__8_BertEncoder_487, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 488; - type_description_2 = "c"; - goto frame_exception_exit_9; - } - } - { - PyObject *tmp_defaults_6; - tmp_defaults_6 = mod_consts[365]; - Py_INCREF(tmp_defaults_6); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__24_forward(tmp_defaults_6); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__8_BertEncoder_487, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 495; - type_description_2 = "c"; - goto frame_exception_exit_9; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e1623af249db2190f4f0a833e30e71e3_9); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_8; - - frame_exception_exit_9:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e1623af249db2190f4f0a833e30e71e3_9); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_e1623af249db2190f4f0a833e30e71e3_9, exception_lineno); - } else if (exception_tb->tb_frame != &frame_e1623af249db2190f4f0a833e30e71e3_9->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_e1623af249db2190f4f0a833e30e71e3_9, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_e1623af249db2190f4f0a833e30e71e3_9, - type_description_2, - outline_7_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_e1623af249db2190f4f0a833e30e71e3_9 == cache_frame_e1623af249db2190f4f0a833e30e71e3_9) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_e1623af249db2190f4f0a833e30e71e3_9); - cache_frame_e1623af249db2190f4f0a833e30e71e3_9 = NULL; - } - - assertFrameObject(frame_e1623af249db2190f4f0a833e30e71e3_9); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_8; - - frame_no_exception_8:; - goto skip_nested_handling_8; - nested_frame_exit_8:; - - goto try_except_handler_28; - skip_nested_handling_8:; - { - nuitka_bool tmp_condition_result_48; - PyObject *tmp_compexpr_left_8; - PyObject *tmp_compexpr_right_8; - CHECK_OBJECT(tmp_class_creation_8__bases); - tmp_compexpr_left_8 = tmp_class_creation_8__bases; - CHECK_OBJECT(tmp_class_creation_8__bases_orig); - tmp_compexpr_right_8 = tmp_class_creation_8__bases_orig; - tmp_condition_result_48 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_8, tmp_compexpr_right_8); - if (tmp_condition_result_48 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_28; - } - if (tmp_condition_result_48 == NUITKA_BOOL_TRUE) { - goto branch_yes_32; - } else { - goto branch_no_32; - } - assert(tmp_condition_result_48 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_32:; - CHECK_OBJECT(tmp_class_creation_8__bases_orig); - tmp_dictset_value = tmp_class_creation_8__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__8_BertEncoder_487, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_28; - } - branch_no_32:; - { - PyObject *tmp_assign_source_106; - PyObject *tmp_called_name_17; - PyObject *tmp_args_name_16; - PyObject *tmp_tuple_element_32; - PyObject *tmp_kwargs_name_16; - CHECK_OBJECT(tmp_class_creation_8__metaclass); - tmp_called_name_17 = tmp_class_creation_8__metaclass; - tmp_tuple_element_32 = mod_consts[194]; - tmp_args_name_16 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_16, 0, tmp_tuple_element_32); - CHECK_OBJECT(tmp_class_creation_8__bases); - tmp_tuple_element_32 = tmp_class_creation_8__bases; - PyTuple_SET_ITEM0(tmp_args_name_16, 1, tmp_tuple_element_32); - tmp_tuple_element_32 = locals_models$Qformer$$$class__8_BertEncoder_487; - PyTuple_SET_ITEM0(tmp_args_name_16, 2, tmp_tuple_element_32); - CHECK_OBJECT(tmp_class_creation_8__class_decl_dict); - tmp_kwargs_name_16 = tmp_class_creation_8__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 487; - tmp_assign_source_106 = CALL_FUNCTION(tmp_called_name_17, tmp_args_name_16, tmp_kwargs_name_16); - Py_DECREF(tmp_args_name_16); - if (tmp_assign_source_106 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 487; - - goto try_except_handler_28; - } - { - PyObject *old = Nuitka_Cell_GET(outline_7_var___class__); - PyCell_SET(outline_7_var___class__, tmp_assign_source_106); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_7_var___class__)); - tmp_assign_source_105 = Nuitka_Cell_GET(outline_7_var___class__); - Py_INCREF(tmp_assign_source_105); - goto try_return_handler_28; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_28:; - Py_DECREF(locals_models$Qformer$$$class__8_BertEncoder_487); - locals_models$Qformer$$$class__8_BertEncoder_487 = NULL; - goto try_return_handler_27; - // Exception handler code: - try_except_handler_28:; - exception_keeper_type_26 = exception_type; - exception_keeper_value_26 = exception_value; - exception_keeper_tb_26 = exception_tb; - exception_keeper_lineno_26 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__8_BertEncoder_487); - locals_models$Qformer$$$class__8_BertEncoder_487 = NULL; - // Re-raise. - exception_type = exception_keeper_type_26; - exception_value = exception_keeper_value_26; - exception_tb = exception_keeper_tb_26; - exception_lineno = exception_keeper_lineno_26; - - goto try_except_handler_27; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_27:; - CHECK_OBJECT(outline_7_var___class__); - Py_DECREF(outline_7_var___class__); - outline_7_var___class__ = NULL; - goto outline_result_8; - // Exception handler code: - try_except_handler_27:; - exception_keeper_type_27 = exception_type; - exception_keeper_value_27 = exception_value; - exception_keeper_tb_27 = exception_tb; - exception_keeper_lineno_27 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_7_var___class__); - Py_DECREF(outline_7_var___class__); - outline_7_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_27; - exception_value = exception_keeper_value_27; - exception_tb = exception_keeper_tb_27; - exception_lineno = exception_keeper_lineno_27; - - goto outline_exception_8; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_8:; - exception_lineno = 487; - goto try_except_handler_26; - outline_result_8:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[194], tmp_assign_source_105); - } - goto try_end_12; - // Exception handler code: - try_except_handler_26:; - exception_keeper_type_28 = exception_type; - exception_keeper_value_28 = exception_value; - exception_keeper_tb_28 = exception_tb; - exception_keeper_lineno_28 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_8__bases_orig); - tmp_class_creation_8__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_8__bases); - tmp_class_creation_8__bases = NULL; - Py_XDECREF(tmp_class_creation_8__class_decl_dict); - tmp_class_creation_8__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_8__metaclass); - tmp_class_creation_8__metaclass = NULL; - Py_XDECREF(tmp_class_creation_8__prepared); - tmp_class_creation_8__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_28; - exception_value = exception_keeper_value_28; - exception_tb = exception_keeper_tb_28; - exception_lineno = exception_keeper_lineno_28; - - goto frame_exception_exit_1; - // End of try: - try_end_12:; - CHECK_OBJECT(tmp_class_creation_8__bases_orig); - Py_DECREF(tmp_class_creation_8__bases_orig); - tmp_class_creation_8__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_8__bases); - tmp_class_creation_8__bases = NULL; - Py_XDECREF(tmp_class_creation_8__class_decl_dict); - tmp_class_creation_8__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_8__metaclass); - tmp_class_creation_8__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_8__prepared); - Py_DECREF(tmp_class_creation_8__prepared); - tmp_class_creation_8__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_107; - PyObject *tmp_tuple_element_33; - PyObject *tmp_expression_name_50; - tmp_expression_name_50 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_50 == NULL)) { - tmp_expression_name_50 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_50 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_tuple_element_33 = LOOKUP_ATTRIBUTE(tmp_expression_name_50, mod_consts[325]); - if (tmp_tuple_element_33 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_assign_source_107 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_107, 0, tmp_tuple_element_33); - assert(tmp_class_creation_9__bases_orig == NULL); - tmp_class_creation_9__bases_orig = tmp_assign_source_107; - } - { - PyObject *tmp_assign_source_108; - PyObject *tmp_dircall_arg1_9; - CHECK_OBJECT(tmp_class_creation_9__bases_orig); - tmp_dircall_arg1_9 = tmp_class_creation_9__bases_orig; - Py_INCREF(tmp_dircall_arg1_9); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_9}; - tmp_assign_source_108 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_108 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - assert(tmp_class_creation_9__bases == NULL); - tmp_class_creation_9__bases = tmp_assign_source_108; - } - { - PyObject *tmp_assign_source_109; - tmp_assign_source_109 = PyDict_New(); - assert(tmp_class_creation_9__class_decl_dict == NULL); - tmp_class_creation_9__class_decl_dict = tmp_assign_source_109; - } - { - PyObject *tmp_assign_source_110; - PyObject *tmp_metaclass_name_9; - nuitka_bool tmp_condition_result_49; - PyObject *tmp_key_name_25; - PyObject *tmp_dict_arg_name_25; - PyObject *tmp_dict_arg_name_26; - PyObject *tmp_key_name_26; - nuitka_bool tmp_condition_result_50; - int tmp_truth_name_9; - PyObject *tmp_type_arg_17; - PyObject *tmp_expression_name_51; - PyObject *tmp_subscript_name_9; - PyObject *tmp_bases_name_9; - tmp_key_name_25 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_9__class_decl_dict); - tmp_dict_arg_name_25 = tmp_class_creation_9__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_25, tmp_key_name_25); - assert(!(tmp_res == -1)); - tmp_condition_result_49 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_49 == NUITKA_BOOL_TRUE) { - goto condexpr_true_17; - } else { - goto condexpr_false_17; - } - condexpr_true_17:; - CHECK_OBJECT(tmp_class_creation_9__class_decl_dict); - tmp_dict_arg_name_26 = tmp_class_creation_9__class_decl_dict; - tmp_key_name_26 = mod_consts[326]; - tmp_metaclass_name_9 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_26, tmp_key_name_26); - if (tmp_metaclass_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - goto condexpr_end_17; - condexpr_false_17:; - CHECK_OBJECT(tmp_class_creation_9__bases); - tmp_truth_name_9 = CHECK_IF_TRUE(tmp_class_creation_9__bases); - if (tmp_truth_name_9 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_condition_result_50 = tmp_truth_name_9 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_50 == NUITKA_BOOL_TRUE) { - goto condexpr_true_18; - } else { - goto condexpr_false_18; - } - condexpr_true_18:; - CHECK_OBJECT(tmp_class_creation_9__bases); - tmp_expression_name_51 = tmp_class_creation_9__bases; - tmp_subscript_name_9 = mod_consts[29]; - tmp_type_arg_17 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_51, tmp_subscript_name_9, 0); - if (tmp_type_arg_17 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_metaclass_name_9 = BUILTIN_TYPE1(tmp_type_arg_17); - Py_DECREF(tmp_type_arg_17); - if (tmp_metaclass_name_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - goto condexpr_end_18; - condexpr_false_18:; - tmp_metaclass_name_9 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_9); - condexpr_end_18:; - condexpr_end_17:; - CHECK_OBJECT(tmp_class_creation_9__bases); - tmp_bases_name_9 = tmp_class_creation_9__bases; - tmp_assign_source_110 = SELECT_METACLASS(tmp_metaclass_name_9, tmp_bases_name_9); - Py_DECREF(tmp_metaclass_name_9); - if (tmp_assign_source_110 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - assert(tmp_class_creation_9__metaclass == NULL); - tmp_class_creation_9__metaclass = tmp_assign_source_110; - } - { - nuitka_bool tmp_condition_result_51; - PyObject *tmp_key_name_27; - PyObject *tmp_dict_arg_name_27; - tmp_key_name_27 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_9__class_decl_dict); - tmp_dict_arg_name_27 = tmp_class_creation_9__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_27, tmp_key_name_27); - assert(!(tmp_res == -1)); - tmp_condition_result_51 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_51 == NUITKA_BOOL_TRUE) { - goto branch_yes_33; - } else { - goto branch_no_33; - } - } - branch_yes_33:; - CHECK_OBJECT(tmp_class_creation_9__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_9__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - branch_no_33:; - { - nuitka_bool tmp_condition_result_52; - PyObject *tmp_expression_name_52; - CHECK_OBJECT(tmp_class_creation_9__metaclass); - tmp_expression_name_52 = tmp_class_creation_9__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_52, mod_consts[327]); - tmp_condition_result_52 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_52 == NUITKA_BOOL_TRUE) { - goto branch_yes_34; - } else { - goto branch_no_34; - } - } - branch_yes_34:; - { - PyObject *tmp_assign_source_111; - PyObject *tmp_called_name_18; - PyObject *tmp_expression_name_53; - PyObject *tmp_args_name_17; - PyObject *tmp_tuple_element_34; - PyObject *tmp_kwargs_name_17; - CHECK_OBJECT(tmp_class_creation_9__metaclass); - tmp_expression_name_53 = tmp_class_creation_9__metaclass; - tmp_called_name_18 = LOOKUP_ATTRIBUTE(tmp_expression_name_53, mod_consts[327]); - if (tmp_called_name_18 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_tuple_element_34 = mod_consts[196]; - tmp_args_name_17 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_17, 0, tmp_tuple_element_34); - CHECK_OBJECT(tmp_class_creation_9__bases); - tmp_tuple_element_34 = tmp_class_creation_9__bases; - PyTuple_SET_ITEM0(tmp_args_name_17, 1, tmp_tuple_element_34); - CHECK_OBJECT(tmp_class_creation_9__class_decl_dict); - tmp_kwargs_name_17 = tmp_class_creation_9__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 592; - tmp_assign_source_111 = CALL_FUNCTION(tmp_called_name_18, tmp_args_name_17, tmp_kwargs_name_17); - Py_DECREF(tmp_called_name_18); - Py_DECREF(tmp_args_name_17); - if (tmp_assign_source_111 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - assert(tmp_class_creation_9__prepared == NULL); - tmp_class_creation_9__prepared = tmp_assign_source_111; - } - { - nuitka_bool tmp_condition_result_53; - PyObject *tmp_operand_name_9; - PyObject *tmp_expression_name_54; - CHECK_OBJECT(tmp_class_creation_9__prepared); - tmp_expression_name_54 = tmp_class_creation_9__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_54, mod_consts[328]); - tmp_operand_name_9 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_9); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_condition_result_53 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_53 == NUITKA_BOOL_TRUE) { - goto branch_yes_35; - } else { - goto branch_no_35; - } - } - branch_yes_35:; - { - PyObject *tmp_raise_type_9; - PyObject *tmp_raise_value_9; - PyObject *tmp_left_name_9; - PyObject *tmp_right_name_9; - PyObject *tmp_tuple_element_35; - PyObject *tmp_getattr_target_9; - PyObject *tmp_getattr_attr_9; - PyObject *tmp_getattr_default_9; - tmp_raise_type_9 = PyExc_TypeError; - tmp_left_name_9 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_9__metaclass); - tmp_getattr_target_9 = tmp_class_creation_9__metaclass; - tmp_getattr_attr_9 = mod_consts[324]; - tmp_getattr_default_9 = mod_consts[330]; - tmp_tuple_element_35 = BUILTIN_GETATTR(tmp_getattr_target_9, tmp_getattr_attr_9, tmp_getattr_default_9); - if (tmp_tuple_element_35 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - tmp_right_name_9 = PyTuple_New(2); - { - PyObject *tmp_expression_name_55; - PyObject *tmp_type_arg_18; - PyTuple_SET_ITEM(tmp_right_name_9, 0, tmp_tuple_element_35); - CHECK_OBJECT(tmp_class_creation_9__prepared); - tmp_type_arg_18 = tmp_class_creation_9__prepared; - tmp_expression_name_55 = BUILTIN_TYPE1(tmp_type_arg_18); - assert(!(tmp_expression_name_55 == NULL)); - tmp_tuple_element_35 = LOOKUP_ATTRIBUTE(tmp_expression_name_55, mod_consts[324]); - Py_DECREF(tmp_expression_name_55); - if (tmp_tuple_element_35 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto tuple_build_exception_9; - } - PyTuple_SET_ITEM(tmp_right_name_9, 1, tmp_tuple_element_35); - } - goto tuple_build_noexception_9; - // Exception handling pass through code for tuple_build: - tuple_build_exception_9:; - Py_DECREF(tmp_right_name_9); - goto try_except_handler_29; - // Finished with no exception for tuple_build: - tuple_build_noexception_9:; - tmp_raise_value_9 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_9, tmp_right_name_9); - Py_DECREF(tmp_right_name_9); - if (tmp_raise_value_9 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_29; - } - exception_type = tmp_raise_type_9; - Py_INCREF(tmp_raise_type_9); - exception_value = tmp_raise_value_9; - exception_lineno = 592; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_29; - } - branch_no_35:; - goto branch_end_34; - branch_no_34:; - { - PyObject *tmp_assign_source_112; - tmp_assign_source_112 = PyDict_New(); - assert(tmp_class_creation_9__prepared == NULL); - tmp_class_creation_9__prepared = tmp_assign_source_112; - } - branch_end_34:; - { - PyObject *tmp_assign_source_113; - { - PyObject *tmp_set_locals_9; - CHECK_OBJECT(tmp_class_creation_9__prepared); - tmp_set_locals_9 = tmp_class_creation_9__prepared; - locals_models$Qformer$$$class__9_BertPooler_592 = tmp_set_locals_9; - Py_INCREF(tmp_set_locals_9); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__9_BertPooler_592, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_31; - } - tmp_dictset_value = mod_consts[196]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__9_BertPooler_592, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_31; - } - if (isFrameUnusable(cache_frame_ab5a99313f9b6e1e298f4606848400d8_10)) { - Py_XDECREF(cache_frame_ab5a99313f9b6e1e298f4606848400d8_10); - -#if _DEBUG_REFCOUNTS - if (cache_frame_ab5a99313f9b6e1e298f4606848400d8_10 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_ab5a99313f9b6e1e298f4606848400d8_10 = MAKE_FUNCTION_FRAME(codeobj_ab5a99313f9b6e1e298f4606848400d8, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_ab5a99313f9b6e1e298f4606848400d8_10->m_type_description == NULL); - frame_ab5a99313f9b6e1e298f4606848400d8_10 = cache_frame_ab5a99313f9b6e1e298f4606848400d8_10; - - // Push the new frame as the currently active one. - pushFrameStack(frame_ab5a99313f9b6e1e298f4606848400d8_10); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_ab5a99313f9b6e1e298f4606848400d8_10) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_9[1]; - - tmp_closure_9[0] = outline_8_var___class__; - Py_INCREF(tmp_closure_9[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__25___init__(tmp_closure_9); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__9_BertPooler_592, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 593; - type_description_2 = "c"; - goto frame_exception_exit_10; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__26_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__9_BertPooler_592, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 598; - type_description_2 = "c"; - goto frame_exception_exit_10; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ab5a99313f9b6e1e298f4606848400d8_10); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_9; - - frame_exception_exit_10:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_ab5a99313f9b6e1e298f4606848400d8_10); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_ab5a99313f9b6e1e298f4606848400d8_10, exception_lineno); - } else if (exception_tb->tb_frame != &frame_ab5a99313f9b6e1e298f4606848400d8_10->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_ab5a99313f9b6e1e298f4606848400d8_10, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_ab5a99313f9b6e1e298f4606848400d8_10, - type_description_2, - outline_8_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_ab5a99313f9b6e1e298f4606848400d8_10 == cache_frame_ab5a99313f9b6e1e298f4606848400d8_10) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_ab5a99313f9b6e1e298f4606848400d8_10); - cache_frame_ab5a99313f9b6e1e298f4606848400d8_10 = NULL; - } - - assertFrameObject(frame_ab5a99313f9b6e1e298f4606848400d8_10); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_9; - - frame_no_exception_9:; - goto skip_nested_handling_9; - nested_frame_exit_9:; - - goto try_except_handler_31; - skip_nested_handling_9:; - { - nuitka_bool tmp_condition_result_54; - PyObject *tmp_compexpr_left_9; - PyObject *tmp_compexpr_right_9; - CHECK_OBJECT(tmp_class_creation_9__bases); - tmp_compexpr_left_9 = tmp_class_creation_9__bases; - CHECK_OBJECT(tmp_class_creation_9__bases_orig); - tmp_compexpr_right_9 = tmp_class_creation_9__bases_orig; - tmp_condition_result_54 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_9, tmp_compexpr_right_9); - if (tmp_condition_result_54 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_31; - } - if (tmp_condition_result_54 == NUITKA_BOOL_TRUE) { - goto branch_yes_36; - } else { - goto branch_no_36; - } - assert(tmp_condition_result_54 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_36:; - CHECK_OBJECT(tmp_class_creation_9__bases_orig); - tmp_dictset_value = tmp_class_creation_9__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__9_BertPooler_592, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_31; - } - branch_no_36:; - { - PyObject *tmp_assign_source_114; - PyObject *tmp_called_name_19; - PyObject *tmp_args_name_18; - PyObject *tmp_tuple_element_36; - PyObject *tmp_kwargs_name_18; - CHECK_OBJECT(tmp_class_creation_9__metaclass); - tmp_called_name_19 = tmp_class_creation_9__metaclass; - tmp_tuple_element_36 = mod_consts[196]; - tmp_args_name_18 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_18, 0, tmp_tuple_element_36); - CHECK_OBJECT(tmp_class_creation_9__bases); - tmp_tuple_element_36 = tmp_class_creation_9__bases; - PyTuple_SET_ITEM0(tmp_args_name_18, 1, tmp_tuple_element_36); - tmp_tuple_element_36 = locals_models$Qformer$$$class__9_BertPooler_592; - PyTuple_SET_ITEM0(tmp_args_name_18, 2, tmp_tuple_element_36); - CHECK_OBJECT(tmp_class_creation_9__class_decl_dict); - tmp_kwargs_name_18 = tmp_class_creation_9__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 592; - tmp_assign_source_114 = CALL_FUNCTION(tmp_called_name_19, tmp_args_name_18, tmp_kwargs_name_18); - Py_DECREF(tmp_args_name_18); - if (tmp_assign_source_114 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 592; - - goto try_except_handler_31; - } - { - PyObject *old = Nuitka_Cell_GET(outline_8_var___class__); - PyCell_SET(outline_8_var___class__, tmp_assign_source_114); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_8_var___class__)); - tmp_assign_source_113 = Nuitka_Cell_GET(outline_8_var___class__); - Py_INCREF(tmp_assign_source_113); - goto try_return_handler_31; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_31:; - Py_DECREF(locals_models$Qformer$$$class__9_BertPooler_592); - locals_models$Qformer$$$class__9_BertPooler_592 = NULL; - goto try_return_handler_30; - // Exception handler code: - try_except_handler_31:; - exception_keeper_type_29 = exception_type; - exception_keeper_value_29 = exception_value; - exception_keeper_tb_29 = exception_tb; - exception_keeper_lineno_29 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__9_BertPooler_592); - locals_models$Qformer$$$class__9_BertPooler_592 = NULL; - // Re-raise. - exception_type = exception_keeper_type_29; - exception_value = exception_keeper_value_29; - exception_tb = exception_keeper_tb_29; - exception_lineno = exception_keeper_lineno_29; - - goto try_except_handler_30; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_30:; - CHECK_OBJECT(outline_8_var___class__); - Py_DECREF(outline_8_var___class__); - outline_8_var___class__ = NULL; - goto outline_result_9; - // Exception handler code: - try_except_handler_30:; - exception_keeper_type_30 = exception_type; - exception_keeper_value_30 = exception_value; - exception_keeper_tb_30 = exception_tb; - exception_keeper_lineno_30 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_8_var___class__); - Py_DECREF(outline_8_var___class__); - outline_8_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_30; - exception_value = exception_keeper_value_30; - exception_tb = exception_keeper_tb_30; - exception_lineno = exception_keeper_lineno_30; - - goto outline_exception_9; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_9:; - exception_lineno = 592; - goto try_except_handler_29; - outline_result_9:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[196], tmp_assign_source_113); - } - goto try_end_13; - // Exception handler code: - try_except_handler_29:; - exception_keeper_type_31 = exception_type; - exception_keeper_value_31 = exception_value; - exception_keeper_tb_31 = exception_tb; - exception_keeper_lineno_31 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_9__bases_orig); - tmp_class_creation_9__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_9__bases); - tmp_class_creation_9__bases = NULL; - Py_XDECREF(tmp_class_creation_9__class_decl_dict); - tmp_class_creation_9__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_9__metaclass); - tmp_class_creation_9__metaclass = NULL; - Py_XDECREF(tmp_class_creation_9__prepared); - tmp_class_creation_9__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_31; - exception_value = exception_keeper_value_31; - exception_tb = exception_keeper_tb_31; - exception_lineno = exception_keeper_lineno_31; - - goto frame_exception_exit_1; - // End of try: - try_end_13:; - CHECK_OBJECT(tmp_class_creation_9__bases_orig); - Py_DECREF(tmp_class_creation_9__bases_orig); - tmp_class_creation_9__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_9__bases); - tmp_class_creation_9__bases = NULL; - Py_XDECREF(tmp_class_creation_9__class_decl_dict); - tmp_class_creation_9__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_9__metaclass); - tmp_class_creation_9__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_9__prepared); - Py_DECREF(tmp_class_creation_9__prepared); - tmp_class_creation_9__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_115; - PyObject *tmp_tuple_element_37; - PyObject *tmp_expression_name_56; - tmp_expression_name_56 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_56 == NULL)) { - tmp_expression_name_56 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_56 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_tuple_element_37 = LOOKUP_ATTRIBUTE(tmp_expression_name_56, mod_consts[325]); - if (tmp_tuple_element_37 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_assign_source_115 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_115, 0, tmp_tuple_element_37); - assert(tmp_class_creation_10__bases_orig == NULL); - tmp_class_creation_10__bases_orig = tmp_assign_source_115; - } - { - PyObject *tmp_assign_source_116; - PyObject *tmp_dircall_arg1_10; - CHECK_OBJECT(tmp_class_creation_10__bases_orig); - tmp_dircall_arg1_10 = tmp_class_creation_10__bases_orig; - Py_INCREF(tmp_dircall_arg1_10); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_10}; - tmp_assign_source_116 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_116 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - assert(tmp_class_creation_10__bases == NULL); - tmp_class_creation_10__bases = tmp_assign_source_116; - } - { - PyObject *tmp_assign_source_117; - tmp_assign_source_117 = PyDict_New(); - assert(tmp_class_creation_10__class_decl_dict == NULL); - tmp_class_creation_10__class_decl_dict = tmp_assign_source_117; - } - { - PyObject *tmp_assign_source_118; - PyObject *tmp_metaclass_name_10; - nuitka_bool tmp_condition_result_55; - PyObject *tmp_key_name_28; - PyObject *tmp_dict_arg_name_28; - PyObject *tmp_dict_arg_name_29; - PyObject *tmp_key_name_29; - nuitka_bool tmp_condition_result_56; - int tmp_truth_name_10; - PyObject *tmp_type_arg_19; - PyObject *tmp_expression_name_57; - PyObject *tmp_subscript_name_10; - PyObject *tmp_bases_name_10; - tmp_key_name_28 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_10__class_decl_dict); - tmp_dict_arg_name_28 = tmp_class_creation_10__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_28, tmp_key_name_28); - assert(!(tmp_res == -1)); - tmp_condition_result_55 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_55 == NUITKA_BOOL_TRUE) { - goto condexpr_true_19; - } else { - goto condexpr_false_19; - } - condexpr_true_19:; - CHECK_OBJECT(tmp_class_creation_10__class_decl_dict); - tmp_dict_arg_name_29 = tmp_class_creation_10__class_decl_dict; - tmp_key_name_29 = mod_consts[326]; - tmp_metaclass_name_10 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_29, tmp_key_name_29); - if (tmp_metaclass_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - goto condexpr_end_19; - condexpr_false_19:; - CHECK_OBJECT(tmp_class_creation_10__bases); - tmp_truth_name_10 = CHECK_IF_TRUE(tmp_class_creation_10__bases); - if (tmp_truth_name_10 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_condition_result_56 = tmp_truth_name_10 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_56 == NUITKA_BOOL_TRUE) { - goto condexpr_true_20; - } else { - goto condexpr_false_20; - } - condexpr_true_20:; - CHECK_OBJECT(tmp_class_creation_10__bases); - tmp_expression_name_57 = tmp_class_creation_10__bases; - tmp_subscript_name_10 = mod_consts[29]; - tmp_type_arg_19 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_57, tmp_subscript_name_10, 0); - if (tmp_type_arg_19 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_metaclass_name_10 = BUILTIN_TYPE1(tmp_type_arg_19); - Py_DECREF(tmp_type_arg_19); - if (tmp_metaclass_name_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - goto condexpr_end_20; - condexpr_false_20:; - tmp_metaclass_name_10 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_10); - condexpr_end_20:; - condexpr_end_19:; - CHECK_OBJECT(tmp_class_creation_10__bases); - tmp_bases_name_10 = tmp_class_creation_10__bases; - tmp_assign_source_118 = SELECT_METACLASS(tmp_metaclass_name_10, tmp_bases_name_10); - Py_DECREF(tmp_metaclass_name_10); - if (tmp_assign_source_118 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - assert(tmp_class_creation_10__metaclass == NULL); - tmp_class_creation_10__metaclass = tmp_assign_source_118; - } - { - nuitka_bool tmp_condition_result_57; - PyObject *tmp_key_name_30; - PyObject *tmp_dict_arg_name_30; - tmp_key_name_30 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_10__class_decl_dict); - tmp_dict_arg_name_30 = tmp_class_creation_10__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_30, tmp_key_name_30); - assert(!(tmp_res == -1)); - tmp_condition_result_57 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_57 == NUITKA_BOOL_TRUE) { - goto branch_yes_37; - } else { - goto branch_no_37; - } - } - branch_yes_37:; - CHECK_OBJECT(tmp_class_creation_10__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_10__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - branch_no_37:; - { - nuitka_bool tmp_condition_result_58; - PyObject *tmp_expression_name_58; - CHECK_OBJECT(tmp_class_creation_10__metaclass); - tmp_expression_name_58 = tmp_class_creation_10__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_58, mod_consts[327]); - tmp_condition_result_58 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_58 == NUITKA_BOOL_TRUE) { - goto branch_yes_38; - } else { - goto branch_no_38; - } - } - branch_yes_38:; - { - PyObject *tmp_assign_source_119; - PyObject *tmp_called_name_20; - PyObject *tmp_expression_name_59; - PyObject *tmp_args_name_19; - PyObject *tmp_tuple_element_38; - PyObject *tmp_kwargs_name_19; - CHECK_OBJECT(tmp_class_creation_10__metaclass); - tmp_expression_name_59 = tmp_class_creation_10__metaclass; - tmp_called_name_20 = LOOKUP_ATTRIBUTE(tmp_expression_name_59, mod_consts[327]); - if (tmp_called_name_20 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_tuple_element_38 = mod_consts[173]; - tmp_args_name_19 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_19, 0, tmp_tuple_element_38); - CHECK_OBJECT(tmp_class_creation_10__bases); - tmp_tuple_element_38 = tmp_class_creation_10__bases; - PyTuple_SET_ITEM0(tmp_args_name_19, 1, tmp_tuple_element_38); - CHECK_OBJECT(tmp_class_creation_10__class_decl_dict); - tmp_kwargs_name_19 = tmp_class_creation_10__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 607; - tmp_assign_source_119 = CALL_FUNCTION(tmp_called_name_20, tmp_args_name_19, tmp_kwargs_name_19); - Py_DECREF(tmp_called_name_20); - Py_DECREF(tmp_args_name_19); - if (tmp_assign_source_119 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - assert(tmp_class_creation_10__prepared == NULL); - tmp_class_creation_10__prepared = tmp_assign_source_119; - } - { - nuitka_bool tmp_condition_result_59; - PyObject *tmp_operand_name_10; - PyObject *tmp_expression_name_60; - CHECK_OBJECT(tmp_class_creation_10__prepared); - tmp_expression_name_60 = tmp_class_creation_10__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_60, mod_consts[328]); - tmp_operand_name_10 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_10); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_condition_result_59 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_59 == NUITKA_BOOL_TRUE) { - goto branch_yes_39; - } else { - goto branch_no_39; - } - } - branch_yes_39:; - { - PyObject *tmp_raise_type_10; - PyObject *tmp_raise_value_10; - PyObject *tmp_left_name_10; - PyObject *tmp_right_name_10; - PyObject *tmp_tuple_element_39; - PyObject *tmp_getattr_target_10; - PyObject *tmp_getattr_attr_10; - PyObject *tmp_getattr_default_10; - tmp_raise_type_10 = PyExc_TypeError; - tmp_left_name_10 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_10__metaclass); - tmp_getattr_target_10 = tmp_class_creation_10__metaclass; - tmp_getattr_attr_10 = mod_consts[324]; - tmp_getattr_default_10 = mod_consts[330]; - tmp_tuple_element_39 = BUILTIN_GETATTR(tmp_getattr_target_10, tmp_getattr_attr_10, tmp_getattr_default_10); - if (tmp_tuple_element_39 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - tmp_right_name_10 = PyTuple_New(2); - { - PyObject *tmp_expression_name_61; - PyObject *tmp_type_arg_20; - PyTuple_SET_ITEM(tmp_right_name_10, 0, tmp_tuple_element_39); - CHECK_OBJECT(tmp_class_creation_10__prepared); - tmp_type_arg_20 = tmp_class_creation_10__prepared; - tmp_expression_name_61 = BUILTIN_TYPE1(tmp_type_arg_20); - assert(!(tmp_expression_name_61 == NULL)); - tmp_tuple_element_39 = LOOKUP_ATTRIBUTE(tmp_expression_name_61, mod_consts[324]); - Py_DECREF(tmp_expression_name_61); - if (tmp_tuple_element_39 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto tuple_build_exception_10; - } - PyTuple_SET_ITEM(tmp_right_name_10, 1, tmp_tuple_element_39); - } - goto tuple_build_noexception_10; - // Exception handling pass through code for tuple_build: - tuple_build_exception_10:; - Py_DECREF(tmp_right_name_10); - goto try_except_handler_32; - // Finished with no exception for tuple_build: - tuple_build_noexception_10:; - tmp_raise_value_10 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_10, tmp_right_name_10); - Py_DECREF(tmp_right_name_10); - if (tmp_raise_value_10 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_32; - } - exception_type = tmp_raise_type_10; - Py_INCREF(tmp_raise_type_10); - exception_value = tmp_raise_value_10; - exception_lineno = 607; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_32; - } - branch_no_39:; - goto branch_end_38; - branch_no_38:; - { - PyObject *tmp_assign_source_120; - tmp_assign_source_120 = PyDict_New(); - assert(tmp_class_creation_10__prepared == NULL); - tmp_class_creation_10__prepared = tmp_assign_source_120; - } - branch_end_38:; - { - PyObject *tmp_assign_source_121; - { - PyObject *tmp_set_locals_10; - CHECK_OBJECT(tmp_class_creation_10__prepared); - tmp_set_locals_10 = tmp_class_creation_10__prepared; - locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607 = tmp_set_locals_10; - Py_INCREF(tmp_set_locals_10); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_34; - } - tmp_dictset_value = mod_consts[173]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_34; - } - if (isFrameUnusable(cache_frame_1e694c28c1cb7b88d842a0230f304b37_11)) { - Py_XDECREF(cache_frame_1e694c28c1cb7b88d842a0230f304b37_11); - -#if _DEBUG_REFCOUNTS - if (cache_frame_1e694c28c1cb7b88d842a0230f304b37_11 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_1e694c28c1cb7b88d842a0230f304b37_11 = MAKE_FUNCTION_FRAME(codeobj_1e694c28c1cb7b88d842a0230f304b37, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_1e694c28c1cb7b88d842a0230f304b37_11->m_type_description == NULL); - frame_1e694c28c1cb7b88d842a0230f304b37_11 = cache_frame_1e694c28c1cb7b88d842a0230f304b37_11; - - // Push the new frame as the currently active one. - pushFrameStack(frame_1e694c28c1cb7b88d842a0230f304b37_11); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_1e694c28c1cb7b88d842a0230f304b37_11) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_10[1]; - - tmp_closure_10[0] = outline_9_var___class__; - Py_INCREF(tmp_closure_10[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__27___init__(tmp_closure_10); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 608; - type_description_2 = "c"; - goto frame_exception_exit_11; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__28_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 617; - type_description_2 = "c"; - goto frame_exception_exit_11; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_1e694c28c1cb7b88d842a0230f304b37_11); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_10; - - frame_exception_exit_11:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_1e694c28c1cb7b88d842a0230f304b37_11); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_1e694c28c1cb7b88d842a0230f304b37_11, exception_lineno); - } else if (exception_tb->tb_frame != &frame_1e694c28c1cb7b88d842a0230f304b37_11->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_1e694c28c1cb7b88d842a0230f304b37_11, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_1e694c28c1cb7b88d842a0230f304b37_11, - type_description_2, - outline_9_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_1e694c28c1cb7b88d842a0230f304b37_11 == cache_frame_1e694c28c1cb7b88d842a0230f304b37_11) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_1e694c28c1cb7b88d842a0230f304b37_11); - cache_frame_1e694c28c1cb7b88d842a0230f304b37_11 = NULL; - } - - assertFrameObject(frame_1e694c28c1cb7b88d842a0230f304b37_11); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_10; - - frame_no_exception_10:; - goto skip_nested_handling_10; - nested_frame_exit_10:; - - goto try_except_handler_34; - skip_nested_handling_10:; - { - nuitka_bool tmp_condition_result_60; - PyObject *tmp_compexpr_left_10; - PyObject *tmp_compexpr_right_10; - CHECK_OBJECT(tmp_class_creation_10__bases); - tmp_compexpr_left_10 = tmp_class_creation_10__bases; - CHECK_OBJECT(tmp_class_creation_10__bases_orig); - tmp_compexpr_right_10 = tmp_class_creation_10__bases_orig; - tmp_condition_result_60 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_10, tmp_compexpr_right_10); - if (tmp_condition_result_60 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_34; - } - if (tmp_condition_result_60 == NUITKA_BOOL_TRUE) { - goto branch_yes_40; - } else { - goto branch_no_40; - } - assert(tmp_condition_result_60 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_40:; - CHECK_OBJECT(tmp_class_creation_10__bases_orig); - tmp_dictset_value = tmp_class_creation_10__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_34; - } - branch_no_40:; - { - PyObject *tmp_assign_source_122; - PyObject *tmp_called_name_21; - PyObject *tmp_args_name_20; - PyObject *tmp_tuple_element_40; - PyObject *tmp_kwargs_name_20; - CHECK_OBJECT(tmp_class_creation_10__metaclass); - tmp_called_name_21 = tmp_class_creation_10__metaclass; - tmp_tuple_element_40 = mod_consts[173]; - tmp_args_name_20 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_20, 0, tmp_tuple_element_40); - CHECK_OBJECT(tmp_class_creation_10__bases); - tmp_tuple_element_40 = tmp_class_creation_10__bases; - PyTuple_SET_ITEM0(tmp_args_name_20, 1, tmp_tuple_element_40); - tmp_tuple_element_40 = locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607; - PyTuple_SET_ITEM0(tmp_args_name_20, 2, tmp_tuple_element_40); - CHECK_OBJECT(tmp_class_creation_10__class_decl_dict); - tmp_kwargs_name_20 = tmp_class_creation_10__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 607; - tmp_assign_source_122 = CALL_FUNCTION(tmp_called_name_21, tmp_args_name_20, tmp_kwargs_name_20); - Py_DECREF(tmp_args_name_20); - if (tmp_assign_source_122 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 607; - - goto try_except_handler_34; - } - { - PyObject *old = Nuitka_Cell_GET(outline_9_var___class__); - PyCell_SET(outline_9_var___class__, tmp_assign_source_122); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_9_var___class__)); - tmp_assign_source_121 = Nuitka_Cell_GET(outline_9_var___class__); - Py_INCREF(tmp_assign_source_121); - goto try_return_handler_34; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_34:; - Py_DECREF(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607); - locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607 = NULL; - goto try_return_handler_33; - // Exception handler code: - try_except_handler_34:; - exception_keeper_type_32 = exception_type; - exception_keeper_value_32 = exception_value; - exception_keeper_tb_32 = exception_tb; - exception_keeper_lineno_32 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607); - locals_models$Qformer$$$class__10_BertPredictionHeadTransform_607 = NULL; - // Re-raise. - exception_type = exception_keeper_type_32; - exception_value = exception_keeper_value_32; - exception_tb = exception_keeper_tb_32; - exception_lineno = exception_keeper_lineno_32; - - goto try_except_handler_33; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_33:; - CHECK_OBJECT(outline_9_var___class__); - Py_DECREF(outline_9_var___class__); - outline_9_var___class__ = NULL; - goto outline_result_10; - // Exception handler code: - try_except_handler_33:; - exception_keeper_type_33 = exception_type; - exception_keeper_value_33 = exception_value; - exception_keeper_tb_33 = exception_tb; - exception_keeper_lineno_33 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_9_var___class__); - Py_DECREF(outline_9_var___class__); - outline_9_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_33; - exception_value = exception_keeper_value_33; - exception_tb = exception_keeper_tb_33; - exception_lineno = exception_keeper_lineno_33; - - goto outline_exception_10; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_10:; - exception_lineno = 607; - goto try_except_handler_32; - outline_result_10:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[173], tmp_assign_source_121); - } - goto try_end_14; - // Exception handler code: - try_except_handler_32:; - exception_keeper_type_34 = exception_type; - exception_keeper_value_34 = exception_value; - exception_keeper_tb_34 = exception_tb; - exception_keeper_lineno_34 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_10__bases_orig); - tmp_class_creation_10__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_10__bases); - tmp_class_creation_10__bases = NULL; - Py_XDECREF(tmp_class_creation_10__class_decl_dict); - tmp_class_creation_10__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_10__metaclass); - tmp_class_creation_10__metaclass = NULL; - Py_XDECREF(tmp_class_creation_10__prepared); - tmp_class_creation_10__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_34; - exception_value = exception_keeper_value_34; - exception_tb = exception_keeper_tb_34; - exception_lineno = exception_keeper_lineno_34; - - goto frame_exception_exit_1; - // End of try: - try_end_14:; - CHECK_OBJECT(tmp_class_creation_10__bases_orig); - Py_DECREF(tmp_class_creation_10__bases_orig); - tmp_class_creation_10__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_10__bases); - tmp_class_creation_10__bases = NULL; - Py_XDECREF(tmp_class_creation_10__class_decl_dict); - tmp_class_creation_10__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_10__metaclass); - tmp_class_creation_10__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_10__prepared); - Py_DECREF(tmp_class_creation_10__prepared); - tmp_class_creation_10__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_123; - PyObject *tmp_tuple_element_41; - PyObject *tmp_expression_name_62; - tmp_expression_name_62 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_62 == NULL)) { - tmp_expression_name_62 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_62 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_tuple_element_41 = LOOKUP_ATTRIBUTE(tmp_expression_name_62, mod_consts[325]); - if (tmp_tuple_element_41 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_assign_source_123 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_123, 0, tmp_tuple_element_41); - assert(tmp_class_creation_11__bases_orig == NULL); - tmp_class_creation_11__bases_orig = tmp_assign_source_123; - } - { - PyObject *tmp_assign_source_124; - PyObject *tmp_dircall_arg1_11; - CHECK_OBJECT(tmp_class_creation_11__bases_orig); - tmp_dircall_arg1_11 = tmp_class_creation_11__bases_orig; - Py_INCREF(tmp_dircall_arg1_11); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_11}; - tmp_assign_source_124 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_124 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - assert(tmp_class_creation_11__bases == NULL); - tmp_class_creation_11__bases = tmp_assign_source_124; - } - { - PyObject *tmp_assign_source_125; - tmp_assign_source_125 = PyDict_New(); - assert(tmp_class_creation_11__class_decl_dict == NULL); - tmp_class_creation_11__class_decl_dict = tmp_assign_source_125; - } - { - PyObject *tmp_assign_source_126; - PyObject *tmp_metaclass_name_11; - nuitka_bool tmp_condition_result_61; - PyObject *tmp_key_name_31; - PyObject *tmp_dict_arg_name_31; - PyObject *tmp_dict_arg_name_32; - PyObject *tmp_key_name_32; - nuitka_bool tmp_condition_result_62; - int tmp_truth_name_11; - PyObject *tmp_type_arg_21; - PyObject *tmp_expression_name_63; - PyObject *tmp_subscript_name_11; - PyObject *tmp_bases_name_11; - tmp_key_name_31 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_11__class_decl_dict); - tmp_dict_arg_name_31 = tmp_class_creation_11__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_31, tmp_key_name_31); - assert(!(tmp_res == -1)); - tmp_condition_result_61 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_61 == NUITKA_BOOL_TRUE) { - goto condexpr_true_21; - } else { - goto condexpr_false_21; - } - condexpr_true_21:; - CHECK_OBJECT(tmp_class_creation_11__class_decl_dict); - tmp_dict_arg_name_32 = tmp_class_creation_11__class_decl_dict; - tmp_key_name_32 = mod_consts[326]; - tmp_metaclass_name_11 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_32, tmp_key_name_32); - if (tmp_metaclass_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - goto condexpr_end_21; - condexpr_false_21:; - CHECK_OBJECT(tmp_class_creation_11__bases); - tmp_truth_name_11 = CHECK_IF_TRUE(tmp_class_creation_11__bases); - if (tmp_truth_name_11 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_condition_result_62 = tmp_truth_name_11 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_62 == NUITKA_BOOL_TRUE) { - goto condexpr_true_22; - } else { - goto condexpr_false_22; - } - condexpr_true_22:; - CHECK_OBJECT(tmp_class_creation_11__bases); - tmp_expression_name_63 = tmp_class_creation_11__bases; - tmp_subscript_name_11 = mod_consts[29]; - tmp_type_arg_21 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_63, tmp_subscript_name_11, 0); - if (tmp_type_arg_21 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_metaclass_name_11 = BUILTIN_TYPE1(tmp_type_arg_21); - Py_DECREF(tmp_type_arg_21); - if (tmp_metaclass_name_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - goto condexpr_end_22; - condexpr_false_22:; - tmp_metaclass_name_11 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_11); - condexpr_end_22:; - condexpr_end_21:; - CHECK_OBJECT(tmp_class_creation_11__bases); - tmp_bases_name_11 = tmp_class_creation_11__bases; - tmp_assign_source_126 = SELECT_METACLASS(tmp_metaclass_name_11, tmp_bases_name_11); - Py_DECREF(tmp_metaclass_name_11); - if (tmp_assign_source_126 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - assert(tmp_class_creation_11__metaclass == NULL); - tmp_class_creation_11__metaclass = tmp_assign_source_126; - } - { - nuitka_bool tmp_condition_result_63; - PyObject *tmp_key_name_33; - PyObject *tmp_dict_arg_name_33; - tmp_key_name_33 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_11__class_decl_dict); - tmp_dict_arg_name_33 = tmp_class_creation_11__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_33, tmp_key_name_33); - assert(!(tmp_res == -1)); - tmp_condition_result_63 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_63 == NUITKA_BOOL_TRUE) { - goto branch_yes_41; - } else { - goto branch_no_41; - } - } - branch_yes_41:; - CHECK_OBJECT(tmp_class_creation_11__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_11__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - branch_no_41:; - { - nuitka_bool tmp_condition_result_64; - PyObject *tmp_expression_name_64; - CHECK_OBJECT(tmp_class_creation_11__metaclass); - tmp_expression_name_64 = tmp_class_creation_11__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_64, mod_consts[327]); - tmp_condition_result_64 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_64 == NUITKA_BOOL_TRUE) { - goto branch_yes_42; - } else { - goto branch_no_42; - } - } - branch_yes_42:; - { - PyObject *tmp_assign_source_127; - PyObject *tmp_called_name_22; - PyObject *tmp_expression_name_65; - PyObject *tmp_args_name_21; - PyObject *tmp_tuple_element_42; - PyObject *tmp_kwargs_name_21; - CHECK_OBJECT(tmp_class_creation_11__metaclass); - tmp_expression_name_65 = tmp_class_creation_11__metaclass; - tmp_called_name_22 = LOOKUP_ATTRIBUTE(tmp_expression_name_65, mod_consts[327]); - if (tmp_called_name_22 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_tuple_element_42 = mod_consts[180]; - tmp_args_name_21 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_21, 0, tmp_tuple_element_42); - CHECK_OBJECT(tmp_class_creation_11__bases); - tmp_tuple_element_42 = tmp_class_creation_11__bases; - PyTuple_SET_ITEM0(tmp_args_name_21, 1, tmp_tuple_element_42); - CHECK_OBJECT(tmp_class_creation_11__class_decl_dict); - tmp_kwargs_name_21 = tmp_class_creation_11__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 624; - tmp_assign_source_127 = CALL_FUNCTION(tmp_called_name_22, tmp_args_name_21, tmp_kwargs_name_21); - Py_DECREF(tmp_called_name_22); - Py_DECREF(tmp_args_name_21); - if (tmp_assign_source_127 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - assert(tmp_class_creation_11__prepared == NULL); - tmp_class_creation_11__prepared = tmp_assign_source_127; - } - { - nuitka_bool tmp_condition_result_65; - PyObject *tmp_operand_name_11; - PyObject *tmp_expression_name_66; - CHECK_OBJECT(tmp_class_creation_11__prepared); - tmp_expression_name_66 = tmp_class_creation_11__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_66, mod_consts[328]); - tmp_operand_name_11 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_11); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_condition_result_65 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_65 == NUITKA_BOOL_TRUE) { - goto branch_yes_43; - } else { - goto branch_no_43; - } - } - branch_yes_43:; - { - PyObject *tmp_raise_type_11; - PyObject *tmp_raise_value_11; - PyObject *tmp_left_name_11; - PyObject *tmp_right_name_11; - PyObject *tmp_tuple_element_43; - PyObject *tmp_getattr_target_11; - PyObject *tmp_getattr_attr_11; - PyObject *tmp_getattr_default_11; - tmp_raise_type_11 = PyExc_TypeError; - tmp_left_name_11 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_11__metaclass); - tmp_getattr_target_11 = tmp_class_creation_11__metaclass; - tmp_getattr_attr_11 = mod_consts[324]; - tmp_getattr_default_11 = mod_consts[330]; - tmp_tuple_element_43 = BUILTIN_GETATTR(tmp_getattr_target_11, tmp_getattr_attr_11, tmp_getattr_default_11); - if (tmp_tuple_element_43 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - tmp_right_name_11 = PyTuple_New(2); - { - PyObject *tmp_expression_name_67; - PyObject *tmp_type_arg_22; - PyTuple_SET_ITEM(tmp_right_name_11, 0, tmp_tuple_element_43); - CHECK_OBJECT(tmp_class_creation_11__prepared); - tmp_type_arg_22 = tmp_class_creation_11__prepared; - tmp_expression_name_67 = BUILTIN_TYPE1(tmp_type_arg_22); - assert(!(tmp_expression_name_67 == NULL)); - tmp_tuple_element_43 = LOOKUP_ATTRIBUTE(tmp_expression_name_67, mod_consts[324]); - Py_DECREF(tmp_expression_name_67); - if (tmp_tuple_element_43 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto tuple_build_exception_11; - } - PyTuple_SET_ITEM(tmp_right_name_11, 1, tmp_tuple_element_43); - } - goto tuple_build_noexception_11; - // Exception handling pass through code for tuple_build: - tuple_build_exception_11:; - Py_DECREF(tmp_right_name_11); - goto try_except_handler_35; - // Finished with no exception for tuple_build: - tuple_build_noexception_11:; - tmp_raise_value_11 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_11, tmp_right_name_11); - Py_DECREF(tmp_right_name_11); - if (tmp_raise_value_11 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_35; - } - exception_type = tmp_raise_type_11; - Py_INCREF(tmp_raise_type_11); - exception_value = tmp_raise_value_11; - exception_lineno = 624; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_35; - } - branch_no_43:; - goto branch_end_42; - branch_no_42:; - { - PyObject *tmp_assign_source_128; - tmp_assign_source_128 = PyDict_New(); - assert(tmp_class_creation_11__prepared == NULL); - tmp_class_creation_11__prepared = tmp_assign_source_128; - } - branch_end_42:; - { - PyObject *tmp_assign_source_129; - { - PyObject *tmp_set_locals_11; - CHECK_OBJECT(tmp_class_creation_11__prepared); - tmp_set_locals_11 = tmp_class_creation_11__prepared; - locals_models$Qformer$$$class__11_BertLMPredictionHead_624 = tmp_set_locals_11; - Py_INCREF(tmp_set_locals_11); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__11_BertLMPredictionHead_624, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_37; - } - tmp_dictset_value = mod_consts[180]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__11_BertLMPredictionHead_624, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_37; - } - if (isFrameUnusable(cache_frame_6e22728e3deba4360239f923eb721087_12)) { - Py_XDECREF(cache_frame_6e22728e3deba4360239f923eb721087_12); - -#if _DEBUG_REFCOUNTS - if (cache_frame_6e22728e3deba4360239f923eb721087_12 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_6e22728e3deba4360239f923eb721087_12 = MAKE_FUNCTION_FRAME(codeobj_6e22728e3deba4360239f923eb721087, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_6e22728e3deba4360239f923eb721087_12->m_type_description == NULL); - frame_6e22728e3deba4360239f923eb721087_12 = cache_frame_6e22728e3deba4360239f923eb721087_12; - - // Push the new frame as the currently active one. - pushFrameStack(frame_6e22728e3deba4360239f923eb721087_12); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_6e22728e3deba4360239f923eb721087_12) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_11[1]; - - tmp_closure_11[0] = outline_10_var___class__; - Py_INCREF(tmp_closure_11[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__29___init__(tmp_closure_11); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__11_BertLMPredictionHead_624, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 625; - type_description_2 = "c"; - goto frame_exception_exit_12; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__30_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__11_BertLMPredictionHead_624, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 638; - type_description_2 = "c"; - goto frame_exception_exit_12; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_6e22728e3deba4360239f923eb721087_12); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_11; - - frame_exception_exit_12:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_6e22728e3deba4360239f923eb721087_12); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_6e22728e3deba4360239f923eb721087_12, exception_lineno); - } else if (exception_tb->tb_frame != &frame_6e22728e3deba4360239f923eb721087_12->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_6e22728e3deba4360239f923eb721087_12, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_6e22728e3deba4360239f923eb721087_12, - type_description_2, - outline_10_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_6e22728e3deba4360239f923eb721087_12 == cache_frame_6e22728e3deba4360239f923eb721087_12) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_6e22728e3deba4360239f923eb721087_12); - cache_frame_6e22728e3deba4360239f923eb721087_12 = NULL; - } - - assertFrameObject(frame_6e22728e3deba4360239f923eb721087_12); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_11; - - frame_no_exception_11:; - goto skip_nested_handling_11; - nested_frame_exit_11:; - - goto try_except_handler_37; - skip_nested_handling_11:; - { - nuitka_bool tmp_condition_result_66; - PyObject *tmp_compexpr_left_11; - PyObject *tmp_compexpr_right_11; - CHECK_OBJECT(tmp_class_creation_11__bases); - tmp_compexpr_left_11 = tmp_class_creation_11__bases; - CHECK_OBJECT(tmp_class_creation_11__bases_orig); - tmp_compexpr_right_11 = tmp_class_creation_11__bases_orig; - tmp_condition_result_66 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_11, tmp_compexpr_right_11); - if (tmp_condition_result_66 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_37; - } - if (tmp_condition_result_66 == NUITKA_BOOL_TRUE) { - goto branch_yes_44; - } else { - goto branch_no_44; - } - assert(tmp_condition_result_66 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_44:; - CHECK_OBJECT(tmp_class_creation_11__bases_orig); - tmp_dictset_value = tmp_class_creation_11__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__11_BertLMPredictionHead_624, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_37; - } - branch_no_44:; - { - PyObject *tmp_assign_source_130; - PyObject *tmp_called_name_23; - PyObject *tmp_args_name_22; - PyObject *tmp_tuple_element_44; - PyObject *tmp_kwargs_name_22; - CHECK_OBJECT(tmp_class_creation_11__metaclass); - tmp_called_name_23 = tmp_class_creation_11__metaclass; - tmp_tuple_element_44 = mod_consts[180]; - tmp_args_name_22 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_22, 0, tmp_tuple_element_44); - CHECK_OBJECT(tmp_class_creation_11__bases); - tmp_tuple_element_44 = tmp_class_creation_11__bases; - PyTuple_SET_ITEM0(tmp_args_name_22, 1, tmp_tuple_element_44); - tmp_tuple_element_44 = locals_models$Qformer$$$class__11_BertLMPredictionHead_624; - PyTuple_SET_ITEM0(tmp_args_name_22, 2, tmp_tuple_element_44); - CHECK_OBJECT(tmp_class_creation_11__class_decl_dict); - tmp_kwargs_name_22 = tmp_class_creation_11__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 624; - tmp_assign_source_130 = CALL_FUNCTION(tmp_called_name_23, tmp_args_name_22, tmp_kwargs_name_22); - Py_DECREF(tmp_args_name_22); - if (tmp_assign_source_130 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 624; - - goto try_except_handler_37; - } - { - PyObject *old = Nuitka_Cell_GET(outline_10_var___class__); - PyCell_SET(outline_10_var___class__, tmp_assign_source_130); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_10_var___class__)); - tmp_assign_source_129 = Nuitka_Cell_GET(outline_10_var___class__); - Py_INCREF(tmp_assign_source_129); - goto try_return_handler_37; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_37:; - Py_DECREF(locals_models$Qformer$$$class__11_BertLMPredictionHead_624); - locals_models$Qformer$$$class__11_BertLMPredictionHead_624 = NULL; - goto try_return_handler_36; - // Exception handler code: - try_except_handler_37:; - exception_keeper_type_35 = exception_type; - exception_keeper_value_35 = exception_value; - exception_keeper_tb_35 = exception_tb; - exception_keeper_lineno_35 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__11_BertLMPredictionHead_624); - locals_models$Qformer$$$class__11_BertLMPredictionHead_624 = NULL; - // Re-raise. - exception_type = exception_keeper_type_35; - exception_value = exception_keeper_value_35; - exception_tb = exception_keeper_tb_35; - exception_lineno = exception_keeper_lineno_35; - - goto try_except_handler_36; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_36:; - CHECK_OBJECT(outline_10_var___class__); - Py_DECREF(outline_10_var___class__); - outline_10_var___class__ = NULL; - goto outline_result_11; - // Exception handler code: - try_except_handler_36:; - exception_keeper_type_36 = exception_type; - exception_keeper_value_36 = exception_value; - exception_keeper_tb_36 = exception_tb; - exception_keeper_lineno_36 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_10_var___class__); - Py_DECREF(outline_10_var___class__); - outline_10_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_36; - exception_value = exception_keeper_value_36; - exception_tb = exception_keeper_tb_36; - exception_lineno = exception_keeper_lineno_36; - - goto outline_exception_11; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_11:; - exception_lineno = 624; - goto try_except_handler_35; - outline_result_11:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[180], tmp_assign_source_129); - } - goto try_end_15; - // Exception handler code: - try_except_handler_35:; - exception_keeper_type_37 = exception_type; - exception_keeper_value_37 = exception_value; - exception_keeper_tb_37 = exception_tb; - exception_keeper_lineno_37 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_11__bases_orig); - tmp_class_creation_11__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_11__bases); - tmp_class_creation_11__bases = NULL; - Py_XDECREF(tmp_class_creation_11__class_decl_dict); - tmp_class_creation_11__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_11__metaclass); - tmp_class_creation_11__metaclass = NULL; - Py_XDECREF(tmp_class_creation_11__prepared); - tmp_class_creation_11__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_37; - exception_value = exception_keeper_value_37; - exception_tb = exception_keeper_tb_37; - exception_lineno = exception_keeper_lineno_37; - - goto frame_exception_exit_1; - // End of try: - try_end_15:; - CHECK_OBJECT(tmp_class_creation_11__bases_orig); - Py_DECREF(tmp_class_creation_11__bases_orig); - tmp_class_creation_11__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_11__bases); - tmp_class_creation_11__bases = NULL; - Py_XDECREF(tmp_class_creation_11__class_decl_dict); - tmp_class_creation_11__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_11__metaclass); - tmp_class_creation_11__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_11__prepared); - Py_DECREF(tmp_class_creation_11__prepared); - tmp_class_creation_11__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_131; - PyObject *tmp_tuple_element_45; - PyObject *tmp_expression_name_68; - tmp_expression_name_68 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[2]); - - if (unlikely(tmp_expression_name_68 == NULL)) { - tmp_expression_name_68 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[2]); - } - - if (tmp_expression_name_68 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_tuple_element_45 = LOOKUP_ATTRIBUTE(tmp_expression_name_68, mod_consts[325]); - if (tmp_tuple_element_45 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_assign_source_131 = PyTuple_New(1); - PyTuple_SET_ITEM(tmp_assign_source_131, 0, tmp_tuple_element_45); - assert(tmp_class_creation_12__bases_orig == NULL); - tmp_class_creation_12__bases_orig = tmp_assign_source_131; - } - { - PyObject *tmp_assign_source_132; - PyObject *tmp_dircall_arg1_12; - CHECK_OBJECT(tmp_class_creation_12__bases_orig); - tmp_dircall_arg1_12 = tmp_class_creation_12__bases_orig; - Py_INCREF(tmp_dircall_arg1_12); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_12}; - tmp_assign_source_132 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_132 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - assert(tmp_class_creation_12__bases == NULL); - tmp_class_creation_12__bases = tmp_assign_source_132; - } - { - PyObject *tmp_assign_source_133; - tmp_assign_source_133 = PyDict_New(); - assert(tmp_class_creation_12__class_decl_dict == NULL); - tmp_class_creation_12__class_decl_dict = tmp_assign_source_133; - } - { - PyObject *tmp_assign_source_134; - PyObject *tmp_metaclass_name_12; - nuitka_bool tmp_condition_result_67; - PyObject *tmp_key_name_34; - PyObject *tmp_dict_arg_name_34; - PyObject *tmp_dict_arg_name_35; - PyObject *tmp_key_name_35; - nuitka_bool tmp_condition_result_68; - int tmp_truth_name_12; - PyObject *tmp_type_arg_23; - PyObject *tmp_expression_name_69; - PyObject *tmp_subscript_name_12; - PyObject *tmp_bases_name_12; - tmp_key_name_34 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_12__class_decl_dict); - tmp_dict_arg_name_34 = tmp_class_creation_12__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_34, tmp_key_name_34); - assert(!(tmp_res == -1)); - tmp_condition_result_67 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_67 == NUITKA_BOOL_TRUE) { - goto condexpr_true_23; - } else { - goto condexpr_false_23; - } - condexpr_true_23:; - CHECK_OBJECT(tmp_class_creation_12__class_decl_dict); - tmp_dict_arg_name_35 = tmp_class_creation_12__class_decl_dict; - tmp_key_name_35 = mod_consts[326]; - tmp_metaclass_name_12 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_35, tmp_key_name_35); - if (tmp_metaclass_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - goto condexpr_end_23; - condexpr_false_23:; - CHECK_OBJECT(tmp_class_creation_12__bases); - tmp_truth_name_12 = CHECK_IF_TRUE(tmp_class_creation_12__bases); - if (tmp_truth_name_12 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_condition_result_68 = tmp_truth_name_12 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_68 == NUITKA_BOOL_TRUE) { - goto condexpr_true_24; - } else { - goto condexpr_false_24; - } - condexpr_true_24:; - CHECK_OBJECT(tmp_class_creation_12__bases); - tmp_expression_name_69 = tmp_class_creation_12__bases; - tmp_subscript_name_12 = mod_consts[29]; - tmp_type_arg_23 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_69, tmp_subscript_name_12, 0); - if (tmp_type_arg_23 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_metaclass_name_12 = BUILTIN_TYPE1(tmp_type_arg_23); - Py_DECREF(tmp_type_arg_23); - if (tmp_metaclass_name_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - goto condexpr_end_24; - condexpr_false_24:; - tmp_metaclass_name_12 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_12); - condexpr_end_24:; - condexpr_end_23:; - CHECK_OBJECT(tmp_class_creation_12__bases); - tmp_bases_name_12 = tmp_class_creation_12__bases; - tmp_assign_source_134 = SELECT_METACLASS(tmp_metaclass_name_12, tmp_bases_name_12); - Py_DECREF(tmp_metaclass_name_12); - if (tmp_assign_source_134 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - assert(tmp_class_creation_12__metaclass == NULL); - tmp_class_creation_12__metaclass = tmp_assign_source_134; - } - { - nuitka_bool tmp_condition_result_69; - PyObject *tmp_key_name_36; - PyObject *tmp_dict_arg_name_36; - tmp_key_name_36 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_12__class_decl_dict); - tmp_dict_arg_name_36 = tmp_class_creation_12__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_36, tmp_key_name_36); - assert(!(tmp_res == -1)); - tmp_condition_result_69 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_69 == NUITKA_BOOL_TRUE) { - goto branch_yes_45; - } else { - goto branch_no_45; - } - } - branch_yes_45:; - CHECK_OBJECT(tmp_class_creation_12__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_12__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - branch_no_45:; - { - nuitka_bool tmp_condition_result_70; - PyObject *tmp_expression_name_70; - CHECK_OBJECT(tmp_class_creation_12__metaclass); - tmp_expression_name_70 = tmp_class_creation_12__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_70, mod_consts[327]); - tmp_condition_result_70 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_70 == NUITKA_BOOL_TRUE) { - goto branch_yes_46; - } else { - goto branch_no_46; - } - } - branch_yes_46:; - { - PyObject *tmp_assign_source_135; - PyObject *tmp_called_name_24; - PyObject *tmp_expression_name_71; - PyObject *tmp_args_name_23; - PyObject *tmp_tuple_element_46; - PyObject *tmp_kwargs_name_23; - CHECK_OBJECT(tmp_class_creation_12__metaclass); - tmp_expression_name_71 = tmp_class_creation_12__metaclass; - tmp_called_name_24 = LOOKUP_ATTRIBUTE(tmp_expression_name_71, mod_consts[327]); - if (tmp_called_name_24 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_tuple_element_46 = mod_consts[242]; - tmp_args_name_23 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_23, 0, tmp_tuple_element_46); - CHECK_OBJECT(tmp_class_creation_12__bases); - tmp_tuple_element_46 = tmp_class_creation_12__bases; - PyTuple_SET_ITEM0(tmp_args_name_23, 1, tmp_tuple_element_46); - CHECK_OBJECT(tmp_class_creation_12__class_decl_dict); - tmp_kwargs_name_23 = tmp_class_creation_12__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 644; - tmp_assign_source_135 = CALL_FUNCTION(tmp_called_name_24, tmp_args_name_23, tmp_kwargs_name_23); - Py_DECREF(tmp_called_name_24); - Py_DECREF(tmp_args_name_23); - if (tmp_assign_source_135 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - assert(tmp_class_creation_12__prepared == NULL); - tmp_class_creation_12__prepared = tmp_assign_source_135; - } - { - nuitka_bool tmp_condition_result_71; - PyObject *tmp_operand_name_12; - PyObject *tmp_expression_name_72; - CHECK_OBJECT(tmp_class_creation_12__prepared); - tmp_expression_name_72 = tmp_class_creation_12__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_72, mod_consts[328]); - tmp_operand_name_12 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_12); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_condition_result_71 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_71 == NUITKA_BOOL_TRUE) { - goto branch_yes_47; - } else { - goto branch_no_47; - } - } - branch_yes_47:; - { - PyObject *tmp_raise_type_12; - PyObject *tmp_raise_value_12; - PyObject *tmp_left_name_12; - PyObject *tmp_right_name_12; - PyObject *tmp_tuple_element_47; - PyObject *tmp_getattr_target_12; - PyObject *tmp_getattr_attr_12; - PyObject *tmp_getattr_default_12; - tmp_raise_type_12 = PyExc_TypeError; - tmp_left_name_12 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_12__metaclass); - tmp_getattr_target_12 = tmp_class_creation_12__metaclass; - tmp_getattr_attr_12 = mod_consts[324]; - tmp_getattr_default_12 = mod_consts[330]; - tmp_tuple_element_47 = BUILTIN_GETATTR(tmp_getattr_target_12, tmp_getattr_attr_12, tmp_getattr_default_12); - if (tmp_tuple_element_47 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - tmp_right_name_12 = PyTuple_New(2); - { - PyObject *tmp_expression_name_73; - PyObject *tmp_type_arg_24; - PyTuple_SET_ITEM(tmp_right_name_12, 0, tmp_tuple_element_47); - CHECK_OBJECT(tmp_class_creation_12__prepared); - tmp_type_arg_24 = tmp_class_creation_12__prepared; - tmp_expression_name_73 = BUILTIN_TYPE1(tmp_type_arg_24); - assert(!(tmp_expression_name_73 == NULL)); - tmp_tuple_element_47 = LOOKUP_ATTRIBUTE(tmp_expression_name_73, mod_consts[324]); - Py_DECREF(tmp_expression_name_73); - if (tmp_tuple_element_47 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto tuple_build_exception_12; - } - PyTuple_SET_ITEM(tmp_right_name_12, 1, tmp_tuple_element_47); - } - goto tuple_build_noexception_12; - // Exception handling pass through code for tuple_build: - tuple_build_exception_12:; - Py_DECREF(tmp_right_name_12); - goto try_except_handler_38; - // Finished with no exception for tuple_build: - tuple_build_noexception_12:; - tmp_raise_value_12 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_12, tmp_right_name_12); - Py_DECREF(tmp_right_name_12); - if (tmp_raise_value_12 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_38; - } - exception_type = tmp_raise_type_12; - Py_INCREF(tmp_raise_type_12); - exception_value = tmp_raise_value_12; - exception_lineno = 644; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_38; - } - branch_no_47:; - goto branch_end_46; - branch_no_46:; - { - PyObject *tmp_assign_source_136; - tmp_assign_source_136 = PyDict_New(); - assert(tmp_class_creation_12__prepared == NULL); - tmp_class_creation_12__prepared = tmp_assign_source_136; - } - branch_end_46:; - { - PyObject *tmp_assign_source_137; - { - PyObject *tmp_set_locals_12; - CHECK_OBJECT(tmp_class_creation_12__prepared); - tmp_set_locals_12 = tmp_class_creation_12__prepared; - locals_models$Qformer$$$class__12_BertOnlyMLMHead_644 = tmp_set_locals_12; - Py_INCREF(tmp_set_locals_12); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_40; - } - tmp_dictset_value = mod_consts[242]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_40; - } - if (isFrameUnusable(cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13)) { - Py_XDECREF(cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13); - -#if _DEBUG_REFCOUNTS - if (cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13 = MAKE_FUNCTION_FRAME(codeobj_2f024c1c2781aa4346c9360dc9ca9c37, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13->m_type_description == NULL); - frame_2f024c1c2781aa4346c9360dc9ca9c37_13 = cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13; - - // Push the new frame as the currently active one. - pushFrameStack(frame_2f024c1c2781aa4346c9360dc9ca9c37_13); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_2f024c1c2781aa4346c9360dc9ca9c37_13) == 2); // Frame stack - - // Framed code: - { - struct Nuitka_CellObject *tmp_closure_12[1]; - - tmp_closure_12[0] = outline_11_var___class__; - Py_INCREF(tmp_closure_12[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__31___init__(tmp_closure_12); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 645; - type_description_2 = "c"; - goto frame_exception_exit_13; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__32_forward(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 649; - type_description_2 = "c"; - goto frame_exception_exit_13; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2f024c1c2781aa4346c9360dc9ca9c37_13); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_12; - - frame_exception_exit_13:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2f024c1c2781aa4346c9360dc9ca9c37_13); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_2f024c1c2781aa4346c9360dc9ca9c37_13, exception_lineno); - } else if (exception_tb->tb_frame != &frame_2f024c1c2781aa4346c9360dc9ca9c37_13->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_2f024c1c2781aa4346c9360dc9ca9c37_13, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_2f024c1c2781aa4346c9360dc9ca9c37_13, - type_description_2, - outline_11_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_2f024c1c2781aa4346c9360dc9ca9c37_13 == cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13); - cache_frame_2f024c1c2781aa4346c9360dc9ca9c37_13 = NULL; - } - - assertFrameObject(frame_2f024c1c2781aa4346c9360dc9ca9c37_13); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_12; - - frame_no_exception_12:; - goto skip_nested_handling_12; - nested_frame_exit_12:; - - goto try_except_handler_40; - skip_nested_handling_12:; - { - nuitka_bool tmp_condition_result_72; - PyObject *tmp_compexpr_left_12; - PyObject *tmp_compexpr_right_12; - CHECK_OBJECT(tmp_class_creation_12__bases); - tmp_compexpr_left_12 = tmp_class_creation_12__bases; - CHECK_OBJECT(tmp_class_creation_12__bases_orig); - tmp_compexpr_right_12 = tmp_class_creation_12__bases_orig; - tmp_condition_result_72 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_12, tmp_compexpr_right_12); - if (tmp_condition_result_72 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_40; - } - if (tmp_condition_result_72 == NUITKA_BOOL_TRUE) { - goto branch_yes_48; - } else { - goto branch_no_48; - } - assert(tmp_condition_result_72 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_48:; - CHECK_OBJECT(tmp_class_creation_12__bases_orig); - tmp_dictset_value = tmp_class_creation_12__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_40; - } - branch_no_48:; - { - PyObject *tmp_assign_source_138; - PyObject *tmp_called_name_25; - PyObject *tmp_args_name_24; - PyObject *tmp_tuple_element_48; - PyObject *tmp_kwargs_name_24; - CHECK_OBJECT(tmp_class_creation_12__metaclass); - tmp_called_name_25 = tmp_class_creation_12__metaclass; - tmp_tuple_element_48 = mod_consts[242]; - tmp_args_name_24 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_24, 0, tmp_tuple_element_48); - CHECK_OBJECT(tmp_class_creation_12__bases); - tmp_tuple_element_48 = tmp_class_creation_12__bases; - PyTuple_SET_ITEM0(tmp_args_name_24, 1, tmp_tuple_element_48); - tmp_tuple_element_48 = locals_models$Qformer$$$class__12_BertOnlyMLMHead_644; - PyTuple_SET_ITEM0(tmp_args_name_24, 2, tmp_tuple_element_48); - CHECK_OBJECT(tmp_class_creation_12__class_decl_dict); - tmp_kwargs_name_24 = tmp_class_creation_12__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 644; - tmp_assign_source_138 = CALL_FUNCTION(tmp_called_name_25, tmp_args_name_24, tmp_kwargs_name_24); - Py_DECREF(tmp_args_name_24); - if (tmp_assign_source_138 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 644; - - goto try_except_handler_40; - } - { - PyObject *old = Nuitka_Cell_GET(outline_11_var___class__); - PyCell_SET(outline_11_var___class__, tmp_assign_source_138); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_11_var___class__)); - tmp_assign_source_137 = Nuitka_Cell_GET(outline_11_var___class__); - Py_INCREF(tmp_assign_source_137); - goto try_return_handler_40; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_40:; - Py_DECREF(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644); - locals_models$Qformer$$$class__12_BertOnlyMLMHead_644 = NULL; - goto try_return_handler_39; - // Exception handler code: - try_except_handler_40:; - exception_keeper_type_38 = exception_type; - exception_keeper_value_38 = exception_value; - exception_keeper_tb_38 = exception_tb; - exception_keeper_lineno_38 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__12_BertOnlyMLMHead_644); - locals_models$Qformer$$$class__12_BertOnlyMLMHead_644 = NULL; - // Re-raise. - exception_type = exception_keeper_type_38; - exception_value = exception_keeper_value_38; - exception_tb = exception_keeper_tb_38; - exception_lineno = exception_keeper_lineno_38; - - goto try_except_handler_39; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_39:; - CHECK_OBJECT(outline_11_var___class__); - Py_DECREF(outline_11_var___class__); - outline_11_var___class__ = NULL; - goto outline_result_12; - // Exception handler code: - try_except_handler_39:; - exception_keeper_type_39 = exception_type; - exception_keeper_value_39 = exception_value; - exception_keeper_tb_39 = exception_tb; - exception_keeper_lineno_39 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_11_var___class__); - Py_DECREF(outline_11_var___class__); - outline_11_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_39; - exception_value = exception_keeper_value_39; - exception_tb = exception_keeper_tb_39; - exception_lineno = exception_keeper_lineno_39; - - goto outline_exception_12; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_12:; - exception_lineno = 644; - goto try_except_handler_38; - outline_result_12:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[242], tmp_assign_source_137); - } - goto try_end_16; - // Exception handler code: - try_except_handler_38:; - exception_keeper_type_40 = exception_type; - exception_keeper_value_40 = exception_value; - exception_keeper_tb_40 = exception_tb; - exception_keeper_lineno_40 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_12__bases_orig); - tmp_class_creation_12__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_12__bases); - tmp_class_creation_12__bases = NULL; - Py_XDECREF(tmp_class_creation_12__class_decl_dict); - tmp_class_creation_12__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_12__metaclass); - tmp_class_creation_12__metaclass = NULL; - Py_XDECREF(tmp_class_creation_12__prepared); - tmp_class_creation_12__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_40; - exception_value = exception_keeper_value_40; - exception_tb = exception_keeper_tb_40; - exception_lineno = exception_keeper_lineno_40; - - goto frame_exception_exit_1; - // End of try: - try_end_16:; - CHECK_OBJECT(tmp_class_creation_12__bases_orig); - Py_DECREF(tmp_class_creation_12__bases_orig); - tmp_class_creation_12__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_12__bases); - tmp_class_creation_12__bases = NULL; - Py_XDECREF(tmp_class_creation_12__class_decl_dict); - tmp_class_creation_12__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_12__metaclass); - tmp_class_creation_12__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_12__prepared); - Py_DECREF(tmp_class_creation_12__prepared); - tmp_class_creation_12__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_139; - PyObject *tmp_tuple_element_49; - tmp_tuple_element_49 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[316]); - - if (unlikely(tmp_tuple_element_49 == NULL)) { - tmp_tuple_element_49 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[316]); - } - - if (tmp_tuple_element_49 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - tmp_assign_source_139 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_assign_source_139, 0, tmp_tuple_element_49); - assert(tmp_class_creation_13__bases_orig == NULL); - tmp_class_creation_13__bases_orig = tmp_assign_source_139; - } - { - PyObject *tmp_assign_source_140; - PyObject *tmp_dircall_arg1_13; - CHECK_OBJECT(tmp_class_creation_13__bases_orig); - tmp_dircall_arg1_13 = tmp_class_creation_13__bases_orig; - Py_INCREF(tmp_dircall_arg1_13); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_13}; - tmp_assign_source_140 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_140 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - assert(tmp_class_creation_13__bases == NULL); - tmp_class_creation_13__bases = tmp_assign_source_140; - } - { - PyObject *tmp_assign_source_141; - tmp_assign_source_141 = PyDict_New(); - assert(tmp_class_creation_13__class_decl_dict == NULL); - tmp_class_creation_13__class_decl_dict = tmp_assign_source_141; - } - { - PyObject *tmp_assign_source_142; - PyObject *tmp_metaclass_name_13; - nuitka_bool tmp_condition_result_73; - PyObject *tmp_key_name_37; - PyObject *tmp_dict_arg_name_37; - PyObject *tmp_dict_arg_name_38; - PyObject *tmp_key_name_38; - nuitka_bool tmp_condition_result_74; - int tmp_truth_name_13; - PyObject *tmp_type_arg_25; - PyObject *tmp_expression_name_74; - PyObject *tmp_subscript_name_13; - PyObject *tmp_bases_name_13; - tmp_key_name_37 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_13__class_decl_dict); - tmp_dict_arg_name_37 = tmp_class_creation_13__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_37, tmp_key_name_37); - assert(!(tmp_res == -1)); - tmp_condition_result_73 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_73 == NUITKA_BOOL_TRUE) { - goto condexpr_true_25; - } else { - goto condexpr_false_25; - } - condexpr_true_25:; - CHECK_OBJECT(tmp_class_creation_13__class_decl_dict); - tmp_dict_arg_name_38 = tmp_class_creation_13__class_decl_dict; - tmp_key_name_38 = mod_consts[326]; - tmp_metaclass_name_13 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_38, tmp_key_name_38); - if (tmp_metaclass_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - goto condexpr_end_25; - condexpr_false_25:; - CHECK_OBJECT(tmp_class_creation_13__bases); - tmp_truth_name_13 = CHECK_IF_TRUE(tmp_class_creation_13__bases); - if (tmp_truth_name_13 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - tmp_condition_result_74 = tmp_truth_name_13 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_74 == NUITKA_BOOL_TRUE) { - goto condexpr_true_26; - } else { - goto condexpr_false_26; - } - condexpr_true_26:; - CHECK_OBJECT(tmp_class_creation_13__bases); - tmp_expression_name_74 = tmp_class_creation_13__bases; - tmp_subscript_name_13 = mod_consts[29]; - tmp_type_arg_25 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_74, tmp_subscript_name_13, 0); - if (tmp_type_arg_25 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - tmp_metaclass_name_13 = BUILTIN_TYPE1(tmp_type_arg_25); - Py_DECREF(tmp_type_arg_25); - if (tmp_metaclass_name_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - goto condexpr_end_26; - condexpr_false_26:; - tmp_metaclass_name_13 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_13); - condexpr_end_26:; - condexpr_end_25:; - CHECK_OBJECT(tmp_class_creation_13__bases); - tmp_bases_name_13 = tmp_class_creation_13__bases; - tmp_assign_source_142 = SELECT_METACLASS(tmp_metaclass_name_13, tmp_bases_name_13); - Py_DECREF(tmp_metaclass_name_13); - if (tmp_assign_source_142 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - assert(tmp_class_creation_13__metaclass == NULL); - tmp_class_creation_13__metaclass = tmp_assign_source_142; - } - { - nuitka_bool tmp_condition_result_75; - PyObject *tmp_key_name_39; - PyObject *tmp_dict_arg_name_39; - tmp_key_name_39 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_13__class_decl_dict); - tmp_dict_arg_name_39 = tmp_class_creation_13__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_39, tmp_key_name_39); - assert(!(tmp_res == -1)); - tmp_condition_result_75 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_75 == NUITKA_BOOL_TRUE) { - goto branch_yes_49; - } else { - goto branch_no_49; - } - } - branch_yes_49:; - CHECK_OBJECT(tmp_class_creation_13__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_13__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - branch_no_49:; - { - nuitka_bool tmp_condition_result_76; - PyObject *tmp_expression_name_75; - CHECK_OBJECT(tmp_class_creation_13__metaclass); - tmp_expression_name_75 = tmp_class_creation_13__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_75, mod_consts[327]); - tmp_condition_result_76 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_76 == NUITKA_BOOL_TRUE) { - goto branch_yes_50; - } else { - goto branch_no_50; - } - } - branch_yes_50:; - { - PyObject *tmp_assign_source_143; - PyObject *tmp_called_name_26; - PyObject *tmp_expression_name_76; - PyObject *tmp_args_name_25; - PyObject *tmp_tuple_element_50; - PyObject *tmp_kwargs_name_25; - CHECK_OBJECT(tmp_class_creation_13__metaclass); - tmp_expression_name_76 = tmp_class_creation_13__metaclass; - tmp_called_name_26 = LOOKUP_ATTRIBUTE(tmp_expression_name_76, mod_consts[327]); - if (tmp_called_name_26 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - tmp_tuple_element_50 = mod_consts[375]; - tmp_args_name_25 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_25, 0, tmp_tuple_element_50); - CHECK_OBJECT(tmp_class_creation_13__bases); - tmp_tuple_element_50 = tmp_class_creation_13__bases; - PyTuple_SET_ITEM0(tmp_args_name_25, 1, tmp_tuple_element_50); - CHECK_OBJECT(tmp_class_creation_13__class_decl_dict); - tmp_kwargs_name_25 = tmp_class_creation_13__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 654; - tmp_assign_source_143 = CALL_FUNCTION(tmp_called_name_26, tmp_args_name_25, tmp_kwargs_name_25); - Py_DECREF(tmp_called_name_26); - Py_DECREF(tmp_args_name_25); - if (tmp_assign_source_143 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - assert(tmp_class_creation_13__prepared == NULL); - tmp_class_creation_13__prepared = tmp_assign_source_143; - } - { - nuitka_bool tmp_condition_result_77; - PyObject *tmp_operand_name_13; - PyObject *tmp_expression_name_77; - CHECK_OBJECT(tmp_class_creation_13__prepared); - tmp_expression_name_77 = tmp_class_creation_13__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_77, mod_consts[328]); - tmp_operand_name_13 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_13); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - tmp_condition_result_77 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_77 == NUITKA_BOOL_TRUE) { - goto branch_yes_51; - } else { - goto branch_no_51; - } - } - branch_yes_51:; - { - PyObject *tmp_raise_type_13; - PyObject *tmp_raise_value_13; - PyObject *tmp_left_name_13; - PyObject *tmp_right_name_13; - PyObject *tmp_tuple_element_51; - PyObject *tmp_getattr_target_13; - PyObject *tmp_getattr_attr_13; - PyObject *tmp_getattr_default_13; - tmp_raise_type_13 = PyExc_TypeError; - tmp_left_name_13 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_13__metaclass); - tmp_getattr_target_13 = tmp_class_creation_13__metaclass; - tmp_getattr_attr_13 = mod_consts[324]; - tmp_getattr_default_13 = mod_consts[330]; - tmp_tuple_element_51 = BUILTIN_GETATTR(tmp_getattr_target_13, tmp_getattr_attr_13, tmp_getattr_default_13); - if (tmp_tuple_element_51 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - tmp_right_name_13 = PyTuple_New(2); - { - PyObject *tmp_expression_name_78; - PyObject *tmp_type_arg_26; - PyTuple_SET_ITEM(tmp_right_name_13, 0, tmp_tuple_element_51); - CHECK_OBJECT(tmp_class_creation_13__prepared); - tmp_type_arg_26 = tmp_class_creation_13__prepared; - tmp_expression_name_78 = BUILTIN_TYPE1(tmp_type_arg_26); - assert(!(tmp_expression_name_78 == NULL)); - tmp_tuple_element_51 = LOOKUP_ATTRIBUTE(tmp_expression_name_78, mod_consts[324]); - Py_DECREF(tmp_expression_name_78); - if (tmp_tuple_element_51 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto tuple_build_exception_13; - } - PyTuple_SET_ITEM(tmp_right_name_13, 1, tmp_tuple_element_51); - } - goto tuple_build_noexception_13; - // Exception handling pass through code for tuple_build: - tuple_build_exception_13:; - Py_DECREF(tmp_right_name_13); - goto try_except_handler_41; - // Finished with no exception for tuple_build: - tuple_build_noexception_13:; - tmp_raise_value_13 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_13, tmp_right_name_13); - Py_DECREF(tmp_right_name_13); - if (tmp_raise_value_13 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_41; - } - exception_type = tmp_raise_type_13; - Py_INCREF(tmp_raise_type_13); - exception_value = tmp_raise_value_13; - exception_lineno = 654; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_41; - } - branch_no_51:; - goto branch_end_50; - branch_no_50:; - { - PyObject *tmp_assign_source_144; - tmp_assign_source_144 = PyDict_New(); - assert(tmp_class_creation_13__prepared == NULL); - tmp_class_creation_13__prepared = tmp_assign_source_144; - } - branch_end_50:; - { - PyObject *tmp_assign_source_145; - { - PyObject *tmp_set_locals_13; - CHECK_OBJECT(tmp_class_creation_13__prepared); - tmp_set_locals_13 = tmp_class_creation_13__prepared; - locals_models$Qformer$$$class__13_BertPreTrainedModel_654 = tmp_set_locals_13; - Py_INCREF(tmp_set_locals_13); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_43; - } - tmp_dictset_value = mod_consts[376]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[276], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_43; - } - tmp_dictset_value = mod_consts[375]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_43; - } - if (isFrameUnusable(cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14)) { - Py_XDECREF(cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14); - -#if _DEBUG_REFCOUNTS - if (cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14 = MAKE_FUNCTION_FRAME(codeobj_2ba10c444d39cd9fbc64d82f9cd4789e, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14->m_type_description == NULL); - frame_2ba10c444d39cd9fbc64d82f9cd4789e_14 = cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14; - - // Push the new frame as the currently active one. - pushFrameStack(frame_2ba10c444d39cd9fbc64d82f9cd4789e_14); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_2ba10c444d39cd9fbc64d82f9cd4789e_14) == 2); // Frame stack - - // Framed code: - tmp_dictset_value = PyObject_GetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[322]); - - if (tmp_dictset_value == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[322]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[322]); - } - - if (tmp_dictset_value == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 660; - type_description_2 = "o"; - goto frame_exception_exit_14; - } - Py_INCREF(tmp_dictset_value); - } - } - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[377], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 660; - type_description_2 = "o"; - goto frame_exception_exit_14; - } - tmp_dictset_value = mod_consts[241]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[378], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 661; - type_description_2 = "o"; - goto frame_exception_exit_14; - } - tmp_dictset_value = LIST_COPY(mod_consts[379]); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[380], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 662; - type_description_2 = "o"; - goto frame_exception_exit_14; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__33__init_weights(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[381], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 664; - type_description_2 = "o"; - goto frame_exception_exit_14; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2ba10c444d39cd9fbc64d82f9cd4789e_14); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_13; - - frame_exception_exit_14:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2ba10c444d39cd9fbc64d82f9cd4789e_14); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_2ba10c444d39cd9fbc64d82f9cd4789e_14, exception_lineno); - } else if (exception_tb->tb_frame != &frame_2ba10c444d39cd9fbc64d82f9cd4789e_14->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_2ba10c444d39cd9fbc64d82f9cd4789e_14, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_2ba10c444d39cd9fbc64d82f9cd4789e_14, - type_description_2, - outline_12_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_2ba10c444d39cd9fbc64d82f9cd4789e_14 == cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14); - cache_frame_2ba10c444d39cd9fbc64d82f9cd4789e_14 = NULL; - } - - assertFrameObject(frame_2ba10c444d39cd9fbc64d82f9cd4789e_14); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_13; - - frame_no_exception_13:; - goto skip_nested_handling_13; - nested_frame_exit_13:; - - goto try_except_handler_43; - skip_nested_handling_13:; - { - nuitka_bool tmp_condition_result_78; - PyObject *tmp_compexpr_left_13; - PyObject *tmp_compexpr_right_13; - CHECK_OBJECT(tmp_class_creation_13__bases); - tmp_compexpr_left_13 = tmp_class_creation_13__bases; - CHECK_OBJECT(tmp_class_creation_13__bases_orig); - tmp_compexpr_right_13 = tmp_class_creation_13__bases_orig; - tmp_condition_result_78 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_13, tmp_compexpr_right_13); - if (tmp_condition_result_78 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_43; - } - if (tmp_condition_result_78 == NUITKA_BOOL_TRUE) { - goto branch_yes_52; - } else { - goto branch_no_52; - } - assert(tmp_condition_result_78 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_52:; - CHECK_OBJECT(tmp_class_creation_13__bases_orig); - tmp_dictset_value = tmp_class_creation_13__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__13_BertPreTrainedModel_654, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_43; - } - branch_no_52:; - { - PyObject *tmp_assign_source_146; - PyObject *tmp_called_name_27; - PyObject *tmp_args_name_26; - PyObject *tmp_tuple_element_52; - PyObject *tmp_kwargs_name_26; - CHECK_OBJECT(tmp_class_creation_13__metaclass); - tmp_called_name_27 = tmp_class_creation_13__metaclass; - tmp_tuple_element_52 = mod_consts[375]; - tmp_args_name_26 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_26, 0, tmp_tuple_element_52); - CHECK_OBJECT(tmp_class_creation_13__bases); - tmp_tuple_element_52 = tmp_class_creation_13__bases; - PyTuple_SET_ITEM0(tmp_args_name_26, 1, tmp_tuple_element_52); - tmp_tuple_element_52 = locals_models$Qformer$$$class__13_BertPreTrainedModel_654; - PyTuple_SET_ITEM0(tmp_args_name_26, 2, tmp_tuple_element_52); - CHECK_OBJECT(tmp_class_creation_13__class_decl_dict); - tmp_kwargs_name_26 = tmp_class_creation_13__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 654; - tmp_assign_source_146 = CALL_FUNCTION(tmp_called_name_27, tmp_args_name_26, tmp_kwargs_name_26); - Py_DECREF(tmp_args_name_26); - if (tmp_assign_source_146 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 654; - - goto try_except_handler_43; - } - assert(outline_12_var___class__ == NULL); - outline_12_var___class__ = tmp_assign_source_146; - } - CHECK_OBJECT(outline_12_var___class__); - tmp_assign_source_145 = outline_12_var___class__; - Py_INCREF(tmp_assign_source_145); - goto try_return_handler_43; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_43:; - Py_DECREF(locals_models$Qformer$$$class__13_BertPreTrainedModel_654); - locals_models$Qformer$$$class__13_BertPreTrainedModel_654 = NULL; - goto try_return_handler_42; - // Exception handler code: - try_except_handler_43:; - exception_keeper_type_41 = exception_type; - exception_keeper_value_41 = exception_value; - exception_keeper_tb_41 = exception_tb; - exception_keeper_lineno_41 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__13_BertPreTrainedModel_654); - locals_models$Qformer$$$class__13_BertPreTrainedModel_654 = NULL; - // Re-raise. - exception_type = exception_keeper_type_41; - exception_value = exception_keeper_value_41; - exception_tb = exception_keeper_tb_41; - exception_lineno = exception_keeper_lineno_41; - - goto try_except_handler_42; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_42:; - CHECK_OBJECT(outline_12_var___class__); - Py_DECREF(outline_12_var___class__); - outline_12_var___class__ = NULL; - goto outline_result_13; - // Exception handler code: - try_except_handler_42:; - exception_keeper_type_42 = exception_type; - exception_keeper_value_42 = exception_value; - exception_keeper_tb_42 = exception_tb; - exception_keeper_lineno_42 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - // Re-raise. - exception_type = exception_keeper_type_42; - exception_value = exception_keeper_value_42; - exception_tb = exception_keeper_tb_42; - exception_lineno = exception_keeper_lineno_42; - - goto outline_exception_13; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_13:; - exception_lineno = 654; - goto try_except_handler_41; - outline_result_13:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[375], tmp_assign_source_145); - } - goto try_end_17; - // Exception handler code: - try_except_handler_41:; - exception_keeper_type_43 = exception_type; - exception_keeper_value_43 = exception_value; - exception_keeper_tb_43 = exception_tb; - exception_keeper_lineno_43 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_13__bases_orig); - tmp_class_creation_13__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_13__bases); - tmp_class_creation_13__bases = NULL; - Py_XDECREF(tmp_class_creation_13__class_decl_dict); - tmp_class_creation_13__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_13__metaclass); - tmp_class_creation_13__metaclass = NULL; - Py_XDECREF(tmp_class_creation_13__prepared); - tmp_class_creation_13__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_43; - exception_value = exception_keeper_value_43; - exception_tb = exception_keeper_tb_43; - exception_lineno = exception_keeper_lineno_43; - - goto frame_exception_exit_1; - // End of try: - try_end_17:; - CHECK_OBJECT(tmp_class_creation_13__bases_orig); - Py_DECREF(tmp_class_creation_13__bases_orig); - tmp_class_creation_13__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_13__bases); - tmp_class_creation_13__bases = NULL; - Py_XDECREF(tmp_class_creation_13__class_decl_dict); - tmp_class_creation_13__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_13__metaclass); - tmp_class_creation_13__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_13__prepared); - Py_DECREF(tmp_class_creation_13__prepared); - tmp_class_creation_13__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_147; - PyObject *tmp_tuple_element_53; - tmp_tuple_element_53 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[375]); - - if (unlikely(tmp_tuple_element_53 == NULL)) { - tmp_tuple_element_53 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[375]); - } - - if (tmp_tuple_element_53 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - tmp_assign_source_147 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_assign_source_147, 0, tmp_tuple_element_53); - assert(tmp_class_creation_14__bases_orig == NULL); - tmp_class_creation_14__bases_orig = tmp_assign_source_147; - } - { - PyObject *tmp_assign_source_148; - PyObject *tmp_dircall_arg1_14; - CHECK_OBJECT(tmp_class_creation_14__bases_orig); - tmp_dircall_arg1_14 = tmp_class_creation_14__bases_orig; - Py_INCREF(tmp_dircall_arg1_14); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_14}; - tmp_assign_source_148 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_148 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - assert(tmp_class_creation_14__bases == NULL); - tmp_class_creation_14__bases = tmp_assign_source_148; - } - { - PyObject *tmp_assign_source_149; - tmp_assign_source_149 = PyDict_New(); - assert(tmp_class_creation_14__class_decl_dict == NULL); - tmp_class_creation_14__class_decl_dict = tmp_assign_source_149; - } - { - PyObject *tmp_assign_source_150; - PyObject *tmp_metaclass_name_14; - nuitka_bool tmp_condition_result_79; - PyObject *tmp_key_name_40; - PyObject *tmp_dict_arg_name_40; - PyObject *tmp_dict_arg_name_41; - PyObject *tmp_key_name_41; - nuitka_bool tmp_condition_result_80; - int tmp_truth_name_14; - PyObject *tmp_type_arg_27; - PyObject *tmp_expression_name_79; - PyObject *tmp_subscript_name_14; - PyObject *tmp_bases_name_14; - tmp_key_name_40 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_14__class_decl_dict); - tmp_dict_arg_name_40 = tmp_class_creation_14__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_40, tmp_key_name_40); - assert(!(tmp_res == -1)); - tmp_condition_result_79 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_79 == NUITKA_BOOL_TRUE) { - goto condexpr_true_27; - } else { - goto condexpr_false_27; - } - condexpr_true_27:; - CHECK_OBJECT(tmp_class_creation_14__class_decl_dict); - tmp_dict_arg_name_41 = tmp_class_creation_14__class_decl_dict; - tmp_key_name_41 = mod_consts[326]; - tmp_metaclass_name_14 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_41, tmp_key_name_41); - if (tmp_metaclass_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - goto condexpr_end_27; - condexpr_false_27:; - CHECK_OBJECT(tmp_class_creation_14__bases); - tmp_truth_name_14 = CHECK_IF_TRUE(tmp_class_creation_14__bases); - if (tmp_truth_name_14 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - tmp_condition_result_80 = tmp_truth_name_14 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_80 == NUITKA_BOOL_TRUE) { - goto condexpr_true_28; - } else { - goto condexpr_false_28; - } - condexpr_true_28:; - CHECK_OBJECT(tmp_class_creation_14__bases); - tmp_expression_name_79 = tmp_class_creation_14__bases; - tmp_subscript_name_14 = mod_consts[29]; - tmp_type_arg_27 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_79, tmp_subscript_name_14, 0); - if (tmp_type_arg_27 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - tmp_metaclass_name_14 = BUILTIN_TYPE1(tmp_type_arg_27); - Py_DECREF(tmp_type_arg_27); - if (tmp_metaclass_name_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - goto condexpr_end_28; - condexpr_false_28:; - tmp_metaclass_name_14 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_14); - condexpr_end_28:; - condexpr_end_27:; - CHECK_OBJECT(tmp_class_creation_14__bases); - tmp_bases_name_14 = tmp_class_creation_14__bases; - tmp_assign_source_150 = SELECT_METACLASS(tmp_metaclass_name_14, tmp_bases_name_14); - Py_DECREF(tmp_metaclass_name_14); - if (tmp_assign_source_150 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - assert(tmp_class_creation_14__metaclass == NULL); - tmp_class_creation_14__metaclass = tmp_assign_source_150; - } - { - nuitka_bool tmp_condition_result_81; - PyObject *tmp_key_name_42; - PyObject *tmp_dict_arg_name_42; - tmp_key_name_42 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_14__class_decl_dict); - tmp_dict_arg_name_42 = tmp_class_creation_14__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_42, tmp_key_name_42); - assert(!(tmp_res == -1)); - tmp_condition_result_81 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_81 == NUITKA_BOOL_TRUE) { - goto branch_yes_53; - } else { - goto branch_no_53; - } - } - branch_yes_53:; - CHECK_OBJECT(tmp_class_creation_14__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_14__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - branch_no_53:; - { - nuitka_bool tmp_condition_result_82; - PyObject *tmp_expression_name_80; - CHECK_OBJECT(tmp_class_creation_14__metaclass); - tmp_expression_name_80 = tmp_class_creation_14__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_80, mod_consts[327]); - tmp_condition_result_82 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_82 == NUITKA_BOOL_TRUE) { - goto branch_yes_54; - } else { - goto branch_no_54; - } - } - branch_yes_54:; - { - PyObject *tmp_assign_source_151; - PyObject *tmp_called_name_28; - PyObject *tmp_expression_name_81; - PyObject *tmp_args_name_27; - PyObject *tmp_tuple_element_54; - PyObject *tmp_kwargs_name_27; - CHECK_OBJECT(tmp_class_creation_14__metaclass); - tmp_expression_name_81 = tmp_class_creation_14__metaclass; - tmp_called_name_28 = LOOKUP_ATTRIBUTE(tmp_expression_name_81, mod_consts[327]); - if (tmp_called_name_28 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - tmp_tuple_element_54 = mod_consts[239]; - tmp_args_name_27 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_27, 0, tmp_tuple_element_54); - CHECK_OBJECT(tmp_class_creation_14__bases); - tmp_tuple_element_54 = tmp_class_creation_14__bases; - PyTuple_SET_ITEM0(tmp_args_name_27, 1, tmp_tuple_element_54); - CHECK_OBJECT(tmp_class_creation_14__class_decl_dict); - tmp_kwargs_name_27 = tmp_class_creation_14__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 677; - tmp_assign_source_151 = CALL_FUNCTION(tmp_called_name_28, tmp_args_name_27, tmp_kwargs_name_27); - Py_DECREF(tmp_called_name_28); - Py_DECREF(tmp_args_name_27); - if (tmp_assign_source_151 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - assert(tmp_class_creation_14__prepared == NULL); - tmp_class_creation_14__prepared = tmp_assign_source_151; - } - { - nuitka_bool tmp_condition_result_83; - PyObject *tmp_operand_name_14; - PyObject *tmp_expression_name_82; - CHECK_OBJECT(tmp_class_creation_14__prepared); - tmp_expression_name_82 = tmp_class_creation_14__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_82, mod_consts[328]); - tmp_operand_name_14 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_14); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - tmp_condition_result_83 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_83 == NUITKA_BOOL_TRUE) { - goto branch_yes_55; - } else { - goto branch_no_55; - } - } - branch_yes_55:; - { - PyObject *tmp_raise_type_14; - PyObject *tmp_raise_value_14; - PyObject *tmp_left_name_14; - PyObject *tmp_right_name_14; - PyObject *tmp_tuple_element_55; - PyObject *tmp_getattr_target_14; - PyObject *tmp_getattr_attr_14; - PyObject *tmp_getattr_default_14; - tmp_raise_type_14 = PyExc_TypeError; - tmp_left_name_14 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_14__metaclass); - tmp_getattr_target_14 = tmp_class_creation_14__metaclass; - tmp_getattr_attr_14 = mod_consts[324]; - tmp_getattr_default_14 = mod_consts[330]; - tmp_tuple_element_55 = BUILTIN_GETATTR(tmp_getattr_target_14, tmp_getattr_attr_14, tmp_getattr_default_14); - if (tmp_tuple_element_55 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - tmp_right_name_14 = PyTuple_New(2); - { - PyObject *tmp_expression_name_83; - PyObject *tmp_type_arg_28; - PyTuple_SET_ITEM(tmp_right_name_14, 0, tmp_tuple_element_55); - CHECK_OBJECT(tmp_class_creation_14__prepared); - tmp_type_arg_28 = tmp_class_creation_14__prepared; - tmp_expression_name_83 = BUILTIN_TYPE1(tmp_type_arg_28); - assert(!(tmp_expression_name_83 == NULL)); - tmp_tuple_element_55 = LOOKUP_ATTRIBUTE(tmp_expression_name_83, mod_consts[324]); - Py_DECREF(tmp_expression_name_83); - if (tmp_tuple_element_55 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto tuple_build_exception_14; - } - PyTuple_SET_ITEM(tmp_right_name_14, 1, tmp_tuple_element_55); - } - goto tuple_build_noexception_14; - // Exception handling pass through code for tuple_build: - tuple_build_exception_14:; - Py_DECREF(tmp_right_name_14); - goto try_except_handler_44; - // Finished with no exception for tuple_build: - tuple_build_noexception_14:; - tmp_raise_value_14 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_14, tmp_right_name_14); - Py_DECREF(tmp_right_name_14); - if (tmp_raise_value_14 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_44; - } - exception_type = tmp_raise_type_14; - Py_INCREF(tmp_raise_type_14); - exception_value = tmp_raise_value_14; - exception_lineno = 677; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_44; - } - branch_no_55:; - goto branch_end_54; - branch_no_54:; - { - PyObject *tmp_assign_source_152; - tmp_assign_source_152 = PyDict_New(); - assert(tmp_class_creation_14__prepared == NULL); - tmp_class_creation_14__prepared = tmp_assign_source_152; - } - branch_end_54:; - { - PyObject *tmp_assign_source_153; - { - PyObject *tmp_set_locals_14; - CHECK_OBJECT(tmp_class_creation_14__prepared); - tmp_set_locals_14 = tmp_class_creation_14__prepared; - locals_models$Qformer$$$class__14_BertModel_677 = tmp_set_locals_14; - Py_INCREF(tmp_set_locals_14); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_46; - } - tmp_dictset_value = mod_consts[383]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[276], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_46; - } - tmp_dictset_value = mod_consts[239]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_46; - } - if (isFrameUnusable(cache_frame_25865ea0df4a3f86bdd137c22518ab84_15)) { - Py_XDECREF(cache_frame_25865ea0df4a3f86bdd137c22518ab84_15); - -#if _DEBUG_REFCOUNTS - if (cache_frame_25865ea0df4a3f86bdd137c22518ab84_15 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_25865ea0df4a3f86bdd137c22518ab84_15 = MAKE_FUNCTION_FRAME(codeobj_25865ea0df4a3f86bdd137c22518ab84, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_25865ea0df4a3f86bdd137c22518ab84_15->m_type_description == NULL); - frame_25865ea0df4a3f86bdd137c22518ab84_15 = cache_frame_25865ea0df4a3f86bdd137c22518ab84_15; - - // Push the new frame as the currently active one. - pushFrameStack(frame_25865ea0df4a3f86bdd137c22518ab84_15); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_25865ea0df4a3f86bdd137c22518ab84_15) == 2); // Frame stack - - // Framed code: - { - PyObject *tmp_defaults_7; - struct Nuitka_CellObject *tmp_closure_13[1]; - tmp_defaults_7 = mod_consts[351]; - Py_INCREF(tmp_defaults_7); - - tmp_closure_13[0] = outline_13_var___class__; - Py_INCREF(tmp_closure_13[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__34___init__(tmp_defaults_7, tmp_closure_13); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 687; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__35_get_input_embeddings(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[385], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 699; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__36_set_input_embeddings(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[387], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 702; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__37__prune_heads(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[389], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 705; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - { - PyObject *tmp_defaults_8; - PyObject *tmp_annotations_1; - PyObject *tmp_dict_key_1; - PyObject *tmp_dict_value_1; - tmp_defaults_8 = mod_consts[351]; - tmp_dict_key_1 = mod_consts[128]; - tmp_dict_value_1 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[294]); - - if (tmp_dict_value_1 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_dict_value_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[294]); - - if (unlikely(tmp_dict_value_1 == NULL)) { - tmp_dict_value_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[294]); - } - - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 715; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - Py_INCREF(tmp_dict_value_1); - } - } - - tmp_annotations_1 = _PyDict_NewPresized( 6 ); - { - PyObject *tmp_expression_name_84; - PyObject *tmp_subscript_name_15; - tmp_res = PyDict_SetItem(tmp_annotations_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[228]; - tmp_expression_name_84 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[290]); - - if (tmp_expression_name_84 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_expression_name_84 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[290]); - - if (unlikely(tmp_expression_name_84 == NULL)) { - tmp_expression_name_84 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[290]); - } - - if (tmp_expression_name_84 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 716; - type_description_2 = "c"; - goto dict_build_exception_1; - } - Py_INCREF(tmp_expression_name_84); - } - } - - tmp_subscript_name_15 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[391]); - - if (tmp_subscript_name_15 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_subscript_name_15 = (PyObject *)&PyLong_Type; - Py_INCREF(tmp_subscript_name_15); - } - } - - tmp_dict_value_1 = LOOKUP_SUBSCRIPT(tmp_expression_name_84, tmp_subscript_name_15); - Py_DECREF(tmp_expression_name_84); - Py_DECREF(tmp_subscript_name_15); - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 716; - type_description_2 = "c"; - goto dict_build_exception_1; - } - tmp_res = PyDict_SetItem(tmp_annotations_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[70]; - tmp_dict_value_1 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[70]); - - if (tmp_dict_value_1 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_dict_value_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[70]); - - if (unlikely(tmp_dict_value_1 == NULL)) { - tmp_dict_value_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[70]); - } - - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 717; - type_description_2 = "c"; - goto dict_build_exception_1; - } - Py_INCREF(tmp_dict_value_1); - } - } - - tmp_res = PyDict_SetItem(tmp_annotations_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[244]; - tmp_dict_value_1 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[392]); - - if (tmp_dict_value_1 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_dict_value_1 = (PyObject *)&PyBool_Type; - Py_INCREF(tmp_dict_value_1); - } - } - - tmp_res = PyDict_SetItem(tmp_annotations_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[227]; - tmp_dict_value_1 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[392]); - - if (tmp_dict_value_1 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_dict_value_1 = (PyObject *)&PyBool_Type; - Py_INCREF(tmp_dict_value_1); - } - } - - tmp_res = PyDict_SetItem(tmp_annotations_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - tmp_dict_key_1 = mod_consts[393]; - tmp_dict_value_1 = PyObject_GetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[294]); - - if (tmp_dict_value_1 == NULL) { - if (CHECK_AND_CLEAR_KEY_ERROR_OCCURRED()) { - tmp_dict_value_1 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[294]); - - if (unlikely(tmp_dict_value_1 == NULL)) { - tmp_dict_value_1 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[294]); - } - - if (tmp_dict_value_1 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 720; - type_description_2 = "c"; - goto dict_build_exception_1; - } - Py_INCREF(tmp_dict_value_1); - } - } - - tmp_res = PyDict_SetItem(tmp_annotations_1, tmp_dict_key_1, tmp_dict_value_1); - Py_DECREF(tmp_dict_value_1); - assert(!(tmp_res != 0)); - } - goto dict_build_noexception_1; - // Exception handling pass through code for dict_build: - dict_build_exception_1:; - Py_DECREF(tmp_annotations_1); - goto frame_exception_exit_15; - // Finished with no exception for dict_build: - dict_build_noexception_1:; - Py_INCREF(tmp_defaults_8); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__38_get_extended_attention_mask(tmp_defaults_8, tmp_annotations_1); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[226], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 713; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - } - { - PyObject *tmp_defaults_9; - tmp_defaults_9 = mod_consts[395]; - Py_INCREF(tmp_defaults_9); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__39_forward(tmp_defaults_9); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 804; - type_description_2 = "c"; - goto frame_exception_exit_15; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_25865ea0df4a3f86bdd137c22518ab84_15); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_14; - - frame_exception_exit_15:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_25865ea0df4a3f86bdd137c22518ab84_15); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_25865ea0df4a3f86bdd137c22518ab84_15, exception_lineno); - } else if (exception_tb->tb_frame != &frame_25865ea0df4a3f86bdd137c22518ab84_15->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_25865ea0df4a3f86bdd137c22518ab84_15, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_25865ea0df4a3f86bdd137c22518ab84_15, - type_description_2, - outline_13_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_25865ea0df4a3f86bdd137c22518ab84_15 == cache_frame_25865ea0df4a3f86bdd137c22518ab84_15) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_25865ea0df4a3f86bdd137c22518ab84_15); - cache_frame_25865ea0df4a3f86bdd137c22518ab84_15 = NULL; - } - - assertFrameObject(frame_25865ea0df4a3f86bdd137c22518ab84_15); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_14; - - frame_no_exception_14:; - goto skip_nested_handling_14; - nested_frame_exit_14:; - - goto try_except_handler_46; - skip_nested_handling_14:; - { - nuitka_bool tmp_condition_result_84; - PyObject *tmp_compexpr_left_14; - PyObject *tmp_compexpr_right_14; - CHECK_OBJECT(tmp_class_creation_14__bases); - tmp_compexpr_left_14 = tmp_class_creation_14__bases; - CHECK_OBJECT(tmp_class_creation_14__bases_orig); - tmp_compexpr_right_14 = tmp_class_creation_14__bases_orig; - tmp_condition_result_84 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_14, tmp_compexpr_right_14); - if (tmp_condition_result_84 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_46; - } - if (tmp_condition_result_84 == NUITKA_BOOL_TRUE) { - goto branch_yes_56; - } else { - goto branch_no_56; - } - assert(tmp_condition_result_84 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_56:; - CHECK_OBJECT(tmp_class_creation_14__bases_orig); - tmp_dictset_value = tmp_class_creation_14__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__14_BertModel_677, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_46; - } - branch_no_56:; - { - PyObject *tmp_assign_source_154; - PyObject *tmp_called_name_29; - PyObject *tmp_args_name_28; - PyObject *tmp_tuple_element_56; - PyObject *tmp_kwargs_name_28; - CHECK_OBJECT(tmp_class_creation_14__metaclass); - tmp_called_name_29 = tmp_class_creation_14__metaclass; - tmp_tuple_element_56 = mod_consts[239]; - tmp_args_name_28 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_28, 0, tmp_tuple_element_56); - CHECK_OBJECT(tmp_class_creation_14__bases); - tmp_tuple_element_56 = tmp_class_creation_14__bases; - PyTuple_SET_ITEM0(tmp_args_name_28, 1, tmp_tuple_element_56); - tmp_tuple_element_56 = locals_models$Qformer$$$class__14_BertModel_677; - PyTuple_SET_ITEM0(tmp_args_name_28, 2, tmp_tuple_element_56); - CHECK_OBJECT(tmp_class_creation_14__class_decl_dict); - tmp_kwargs_name_28 = tmp_class_creation_14__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 677; - tmp_assign_source_154 = CALL_FUNCTION(tmp_called_name_29, tmp_args_name_28, tmp_kwargs_name_28); - Py_DECREF(tmp_args_name_28); - if (tmp_assign_source_154 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 677; - - goto try_except_handler_46; - } - { - PyObject *old = Nuitka_Cell_GET(outline_13_var___class__); - PyCell_SET(outline_13_var___class__, tmp_assign_source_154); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_13_var___class__)); - tmp_assign_source_153 = Nuitka_Cell_GET(outline_13_var___class__); - Py_INCREF(tmp_assign_source_153); - goto try_return_handler_46; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_46:; - Py_DECREF(locals_models$Qformer$$$class__14_BertModel_677); - locals_models$Qformer$$$class__14_BertModel_677 = NULL; - goto try_return_handler_45; - // Exception handler code: - try_except_handler_46:; - exception_keeper_type_44 = exception_type; - exception_keeper_value_44 = exception_value; - exception_keeper_tb_44 = exception_tb; - exception_keeper_lineno_44 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__14_BertModel_677); - locals_models$Qformer$$$class__14_BertModel_677 = NULL; - // Re-raise. - exception_type = exception_keeper_type_44; - exception_value = exception_keeper_value_44; - exception_tb = exception_keeper_tb_44; - exception_lineno = exception_keeper_lineno_44; - - goto try_except_handler_45; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_45:; - CHECK_OBJECT(outline_13_var___class__); - Py_DECREF(outline_13_var___class__); - outline_13_var___class__ = NULL; - goto outline_result_14; - // Exception handler code: - try_except_handler_45:; - exception_keeper_type_45 = exception_type; - exception_keeper_value_45 = exception_value; - exception_keeper_tb_45 = exception_tb; - exception_keeper_lineno_45 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_13_var___class__); - Py_DECREF(outline_13_var___class__); - outline_13_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_45; - exception_value = exception_keeper_value_45; - exception_tb = exception_keeper_tb_45; - exception_lineno = exception_keeper_lineno_45; - - goto outline_exception_14; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_14:; - exception_lineno = 677; - goto try_except_handler_44; - outline_result_14:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[239], tmp_assign_source_153); - } - goto try_end_18; - // Exception handler code: - try_except_handler_44:; - exception_keeper_type_46 = exception_type; - exception_keeper_value_46 = exception_value; - exception_keeper_tb_46 = exception_tb; - exception_keeper_lineno_46 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_14__bases_orig); - tmp_class_creation_14__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_14__bases); - tmp_class_creation_14__bases = NULL; - Py_XDECREF(tmp_class_creation_14__class_decl_dict); - tmp_class_creation_14__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_14__metaclass); - tmp_class_creation_14__metaclass = NULL; - Py_XDECREF(tmp_class_creation_14__prepared); - tmp_class_creation_14__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_46; - exception_value = exception_keeper_value_46; - exception_tb = exception_keeper_tb_46; - exception_lineno = exception_keeper_lineno_46; - - goto frame_exception_exit_1; - // End of try: - try_end_18:; - CHECK_OBJECT(tmp_class_creation_14__bases_orig); - Py_DECREF(tmp_class_creation_14__bases_orig); - tmp_class_creation_14__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_14__bases); - tmp_class_creation_14__bases = NULL; - Py_XDECREF(tmp_class_creation_14__class_decl_dict); - tmp_class_creation_14__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_14__metaclass); - tmp_class_creation_14__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_14__prepared); - Py_DECREF(tmp_class_creation_14__prepared); - tmp_class_creation_14__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_155; - PyObject *tmp_tuple_element_57; - tmp_tuple_element_57 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[375]); - - if (unlikely(tmp_tuple_element_57 == NULL)) { - tmp_tuple_element_57 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[375]); - } - - if (tmp_tuple_element_57 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - tmp_assign_source_155 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_assign_source_155, 0, tmp_tuple_element_57); - assert(tmp_class_creation_15__bases_orig == NULL); - tmp_class_creation_15__bases_orig = tmp_assign_source_155; - } - { - PyObject *tmp_assign_source_156; - PyObject *tmp_dircall_arg1_15; - CHECK_OBJECT(tmp_class_creation_15__bases_orig); - tmp_dircall_arg1_15 = tmp_class_creation_15__bases_orig; - Py_INCREF(tmp_dircall_arg1_15); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_15}; - tmp_assign_source_156 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_156 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - assert(tmp_class_creation_15__bases == NULL); - tmp_class_creation_15__bases = tmp_assign_source_156; - } - { - PyObject *tmp_assign_source_157; - tmp_assign_source_157 = PyDict_New(); - assert(tmp_class_creation_15__class_decl_dict == NULL); - tmp_class_creation_15__class_decl_dict = tmp_assign_source_157; - } - { - PyObject *tmp_assign_source_158; - PyObject *tmp_metaclass_name_15; - nuitka_bool tmp_condition_result_85; - PyObject *tmp_key_name_43; - PyObject *tmp_dict_arg_name_43; - PyObject *tmp_dict_arg_name_44; - PyObject *tmp_key_name_44; - nuitka_bool tmp_condition_result_86; - int tmp_truth_name_15; - PyObject *tmp_type_arg_29; - PyObject *tmp_expression_name_85; - PyObject *tmp_subscript_name_16; - PyObject *tmp_bases_name_15; - tmp_key_name_43 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_15__class_decl_dict); - tmp_dict_arg_name_43 = tmp_class_creation_15__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_43, tmp_key_name_43); - assert(!(tmp_res == -1)); - tmp_condition_result_85 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_85 == NUITKA_BOOL_TRUE) { - goto condexpr_true_29; - } else { - goto condexpr_false_29; - } - condexpr_true_29:; - CHECK_OBJECT(tmp_class_creation_15__class_decl_dict); - tmp_dict_arg_name_44 = tmp_class_creation_15__class_decl_dict; - tmp_key_name_44 = mod_consts[326]; - tmp_metaclass_name_15 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_44, tmp_key_name_44); - if (tmp_metaclass_name_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - goto condexpr_end_29; - condexpr_false_29:; - CHECK_OBJECT(tmp_class_creation_15__bases); - tmp_truth_name_15 = CHECK_IF_TRUE(tmp_class_creation_15__bases); - if (tmp_truth_name_15 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - tmp_condition_result_86 = tmp_truth_name_15 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_86 == NUITKA_BOOL_TRUE) { - goto condexpr_true_30; - } else { - goto condexpr_false_30; - } - condexpr_true_30:; - CHECK_OBJECT(tmp_class_creation_15__bases); - tmp_expression_name_85 = tmp_class_creation_15__bases; - tmp_subscript_name_16 = mod_consts[29]; - tmp_type_arg_29 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_85, tmp_subscript_name_16, 0); - if (tmp_type_arg_29 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - tmp_metaclass_name_15 = BUILTIN_TYPE1(tmp_type_arg_29); - Py_DECREF(tmp_type_arg_29); - if (tmp_metaclass_name_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - goto condexpr_end_30; - condexpr_false_30:; - tmp_metaclass_name_15 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_15); - condexpr_end_30:; - condexpr_end_29:; - CHECK_OBJECT(tmp_class_creation_15__bases); - tmp_bases_name_15 = tmp_class_creation_15__bases; - tmp_assign_source_158 = SELECT_METACLASS(tmp_metaclass_name_15, tmp_bases_name_15); - Py_DECREF(tmp_metaclass_name_15); - if (tmp_assign_source_158 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - assert(tmp_class_creation_15__metaclass == NULL); - tmp_class_creation_15__metaclass = tmp_assign_source_158; - } - { - nuitka_bool tmp_condition_result_87; - PyObject *tmp_key_name_45; - PyObject *tmp_dict_arg_name_45; - tmp_key_name_45 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_15__class_decl_dict); - tmp_dict_arg_name_45 = tmp_class_creation_15__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_45, tmp_key_name_45); - assert(!(tmp_res == -1)); - tmp_condition_result_87 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_87 == NUITKA_BOOL_TRUE) { - goto branch_yes_57; - } else { - goto branch_no_57; - } - } - branch_yes_57:; - CHECK_OBJECT(tmp_class_creation_15__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_15__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - branch_no_57:; - { - nuitka_bool tmp_condition_result_88; - PyObject *tmp_expression_name_86; - CHECK_OBJECT(tmp_class_creation_15__metaclass); - tmp_expression_name_86 = tmp_class_creation_15__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_86, mod_consts[327]); - tmp_condition_result_88 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_88 == NUITKA_BOOL_TRUE) { - goto branch_yes_58; - } else { - goto branch_no_58; - } - } - branch_yes_58:; - { - PyObject *tmp_assign_source_159; - PyObject *tmp_called_name_30; - PyObject *tmp_expression_name_87; - PyObject *tmp_args_name_29; - PyObject *tmp_tuple_element_58; - PyObject *tmp_kwargs_name_29; - CHECK_OBJECT(tmp_class_creation_15__metaclass); - tmp_expression_name_87 = tmp_class_creation_15__metaclass; - tmp_called_name_30 = LOOKUP_ATTRIBUTE(tmp_expression_name_87, mod_consts[327]); - if (tmp_called_name_30 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - tmp_tuple_element_58 = mod_consts[397]; - tmp_args_name_29 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_29, 0, tmp_tuple_element_58); - CHECK_OBJECT(tmp_class_creation_15__bases); - tmp_tuple_element_58 = tmp_class_creation_15__bases; - PyTuple_SET_ITEM0(tmp_args_name_29, 1, tmp_tuple_element_58); - CHECK_OBJECT(tmp_class_creation_15__class_decl_dict); - tmp_kwargs_name_29 = tmp_class_creation_15__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 968; - tmp_assign_source_159 = CALL_FUNCTION(tmp_called_name_30, tmp_args_name_29, tmp_kwargs_name_29); - Py_DECREF(tmp_called_name_30); - Py_DECREF(tmp_args_name_29); - if (tmp_assign_source_159 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - assert(tmp_class_creation_15__prepared == NULL); - tmp_class_creation_15__prepared = tmp_assign_source_159; - } - { - nuitka_bool tmp_condition_result_89; - PyObject *tmp_operand_name_15; - PyObject *tmp_expression_name_88; - CHECK_OBJECT(tmp_class_creation_15__prepared); - tmp_expression_name_88 = tmp_class_creation_15__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_88, mod_consts[328]); - tmp_operand_name_15 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_15); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - tmp_condition_result_89 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_89 == NUITKA_BOOL_TRUE) { - goto branch_yes_59; - } else { - goto branch_no_59; - } - } - branch_yes_59:; - { - PyObject *tmp_raise_type_15; - PyObject *tmp_raise_value_15; - PyObject *tmp_left_name_15; - PyObject *tmp_right_name_15; - PyObject *tmp_tuple_element_59; - PyObject *tmp_getattr_target_15; - PyObject *tmp_getattr_attr_15; - PyObject *tmp_getattr_default_15; - tmp_raise_type_15 = PyExc_TypeError; - tmp_left_name_15 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_15__metaclass); - tmp_getattr_target_15 = tmp_class_creation_15__metaclass; - tmp_getattr_attr_15 = mod_consts[324]; - tmp_getattr_default_15 = mod_consts[330]; - tmp_tuple_element_59 = BUILTIN_GETATTR(tmp_getattr_target_15, tmp_getattr_attr_15, tmp_getattr_default_15); - if (tmp_tuple_element_59 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - tmp_right_name_15 = PyTuple_New(2); - { - PyObject *tmp_expression_name_89; - PyObject *tmp_type_arg_30; - PyTuple_SET_ITEM(tmp_right_name_15, 0, tmp_tuple_element_59); - CHECK_OBJECT(tmp_class_creation_15__prepared); - tmp_type_arg_30 = tmp_class_creation_15__prepared; - tmp_expression_name_89 = BUILTIN_TYPE1(tmp_type_arg_30); - assert(!(tmp_expression_name_89 == NULL)); - tmp_tuple_element_59 = LOOKUP_ATTRIBUTE(tmp_expression_name_89, mod_consts[324]); - Py_DECREF(tmp_expression_name_89); - if (tmp_tuple_element_59 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto tuple_build_exception_15; - } - PyTuple_SET_ITEM(tmp_right_name_15, 1, tmp_tuple_element_59); - } - goto tuple_build_noexception_15; - // Exception handling pass through code for tuple_build: - tuple_build_exception_15:; - Py_DECREF(tmp_right_name_15); - goto try_except_handler_47; - // Finished with no exception for tuple_build: - tuple_build_noexception_15:; - tmp_raise_value_15 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_15, tmp_right_name_15); - Py_DECREF(tmp_right_name_15); - if (tmp_raise_value_15 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_47; - } - exception_type = tmp_raise_type_15; - Py_INCREF(tmp_raise_type_15); - exception_value = tmp_raise_value_15; - exception_lineno = 968; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_47; - } - branch_no_59:; - goto branch_end_58; - branch_no_58:; - { - PyObject *tmp_assign_source_160; - tmp_assign_source_160 = PyDict_New(); - assert(tmp_class_creation_15__prepared == NULL); - tmp_class_creation_15__prepared = tmp_assign_source_160; - } - branch_end_58:; - { - PyObject *tmp_assign_source_161; - { - PyObject *tmp_set_locals_15; - CHECK_OBJECT(tmp_class_creation_15__prepared); - tmp_set_locals_15 = tmp_class_creation_15__prepared; - locals_models$Qformer$$$class__15_BertLMHeadModel_968 = tmp_set_locals_15; - Py_INCREF(tmp_set_locals_15); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_49; - } - tmp_dictset_value = mod_consts[397]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_49; - } - if (isFrameUnusable(cache_frame_aa454e092d5abc9f5e4553a289907508_16)) { - Py_XDECREF(cache_frame_aa454e092d5abc9f5e4553a289907508_16); - -#if _DEBUG_REFCOUNTS - if (cache_frame_aa454e092d5abc9f5e4553a289907508_16 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_aa454e092d5abc9f5e4553a289907508_16 = MAKE_FUNCTION_FRAME(codeobj_aa454e092d5abc9f5e4553a289907508, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_aa454e092d5abc9f5e4553a289907508_16->m_type_description == NULL); - frame_aa454e092d5abc9f5e4553a289907508_16 = cache_frame_aa454e092d5abc9f5e4553a289907508_16; - - // Push the new frame as the currently active one. - pushFrameStack(frame_aa454e092d5abc9f5e4553a289907508_16); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_aa454e092d5abc9f5e4553a289907508_16) == 2); // Frame stack - - // Framed code: - tmp_dictset_value = LIST_COPY(mod_consts[398]); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[399], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 970; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - tmp_dictset_value = LIST_COPY(mod_consts[400]); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[380], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 971; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - { - struct Nuitka_CellObject *tmp_closure_14[1]; - - tmp_closure_14[0] = outline_14_var___class__; - Py_INCREF(tmp_closure_14[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__40___init__(tmp_closure_14); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 973; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__41_get_output_embeddings(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[402], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 981; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__42_set_output_embeddings(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[404], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 984; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - { - PyObject *tmp_defaults_10; - tmp_defaults_10 = mod_consts[406]; - Py_INCREF(tmp_defaults_10); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__43_forward(tmp_defaults_10); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 987; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - } - { - PyObject *tmp_defaults_11; - tmp_defaults_11 = mod_consts[408]; - Py_INCREF(tmp_defaults_11); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__44_prepare_inputs_for_generation(tmp_defaults_11); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[409], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1097; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__45__reorder_cache(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[411], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1120; - type_description_2 = "c"; - goto frame_exception_exit_16; - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_aa454e092d5abc9f5e4553a289907508_16); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_15; - - frame_exception_exit_16:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_aa454e092d5abc9f5e4553a289907508_16); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_aa454e092d5abc9f5e4553a289907508_16, exception_lineno); - } else if (exception_tb->tb_frame != &frame_aa454e092d5abc9f5e4553a289907508_16->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_aa454e092d5abc9f5e4553a289907508_16, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_aa454e092d5abc9f5e4553a289907508_16, - type_description_2, - outline_14_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_aa454e092d5abc9f5e4553a289907508_16 == cache_frame_aa454e092d5abc9f5e4553a289907508_16) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_aa454e092d5abc9f5e4553a289907508_16); - cache_frame_aa454e092d5abc9f5e4553a289907508_16 = NULL; - } - - assertFrameObject(frame_aa454e092d5abc9f5e4553a289907508_16); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_15; - - frame_no_exception_15:; - goto skip_nested_handling_15; - nested_frame_exit_15:; - - goto try_except_handler_49; - skip_nested_handling_15:; - { - nuitka_bool tmp_condition_result_90; - PyObject *tmp_compexpr_left_15; - PyObject *tmp_compexpr_right_15; - CHECK_OBJECT(tmp_class_creation_15__bases); - tmp_compexpr_left_15 = tmp_class_creation_15__bases; - CHECK_OBJECT(tmp_class_creation_15__bases_orig); - tmp_compexpr_right_15 = tmp_class_creation_15__bases_orig; - tmp_condition_result_90 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_15, tmp_compexpr_right_15); - if (tmp_condition_result_90 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_49; - } - if (tmp_condition_result_90 == NUITKA_BOOL_TRUE) { - goto branch_yes_60; - } else { - goto branch_no_60; - } - assert(tmp_condition_result_90 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_60:; - CHECK_OBJECT(tmp_class_creation_15__bases_orig); - tmp_dictset_value = tmp_class_creation_15__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__15_BertLMHeadModel_968, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_49; - } - branch_no_60:; - { - PyObject *tmp_assign_source_162; - PyObject *tmp_called_name_31; - PyObject *tmp_args_name_30; - PyObject *tmp_tuple_element_60; - PyObject *tmp_kwargs_name_30; - CHECK_OBJECT(tmp_class_creation_15__metaclass); - tmp_called_name_31 = tmp_class_creation_15__metaclass; - tmp_tuple_element_60 = mod_consts[397]; - tmp_args_name_30 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_30, 0, tmp_tuple_element_60); - CHECK_OBJECT(tmp_class_creation_15__bases); - tmp_tuple_element_60 = tmp_class_creation_15__bases; - PyTuple_SET_ITEM0(tmp_args_name_30, 1, tmp_tuple_element_60); - tmp_tuple_element_60 = locals_models$Qformer$$$class__15_BertLMHeadModel_968; - PyTuple_SET_ITEM0(tmp_args_name_30, 2, tmp_tuple_element_60); - CHECK_OBJECT(tmp_class_creation_15__class_decl_dict); - tmp_kwargs_name_30 = tmp_class_creation_15__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 968; - tmp_assign_source_162 = CALL_FUNCTION(tmp_called_name_31, tmp_args_name_30, tmp_kwargs_name_30); - Py_DECREF(tmp_args_name_30); - if (tmp_assign_source_162 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 968; - - goto try_except_handler_49; - } - { - PyObject *old = Nuitka_Cell_GET(outline_14_var___class__); - PyCell_SET(outline_14_var___class__, tmp_assign_source_162); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_14_var___class__)); - tmp_assign_source_161 = Nuitka_Cell_GET(outline_14_var___class__); - Py_INCREF(tmp_assign_source_161); - goto try_return_handler_49; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_49:; - Py_DECREF(locals_models$Qformer$$$class__15_BertLMHeadModel_968); - locals_models$Qformer$$$class__15_BertLMHeadModel_968 = NULL; - goto try_return_handler_48; - // Exception handler code: - try_except_handler_49:; - exception_keeper_type_47 = exception_type; - exception_keeper_value_47 = exception_value; - exception_keeper_tb_47 = exception_tb; - exception_keeper_lineno_47 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__15_BertLMHeadModel_968); - locals_models$Qformer$$$class__15_BertLMHeadModel_968 = NULL; - // Re-raise. - exception_type = exception_keeper_type_47; - exception_value = exception_keeper_value_47; - exception_tb = exception_keeper_tb_47; - exception_lineno = exception_keeper_lineno_47; - - goto try_except_handler_48; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_48:; - CHECK_OBJECT(outline_14_var___class__); - Py_DECREF(outline_14_var___class__); - outline_14_var___class__ = NULL; - goto outline_result_15; - // Exception handler code: - try_except_handler_48:; - exception_keeper_type_48 = exception_type; - exception_keeper_value_48 = exception_value; - exception_keeper_tb_48 = exception_tb; - exception_keeper_lineno_48 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_14_var___class__); - Py_DECREF(outline_14_var___class__); - outline_14_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_48; - exception_value = exception_keeper_value_48; - exception_tb = exception_keeper_tb_48; - exception_lineno = exception_keeper_lineno_48; - - goto outline_exception_15; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_15:; - exception_lineno = 968; - goto try_except_handler_47; - outline_result_15:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[397], tmp_assign_source_161); - } - goto try_end_19; - // Exception handler code: - try_except_handler_47:; - exception_keeper_type_49 = exception_type; - exception_keeper_value_49 = exception_value; - exception_keeper_tb_49 = exception_tb; - exception_keeper_lineno_49 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_15__bases_orig); - tmp_class_creation_15__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_15__bases); - tmp_class_creation_15__bases = NULL; - Py_XDECREF(tmp_class_creation_15__class_decl_dict); - tmp_class_creation_15__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_15__metaclass); - tmp_class_creation_15__metaclass = NULL; - Py_XDECREF(tmp_class_creation_15__prepared); - tmp_class_creation_15__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_49; - exception_value = exception_keeper_value_49; - exception_tb = exception_keeper_tb_49; - exception_lineno = exception_keeper_lineno_49; - - goto frame_exception_exit_1; - // End of try: - try_end_19:; - CHECK_OBJECT(tmp_class_creation_15__bases_orig); - Py_DECREF(tmp_class_creation_15__bases_orig); - tmp_class_creation_15__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_15__bases); - tmp_class_creation_15__bases = NULL; - Py_XDECREF(tmp_class_creation_15__class_decl_dict); - tmp_class_creation_15__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_15__metaclass); - tmp_class_creation_15__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_15__prepared); - Py_DECREF(tmp_class_creation_15__prepared); - tmp_class_creation_15__prepared = NULL; - // Tried code: - { - PyObject *tmp_assign_source_163; - PyObject *tmp_tuple_element_61; - tmp_tuple_element_61 = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[375]); - - if (unlikely(tmp_tuple_element_61 == NULL)) { - tmp_tuple_element_61 = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[375]); - } - - if (tmp_tuple_element_61 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - tmp_assign_source_163 = PyTuple_New(1); - PyTuple_SET_ITEM0(tmp_assign_source_163, 0, tmp_tuple_element_61); - assert(tmp_class_creation_16__bases_orig == NULL); - tmp_class_creation_16__bases_orig = tmp_assign_source_163; - } - { - PyObject *tmp_assign_source_164; - PyObject *tmp_dircall_arg1_16; - CHECK_OBJECT(tmp_class_creation_16__bases_orig); - tmp_dircall_arg1_16 = tmp_class_creation_16__bases_orig; - Py_INCREF(tmp_dircall_arg1_16); - - { - PyObject *dir_call_args[] = {tmp_dircall_arg1_16}; - tmp_assign_source_164 = impl_models$$$function__1__mro_entries_conversion(dir_call_args); - } - if (tmp_assign_source_164 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - assert(tmp_class_creation_16__bases == NULL); - tmp_class_creation_16__bases = tmp_assign_source_164; - } - { - PyObject *tmp_assign_source_165; - tmp_assign_source_165 = PyDict_New(); - assert(tmp_class_creation_16__class_decl_dict == NULL); - tmp_class_creation_16__class_decl_dict = tmp_assign_source_165; - } - { - PyObject *tmp_assign_source_166; - PyObject *tmp_metaclass_name_16; - nuitka_bool tmp_condition_result_91; - PyObject *tmp_key_name_46; - PyObject *tmp_dict_arg_name_46; - PyObject *tmp_dict_arg_name_47; - PyObject *tmp_key_name_47; - nuitka_bool tmp_condition_result_92; - int tmp_truth_name_16; - PyObject *tmp_type_arg_31; - PyObject *tmp_expression_name_90; - PyObject *tmp_subscript_name_17; - PyObject *tmp_bases_name_16; - tmp_key_name_46 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_16__class_decl_dict); - tmp_dict_arg_name_46 = tmp_class_creation_16__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_46, tmp_key_name_46); - assert(!(tmp_res == -1)); - tmp_condition_result_91 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_91 == NUITKA_BOOL_TRUE) { - goto condexpr_true_31; - } else { - goto condexpr_false_31; - } - condexpr_true_31:; - CHECK_OBJECT(tmp_class_creation_16__class_decl_dict); - tmp_dict_arg_name_47 = tmp_class_creation_16__class_decl_dict; - tmp_key_name_47 = mod_consts[326]; - tmp_metaclass_name_16 = DICT_GET_ITEM_WITH_ERROR(tmp_dict_arg_name_47, tmp_key_name_47); - if (tmp_metaclass_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - goto condexpr_end_31; - condexpr_false_31:; - CHECK_OBJECT(tmp_class_creation_16__bases); - tmp_truth_name_16 = CHECK_IF_TRUE(tmp_class_creation_16__bases); - if (tmp_truth_name_16 == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - tmp_condition_result_92 = tmp_truth_name_16 == 0 ? NUITKA_BOOL_FALSE : NUITKA_BOOL_TRUE; - if (tmp_condition_result_92 == NUITKA_BOOL_TRUE) { - goto condexpr_true_32; - } else { - goto condexpr_false_32; - } - condexpr_true_32:; - CHECK_OBJECT(tmp_class_creation_16__bases); - tmp_expression_name_90 = tmp_class_creation_16__bases; - tmp_subscript_name_17 = mod_consts[29]; - tmp_type_arg_31 = LOOKUP_SUBSCRIPT_CONST(tmp_expression_name_90, tmp_subscript_name_17, 0); - if (tmp_type_arg_31 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - tmp_metaclass_name_16 = BUILTIN_TYPE1(tmp_type_arg_31); - Py_DECREF(tmp_type_arg_31); - if (tmp_metaclass_name_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - goto condexpr_end_32; - condexpr_false_32:; - tmp_metaclass_name_16 = (PyObject *)&PyType_Type; - Py_INCREF(tmp_metaclass_name_16); - condexpr_end_32:; - condexpr_end_31:; - CHECK_OBJECT(tmp_class_creation_16__bases); - tmp_bases_name_16 = tmp_class_creation_16__bases; - tmp_assign_source_166 = SELECT_METACLASS(tmp_metaclass_name_16, tmp_bases_name_16); - Py_DECREF(tmp_metaclass_name_16); - if (tmp_assign_source_166 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - assert(tmp_class_creation_16__metaclass == NULL); - tmp_class_creation_16__metaclass = tmp_assign_source_166; - } - { - nuitka_bool tmp_condition_result_93; - PyObject *tmp_key_name_48; - PyObject *tmp_dict_arg_name_48; - tmp_key_name_48 = mod_consts[326]; - CHECK_OBJECT(tmp_class_creation_16__class_decl_dict); - tmp_dict_arg_name_48 = tmp_class_creation_16__class_decl_dict; - tmp_res = DICT_HAS_ITEM(tmp_dict_arg_name_48, tmp_key_name_48); - assert(!(tmp_res == -1)); - tmp_condition_result_93 = (tmp_res != 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_93 == NUITKA_BOOL_TRUE) { - goto branch_yes_61; - } else { - goto branch_no_61; - } - } - branch_yes_61:; - CHECK_OBJECT(tmp_class_creation_16__class_decl_dict); - tmp_dictdel_dict = tmp_class_creation_16__class_decl_dict; - tmp_dictdel_key = mod_consts[326]; - tmp_result = DICT_REMOVE_ITEM(tmp_dictdel_dict, tmp_dictdel_key); - if (tmp_result == false) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - branch_no_61:; - { - nuitka_bool tmp_condition_result_94; - PyObject *tmp_expression_name_91; - CHECK_OBJECT(tmp_class_creation_16__metaclass); - tmp_expression_name_91 = tmp_class_creation_16__metaclass; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_91, mod_consts[327]); - tmp_condition_result_94 = (tmp_result) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_94 == NUITKA_BOOL_TRUE) { - goto branch_yes_62; - } else { - goto branch_no_62; - } - } - branch_yes_62:; - { - PyObject *tmp_assign_source_167; - PyObject *tmp_called_name_32; - PyObject *tmp_expression_name_92; - PyObject *tmp_args_name_31; - PyObject *tmp_tuple_element_62; - PyObject *tmp_kwargs_name_31; - CHECK_OBJECT(tmp_class_creation_16__metaclass); - tmp_expression_name_92 = tmp_class_creation_16__metaclass; - tmp_called_name_32 = LOOKUP_ATTRIBUTE(tmp_expression_name_92, mod_consts[327]); - if (tmp_called_name_32 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - tmp_tuple_element_62 = mod_consts[413]; - tmp_args_name_31 = PyTuple_New(2); - PyTuple_SET_ITEM0(tmp_args_name_31, 0, tmp_tuple_element_62); - CHECK_OBJECT(tmp_class_creation_16__bases); - tmp_tuple_element_62 = tmp_class_creation_16__bases; - PyTuple_SET_ITEM0(tmp_args_name_31, 1, tmp_tuple_element_62); - CHECK_OBJECT(tmp_class_creation_16__class_decl_dict); - tmp_kwargs_name_31 = tmp_class_creation_16__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 1131; - tmp_assign_source_167 = CALL_FUNCTION(tmp_called_name_32, tmp_args_name_31, tmp_kwargs_name_31); - Py_DECREF(tmp_called_name_32); - Py_DECREF(tmp_args_name_31); - if (tmp_assign_source_167 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - assert(tmp_class_creation_16__prepared == NULL); - tmp_class_creation_16__prepared = tmp_assign_source_167; - } - { - nuitka_bool tmp_condition_result_95; - PyObject *tmp_operand_name_16; - PyObject *tmp_expression_name_93; - CHECK_OBJECT(tmp_class_creation_16__prepared); - tmp_expression_name_93 = tmp_class_creation_16__prepared; - tmp_result = HAS_ATTR_BOOL(tmp_expression_name_93, mod_consts[328]); - tmp_operand_name_16 = (tmp_result) ? Py_True : Py_False; - tmp_res = CHECK_IF_TRUE(tmp_operand_name_16); - if (tmp_res == -1) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - tmp_condition_result_95 = (tmp_res == 0) ? NUITKA_BOOL_TRUE : NUITKA_BOOL_FALSE; - if (tmp_condition_result_95 == NUITKA_BOOL_TRUE) { - goto branch_yes_63; - } else { - goto branch_no_63; - } - } - branch_yes_63:; - { - PyObject *tmp_raise_type_16; - PyObject *tmp_raise_value_16; - PyObject *tmp_left_name_16; - PyObject *tmp_right_name_16; - PyObject *tmp_tuple_element_63; - PyObject *tmp_getattr_target_16; - PyObject *tmp_getattr_attr_16; - PyObject *tmp_getattr_default_16; - tmp_raise_type_16 = PyExc_TypeError; - tmp_left_name_16 = mod_consts[329]; - CHECK_OBJECT(tmp_class_creation_16__metaclass); - tmp_getattr_target_16 = tmp_class_creation_16__metaclass; - tmp_getattr_attr_16 = mod_consts[324]; - tmp_getattr_default_16 = mod_consts[330]; - tmp_tuple_element_63 = BUILTIN_GETATTR(tmp_getattr_target_16, tmp_getattr_attr_16, tmp_getattr_default_16); - if (tmp_tuple_element_63 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - tmp_right_name_16 = PyTuple_New(2); - { - PyObject *tmp_expression_name_94; - PyObject *tmp_type_arg_32; - PyTuple_SET_ITEM(tmp_right_name_16, 0, tmp_tuple_element_63); - CHECK_OBJECT(tmp_class_creation_16__prepared); - tmp_type_arg_32 = tmp_class_creation_16__prepared; - tmp_expression_name_94 = BUILTIN_TYPE1(tmp_type_arg_32); - assert(!(tmp_expression_name_94 == NULL)); - tmp_tuple_element_63 = LOOKUP_ATTRIBUTE(tmp_expression_name_94, mod_consts[324]); - Py_DECREF(tmp_expression_name_94); - if (tmp_tuple_element_63 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto tuple_build_exception_16; - } - PyTuple_SET_ITEM(tmp_right_name_16, 1, tmp_tuple_element_63); - } - goto tuple_build_noexception_16; - // Exception handling pass through code for tuple_build: - tuple_build_exception_16:; - Py_DECREF(tmp_right_name_16); - goto try_except_handler_50; - // Finished with no exception for tuple_build: - tuple_build_noexception_16:; - tmp_raise_value_16 = BINARY_OPERATION_MOD_OBJECT_UNICODE_TUPLE(tmp_left_name_16, tmp_right_name_16); - Py_DECREF(tmp_right_name_16); - if (tmp_raise_value_16 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_50; - } - exception_type = tmp_raise_type_16; - Py_INCREF(tmp_raise_type_16); - exception_value = tmp_raise_value_16; - exception_lineno = 1131; - RAISE_EXCEPTION_IMPLICIT(&exception_type, &exception_value, &exception_tb); - - goto try_except_handler_50; - } - branch_no_63:; - goto branch_end_62; - branch_no_62:; - { - PyObject *tmp_assign_source_168; - tmp_assign_source_168 = PyDict_New(); - assert(tmp_class_creation_16__prepared == NULL); - tmp_class_creation_16__prepared = tmp_assign_source_168; - } - branch_end_62:; - { - PyObject *tmp_assign_source_169; - { - PyObject *tmp_set_locals_16; - CHECK_OBJECT(tmp_class_creation_16__prepared); - tmp_set_locals_16 = tmp_class_creation_16__prepared; - locals_models$Qformer$$$class__16_BertForMaskedLM_1131 = tmp_set_locals_16; - Py_INCREF(tmp_set_locals_16); - } - // Tried code: - // Tried code: - tmp_dictset_value = GET_STRING_DICT_VALUE(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[324]); - - if (unlikely(tmp_dictset_value == NULL)) { - tmp_dictset_value = GET_MODULE_VARIABLE_VALUE_FALLBACK(mod_consts[324]); - } - - assert(!(tmp_dictset_value == NULL)); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[331], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_52; - } - tmp_dictset_value = mod_consts[413]; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[333], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_52; - } - if (isFrameUnusable(cache_frame_e5264d356d902ef78943e91fb87114a1_17)) { - Py_XDECREF(cache_frame_e5264d356d902ef78943e91fb87114a1_17); - -#if _DEBUG_REFCOUNTS - if (cache_frame_e5264d356d902ef78943e91fb87114a1_17 == NULL) { - count_active_frame_cache_instances += 1; - } else { - count_released_frame_cache_instances += 1; - } - count_allocated_frame_cache_instances += 1; -#endif - cache_frame_e5264d356d902ef78943e91fb87114a1_17 = MAKE_FUNCTION_FRAME(codeobj_e5264d356d902ef78943e91fb87114a1, module_models$Qformer, sizeof(void *)); -#if _DEBUG_REFCOUNTS - } else { - count_hit_frame_cache_instances += 1; -#endif - } - assert(cache_frame_e5264d356d902ef78943e91fb87114a1_17->m_type_description == NULL); - frame_e5264d356d902ef78943e91fb87114a1_17 = cache_frame_e5264d356d902ef78943e91fb87114a1_17; - - // Push the new frame as the currently active one. - pushFrameStack(frame_e5264d356d902ef78943e91fb87114a1_17); - - // Mark the frame object as in use, ref count 1 will be up for reuse. - assert(Py_REFCNT(frame_e5264d356d902ef78943e91fb87114a1_17) == 2); // Frame stack - - // Framed code: - tmp_dictset_value = LIST_COPY(mod_consts[398]); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[399], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1133; - type_description_2 = "c"; - goto frame_exception_exit_17; - } - tmp_dictset_value = LIST_COPY(mod_consts[400]); - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[380], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1134; - type_description_2 = "c"; - goto frame_exception_exit_17; - } - { - struct Nuitka_CellObject *tmp_closure_15[1]; - - tmp_closure_15[0] = outline_15_var___class__; - Py_INCREF(tmp_closure_15[0]); - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__46___init__(tmp_closure_15); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[1], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1136; - type_description_2 = "c"; - goto frame_exception_exit_17; - } - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__47_get_output_embeddings(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[402], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1144; - type_description_2 = "c"; - goto frame_exception_exit_17; - } - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__48_set_output_embeddings(); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[404], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1147; - type_description_2 = "c"; - goto frame_exception_exit_17; - } - { - PyObject *tmp_defaults_12; - tmp_defaults_12 = mod_consts[417]; - Py_INCREF(tmp_defaults_12); - - - tmp_dictset_value = MAKE_FUNCTION_models$Qformer$$$function__49_forward(tmp_defaults_12); - - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[336], tmp_dictset_value); - Py_DECREF(tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1150; - type_description_2 = "c"; - goto frame_exception_exit_17; - } - } - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e5264d356d902ef78943e91fb87114a1_17); -#endif - - // Put the previous frame back on top. - popFrameStack(); - - goto frame_no_exception_16; - - frame_exception_exit_17:; - -#if 0 - RESTORE_FRAME_EXCEPTION(frame_e5264d356d902ef78943e91fb87114a1_17); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_e5264d356d902ef78943e91fb87114a1_17, exception_lineno); - } else if (exception_tb->tb_frame != &frame_e5264d356d902ef78943e91fb87114a1_17->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_e5264d356d902ef78943e91fb87114a1_17, exception_lineno); - } - - // Attaches locals to frame if any. - Nuitka_Frame_AttachLocals( - frame_e5264d356d902ef78943e91fb87114a1_17, - type_description_2, - outline_15_var___class__ - ); - - - // Release cached frame if used for exception. - if (frame_e5264d356d902ef78943e91fb87114a1_17 == cache_frame_e5264d356d902ef78943e91fb87114a1_17) { -#if _DEBUG_REFCOUNTS - count_active_frame_cache_instances -= 1; - count_released_frame_cache_instances += 1; -#endif - - Py_DECREF(cache_frame_e5264d356d902ef78943e91fb87114a1_17); - cache_frame_e5264d356d902ef78943e91fb87114a1_17 = NULL; - } - - assertFrameObject(frame_e5264d356d902ef78943e91fb87114a1_17); - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto nested_frame_exit_16; - - frame_no_exception_16:; - goto skip_nested_handling_16; - nested_frame_exit_16:; - - goto try_except_handler_52; - skip_nested_handling_16:; - { - nuitka_bool tmp_condition_result_96; - PyObject *tmp_compexpr_left_16; - PyObject *tmp_compexpr_right_16; - CHECK_OBJECT(tmp_class_creation_16__bases); - tmp_compexpr_left_16 = tmp_class_creation_16__bases; - CHECK_OBJECT(tmp_class_creation_16__bases_orig); - tmp_compexpr_right_16 = tmp_class_creation_16__bases_orig; - tmp_condition_result_96 = RICH_COMPARE_NE_NBOOL_OBJECT_TUPLE(tmp_compexpr_left_16, tmp_compexpr_right_16); - if (tmp_condition_result_96 == NUITKA_BOOL_EXCEPTION) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_52; - } - if (tmp_condition_result_96 == NUITKA_BOOL_TRUE) { - goto branch_yes_64; - } else { - goto branch_no_64; - } - assert(tmp_condition_result_96 != NUITKA_BOOL_UNASSIGNED); - } - branch_yes_64:; - CHECK_OBJECT(tmp_class_creation_16__bases_orig); - tmp_dictset_value = tmp_class_creation_16__bases_orig; - tmp_res = PyObject_SetItem(locals_models$Qformer$$$class__16_BertForMaskedLM_1131, mod_consts[338], tmp_dictset_value); - if (tmp_res != 0) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_52; - } - branch_no_64:; - { - PyObject *tmp_assign_source_170; - PyObject *tmp_called_name_33; - PyObject *tmp_args_name_32; - PyObject *tmp_tuple_element_64; - PyObject *tmp_kwargs_name_32; - CHECK_OBJECT(tmp_class_creation_16__metaclass); - tmp_called_name_33 = tmp_class_creation_16__metaclass; - tmp_tuple_element_64 = mod_consts[413]; - tmp_args_name_32 = PyTuple_New(3); - PyTuple_SET_ITEM0(tmp_args_name_32, 0, tmp_tuple_element_64); - CHECK_OBJECT(tmp_class_creation_16__bases); - tmp_tuple_element_64 = tmp_class_creation_16__bases; - PyTuple_SET_ITEM0(tmp_args_name_32, 1, tmp_tuple_element_64); - tmp_tuple_element_64 = locals_models$Qformer$$$class__16_BertForMaskedLM_1131; - PyTuple_SET_ITEM0(tmp_args_name_32, 2, tmp_tuple_element_64); - CHECK_OBJECT(tmp_class_creation_16__class_decl_dict); - tmp_kwargs_name_32 = tmp_class_creation_16__class_decl_dict; - frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame.f_lineno = 1131; - tmp_assign_source_170 = CALL_FUNCTION(tmp_called_name_33, tmp_args_name_32, tmp_kwargs_name_32); - Py_DECREF(tmp_args_name_32); - if (tmp_assign_source_170 == NULL) { - assert(ERROR_OCCURRED()); - - FETCH_ERROR_OCCURRED(&exception_type, &exception_value, &exception_tb); - - - exception_lineno = 1131; - - goto try_except_handler_52; - } - { - PyObject *old = Nuitka_Cell_GET(outline_15_var___class__); - PyCell_SET(outline_15_var___class__, tmp_assign_source_170); - Py_XDECREF(old); - } - - } - CHECK_OBJECT(Nuitka_Cell_GET(outline_15_var___class__)); - tmp_assign_source_169 = Nuitka_Cell_GET(outline_15_var___class__); - Py_INCREF(tmp_assign_source_169); - goto try_return_handler_52; - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_52:; - Py_DECREF(locals_models$Qformer$$$class__16_BertForMaskedLM_1131); - locals_models$Qformer$$$class__16_BertForMaskedLM_1131 = NULL; - goto try_return_handler_51; - // Exception handler code: - try_except_handler_52:; - exception_keeper_type_50 = exception_type; - exception_keeper_value_50 = exception_value; - exception_keeper_tb_50 = exception_tb; - exception_keeper_lineno_50 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_DECREF(locals_models$Qformer$$$class__16_BertForMaskedLM_1131); - locals_models$Qformer$$$class__16_BertForMaskedLM_1131 = NULL; - // Re-raise. - exception_type = exception_keeper_type_50; - exception_value = exception_keeper_value_50; - exception_tb = exception_keeper_tb_50; - exception_lineno = exception_keeper_lineno_50; - - goto try_except_handler_51; - // End of try: - NUITKA_CANNOT_GET_HERE("tried codes exits in all cases"); - return NULL; - // Return handler code: - try_return_handler_51:; - CHECK_OBJECT(outline_15_var___class__); - Py_DECREF(outline_15_var___class__); - outline_15_var___class__ = NULL; - goto outline_result_16; - // Exception handler code: - try_except_handler_51:; - exception_keeper_type_51 = exception_type; - exception_keeper_value_51 = exception_value; - exception_keeper_tb_51 = exception_tb; - exception_keeper_lineno_51 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - CHECK_OBJECT(outline_15_var___class__); - Py_DECREF(outline_15_var___class__); - outline_15_var___class__ = NULL; - // Re-raise. - exception_type = exception_keeper_type_51; - exception_value = exception_keeper_value_51; - exception_tb = exception_keeper_tb_51; - exception_lineno = exception_keeper_lineno_51; - - goto outline_exception_16; - // End of try: - NUITKA_CANNOT_GET_HERE("Return statement must have exited already."); - return NULL; - outline_exception_16:; - exception_lineno = 1131; - goto try_except_handler_50; - outline_result_16:; - UPDATE_STRING_DICT1(moduledict_models$Qformer, (Nuitka_StringObject *)mod_consts[413], tmp_assign_source_169); - } - goto try_end_20; - // Exception handler code: - try_except_handler_50:; - exception_keeper_type_52 = exception_type; - exception_keeper_value_52 = exception_value; - exception_keeper_tb_52 = exception_tb; - exception_keeper_lineno_52 = exception_lineno; - exception_type = NULL; - exception_value = NULL; - exception_tb = NULL; - exception_lineno = 0; - - Py_XDECREF(tmp_class_creation_16__bases_orig); - tmp_class_creation_16__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_16__bases); - tmp_class_creation_16__bases = NULL; - Py_XDECREF(tmp_class_creation_16__class_decl_dict); - tmp_class_creation_16__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_16__metaclass); - tmp_class_creation_16__metaclass = NULL; - Py_XDECREF(tmp_class_creation_16__prepared); - tmp_class_creation_16__prepared = NULL; - // Re-raise. - exception_type = exception_keeper_type_52; - exception_value = exception_keeper_value_52; - exception_tb = exception_keeper_tb_52; - exception_lineno = exception_keeper_lineno_52; - - goto frame_exception_exit_1; - // End of try: - try_end_20:; - - // Restore frame exception if necessary. -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2bb9003dfff85549a8e8392e723ec6c8); -#endif - popFrameStack(); - - assertFrameObject(frame_2bb9003dfff85549a8e8392e723ec6c8); - - goto frame_no_exception_17; - - frame_exception_exit_1:; -#if 0 - RESTORE_FRAME_EXCEPTION(frame_2bb9003dfff85549a8e8392e723ec6c8); -#endif - - if (exception_tb == NULL) { - exception_tb = MAKE_TRACEBACK(frame_2bb9003dfff85549a8e8392e723ec6c8, exception_lineno); - } else if (exception_tb->tb_frame != &frame_2bb9003dfff85549a8e8392e723ec6c8->m_frame) { - exception_tb = ADD_TRACEBACK(exception_tb, frame_2bb9003dfff85549a8e8392e723ec6c8, exception_lineno); - } - - // Put the previous frame back on top. - popFrameStack(); - - // Return the error. - goto module_exception_exit; - - frame_no_exception_17:; - CHECK_OBJECT(tmp_class_creation_16__bases_orig); - Py_DECREF(tmp_class_creation_16__bases_orig); - tmp_class_creation_16__bases_orig = NULL; - Py_XDECREF(tmp_class_creation_16__bases); - tmp_class_creation_16__bases = NULL; - Py_XDECREF(tmp_class_creation_16__class_decl_dict); - tmp_class_creation_16__class_decl_dict = NULL; - Py_XDECREF(tmp_class_creation_16__metaclass); - tmp_class_creation_16__metaclass = NULL; - CHECK_OBJECT(tmp_class_creation_16__prepared); - Py_DECREF(tmp_class_creation_16__prepared); - tmp_class_creation_16__prepared = NULL; - - return module_models$Qformer; - module_exception_exit: - RESTORE_ERROR_OCCURRED(exception_type, exception_value, exception_tb); - return NULL; -} -