Do you have any suggestions of good books around python and numpy/scipy?

#python #numpy #scipy

@rzeta0 my friend, what do you think about the code using np.roll() (in the linked sketch)?

I'm afraid it would be a bit hard to explain on a short class. So I'll use the simpler inefficient function...

The next big step in efficiency would be using #scipy I think:

def count_live_neighbors(status):
"""Counts the number of neighboring live cells"""
kernel = np.array([
[1, 1, 1],
[1, 0, 1],
[1, 1, 1]
])
return scipy.signal.convolve2d(status, kernel, mode='same', boundary="wrap")
chatterjeexi โ€” SciPy v1.17.0 Manual

I love this logo for the upcoming #SciPy (#Scientific #Python) conference coming up this summer in #Minneapolis #Minnesota

Hi all,

Hope you're fine and safe

An important #announcement about #tyssue , a Python modeling library :

https://github.com/DamCB/tyssue/blob/main/README.md

Please ๐Ÿ” this message to reach the few and far apart people that might be impacted :pray:

#openScience #scipy

tyssue/README.md at main ยท DamCB/tyssue

An epithelium simulation library. Contribute to DamCB/tyssue development by creating an account on GitHub.

GitHub

100% mission complication

https://codeberg.org/guix/guix/issues/2977

@guix Python team has been merged to next-master - NumPy is default on v2.3.1

#Guix #guixpythonteam
#Python
#NumPy #Pandas #SciPy
#OpenScience

NumPy dependent packages check list

Check if they are compatible with NumPy 2.3.1 - [X] python-numpy@2 or python-numpy@1 [719/719][100%] - [X] [email protected]: PASSED - [X] apache-arrow-for-ceph: https://codeberg.org/guix/guix/issues/4758 - [X] [email protected]: PASSED - [X] [email protected]: PASSED - [X] [email protected]....

Codeberg.org

Python Package Guru by Fabrizio Damicelli

https://pypkg.guru

search over #PyPI #python #packages
faster than on pypi.org and interactively

discover packages based on their capabilities (eg, try out "fast dataframe")

#neurodon #neuroscience #compsci #scipy

Python Package Guru

Call for the hand of help to validate NumPy stack based on v2.3.1

guix time-machine --branch=python-team -- build -P1 python-numpy

https://codeberg.org/guix/guix/issues/2977

Please boost

#Guix
#NumPy #SciPy #Pandas #Dask
#OpenScience

NumPy dependent packages check list

Check if they are compatible with NumPy 2.3.1 - [X] python-numpy@2 or python-numpy@1 [719/719][100%] - [X] [email protected]: PASSED - [X] apache-arrow-for-ceph: https://codeberg.org/guix/guix/issues/4758 - [X] [email protected]: PASSED - [X] [email protected]: PASSED - [X] [email protected]....

Codeberg.org

Today I "cheated" and used scipy's MILP solver for Part 2. Discretion is the better part of valor, as they say, and writing a constraint solver by hand is not what I had planned for this Wednesday morning. The existence of `uv` to deal with all the dependencies makes reaching for scipy for even little scripts like this an easy choice.

Part 1 was trivial. Treat the lights and the buttons as bitmasks and recognize that buttons XOR themselves so they're pressed at most 1 time each. Generate the smallest combination of buttons that XOR to the target.

Part 2 is probably solvable via something like DFS before the heat death of the universe, but it would take way too long. Instead, I used scipy's integer linear programming solver, defined the constraints, objective, and bounds, and let it do its thing.

https://github.com/biesnecker/aoc-anyhow/blob/main/202510.py

#adventofcode #adventofcode2025 #python #scipy