Skip to content

Instantly share code, notes, and snippets.

@ksopyla
ksopyla / install_cuda_12_ubuntu_22.04.md
Last active October 14, 2025 11:30
How to install CUDA toolkit 12 on ubuntu 22.04, step by step guide

Step by step instruction how to install CUDA 12 Ubuntu 22.04

Clean all previous nvidia packages [optional step]

sudo apt purge nvidia*
sudo apt remove nvidia-*
sudo rm /etc/apt/sources.list.d/cuda*

How to Install Nvidia Drivers on Proxmox

  1. Your /etc/apt/sources.list should look like something like this:
deb http://ftp.us.debian.org/debian [bullseye, bookworm, etc] main contrib non-free

deb http://ftp.us.debian.org/debian [bullseye, bookworm, etc]-updates main contrib non-free

# security updates
deb http://security.debian.org [bullseye, bookworm, etc]-security main contrib
@tuket
tuket / latlong_tile.py
Last active March 9, 2024 18:17
Google Maps: Get tile image from latlong coordinate
import math
def latlongToTile(latlongDegs, zoom):
n = 2 ** zoom
latRads = math.radians(latlongDegs[0])
tileX = n * ((latlongDegs[1] + 180.0) / 360.0)
tileY = n * (1.0 - (math.log(math.tan(latRads) + 1.0/math.cos(latRads)) / math.pi)) / 2.0
return (int(tileX), int(tileY))
def latlongToUrl(latlongDegs, zoom):
@egg82
egg82 / proxmox_nvidia.md
Last active September 13, 2025 07:23
NVidia Proxmox + LXC

Proxmox

Find the proper driver at the NVidia website.

Note: Make sure to select "Linux 64-bit" as your OS

Hit the "Search" button.