Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 09:12
    anntzer commented #21767
  • 09:09
    jklymak converted_to_draft #21771
  • 09:08
    jklymak milestoned #21771
  • 09:08
    jklymak opened #21771
  • 09:02

    QuLogic on v3.5.0-doc

    Merge pull request #21631 from … Merge pull request #21769 from … (compare)

  • 09:02
    QuLogic closed #21769
  • 08:58
    jklymak commented #14930
  • 08:45

    QuLogic on v3.5.x

    Merge pull request #21631 from … Merge pull request #21770 from … (compare)

  • 08:45
    QuLogic closed #21770
  • 08:37
    QuLogic milestoned #21769
  • 08:37
    QuLogic milestoned #21770
  • 08:37
    QuLogic edited #21770
  • 07:55
    jklymak synchronize #21769
  • 07:53
    jklymak opened #21770
  • 07:51
    jklymak opened #21769
  • 04:54
    greglucas opened #21768
  • 04:54
    greglucas labeled #21768
  • 04:45
    greglucas synchronize #21755
  • 04:02
    joelfrederico commented #14930
  • 02:49
    tacaswell synchronize #20220
Thomas A Caswell
@tacaswell
sigh, timezone are terrible
hannah
@story645
the google calender still has it at 3:00
Thomas A Caswell
@tacaswell
It did not move from my point of view which means it did move in terms of UTC and for anyone who does not observer daylight savings
hannah
@story645
should the first agenda item be pinning down the time?
Greg Lucas
@greglucas
Ahh, OK, so 20:00 UTC. The agenda says 19:00
Thomas A Caswell
@tacaswell
the problem with daylight savings is it only happen 2x per year which is long enough to forget all the things you did wrong 6mo ago that caused trouble
Antony Lee
@anntzer
we should definitely switch to daylight saving every other week :p
Jody Klymak
@jklymak
Sorry, I should have changed the agenda
20:00 UTC is my understanding
Antony Lee
@anntzer
I'll be a bit late
Thomas A Caswell
@tacaswell
There is some fun interaction between our stack walking logic and py311
Jody Klymak
@jklymak
There are 60 PRs in the review queue - if anyone has a few minutes to push a few of them along, that would be great.
Pi
@p-i-

I'm hitting what appears to be a bug with x mouse coords on a realtime animation

import datetime as dt
import matplotlib.pyplot as plt
import matplotlib.animation as animation


fig, axes = plt.subplots(nrows=2, ncols=1)

ax_price, ax_vols = axes

xs, ys = [], []

import math

from time import time
t0 = time()

# This function is called periodically from FuncAnimation
def animate(i, xs, ys):

    y = math.sin(i/10)

    xs.append(time() - t0)
    ys.append(y)

    ax_price.clear()
    ax_price.plot(xs, ys)

def on_click(event):
    # print(time(), event)
    ax = event.inaxes
    x, y, button = event.xdata, event.ydata, event.button
    print(x)

plt.connect('button_press_event', on_click)


# Set up plot to call animate() function periodically
ani = animation.FuncAnimation(fig, animate, fargs=(xs, ys), interval=50)

plt.show()

Now if I click to the right of the axis containing the animating-sine-wave, I would expect the x value to give me roughly the time elapsed since the start of execution.

However some values are failing to output correctly:

2.2027204626029535
0.8588709677419354
0.8588709677419354
4.586874788326601
5.252901354335969
5.775638770384171
6.237269535949154
0.8588709677419354
7.125060982377299
7.654645980077404
0.8588709677419354
8.655085787177086
0.8588709677419354
0.8588709677419354
10.025456918631832

It looks as though sometimes I'm getting the x in the range [0,1] (it reports ~0.85, and I clicked close to the right of the subplot)
Other times it works.

I'm guessing the redraw is interfering with the calculation of the x-value.

Is there a way I can code this to avoid the UB?
Or do I need another interactive realtime plotting approach?
  • rephrase: if I click repeately in the subplot (at the same location), some CLICK events are reporting incorrect xdata/ydata values
