Skip to content

Instantly share code, notes, and snippets.

Avatar

Andrei Zhabinski dfdx

View GitHub Profile
@dfdx
dfdx / benchmark.jl
Last active Jan 31, 2019
Zygote vs. Yota benchmark
View benchmark.jl
using Yota
using Zygote
using Zygote: @adjoint
using BenchmarkTools
using Distributions
import NNlib
logistic(x) = 1 / (1 + exp(-x))
softplus(x) = log(exp(x) + 1)
View gist:f5085ee0e5da68e0b9af1c1a4ae783a7
for n in numbers:
# выполняется для каждого числа
# выполняется после цикла
@dfdx
dfdx / core.jl
Created Jul 28, 2016
Julia Workshop
View core.jl
################ BASICS #################
# dynamic typing
x = 3 # => 3 (Int64)
x = 3.2 # => 3.2 (Float64)
x = 2 + 1im # => 2 + 1im (Complex{Int64})
x = 2//3 # => 2//3 (Rational{Int64})
You can’t perform that action at this time.