Skip to content

Instantly share code, notes, and snippets.

@dmazzer
dmazzer / readme.md
Created April 30, 2019 09:50 — forked from endolith/readme.md
THD+N calculator

Unfortunately, there are 2 versions of this. The other is here: https://github.com/endolith/waveform-analyzer I intend to either completely combine them or completely separate them, eventually.

Somewhat crude THD+N calculator in Python

Measures the total harmonic distortion plus noise (THD+N) for a given input signal, by guessing the fundamental frequency (finding the peak in the FFT), and notching it out in the frequency domain. This is a THDR

@dmazzer
dmazzer / DataTransfer.java
Created October 6, 2017 01:02 — forked from visualskyrim/DataTransfer.java
Simple Flink job streaming data from Kafka to local files.
import org.apache.flink.api.common.restartstrategy.RestartStrategies;
import org.apache.flink.api.java.utils.ParameterTool;
import org.apache.flink.streaming.api.CheckpointingMode;
import org.apache.flink.streaming.api.datastream.DataStream;
import org.apache.flink.streaming.api.environment.CheckpointConfig;
import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment;
import org.apache.flink.streaming.connectors.fs.bucketing.BucketingSink;
import org.apache.flink.streaming.connectors.fs.bucketing.DateTimeBucketer;
import org.apache.flink.streaming.connectors.kafka.FlinkKafkaConsumer08;
import org.apache.flink.streaming.util.serialization.SimpleStringSchema;
@dmazzer
dmazzer / index.html
Created January 6, 2016 00:46 — forked from anonymous/index.html
SVG Examples // source https://jsbin.com/kunesu
<!DOCTYPE html>
<html>
<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.6/d3.min.js"></script>
<meta charset="utf-8">
<link href='https://fonts.googleapis.com/css?family=Quicksand' rel='stylesheet' type='text/css'>
<title>SVG Examples</title>
<style id="jsbin-css">
.textStyle1 {
font-size: 1em;