我正在使用此功能:
def read_example(water_bound, filename, conditions):
f = open(filename,"r")
for i in range(0, conditions):
lines = f.readline()
test = map(int, lines.split(' '))
water_bound.append( test[0]-1 )
Run Code Online (Sandbox Code Playgroud)
我希望能够将它与numba. 据我了解,从这里,我必须将函数声明之前加入这一行:
@jit('void(int32[:], c_string_type, int32 )',nopython=True)
Run Code Online (Sandbox Code Playgroud)
但是,我收到此错误:
NameError: name 'c_string_type' 未定义