MCPcopy Create free account
hub / github.com/numpy/numpy / get_data_files

Function get_data_files

numpy/distutils/misc_util.py:723–740  ·  view source on GitHub ↗
(data)

Source from the content-addressed store, hash-verified

721 return so_ext
722
723def get_data_files(data):
724 if is_string(data):
725 return [data]
726 sources = data[1]
727 filenames = []
728 for s in sources:
729 if hasattr(s, '__call__'):
730 continue
731 if is_local_src_dir(s):
732 filenames.extend(list(general_source_files(s)))
733 elif is_string(s):
734 if os.path.isfile(s):
735 filenames.append(s)
736 else:
737 print('Not existing data file:', s)
738 else:
739 raise TypeError(repr(s))
740 return filenames
741
742def dot_join(*args):
743 return '.'.join([a for a in args if a])

Callers 2

add_defaultsMethod · 0.90

Calls 4

is_stringFunction · 0.85
is_local_src_dirFunction · 0.85
general_source_filesFunction · 0.85
printFunction · 0.85

Tested by

no test coverage detected