Skip to content

Instantly share code, notes, and snippets.

View jeremycochoy's full-sized avatar

Jeremy Cochoy jeremycochoy

View GitHub Profile

Terms & Conditions

By downloading or using the app, these terms will automatically apply to you – you should make sure therefore that you read them carefully before using the app. You’re not allowed to copy, or modify the app, any part of the app, or our trademarks in any way. You’re not allowed to attempt to extract the source code of the app, and you also shouldn’t try to translate the app into other languages, or make derivative versions. The app itself, and all the trade marks, copyright, database rights and other intellectual property rights related to it, still belong to Jeremy Cochoy.

Jeremy Cochoy is committed to ensuring that the app is as useful and efficient as possible. For that reason, we reserve the right to make changes to the app or to charge for its services, at any time and for any reason. We will never charge you for the app or its services without making it very clear to you exactly what you’re paying for.

The SoundBound app stores and processes personal data that you have provided

Privacy Policy

Jeremy Cochoy built the SoundBounce app as a Commercial app. This SERVICE is provided by Jeremy Cochoy and is intended for use as is.

This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service.

If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy.

The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at SoundBounce unless otherwise defined in this Privacy Policy.

Privacy Policy

Jérémy Cochoy built the QArt app as a Free app. This SERVICE is provided by Jérémy Cochoy at no cost and is intended for use as is.

This page is used to inform visitors regarding my policies with the collection, use, and disclosure of Personal Information if anyone decided to use my Service.

If you choose to use my Service, then you agree to the collection and use of information in relation to this policy. The Personal Information that I collect is used for providing and improving the Service. I will not use or share your information with anyone except as described in this Privacy Policy.

The terms used in this Privacy Policy have the same meanings as in our Terms and Conditions, which is accessible at QArt unless otherwise defined in this Privacy Policy.

// Replaces data[0..2*nn-1] by its discrete Fourier transform,
// if isign is input as 1; or replaces data[0..2*nn-1] by nn times its inverse
// discrete Fourier transform, if isign is input as −1.
// data is a complex array of length nn or, equivalently, a real array
// of length 2*nn.
// nn MUST be an integer power of 2 (this is not checked for!).
void dfft(float data[], unsigned int nn, int isign) {
initialize_sincos_tables();
unsigned int n, mmax, m, j, istep, i;
double wtemp, wr, wpr, wpi, wi, theta;
@jeremycochoy
jeremycochoy / fft-ios.swift
Created February 7, 2020 20:41
How to use Apple's Accelerate FFT in swift
//
// MIT LICENSE: Copy past as much as you want :)
//
// Your signal, array of length 1024
let signal: [Float] = (0 ... 1024)
// --- INITIALIZATION
// The length of the input
length = vDSP_Length(signal.count)
import onnxruntime as rt
import onnx
import numpy as np
import torch
import torch.nn as nn
import torch.nn
import torch.onnx
def onnx_export(model: torch.nn.Module, input_shape, filename: str,
var zippy = ListZipper<String>(from: ["I", "love", "pancakes"])
print(zippy.cursor!) // I
zippy.right() // move to the right
print(zippy.cursor!) // love
zippy.cursor = "hate"
print(zippy.toList().joined(separator: " ")) // I hate pancakes
zippy.remove()
zippy.cursor = "Eat"
print(zippy.toList().joined(separator: " ")) // Eat pancakes
/// Map a function to the tracks
func map<R>(f: (T) -> R) -> ListZipper<R> {
var zipper = ListZipper<R>()
zipper.leftList = leftList.map(f)
zipper.cursor = cursor.map(f)
zipper.rightList = rightList.map(f)
return zipper
}
/// Insert a new track
mutating func insert(element: T) {
if let c = cursor {leftList.append(c)}
cursor = element
}
/// Remove the current pointed track
mutating func remove() {
guard let _ = cursor else {return}
/// Select the left element if available
mutating func left() {
guard leftList.isNotEmpty else {return}
if let c = cursor {rightList.append(c)}
cursor = leftList.popLast()
}
/// Select the right element if available
mutating func right() {