I would recommend opening a GitHub issue. I would highly recommend putting
an example there and if you can catch a gif/video of the output that would
be gear too (but not necessary).


On Mon, Oct 3, 2022 at 01:55 AB <[email protected]> wrote:

> Thanks for the feedback - adding the connect parameter does appear to make
> it behave properly.
>
> Playing with it again on my full application (without the additional
> parameter), it looks like it happens more frequently when the (Y) axis is
> manually scaled.
>
> Should I open this as a Github issue?
>
> On Saturday, 1 October 2022 at 06:36:07 UTC+1 Patrick wrote:
>
>> Can reproduce with latest version of pyqtgraph. Some bug with detection
>> of nan/infs, but only on subsequent updates (note the first draw renders
>> correctly). Adding an explicit connect="finite" to the setData calls works
>> as expected.
>>
>> On Saturday, 1 October 2022 at 12:57:30 am UTC+9:30 AB wrote:
>>
>>> OK, I've hacked down the application to a small-ish file (attached).
>>> There are two graphs, side-by-side.  They both have some data with an
>>> invalid section and it is consistently being drawn across until I change
>>> the zoom level - it then reappears on the next graph update.
>>>
>>> On Friday, 30 September 2022 at 16:11:44 UTC+1 AB wrote:
>>>
>>>> np.nan also misbehaves.
>>>>
>>>> On Friday, 30 September 2022 at 16:09:38 UTC+1 AB wrote:
>>>>
>>>>> Since posting earlier, I've tried float("nan"), float("inf") and
>>>>> np.inf and they all behave exactly the same.  I'll see if I can cut my
>>>>> application's code down to something I can share.
>>>>>
>>>>> I did manage to "stop" the graph while the glitch was displayed (and
>>>>> by "stop" I mean that the application was running but I stopped making
>>>>> further calls to setData).  Before zooming the graph I used the
>>>>> context-menu to export data to CSV and I could clearly see that there was 
>>>>> a
>>>>> period exported as "inf" where the line was being displayed.
>>>>>
>>>>> On Friday, 30 September 2022 at 16:02:50 UTC+1 [email protected]
>>>>> wrote:
>>>>>
>>>>>> Hmm, that certainly should not be happening, not sure quite why
>>>>>> things would be going like that.  If you can, I would try slowing down 
>>>>>> the
>>>>>> update rate of the plot, to easily catch one of those instances and post
>>>>>> some code here if you can for us to try and replicate.
>>>>>>
>>>>>> Another suggestion would be to set the invalid points to numpy.nan
>>>>>> instead of float("inf") and see if that gets better behavior; I think 
>>>>>> that
>>>>>> was the value we were originally looking for.
>>>>>>
>>>>>> On Fri, Sep 30, 2022 at 7:27 AM AB <[email protected]> wrote:
>>>>>>
>>>>>>> I am trying to display some data in a line graph - there are 1024
>>>>>>> points, updating ~40 times/second.  Some of the points are invalid (set 
>>>>>>> to
>>>>>>> float("inf") ) and are supposed to cause a break in the line if I
>>>>>>> understand the default behaviour of the "connect" parameter correctly.
>>>>>>> However, I am periodically seeing that there is a straight line joining 
>>>>>>> the
>>>>>>> valid points either side of the invalid period.
>>>>>>>
>>>>>>> I can stop updating the graph and catch this happening - as soon as
>>>>>>> I use the mouse zoom functionality to change the scale of the graph in 
>>>>>>> this
>>>>>>> state the erroneous line vanishes, and the graph is drawn with breaks in
>>>>>>> the line as I expect that it should.
>>>>>>>
>>>>>>> Can anyone suggest why the erroneous lines are appearing, and how I
>>>>>>> can ensure they don't appear?
>>>>>>>
>>>>>>> --
>>>>>>> You received this message because you are subscribed to the Google
>>>>>>> Groups "pyqtgraph" group.
>>>>>>> To unsubscribe from this group and stop receiving emails from it,
>>>>>>> send an email to [email protected].
>>>>>>> To view this discussion on the web visit
>>>>>>> https://groups.google.com/d/msgid/pyqtgraph/559c2c62-8372-471f-b36c-77e314368006n%40googlegroups.com
>>>>>>> <https://groups.google.com/d/msgid/pyqtgraph/559c2c62-8372-471f-b36c-77e314368006n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>>>>> .
>>>>>>>
>>>>>> --
> You received this message because you are subscribed to the Google Groups
> "pyqtgraph" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pyqtgraph/0013f7d6-5daa-4157-80e8-0c1f5b861669n%40googlegroups.com
> <https://groups.google.com/d/msgid/pyqtgraph/0013f7d6-5daa-4157-80e8-0c1f5b861669n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"pyqtgraph" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyqtgraph/CA%2BnduTEubz5wjXQqFOv4caU7CK1W%2B8dg6KNA%2BhcFYUOMDR26Yw%40mail.gmail.com.

Reply via email to