Snowflakes with the SKAIn 1980, Carl Sagan famously stated The total amount of energy from outside the solar system ever received by all the radio telescopes on the planet Earth is less than the energy of a single snowflake striking the ground This remarkable statement w...Jul 1, 2024 · 2 min readastro.hashnode.dev
Debugging a segfault in a python ctypes projectWhen a pure Python program crashes, a verbose traceback is printed. The traceback makes it easy to find where in your code things went wrong. However, if your Python program is wrapping some C code, you need to run through a few hoops to see what wen...Feb 27, 2023 · 1 min readastro.hashnode.dev
Boost multiarray: a short cheat sheetSuppose you're writing some C++ code and you want a function to return a 2D array. How do you do it? The answer is: don't do it. Instead, use boost's multiarray class (although xtensor looks interesting). To make a 2D array in C++, with shape (NxM),...Nov 28, 2022 · 2 min readastro.hashnode.dev