Skip to content

Instantly share code, notes, and snippets.

@kourzanov
kourzanov / Project.toml
Last active January 15, 2020 10:01
Empty notebook
[deps]
Gadfly = "c91e804a-d5a3-530f-b6f0-dfbca275c004"
PyCall = "438e738f-606a-5dbb-bf0a-cddfbfd45ab0"
PyPlot = "d330b81b-6aea-500a-939a-2ce795aea3ee"
RDatasets = "ce6b1742-4840-55fa-b093-852dadbb1d8b"
Cxx = "a0b5b9ef-44b7-5148-a2d1-f6db19f3c3d2"
Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
PlotlyJS = "f0f68f2c-4968-5e81-91da-67840de0976a"
ORCA = "47be7bcc-f1a6-5447-8b36-7eeeff7534fd"
DSP = "717857b8-e6f2-59f4-9121-6e50c889abd2"
@kourzanov
kourzanov / prelude.jl
Last active January 15, 2020 12:55
Julia prelude
# basic packages and plotting
versioninfo()
using FFTW, DSP, DataFrames, Query, Plots, StatsPlots; #plotlyjs()
const N=100
plot(1:N,1:N |> x->cos.(2pi*x/N)+0sin.(2pi*x/N) |> fft |> x->abs.(x) |> fftshift)
# calling to C++ via LLVM
using Cxx
cxx"""#include <iostream>"""
cxx"""using namespace std;"""
@kourzanov
kourzanov / LSF.jl
Created November 13, 2014 14:03
LSF module for Julia
module LSF
immutable LSFManager <: ClusterManager
machines::Dict
function LSFManager(; machines=[])
mhist = Dict()
for m in machines
cnt = get(mhist, m, 0)
mhist[m] = cnt + 1