#!/usr/bin/env python3 from whisper import load_model # pip install openai-whisper model =...
For folks that are on Windows and Visual Studio (not Code), solution files (.sln) are still pretty...
from logging import basicConfig, ERROR from google.genai import Client from google.genai.types...
from json import loads from signal import signal, SIGINT from requests import get # pip install...
from asyncio import run, sleep class AlternatingGenerator: def __init__(self, gen1, gen2): ...
Parsing on my own: #include <stdbool.h> #include <stdio.h> #include...
Here's my routine to debug quick stuff on the cli: $ gcc myprogram.c -g -o myprogram $ gdb -tui...
Using wchar_t didn't quite worked out in my tests, so handling it on my own: #include...
Exchanges & Queues Messages are published to exchanges. Publishers only need to...
#!/usr/bin/env python3 from asyncio import gather, new_event_loop, sleep, Event,...
Here's a little script I made to preview some of my (huge) NumPy's .npy files: #! /usr/bin/env...
I'm used to Redis, and there is a wonderful command called MONITOR that shows the commands being...
from signal import signal, SIGINT signal(SIGINT, lambda _, __: exit()) print('No message or stack...
$ sudo apt install csvkit $ csvsql --query "SELECT * FROM myfile ORDER BY RANDOM() LIMIT 3"...
No printable PDF at the moment, sorry :( psql $ psql -U username -d dbname -h hostname...
Make sure you have sqlite3 available: $ sudo apt install sqlite3 Enter fullscreen mode ...
Sure, it's quicker and easier to run as a container, I know. But some people sometimes just want to...
Transferring files? More often than not, rsync is the answer: rsync --archive --verbose --partial...
Thankfully, it's been awhile since I last had to use Windows on my day to day. If I ever have to...
My Asus motherboard uses F2 for setup key and F8 for boot selection device key. My MSI one uses DEL...
I was getting a lot of noise right at the start of my silly Keras+TensorFlow tests: 2024-09-15...
First, set up an virtual environment with needed packages: $ python3 -m venv venv $ venv/bin/pip...
nohup ./my-script.sh >> my-output.txt 2>&1 & Enter fullscreen mode ...
Let's create a sample CUDA code first: #include <stdio.h> #include...
If you got this when callling ncu-ui: Cannot mix incompatible Qt library (5.15.3) with this...
Setting clipboard: $ echo foo | xclip -selection c Enter fullscreen mode Exit...
$ du -h /var/log/syslog 110G /var/log/syslog $ sudo truncate -s 0 /var/log/syslog $ du -h...
import matplotlib.pyplot as plt def plot_training(history): plt.figure(figsize=(8, 5)) # 8x5...
This: my_model.summary() Enter fullscreen mode Exit fullscreen mode ...
gpus = tf.config.experimental.list_physical_devices('GPU') for gpu in gpus: ...