😶🌫️
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Turing | |
| using MLKernels | |
| using LinearAlgebra | |
| N=100 | |
| X = sort(rand(N,1),1) #Create some data | |
| K = kernelmatrix(SquaredExponentialKernel(100.0),X) #Kernel matrix | |
| y = rand(MvNormal(zeros(N),K+1e-1I)) #Sample from the GP prior with some noise | |
| # Model representing Student-T Likelihood => Normal(y|f,omega)IG(omega|nu/2,nu/2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Makie | |
| N_grid = 100 | |
| x_grid = range(0,1,length=N_grid) | |
| scene = Makie.surface(x_grid,x_grid,rand(N_grid,N_grid)) | |
| push!(scene[end][1],scene[end][1][].+ 1.0f0) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using KernelFunctions | |
| using Stheno | |
| using Stheno: pw | |
| using BenchmarkTools | |
| using Zygote | |
| # Ds = [1,2,5,10,20,50,100,200,500,1000] | |
| Ds = [1,10,100,1000] | |
| timestheno = zeros(Float64,length(Ds)); memstheno = similar(timestheno) | |
| timekf = similar(timestheno); memkf = similar(timestheno) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Plots, Colors, Measures | |
| using AugmentedGaussianProcesses | |
| pyplot() | |
| julia_blue = RGB(0.251, 0.388, 0.847) | |
| julia_green = RGB(0.22, 0.596, 0.149) | |
| julia_purple = RGB(0.584, 0.345, 0.698) | |
| julia_red = RGB(0.796, 0.235, 0.2) | |
| x = [0.1, 0.2, 0.3] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Plots; pyplot() | |
| N = 100 | |
| x = range(-3, 3, length=N) | |
| f1(x, y) = begin z = Complex(x, y); abs(z^z); end | |
| f2(x, y) = begin z = Complex(x, y); angle(z^z); end | |
| surface(x, x, f1.(x, x'), fill_z = f2.(x, x'), clims = (-pi, pi), color = :colorwheel) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Distributions | |
| using Bijectors | |
| using Makie, Colors | |
| using Animations | |
| p0 = MvNormal(ones(2)) | |
| samples = rand(p0, 1) | |
| abslim = -7 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Distributions | |
| using Plots; pyplot() | |
| using ForwardDiff | |
| using LaTeXStrings | |
| λ = 3.0 | |
| μ = 2.0 | |
| s = 0.8 | |
| # α = Exponential(λ) # Measure alpha the starting point | |
| α = Laplace(μ, s + 1.0) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using Makie | |
| using MakieLayout | |
| using LinearAlgebra, Distances | |
| using Distributions | |
| α = MixtureModel([Normal(0.2, 0.05), Normal(0.6, 0.06), Normal(0.8, 0.04)], [0.3, 0.5, 0.2]) | |
| # β = Normal(0.3, 0.09) | |
| β = Laplace(0.5, 0.1) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using HTTP | |
| using Dates | |
| using Printf | |
| using JSON | |
| using DataFrames | |
| using FileIO | |
| using CSV | |
| work_location = (52.516747,13.323553) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using BlockDiagonals | |
| using StatsBase | |
| using BenchmarkTools | |
| using Test | |
| D = 2000 | |
| N = 100 | |
| K = 20 | |
| G = rand(D, N) | |
| X = rand(D, N) | |
| indices = vcat(1, sort(sample(2:D-1, K-1, replace = false)), D+1) |
OlderNewer