Skip to content

Instantly share code, notes, and snippets.

View avinayak's full-sized avatar

Atul Vinayak avinayak

  • Hiive
  • Vancouver, BC
  • 18:23 (UTC -07:00)
View GitHub Profile
@stollcri
stollcri / c41
Last active April 25, 2025 01:13
A Python script to develop scans of C-41 film negatives into color-corrected positive images
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
import logging
import math
import os
import statistics
import signal
import sys
@adibenc
adibenc / docker-compose.yml
Last active April 26, 2022 13:24
example docker-compose.yml for kong, postgres and konga, a bit fixes
version: "3"
networks:
kong-net:
driver: bridge
services:
#######################################
# Postgres: The database used by Kong
@PJUllrich
PJUllrich / big-o.md
Last active February 13, 2025 23:48
Big-O Time Complexities for Elixir Data Structures

Big-O Time Complexities for Elixir data structures

Map [1]

Operation Time Complexity
Access O(log n)
Search O(log n)
Insertion O(n) for <= 32 elements, O(log n) for > 32 elements [2]
Deletion O(n) for <= 32 elements, O(log n) for > 32 elements
@holgergp
holgergp / smartSmoothStep.ts
Last active October 20, 2024 00:49
Retrofitted SmoothStepPath to react-flow-smart-edge
import { SVGDrawFunction } from "@tisoap/react-flow-smart-edge/src/functions/drawSvgPath";
import { XYPosition } from "reactflow";
const distance = (a: XYPosition, b: XYPosition) => Math.sqrt(Math.pow(b.x - a.x, 2) + Math.pow(b.y - a.y, 2));
function getBend(a: XYPosition, b: XYPosition, c: XYPosition, size: number): string {
const bendSize = Math.min(distance(a, b) / 2, distance(b, c) / 2, size);
const { x, y } = b;
// no bend