Skip to content

Instantly share code, notes, and snippets.

View iBluemind's full-sized avatar
๐Ÿ‘‹
Hello, world!

Manjong Han iBluemind

๐Ÿ‘‹
Hello, world!
View GitHub Profile
"""
The most atomic way to train and run inference for a GPT in pure, dependency-free Python.
This file is the complete algorithm.
Everything else is just efficiency.
@karpathy
"""
import os # os.path.exists
import math # math.log, math.exp
@victorrica
victorrica / bypass_ssl_pining.js
Last active February 17, 2025 00:25
Shifty ์•ฑ ๋ฆฌ๋ฒ„์Šค ์—”์ง€๋‹ˆ์–ด๋ง
Java.perform(function() {
var array_list = Java.use("java.util.ArrayList");
var ApiClient = Java.use('com.android.org.conscrypt.TrustManagerImpl');
ApiClient.checkTrustedRecursive.implementation = function(a1, a2, a3, a4, a5, a6) {
// console.log('Bypassing SSL Pinning');
var k = array_list.$new();
return k;
}
@claudiok
claudiok / OpenStack_consumer_GPU_passthrough.md
Last active April 9, 2026 04:16
Consumer-grade GPU passthrough in an OpenStack system (NVIDIA GPUs)

Consumer-grade GPUs in an OpenStack system (NVIDIA GPUs)

Assumptions

This assumes you have GTX980 cards in your system (PCI id 10de:13c0 & 10de:0fbb per card). Just add more IDs for other cards in order to make this more generic. This also assumes nova uses qemu-kvm as the virtualization hypervisor (qemu-system-x86_64). This seems to be the default on OpenStack Newton when installed using openstack-ansible.

We assume OpenStack Newton is pre-installed and that we are working on a Nova compute node. This has been tested on an Ubuntu 16.04 system where I installed OpenStack AIO version 14.0.0 (different from the git tag used in the instructions!): http://docs.openstack.org/developer/openstack-ansible/developer-docs/quickstart-aio.html

Prepare the system for GPU passthrough (set up IOMMU/vfio/...)

Note: This is heavily based on information from https://wiki.archlinux.org/index.php/PCI_passthrough_via_OVMF#Enabling_IOMMU adapted for Ubuntu 16.04

@ihoneymon
ihoneymon / springboot-introduction.md
Last active October 14, 2022 08:44
์Šคํ”„๋ง๋ถ€ํŠธ ์†Œ๊ฐœ

์Šคํ”„๋ง๋ถ€ํŠธ ์†Œ๊ฐœ

0. ์Šคํ”„๋ง๋ถ€ํŠธSpringBoot๋ž€?

Spring Boot makes it easy to create stand-alone, production-grade Spring based Applications that you can "just run". We take an opinionated view of the Spring platform and third-party libraries so you can get started with minimum fuss. Most Spring Boot applications need very little Spring configuration.

  • ์Šคํ”„๋ง๋ถ€ํŠธ๋Š” ๋‹จ๋…์‹คํ–‰๋˜๋Š”, ์‹คํ–‰ํ•˜๊ธฐ๋งŒ ํ•˜๋ฉด ๋˜๋Š” ์ƒ์šฉํ™” ๊ฐ€๋Šฅํ•œ ์ˆ˜์ค€์˜, ์Šคํ”„๋ง ๊ธฐ๋ฐ˜ ์• ํ”Œ๋ฆฌ์ผ€์ด์…˜์„ ์‰ฝ๊ฒŒ ๋งŒ๋“ค์–ด๋‚ผ ์ˆ˜ ์žˆ๋‹ค.
  • ์ตœ์†Œํ•œ์˜ ์„ค์ •์œผ๋กœ ์Šคํ”„๋ง ํ”Œ๋žซํผ๊ณผ ์„œ๋“œํŒŒํ‹ฐ ๋ผ์ด๋ธŒ๋Ÿฌ๋ฆฌ๋“ค์„ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ๋„๋ก ํ•˜๊ณ  ์žˆ๋‹ค.
@staltz
staltz / introrx.md
Last active May 3, 2026 02:38
The introduction to Reactive Programming you've been missing
@dhh
dhh / test_induced_design_damage.rb
Last active November 2, 2024 00:52
This is an extraction from Jim Weirich's "Decoupling from Rails" talk, which explained how to apply the hexagonal design pattern to make every layer of your application easily unit testable (without touching the database etc). It only seeks to extract a single method, the EmployeesController#create method, to illustrate the design damage that's โ€ฆ
# Original Rails controller and action
class EmployeesController < ApplicationController
def create
@employee = Employee.new(employee_params)
if @employee.save
redirect_to @employee, notice: "Employee #{@employee.name} created"
else
render :new
end
@willurd
willurd / web-servers.md
Last active May 5, 2026 10:35
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000