Open pendave opened 3 years ago
I am getting the same error. Did you find a solution to this?
Got solution? facing the same issue.
print("Number of parameters is %d" % sum(np.prod(p.get_value().shape) for p in self.params))
I think this should work.
Hello. please help.
WARNING (theano.tensor.blas): Using NumPy C-API based implementation for BLAS functions. Traceback (most recent call last): File "E:\MyPython\punctuator给无标点符号的文本段落添加标点分句.py", line 3, in <module> p = Punctuator('Demo-Europarl-EN.pcl') File "C:\Program Files\Python38\lib\site-packages\punctuator\punc.py", line 204, in __init__ net, _ = models.load(model_file, 1, x) File "C:\Program Files\Python38\lib\site-packages\punctuator\models.py", line 69, in load net = Model( File "C:\Program Files\Python38\lib\site-packages\punctuator\models.py", line 254, in __init__ logging.info("Number of parameters is %d", sum(np.prod(p.shape.eval()) for p in self.params)) File "C:\Program Files\Python38\lib\site-packages\punctuator\models.py", line 254, in <genexpr> logging.info("Number of parameters is %d", sum(np.prod(p.shape.eval()) for p in self.params)) File "C:\Program Files\Python38\lib\site-packages\theano\gof\graph.py", line 522, in eval self._fn_cache[inputs] = theano.function(inputs, self) File "C:\Program Files\Python38\lib\site-packages\theano\compile\function.py", line 306, in function fn = pfunc(params=inputs, File "C:\Program Files\Python38\lib\site-packages\theano\compile\pfunc.py", line 483, in pfunc return orig_function(inputs, cloned_outputs, mode, File "C:\Program Files\Python38\lib\site-packages\theano\compile\function_module.py", line 1841, in orig_function fn = m.create(defaults) File "C:\Program Files\Python38\lib\site-packages\theano\compile\function_module.py", line 1714, in create _fn, _i, _o = self.linker.make_thunk( File "C:\Program Files\Python38\lib\site-packages\theano\gof\link.py", line 697, in make_thunk return self.make_all(input_storage=input_storage, File "C:\Program Files\Python38\lib\site-packages\theano\gof\vm.py", line 1087, in make_all thunks.append(node.op.make_thunk(node, File "C:\Program Files\Python38\lib\site-packages\theano\gof\op.py", line 954, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, File "C:\Program Files\Python38\lib\site-packages\theano\gof\op.py", line 857, in make_c_thunk outputs = cl.make_thunk(input_storage=node_input_storage, File "C:\Program Files\Python38\lib\site-packages\theano\gof\cc.py", line 1215, in make_thunk cthunk, module, in_storage, out_storage, error_storage = self.__compile__( File "C:\Program Files\Python38\lib\site-packages\theano\gof\cc.py", line 1153, in __compile__ thunk, module = self.cthunk_factory(error_storage, File "C:\Program Files\Python38\lib\site-packages\theano\gof\cc.py", line 1623, in cthunk_factory module = get_module_cache().module_from_key( File "C:\Program Files\Python38\lib\site-packages\theano\gof\cmodule.py", line 1189, in module_from_key module = lnk.compile_cmodule(location) File "C:\Program Files\Python38\lib\site-packages\theano\gof\cc.py", line 1520, in compile_cmodule module = c_compiler.compile_str( File "C:\Program Files\Python38\lib\site-packages\theano\gof\cmodule.py", line 2420, in compile_str return dlimport(lib_filename) File "C:\Program Files\Python38\lib\site-packages\theano\gof\cmodule.py", line 317, in dlimport rval = __import__(module_name, {}, {}, [module_name]) ImportError: DLL load failed while importing m60a068f5e4bfe48344c4e636f49e249da0f0a2df673bf7ffb57b86690cf56e0d: 找不到指定的模块。