Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR in mssa.fit(df_tr) #5

Open
ashi24lion opened this issue Mar 28, 2019 · 7 comments
Open

ERROR in mssa.fit(df_tr) #5

ashi24lion opened this issue Mar 28, 2019 · 7 comments

Comments

@ashi24lion
Copy link

Constructing trajectory matrix
Trajectory matrix shape: (1600, 801)
Decomposing trajectory covariance matrix with SVD
Constructing components

ValueError Traceback (most recent call last)
~\Anaconda3\lib\site-packages\numba\errors.py in new_error_context(fmt_, *args, **kwargs)
490 try:
--> 491 yield
492 except NumbaError as e:

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_block(self, block)
215 loc=self.loc, errcls_=defaulterrcls):
--> 216 self.lower_inst(inst)
217

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_inst(self, inst)
264 ty = self.typeof(inst.target.name)
--> 265 val = self.lower_assign(ty, inst)
266 self.storevar(val, inst.target.name)

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_assign(self, ty, inst)
410 elif isinstance(value, ir.Expr):
--> 411 return self.lower_expr(ty, value)
412

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_expr(self, resty, expr)
742 elif expr.op == 'call':
--> 743 res = self.lower_call(resty, expr)
744 return res

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_call(self, resty, expr)
708
--> 709 res = impl(self.builder, argvals)
710

~\Anaconda3\lib\site-packages\numba\targets\base.py in call(self, builder, args)
1042 def call(self, builder, args):
-> 1043 return self._imp(self._context, builder, self._sig, args)
1044

~\Anaconda3\lib\site-packages\numba\targets\arrayobj.py in numpy_zeros_nd(context, builder, sig, args)
3260 arrtype, shapes = _parse_empty_args(context, builder, sig, args)
-> 3261 ary = _empty_nd_impl(context, builder, arrtype, shapes)
3262 _zero_fill_array(context, builder, ary)

~\Anaconda3\lib\site-packages\numba\targets\arrayobj.py in _empty_nd_impl(context, builder, arrtype, shapes)
3147 for s in shapes:
-> 3148 arrlen = builder.mul(arrlen, s)
3149

~\Anaconda3\lib\site-packages\llvmlite\ir\builder.py in wrapped(self, lhs, rhs, name, flags)
23 raise ValueError("Operands must be the same type, got (%s, %s)"
---> 24 % (lhs.type, rhs.type))
25 instr = cls(self.block, lhs.type, opname, (lhs, rhs), name, flags)

ValueError: Operands must be the same type, got (i64, i32)

During handling of the above exception, another exception occurred:

LoweringError Traceback (most recent call last)
in ()
----> 1 mssa.fit(df_tr)

~\python_stuff_my_module\pymssa\mssa.py in fit(self, timeseries)
546 self.P_,
547 self.N_,
--> 548 self.L_
549 )
550

~\Anaconda3\lib\site-packages\numba\dispatcher.py in _compile_for_args(self, *args, **kws)
358 e.patch_message(''.join(e.args) + help_msg)
359 # ignore the FULL_TRACEBACKS config, this needs reporting!
--> 360 raise e
361
362 def inspect_llvm(self, signature=None):

~\Anaconda3\lib\site-packages\numba\dispatcher.py in _compile_for_args(self, *args, **kws)
309 argtypes.append(self.typeof_pyval(a))
310 try:
--> 311 return self.compile(tuple(argtypes))
312 except errors.TypingError as e:
313 # Intercept typing error that may be due to an argument

~\Anaconda3\lib\site-packages\numba\dispatcher.py in compile(self, sig)
616
617 self._cache_misses[sig] += 1
--> 618 cres = self._compiler.compile(args, return_type)
619 self.add_overload(cres)
620 self._cache.save_overload(sig, cres)

~\Anaconda3\lib\site-packages\numba\dispatcher.py in compile(self, args, return_type)
81 args=args, return_type=return_type,
82 flags=flags, locals=self.locals,
---> 83 pipeline_class=self.pipeline_class)
84 # Check typing error if object mode is used
85 if cres.typing_error is not None and not flags.enable_pyobject:

~\Anaconda3\lib\site-packages\numba\compiler.py in compile_extra(typingctx, targetctx, func, args, return_type, flags, locals, library, pipeline_class)
869 pipeline = pipeline_class(typingctx, targetctx, library,
870 args, return_type, flags, locals)
--> 871 return pipeline.compile_extra(func)
872
873

~\Anaconda3\lib\site-packages\numba\compiler.py in compile_extra(self, func)
363 self.lifted = ()
364 self.lifted_from = None
--> 365 return self._compile_bytecode()
366
367 def compile_ir(self, func_ir, lifted=(), lifted_from=None):

