MCPcopy Create free account
hub / github.com/pydata/numexpr / configuration

Function configuration

setup.py:210–284  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

208
209
210 def configuration():
211 from numpy.distutils.misc_util import Configuration, dict_append
212 from numpy.distutils.system_info import system_info, mkl_info
213
214 config = Configuration('numexpr3')
215
216 #try to find configuration for MKL, either from environment or site.cfg
217 # if os.path.exists('site.cfg'):
218 # # Probably here we should build custom build_mkl or build_icc
219 # # commands instead?
220 # mkl_config = mkl_info()
221 #
222 # print( 'Found Intel MKL at: {}'.format( mkl_config.get_mkl_rootdir() ) )
223 # # Check if the user mis-typed a directory
224 # # mkl_include_dir = mkl_config.get_include_dirs()
225 # # mkl_lib_dir = mkl_config.get_lib_dirs()
226 # mkl_config_data = config.get_info('mkl')
227 #
228 # # some version of MKL need to be linked with libgfortran, for this, use
229 # # entries of DEFAULT section in site.cfg
230 # # default_config = system_info() # You don't work
231 # # dict_append(mkl_config_data,
232 # # libraries=default_config.get_libraries(),
233 # # library_dirs=default_config.get_lib_dirs())
234 # # RAM: mkl_info() doesn't see to populate get_libraries()...
235 # dict_append(mkl_config_data,
236 # include_dirs=mkl_config.get_include_dirs(),
237 # libraries=mkl_config.get_libraries(),
238 # library_dirs=mkl_config.get_lib_dirs() )
239 # else:
240 # mkl_config_data = {}
241
242
243 #setup information for C extension
244 pthread_win = []
245 if os.name == 'nt':
246 pthread_win = ['numexpr3/win32/pthread.c']
247
248
249 # Maybe we need a newer cpuinfo.py
250 extension_config_data = {
251 'sources': ['numexpr3/interpreter.cpp',
252 'numexpr3/module.cpp',
253 'numexpr3/numexpr_object.cpp',
254 'numexpr3/benchmark.hpp'] + pthread_win,
255 'depends': ['numexpr3/functions_GENERATED.cpp',
256 'numexpr3/interp_body_GENERATED.cpp',
257 'numexpr3/interp_header_GENERATED.hpp',
258 'numexpr3/module.hpp',
259 'numexpr3/msvc_function_stubs.hpp',
260 'numexpr3/numexpr_config.hpp',
261 'numexpr3/numexpr_object.hpp',
262 'numexpr3/complex_functions.hpp',
263 'numexpr3/real_functions.hpp',
264 'numexpr3/string_functions.hpp',
265 ],
266 'libraries': [],
267 # Compile args come in after the initial args, so I'm not sure

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…