Skip to content

Instantly share code, notes, and snippets.

View evadne's full-sized avatar
🎣
gone fishing

Evadne Wu evadne

🎣
gone fishing
View GitHub Profile
Mix.install([
{:ortex, "~> 0.1.10"},
{:nx, "~> 0.10.0"}
])
directory_path = "/Users/evadne/Projects/magika/assets/models/standard_v3_3"
model_path = Path.join(directory_path, "model.onnx")
config_path = Path.join(directory_path, "config.min.json")
config = config_path |> File.read!() |> JSON.decode!()
min_size = config["min_file_size_for_dl"]
@evadne
evadne / lecture.md
Last active September 15, 2025 10:56
How to Sell Elixir (2023)

How to Sell Elixir AGAIN (2023)

Presented by Evadne Wu at Code BEAM Lite in Stockholm, Sweden on 12 May 2023

Synopsis

We have celebrated 10 years of Elixir and also nearly 25 years of Erlang since the open source release in December 1998.

Most of the libraries that were needed to make the ecosystem viable have been built, talks given, books written, conferences held and training sessions provided. A new generation of companies have been built on top of the Elixir / Erlang ecosystem. In all measures, we have achieved further reach and maturity than 5 years ago.

@evadne
evadne / a-reverse-bench.exs
Last active July 24, 2025 17:08
Reversing Binaries in Elixir
defmodule Benchmarker do
def run(title, module, function, size \\ 1024, iterations \\ 100) do
times = for (_ <- 1 .. iterations) do
data = :crypto.strong_rand_bytes(size)
{duration, _value} = :timer.tc fn ->
apply(module, function, [data])
end
duration
end
@evadne
evadne / hypnos.yaml
Created February 11, 2025 02:58
LLaMA.cpp Server on Incus
architecture: x86_64
config:
cloud-init.user-data: |
#cloud-config
package_upgrade: true
packages:
- apt-transport-https
- build-essential
- ca-certificates
- cmake
@evadne
evadne / minerva.yaml
Last active February 6, 2025 19:08
Open WebUI on Incus (images:debian/bookworm/cloud)
architecture: x86_64
config:
cloud-init.user-data: |
#cloud-config
package_upgrade: true
packages:
- apt-transport-https
- ca-certificates
- curl
write_files:
@evadne
evadne / gist:440558b18228ca657ef22b465793a0c3
Last active June 21, 2024 01:57
Using SchemaCrawler on PostgreSQL databases
@evadne
evadne / About.md
Last active April 9, 2024 07:19
Create display override file to force Mac OS X to use RGB mode for Display.

Create display override file to force Mac OS X to use RGB mode for Display.

  • Dell (4268) = 0x40ac
  • U3011 (16485) = 0x4065: /System/Library/Displays/Overrides/DisplayVendorID-10ac/DisplayProductID-4065
  • U2713HM (16512) = 0x4080: /System/Library/Displays/Overrides/DisplayVendorID-10ac/DisplayProductID-4080

Credit: http://embdev.net/topic/284710; works for OS X 10.8 & last tested on 10.9 13A476u.

@evadne
evadne / console.ex
Last active November 5, 2023 18:36
Elixir Tic Tac Toe with Minimax
defmodule TTT.Console do
def print(board) do
at = fn index ->
case elem(board, index) do
nil -> " "
:X -> "X"
:O -> "O"
end
end
@evadne
evadne / gist:4544569
Last active August 14, 2023 05:04
Todd Laney’s enhancements to Sticky Headers + UICollectionViewFlowLayout
//
// StickyHeaderLayout.h
// Wombat
//
// Created by Todd Laney on 1/9/13.
// Copyright (c) 2013 ToddLa. All rights reserved.
//
// Modified from http://blog.radi.ws/post/32905838158/sticky-headers-for-uicollectionview-using THANKS!
//
out.txt
out-sorted.txt
words.txt