Antony Lee
@anntzer
Jody Klymak
@jklymak
@Pi, yes, don't clear the plot - set the x and y data as in the full example at https://matplotlib.org/stable/api/animation_api.html If you click while the axes is cleared you will get something that is wrong. I'm not actually sure how good clicking while animating is going to work, but...
Tim Hoffmann
@timhoffm
grafik.png
grafik.png
grafik.png
grafik.png
I can do more art :) - Created while trying to understand how annotate(..., arrowpros) works.
story645
@story645:matrix.org
[m]
Can I give you the Instagram password to post a gallery? (Would also make a cool blog post on debugging)
Tim Hoffmann
@timhoffm
@story645:matrix.org Sure, we can do that some time but not right now. That took longer than thought and I have to do something else. Please remember me in case i forget. :)
story645
@story645:matrix.org
[m]
Yay!
Tim Hoffmann
@timhoffm
My realization of the day: We can use the .. plot:: directive in examples / tutorials if we want to include instuctive plots, where the code is not important, e.g. references. The downside is that it doesn't generate 2x images and you cannot use it for the thumbnail. - Seems I still have to wait that somebody implements foldable code boxes for sphinx-gallery.
story645
@story645:matrix.org
[m]
Did you put in a feature request/anyone wanna mentor for that for GSOC?
Elliott Sales de Andrade
@QuLogic
I think I started looking into 2x plots, but I'm not sure that I wrote anything
hannah
@story645
Apparently there's a way to do tweets via PR w/ a whole approval process & would folks be in favor of doing that over the current process of getting access via tweetdeck? https://twitter.com/bitandbang/status/1461839737929482252?t=js_sknzPePeyHrYs4CIRGw&s=19
Pro is more transparency & folks get more say in what goes out, cons are increased overhead & slow down, might be good as a middle ground way for folks to submit one off things/create a st
social media queue
Jody Klymak
@jklymak
I think @matplotlib on twitter is great right now. It seems running it through the filter of review would make it much more staid.
story645
@story645:matrix.org
[m]
Thanks! Admittedly, I'd probably find it annoying & it would add so much overhead...but it would be a way to pull the social more inline w/ the code process
Though I think a queue could be useful & down the line when I have more time (or there are more people doing social) the issues/projects of that repo could be a place to do planning & a way to onboard new folk
But, as @JosephTLucas mentioned (https://gitter.im/matplotlib/community?at=619f2995c6149e53494b2a2f), it wouldn't help for most of the engagement type tasks - replies/RTs/likes
Jody Klymak
@jklymak
Having somewhere to send things to the chief twitterer doesnt' seem a bad idea, but I'd only move to an internal-moderation process if we feel there are problematic tweets going out. I definitely think that it is currently being operated with the best interests of the project at heart, and I wouldn't vote to change things. If you were to step away, and there was someone less connected to the project running things, it may require revisiting.
Jody Klymak
@jklymak
Hi all, Please add items, big or small, to the weekly call agenda, today at 2000 UTC, (2100 CEST, 1500 EST, 1200 PST, 1000 HST)
(0130 26 Nov IST)
Jody Klymak
@jklymak
Ooops, I just realized that it is Thanksgiving in the US. That probably means that over half the usual attendees on the call will be unable to join us. I suggest we adjourn until next week.
Thomas Robitaille
@astrofrog
Hi all, I'm trying to track down a memory leak introduced by matplotlib/matplotlib#19255 in the glue code when used with PyQt5 - @tacaswell @anntzer, before I dig too deep, are there any expected changes with the PyQt5 support in that PR?
Thomas Robitaille
@astrofrog
It looks like this happens specifically when I resize a QMainWindow containing a Matplotlib figure - doing this results in some residual references to the QMainWindow once I try and close it
Antony Lee
@anntzer
hard to say; does gc.collect() help?
Till Stensitzki
@Tillsten
Hey, if I call fig.align_ylabel() and the figure is using constrained layout I get an exception.
Ok it is a little bit more complicated, empty axes works
So it is the added colorbar inducting the problem
fig, ax = plt.subplot_mosaic('AABB', figsize=(5, 2), constrained_layout=True)
pm = ax["A"].pcolormesh(np.random.randn(100, 100))
plt.colorbar(pm, ax=ax['A'], shrink=0.69, pad=0)
fig.align_ylabels()
Jody Klymak
@jklymak
Agreed and relatively easy to squash. In the meantime, you can pass ax=ax to the align call to explicitly say which axes you want aligned
axs=ax
Interestingly, somehow the align_xlabels snuch in with no tests!
Jody Klymak
@jklymak
Oh they did have a test, under align_labels. Anyhow PR at #21762