Skip to content

Instantly share code, notes, and snippets.

@bigs
bigs / testbed_notes.txt
Created January 17, 2019 18:03
i'm so tired, these are probably slightly stupid
testbed notes
worth considering notes here https://github.com/ipfs/notes/issues/191, though
i have fears this leads us towards a path to kubernetes!
definition of terms:
- topology: weighted composition of nodes, e.g. gateway vs full ipfs vs p2pd
with specific modules enabled.
- scenario: the general definition of behaviors of nodes in the testbed. one
scenario runner is run per physical machine. it is responsible for
s.boot;
(
SynthDef(\thicc, { |freq, ffreq=0, ftrack=1.0, res=0.5, gate=1, amp=1, out|
var unison = 5;
var freqs = Array.fill(unison, { |i|
var even, offset;
even = i % 2 == 0;
offset = ((i / 2).floor + 1) / (unison / 2) * (freq * 0.01);
offset = if (even, offset, offset.neg);
package main
import (
"bufio"
"context"
"fmt"
"os"
"time"
cid "github.com/ipfs/go-cid"
(
play{
var n = 5;
var fmodrate = Duty.kr(2, 0, Drand([1/16, 1, 1/16, 1/8, 4], inf));
var modfreq = Slew.kr(Duty.kr(8, 0, Drand([110, 220, 440], inf)));
Limiter.ar(GVerb.ar(Pan2.ar(
Mix.fill(n, { arg index;
SinOsc.ar(220 + (index ** n), SinOsc.ar(modfreq + (index ** n), 0, Saw.kr(fmodrate, 2.5, 2.5)), 1 / n)
}),
SinOsc.kr(1)
data GeoCoordinate = GeoCoordinate
{ _geoCoordinateLatitude :: Double
, _geoCoordinateLongitude :: Double
} deriving (Eq, Read, Show, Generic)
instance Binary GeoCoordinate where
put (GeoCoordinate lat long) = do
put (0 :: Int8) -- we'll use big endian, Data.Binary's default
put (1 :: Int32)
put (4326 :: Int32)
#lang racket
(define miLRco
(lambda (new oldL oldR lat col)
(cond
((null? lat)
(col '() 0 0))
((eq? (car lat) oldL)
(miLRco new oldL oldR
(cdr lat)
// pulse threshold (v)
Param threshold(1.5);
// clock mul (pos) or div (neg) factor
Param factor(1);
History last(0.);
History ticks(0.);
History childTicks(0.);
History clockLength(0.);
History childClockLength(0.);
bigs@mako:~/code/L-SPACE$ mediachain history 3fab9a8b-570d-47df-9157-6fd2cf94a5e5
{
"canonicalID":"3fab9a8b-570d-47df-9157-6fd2cf94a5e5",
"revisions":[
{
"signatures":{},
"description":"Photograph, gelatin silver print on paper",
"title":"Hy\u00e8res, France",
"author":{
"external_ids":{},
usage: mediachain [-h] {ingest,list,get,history,revise,works,config} ...
Mediachain CLI
positional arguments:
{ingest,list,get,history,revise,works,config}
Mediachain subcommands
ingest Ingest a dataset
list List canonical IDs in the system
get Get the data for a canonical