Skip to content

Instantly share code, notes, and snippets.

@AlkindiX
AlkindiX / MEMO
Last active March 10, 2024 20:10
Run machine learning on 7900XT and 7900XTX on PyTorch
Requirements:-
1. Ubuntu 22.04
2. 7900XT or 7900XTX
Pre-requests before making any installation.
Follow step 1-3 if you installed amdgpu.
1. If you already installed redeon graphic card driver from AMD using amdgpu-install. Completely remove the driver
and connect your HDMI to motherboard. Then restart your PC
@rain-1
rain-1 / LLM.md
Last active July 25, 2024 18:44
LLM Introduction: Learn Language Models

Purpose

Bootstrap knowledge of LLMs ASAP. With a bias/focus to GPT.

Avoid being a link dump. Try to provide only valuable well tuned information.

Prelude

Neural network links before starting with transformers.

@slimsag
slimsag / ramblings.md
Last active December 13, 2023 08:02
Because cross-compiling binaries for Windows is easier than building natively

Because cross-compiling binaries for Windows is easier than building natively

I want Microsoft to do better, want Windows to be a decent development platform-and yet, I constantly see Microsoft playing the open source game: advertising how open-source and developer friendly they are - only to crush developers under the heel of the corporate behemoth's boot.

The people who work at Microsoft are amazing, kind, talented individuals. This is aimed at the company's leadership, who I feel has on many occassions crushed myself and other developers under. It's a plea for help.

The source of truth for the 'open source' C#, C++, Rust, and other Windows SDKs is proprietary

You probably haven't heard of it before, but if you've ever used win32 API bindings in C#, C++, Rust, or other languages, odds are they were generated from a repository called microsoft/win32metadata.

image: fishtownanalytics/dbt:1.0.0
pipelines:
branches:
master:
- step:
name: 'setup and compile dbt'
script:
- cd dbt_project
- dbt deps --profiles-dir ./profiles
from typing import List, Dict
import random
import numpy as np
import sys
Actions = ['B', 'C'] # bet/call vs check/fold
class InformationSet():
def __init__(self):
self.cumulative_regrets = np.zeros(shape=len(Actions))

Installing SBCL from source on Windows

This tutorial assumes you have installed binary version of SBCL downloaded from http://www.sbcl.org/platform-table.html

Also, it assumes you have Msys2 installed. https://www.msys2.org/ And all the tools needed for compilation are there.

On top of that I used Windows cmd started from a bat file that adds Msys2 paths.

@frederikbosch
frederikbosch / Dockerfile
Created March 11, 2019 09:34
osslsigncode
FROM ubuntu:18.04
RUN apt-get update && apt-get install -y \
openssl libcurl4-openssl-dev libssl-dev libengine-pkcs11-openssl \
curl libcurl4 \
git automake libtool pkg-config wget \
libccid libpcsclite1 pcscd usbutils opensc
RUN git clone https://github.com/mtrojnar/osslsigncode
@kafkasl
kafkasl / sp500_constituents.json
Created March 7, 2019 13:47
List of S&P 500 historical constituents from 2008/01/31 to 2019/02/27. JSON format where each date contains a list of the constituents.
This file has been truncated, but you can view the full file.
{
"2008/01/31":[
"GHC",
"MDP",
"GAS",
"AZO",
"MIL",
"MXA",
"ASH",
@munificent
munificent / generate.c
Last active May 14, 2024 05:30
A random dungeon generator that fits on a business card
#include <time.h> // Robert Nystrom
#include <stdio.h> // @munificentbob
#include <stdlib.h> // for Ginny
#define r return // 2008-2019
#define l(a, b, c, d) for (i y=a;y\
<b; y++) for (int x = c; x < d; x++)
typedef int i;const i H=40;const i W
=80;i m[40][80];i g(i x){r rand()%x;
}void cave(i s){i w=g(10)+5;i h=g(6)
+3;i t=g(W-w-2)+1;i u=g(H-h-2)+1;l(u
@vireshas
vireshas / split_wav.py
Created November 16, 2017 12:16 — forked from rudolfbyker/split_wav.py
Split WAV files at silence
#!/usr/bin/env python
from scipy.io import wavfile
import os
import numpy as np
import argparse
from tqdm import tqdm
# Utility functions