Skip to content

Instantly share code, notes, and snippets.

View AndhikaWB's full-sized avatar
😶‍🌫️
I may be slow to respond.

AndhikaWB

😶‍🌫️
I may be slow to respond.
  • Southeast Asia
View GitHub Profile
@AndhikaWB
AndhikaWB / README.md
Created October 30, 2025 06:57
Use Docker (without Docker Desktop) from Arch Linux WSL

Why?

Docker Desktop on Windows is bloated, it requires running Docker Desktop all the time. Not to mention all the AI stuff that is being pushed to it. Running Docker on Linux (WSL) directly is more efficient as Docker Desktop uses a Linux VM too behind the scene.

Setup

Install Arch Linux WSL distro. You will enter Arch Linux automatically when it's done downloading.

wsl --install archlinux
@AndhikaWB
AndhikaWB / README.md
Last active October 29, 2025 08:15
Fedora Silverblue/Kinoite/Atomic - Nvidia GPU/CUDA Setup for ML

This guide is partially based on deekej's HackMD post [^9]. I added the ML (machine learning) and container part since the original post doesn't have this info. I tested this on Fedora Kinoite 42.

Initial preparation

Setting the repos

First of all, we need to disable the RPM Fusion Nvidia repo, since it may conflict with package names from negativo17's Nvidia repo later (e.g. akmod-nvidia) [^1].

sudo sed -ie 's/enabled=1/enabled=0/g' /etc/yum.repos.d/rpmfusion-nonfree-nvidia-driver.repo
@AndhikaWB
AndhikaWB / README.md
Last active October 2, 2025 10:46
SQLAlchemy Relationship, Cascade, and Passive Deletes Test

Objective

The purpose of this gist is to test the exact behavior of SQLAlchemy relationship when coded in a certain way. What are tested:

  • The existence of relationship() in the class
  • The value of cascade = XXX in the relationship()
  • The value of passive_deletes = XXX in the relationship()

Code

Code that will be used for experiment (using SQLAlchemy 2.0):

@AndhikaWB
AndhikaWB / README.md
Created September 12, 2025 14:23
Prefect Lazy Materialize

Intro

Click to expand

Decorator to lazily materialize an asset based on the task input/output value. The usage is very similar as the original materialize decorator, here's an example:

@lazy_materialize('{{out_dir}}', asset_deps = ['{{data_dir}}/raw'], output_as = 'out_dir')
def preprocess_data(data_dir: str, preproc_folder: str):