MCPcopy Create free account
hub / github.com/Sally-SH/VSP-LLM / __Pyx__ImportDottedModule

Function __Pyx__ImportDottedModule

fairseq/fairseq/data/data_utils_fast.cpp:26328–26353  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26326}
26327#endif
26328static PyObject *__Pyx__ImportDottedModule(PyObject *name, PyObject *parts_tuple) {
26329#if PY_MAJOR_VERSION < 3
26330 PyObject *module, *from_list, *star = __pyx_n_s__3;
26331 CYTHON_UNUSED_VAR(parts_tuple);
26332 from_list = PyList_New(1);
26333 if (unlikely(!from_list))
26334 return NULL;
26335 Py_INCREF(star);
26336 PyList_SET_ITEM(from_list, 0, star);
26337 module = __Pyx_Import(name, from_list, 0);
26338 Py_DECREF(from_list);
26339 return module;
26340#else
26341 PyObject *imported_module;
26342 PyObject *module = __Pyx_Import(name, NULL, 0);
26343 if (!parts_tuple || unlikely(!module))
26344 return module;
26345 imported_module = __Pyx__ImportDottedModule_Lookup(name);
26346 if (likely(imported_module)) {
26347 Py_DECREF(module);
26348 return imported_module;
26349 }
26350 PyErr_Clear();
26351 return __Pyx_ImportDottedModule_WalkParts(module, name, parts_tuple);
26352#endif
26353}
26354static PyObject *__Pyx_ImportDottedModule(PyObject *name, PyObject *parts_tuple) {
26355#if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030400B1
26356 PyObject *module = __Pyx__ImportDottedModule_Lookup(name);

Callers 1

__Pyx_ImportDottedModuleFunction · 0.70

Calls 4

CYTHON_UNUSED_VARFunction · 0.70
__Pyx_ImportFunction · 0.70

Tested by

no test coverage detected