HackerTrans
TopNewTrendsCommentsPastAskShowJobs

smacke

465 karmajoined vor 7 Jahren
https://github.com/smacke

Submissions

Show HN: Magrittr-like pipe syntax for Python

github.com
2 points·by smacke·vor 6 Monaten·0 comments

Show HN: Magrittr-like pipe syntax for IPython

github.com
2 points·by smacke·vor 6 Monaten·1 comments

Show HN: Powerful pipeline syntax for IPython and Jupyter

github.com
2 points·by smacke·vor 6 Monaten·0 comments

Show HN: Powerful pipeline syntax for IPython and Jupyter

github.com
5 points·by smacke·vor 6 Monaten·1 comments

comments

smacke
·gestern·discuss
I started burning down the backlog of all the stuff I wanted to get to for side projects but never had time for (before LLMs):

- https://smacke.net/ffsubsync -- automagically synchronize subtitles, now purely client-side in your browser thanks to pyodide

- https://ipyflow.github.io/ipyflow/lab/index.html?path=demo.i... -- reactive python jupyter notebooks, again in the browser thanks to pyodide / jupyterlite

- https://smacke.net/pipescript/lab/index.html?path=demo.ipynb -- magritter-like pipe / placeholder syntax for ipython / jupyter, again able to run purely in the browser

- https://smacke.net/pycograd/lab/index.html?path=pycograd_sim... -- pyccolo and pipescript-powered autograd, once again able to run purely in the browser since numpy has a wasm target (notice a theme here :) )
smacke
·vor 6 Monaten·discuss
Some auto formatting italicized the text between * on different lines :')

Should be `reduce[$*$]`
smacke
·vor 6 Monaten·discuss
Hi HN, I built pipescript over the holidays after I discovered magrittr for R and realized the same kind of pipe operator and placeholder syntax could be implemented for Python notebooks with a bit of creativity. I developed it while using it in parallel for Advent of Code and had a lot of fun with it; hope you like it.
smacke
·vor 11 Monaten·discuss
Pickling + unpickling the object is a neat trick to update objects to point to the new methods, but it's even more straightforward to just patch `obj.__class__ = reloaded_module.NewClass`. This is what ipython's autoreload extension used to do (and still does in some circumstances, along with other tricks to patch up old references), though nowadays it's had some improvements over this approach: https://github.com/ipython/ipython/pull/14500
smacke
·vor 11 Monaten·discuss
I developed a tool (https://github.com/smacke/ffsubsync) which can sync subtitles against each other (or even against an audio track), and this can be used in conjunction with other tools such as https://pypi.org/project/srt/ to combine multiple subtitle streams into a single stream. I've used this strategy to good effect to get both English and Chinese subtitles up at once.