~\Anaconda3\lib\site-packages\numba\compiler.py in _compile_bytecode(self)
800 """
801 assert self.func_ir is None
--> 802 return self._compile_core()
803
804 def _compile_ir(self):

~\Anaconda3\lib\site-packages\numba\compiler.py in _compile_core(self)
787 self.define_pipelines(pm)
788 pm.finalize()
--> 789 res = pm.run(self.status)
790 if res is not None:
791 # Early pipeline completion

~\Anaconda3\lib\site-packages\numba\compiler.py in run(self, status)
249 # No more fallback pipelines?
250 if is_final_pipeline:
--> 251 raise patched_exception
252 # Go to next fallback pipeline
253 else:

~\Anaconda3\lib\site-packages\numba\compiler.py in run(self, status)
241 try:
242 event(stage_name)
--> 243 stage()
244 except _EarlyPipelineCompletion as e:
245 return e.result

~\Anaconda3\lib\site-packages\numba\compiler.py in stage_nopython_backend(self)
674 """
675 lowerfn = self.backend_nopython_mode
--> 676 self._backend(lowerfn, objectmode=False)
677
678 def stage_compile_interp_mode(self):

~\Anaconda3\lib\site-packages\numba\compiler.py in _backend(self, lowerfn, objectmode)
624 self.library.enable_object_caching()
625
--> 626 lowered = lowerfn()
627 signature = typing.signature(self.return_type, *self.args)
628 self.cr = compile_result(

~\Anaconda3\lib\site-packages\numba\compiler.py in backend_nopython_mode(self)
611 self.return_type,
612 self.calltypes,
--> 613 self.flags)
614
615 def _backend(self, lowerfn, objectmode):

~\Anaconda3\lib\site-packages\numba\compiler.py in native_lowering_stage(targetctx, library, interp, typemap, restype, calltypes, flags)
988
989 lower = lowering.Lower(targetctx, library, fndesc, interp)
--> 990 lower.lower()
991 if not flags.no_cpython_wrapper:
992 lower.create_cpython_wrapper(flags.release_gil)

~\Anaconda3\lib\site-packages\numba\lowering.py in lower(self)
133 if self.generator_info is None:
134 self.genlower = None
--> 135 self.lower_normal_function(self.fndesc)
136 else:
137 self.genlower = self.GeneratorLower(self)

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_normal_function(self, fndesc)
174 # Init argument values
175 self.extract_function_arguments()
--> 176 entry_block_tail = self.lower_function_body()
177
178 # Close tail of entry block

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_function_body(self)
199 bb = self.blkmap[offset]
200 self.builder.position_at_end(bb)
--> 201 self.lower_block(block)
202
203 self.post_lower()

~\Anaconda3\lib\site-packages\numba\lowering.py in lower_block(self, block)
214 with new_error_context('lowering "{inst}" at {loc}', inst=inst,
215 loc=self.loc, errcls_=defaulterrcls):
--> 216 self.lower_inst(inst)
217
218 def create_cpython_wrapper(self, release_gil=False):

~\Anaconda3\lib\contextlib.py in exit(self, type, value, traceback)
97 value = type()
98 try:
---> 99 self.gen.throw(type, value, traceback)
100 except StopIteration as exc:
101 # Suppress StopIteration unless it's the same exception that

~\Anaconda3\lib\site-packages\numba\errors.py in new_error_context(fmt_, *args, **kwargs)
497 from numba import config
498 tb = sys.exc_info()[2] if config.FULL_TRACEBACKS else None
--> 499 six.reraise(type(newerr), newerr, tb)
500
501

~\Anaconda3\lib\site-packages\numba\six.py in reraise(tp, value, tb)
657 if value.traceback is not tb:
658 raise value.with_traceback(tb)
--> 659 raise value
660
661 else:

LoweringError: Failed at nopython (nopython mode backend)
Operands must be the same type, got (i64, i32)

File "....\python_stuff_my_module\pymssa\optimized.py", line 226:
def incremental_component_reconstruction(trajectory_matrix,

components = np.zeros((P, N, rank))
^

[1] During: lowering "$0.7 = call $0.2($0.6, func=$0.2, args=[Var($0.6, C:\Users\devendra\python_stuff_my_module\pymssa\optimized.py (226))], kws=(), vararg=None)" at C:\Users\devendra\python_stuff_my_module\pymssa\optimized.py (226)

This should not have happened, a problem has occurred in Numba's internals.

Please report the error message and traceback, along with a minimal reproducer
at: https://github.com/numba/numba/issues/new

If you need help writing a minimal reproducer please see:
http://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports

If more help is needed please feel free to speak to the Numba core developers
directly at: https://gitter.im/numba/numba

Thanks in advance for your help in improving Numba!

@henie5
Copy link

henie5 commented Apr 6, 2019

I 'm at the same position

@veager
Copy link

veager commented Jun 13, 2019

So do I. But how to deal with it?

@wieczorekmichal1
Copy link

Me too

@xialang2012
Copy link

so do I

@harveybc
Copy link

I have the same problem, using windows 10 and numba 0.45.1, any ideas on how to solve it?

@CoteDave
Copy link

CoteDave commented Sep 9, 2019

LoweringError: Operands must be the same type, got (i64, i32)

Same error here ! Is there a a way to patch this ? Seem to come from the L_ parameter (Window size)

@RogerPallares
Copy link

I showed a solution that worked for me in another issue, hope it works for all of you as well.

#9 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants