MCPcopy Create free account
hub / github.com/apache/arrow / ImportModule

Function ImportModule

python/pyarrow/src/arrow/python/helpers.cc:145–150  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

143}
144
145Status ImportModule(const std::string& module_name, OwnedRef* ref) {
146 PyObject* module = PyImport_ImportModule(module_name.c_str());
147 RETURN_IF_PYERROR();
148 ref->reset(module);
149 return Status::OK();
150}
151
152Status ImportFromModule(PyObject* module, const std::string& name, OwnedRef* ref) {
153 PyObject* attr = PyObject_GetAttrString(module, name.c_str());

Calls 2

OKFunction · 0.50
resetMethod · 0.45