Skip to content

Instantly share code, notes, and snippets.

Avatar
:octocat:

Matthias Bussonnier Carreau

:octocat:
View GitHub Profile
View .zshrc
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
#
PATH=$HOME/bin:$PATH
#
if [ $(arch) = 'arm64' ]; then
export ARCH_MARKER=""
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
View patch_completer.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View gist:283d6d3275b371bfaff58146f72cdae9
---------------------------------------------------------------------------
IndexError Traceback (most recent call last)
File ~/miniconda3-intel/envs/napari/lib/python3.9/site-packages/vispy/app/backends/_qt.py:512, in QtBaseCanvasBackend.mouseReleaseEvent(self=<vispy.app.backends._qt.CanvasBackendDesktop object>, ev=<PyQt5.QtGui.QMouseEvent object>)
510 if self._vispy_canvas is None:
511 return
--> 512 self._vispy_mouse_release(
self = <vispy.app.backends._qt.CanvasBackendDesktop object at 0x7fb2419960d0>
ev = <PyQt5.QtGui.QMouseEvent object at 0x7fb254e5f790>
BUTTONMAP = {0: 0, 1: 1, 2: 2, 4: 3, 8: 4, 16: 5}
View affine_transforms.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Carreau
Carreau / LICENSE
Last active Oct 12, 2021
transform python AST
View LICENSE
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
@Carreau
Carreau / cartomap.py
Created May 27, 2021
PyShS demo Script
View cartomap.py
import sys
import geocoder
import matplotlib
matplotlib.use('agg')
import matplotlib.pyplot as plt
import argparse
import wikipedia
import wptools
import flask
import io
View poly_crash
---------------------------------------------------------------------------
IndexError Traceback (most recent call last)
~/miniconda3/envs/napari/lib/python3.9/site-packages/vispy/app/backends/_qt.py in keyPressEvent(self=<vispy.app.backends._qt.CanvasBackendDesktop object>, ev=<PyQt5.QtGui.QKeyEvent object>)
500
501 def keyPressEvent(self, ev):
--> 502 self._keyEvent(self._vispy_canvas.events.key_press, ev)
self._keyEvent = <bound method QtBaseCanvasBackend._keyEvent of <vispy.app.backends._qt.CanvasBackendDesktop object at 0x7f98f79270d0>>
self._vispy_canvas.events.key_press = <vispy.util.event.EventEmitter object at 0x7f98f7919d90>
ev = <PyQt5.QtGui.QKeyEvent object at 0x7f98e048ea60>
503
View gist:c96e7b5e20a55c975f4747f809cde424
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:605 in 'compute_new_doc' | distributed/cfexecutor.py:map
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:607 in 'compute_new_doc' | missing: {'**kwargs'}
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:609 in 'compute_new_doc' | extra: {'timeout', 'chunksize'}
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:605 in 'compute_new_doc' | distributed/client.py:gather
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:607 in 'compute_new_doc' | missing: {'asynchronous'}
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:605 in 'compute_new_doc' | distributed/client.py:scatter
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:607 in 'compute_new_doc' | missing: {'timeout', 'asynchronous'}
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:605 in 'compute_new_doc' | distributed/client.py:cancel
63027 ~/miniconda3/lib/python3.8/site-packages/velin/ref.py:607 in 'compute_new_doc'
View chap9-usages-avances-Copy1.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View gist:9bea1682d339cec801b08d7d3fc3af0e
~/dev/papyri[master ✗] $ python jd.py
Traceback (most recent call last):
File "jd.py", line 10, in <module>
i.infer(4, 0)
File "/Users/bussonniermatthias/dev/jedi/jedi/api/helpers.py", line 488, in wrapper
return func(self, line, column, *args, **kwargs)
File "/Users/bussonniermatthias/dev/jedi/jedi/api/__init__.py", line 244, in infer
values = helpers.infer(self._inference_state, context, leaf)
File "/Users/bussonniermatthias/dev/jedi/jedi/api/helpers.py", line 167, in infer
return inference_state.infer(context, leaf)