- Expose artist zorder.
- Toggle legend (via checkbox rather than click). Add recipe for legend that allows toggling artist visibility.
- Change normalization class.
- Change normalization bounds.
- Change image smoothing.
from functools import partial | |
import matplotlib as mpl | |
from matplotlib import pyplot as plt | |
def patched_update_bbox_position_size(text, renderer): | |
# Absolutely zero guarantees that the internally returned value will not | |
# change in future versions! | |
orig_get_layout = text._get_layout |
// The ``P11X_DECLARE_ENUM`` macro and the ``p11x::bind_enums`` function | |
// bind enums to Python's ``enum.Enum`` or one of its subclasses | |
// (``enum.IntEnum``, ``enum.Flag``, ``enum.IntFlag``) -- unlike | |
// ``pybind11::enum_`` which uses an unrelated implementation. | |
// | |
// Use as follows: | |
// | |
// .. code-block:: c++ | |
// | |
// // Define module_name.NameOfPythonEnum as an enum.Enum subclass, with |
Patch to have "light" icons when using a dark theme in GTK3. | |
Unfortunately the foreground color is reported as full white, which gives too bright icons? |
""" | |
=============== | |
Qt Fourier Demo | |
=============== | |
""" | |
import contextlib | |
import sys | |
from matplotlib.backends.backend_qt5agg import FigureCanvas |
%!CairoScript | |
<< /content //COLOR_ALPHA /width 460 /height 345 /fallback-resolution [100 100] >> surface context | |
1 g set-source | |
paint | |
//ALPHA [] record | |
dup /s6 exch def dup context | |
[12 0 0 12 0 0] set-font-matrix | |
<< /type 42 /index 0 /flags 32 /source <|!"4WsGb"-6$%*FUqEJ4bI8%tT3BHCJOCTJq"GhSa(_@96*-)uB+sIY[E.rfs+sJ/8Lr^c06psG/72?FH&J5Qd&J7m&78RM,=Vb/!!>-Ip!bVF-4k7Yr/d-=kkPK^OlLTDhRHj(;l?]%JlD^6?*^U/V3e0oXZu;SiF]=8&lNs7j+LP7*oQKV7-dHN9hhMi]Ap<Id^$!9.8S8?l/ePB3^-g4.g:m5t=s$'HeKQ:8@+SU<4"^t!T1$a]33K^XhQq4N]<3#m%3_3E6$^-JNm&ED55j?Yn9m2<0dd0caUaMBE@hIl@LCU^P!+-4aSVEc),A8>n=@3I,jYHW`!1eZCBEC!6ZO6j*]dlr[ICjEd2qR7FE#eRm@Gnj'Dq0<iHXsfOPp+2_Ro;c(OWDJFCbC'&$Fga1OLi&,V+5[i4N=84)-idJ"nY?2da]F2))*2S8C'<rH)s;5&Fi]f[7*MWqR)qjrl]KPaaONE5K]!IjL+:i9O+kkY_*;LMUI5'#uP_O<;f-c5SnB7b`uW3-fQ[kTdrkPO,endGK6Ifn>uUb@5q="21)=ppDer(Qm?"6J:\k"5pVmD8:YB4pM!"[KH;#fk8+hAp](.S/hY0hs<G_MqDb%M]%c#cEK+?T4MYd5KCW/P)'6XOJjE,Y=K#iWh]]7PAJ$MOr\e&j8e$c\U\nI0nd](>a%^!/]C/Wi`=if.39cBGcq`*P#=Z("hpiH#CO/s%t&tl!.7>:$[b+6*q2`n-f@':SUp7(F9B7hdM'dF<:YRS?[2e& |
#!/bin/bash | |
# Written by Antony Lee (@anntzer). | |
set -e | |
PYTHON_VERSION=36 | |
PIP="/opt/python/cp$PYTHON_VERSION-cp${PYTHON_VERSION}m/bin/pip" | |
if ! [[ -e "$PIP" ]]; then | |
# Not in the manylinux image yet: call self from within docker. | |
docker run -it \ |
import time | |
from matplotlib import pyplot as plt | |
import numpy as np | |
ns = [10, 30, 100, 300, 1000, 3000, 10000] | |
all_times = [] | |
for n in ns: |
# Copyright 2016 Antony Lee. All rights reserved. | |
# Redistribution and use in source and binary forms, with or without modification, | |
# are permitted provided that the following conditions are met: | |
# 1. Redistributions of source code must retain the above copyright notice, | |
# this list of conditions and the following disclaimer. | |
# 2. Redistributions in binary form must reproduce the above copyright notice, | |
# this list of conditions and the following disclaimer in the documentation |
#vim: fileencoding=utf-8 | |
import time | |
import timeit | |
import numpy as np | |
from scipy import weave | |
dtype = np.int8 | |