discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] ValueError: operands could not be broadcast toget


From: Tom Rondeau
Subject: Re: [Discuss-gnuradio] ValueError: operands could not be broadcast together with shapes (4095) (4081)
Date: Thu, 6 Feb 2014 10:18:39 +0000

On Wed, Feb 5, 2014 at 5:59 PM, Mauricio Olivera
<address@hidden> wrote:
> Hi everybody,
>
> I am also facing this problem. I am running a GMSK modulation and sometimes
> I get the error:
>
> Exception in thread Thread-915:
> Traceback (most recent call last):
>   File "/usr/lib/python2.7/threading.py", line 808, in __bootstrap_inner
>     self.run()
>   File "/usr/lib/python2.7/site-packages/grc_gnuradio/blks2/packet.py", line
> 144, in run
>     ok, payload = packet_utils.unmake_packet(msg.to_string(),
> int(msg.arg1()))
>   File "/usr/lib/python2.7/site-packages/gnuradio/digital/packet_utils.py",
> line 187, in unmake_packet
>     payload_with_crc = dewhiten(whitened_payload_with_crc, whitener_offset)
>   File "/usr/lib/python2.7/site-packages/gnuradio/digital/packet_utils.py",
> line 95, in dewhiten
>     return whiten(s, o)        # self inverse
>   File "/usr/lib/python2.7/site-packages/gnuradio/digital/packet_utils.py",
> line 91, in whiten
>     z = sa ^ random_mask_vec8[o:len(sa)+o]
> ValueError: operands could not be broadcast together with shapes (4095)
> (4081)
>
> I really dont know what could be happening. What I have realize is that
> everytime this happens, even though the code keeps running, the flow does
> not keep working as is suposed to.
>
> Any idea???
> Thanks


My guess would be that there is some data corruption that's causing
the size of the packet to become skewed. The code isn't properly
checking for that condition, which should be considered a packet error
and dropped, and instead trying to process it like it was correct. You
can try a "try/catch" block around this call to the whitener to catch
that exception and ignore it.

Though really, there should be more robust error handling in these
things, anyways.

Tom



reply via email to

[Prev in Thread] Current Thread [Next in Thread]