Skip to content

Instantly share code, notes, and snippets.

View yohanesgultom's full-sized avatar
🏠
Working from home

Yohanes Gultom yohanesgultom

🏠
Working from home
View GitHub Profile
@yohanesgultom
yohanesgultom / ! PHP Scripts
Last active May 30, 2021 10:38
Random PHP scripts
Random PHP scripts
@yohanesgultom
yohanesgultom / ! Python Machine Learning
Last active February 1, 2023 18:12
Python machine learning scripts
Python machine learning scripts
@yohanesgultom
yohanesgultom / ! CUDA & OpenCL Intro
Last active May 27, 2023 04:51
Simple CUDA and OpenCL code
Simple CUDA and OpenCL code
Compilation:
* CUDA (*.cu): nvcc filename.cu
* CUDA + CUBLAS (*.cu): nvcc filename.cu -lcublas
* OpenCL (*.c): gcc filename.c -lOpenCL
@yohanesgultom
yohanesgultom / ! Python Scripts
Last active August 11, 2023 16:30
Random python scripts
Random collection of python scripts
@yohanesgultom
yohanesgultom / ! SQL scripts
Last active October 7, 2023 02:38
SQL scripts
SQL scripts
const API_URL = 'https://example.com';
const AUTH = 'Basic XXXXXXXXXXXXXXXXXXXXXX';
function getContact(phone) {
const res = UrlFetchApp.fetch(`${API_URL}/contacts/${phone}@c.us`, {
method : 'get',
contentType: 'application/json',
headers : {
Authorization: AUTH,
},
@yohanesgultom
yohanesgultom / ! Ubuntu commands and scripts
Last active February 22, 2024 00:31
Ubuntu common scripts
Random Ubuntu commands and scripts
@yohanesgultom
yohanesgultom / cuda-ubuntu-installation.md
Last active March 10, 2024 04:31
NVIDIA CUDA installation and configuration notes

CUDA installation on Ubuntu

WARNING This installation will REPLACE existing Nvidia driver

Download CUDA https://developer.nvidia.com/cuda-downloads (tested with CUDA 10) Run commands:

sudo dpkg -i cuda-repo-<version>.deb
sudo apt-key add /var/cuda-repo-<version>/7fa2af80.pub
sudo apt-get update
@yohanesgultom
yohanesgultom / rocks.md
Last active April 30, 2024 21:26
Rocks cluster Sidewinder (6.2) installation stuff (virtualbox with Ubuntu 15 as host)

Rocks cluster Sidewinder (6.2) Virtualbox

Installation in Nutshell

  1. Download jumbo DVD iso from rocks website
  2. Setup VM in virtualbox:
    1. Frontend node: Linux/Redhat x64 with min 1GB RAM, 30GB HDD, 1 optical drive (with rocks dvd iso mounted), 1 Internal Network interface (any name), 1 NAT, boot from optical drive
    2. Compute node(s): Linux/Redhat x64 min 1GB RAM, 30GB HDD, 1 Internal Network interface (same name as frontend-node), boot from network
  3. Start frontend-node VM, type build when prompted
  4. Select CD/DVD based rolls, at least os, kernel, base. Some recommended rolls are web server + ganglia (monitoring) and hpc (OpenMPI and MPICH)