diff --git a/benchmarks/benchmark_multimodal.jl b/benchmarks/benchmark_multimodal.jl index eb2ef6f..1fe5513 100644 --- a/benchmarks/benchmark_multimodal.jl +++ b/benchmarks/benchmark_multimodal.jl @@ -17,7 +17,7 @@ include("benchmark_utils.jl") hparams = HyperParamsVanillaGan(; data_size=100, batch_size=1, - epochs=1e3, + epochs=1e4, lr_dscr=1e-4, lr_gen=1e-4, dscr_steps=0, @@ -29,7 +29,7 @@ include("benchmark_utils.jl") train_vanilla_gan(dscr, gen, hparams) hparams = HyperParams(; - samples=1000, K=100, epochs=100, η=1e-2, transform=noise_model + samples=200, K=10, epochs=1000, η=2e-2, transform=noise_model ) #hparams = AutoAdaptativeHyperParams(; # max_k=20, samples=1200, epochs=10000, η=1e-3, transform=noise_model @@ -59,7 +59,7 @@ include("benchmark_utils.jl") gen, n_samples, (-3:0.1:3), - (5:0.2:15), + (-8:0.2:8), ) #@test js_divergence(hist1.weights, hist2.weights)/hparams.samples < 0.03 diff --git a/test/runtests.jl b/test/runtests.jl index e19d772..636b8d3 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -88,7 +88,7 @@ end; @testset "adaptative_block_learning" begin @testset "learning Normal(4.0f0, 2.0f0)" begin nn = Chain(Dense(1, 7), elu, Dense(7, 13), elu, Dense(13, 7), elu, Dense(7, 1)) - hparams = HyperParams(1000, 10, 400, 1e-2, Normal(0.0f0, 1.0f0)) + hparams = HyperParams(1000, 10, 1000, 1e-2, Normal(0.0f0, 1.0f0)) function real_model(ϵ) return rand(Normal(4.0f0, 2.0f0)) @@ -112,7 +112,7 @@ end; @testset "learning uniform distribution (1,3)" begin nn = Chain(Dense(1, 7), elu, Dense(7, 13), elu, Dense(13, 7), elu, Dense(7, 1)) - hparams = HyperParams(100, 10, 1000, 1e-2, Normal(0.0f0, 1.0f0)) + hparams = HyperParams(100, 10, 2000, 1e-2, Normal(0.0f0, 1.0f0)) function real_model(ϵ) return rand(Float32) * 2 + 1 @@ -132,7 +132,7 @@ end; @testset "learning Cauchy distribution" begin nn = Chain(Dense(1, 7), elu, Dense(7, 13), elu, Dense(13, 7), elu, Dense(7, 1)) - hparams = HyperParams(100, 10, 1000, 1e-3, Normal(0.0f0, 1.0f0)) + hparams = HyperParams(100, 10, 2000, 1e-3, Normal(0.0f0, 1.0f0)) function real_model(ϵ) return rand(Cauchy(1.0f0, 2.0f0)) @@ -152,7 +152,7 @@ end; @testset "learning Bimodal Normal Distribution" begin nn = Chain(Dense(1, 7), elu, Dense(7, 13), elu, Dense(13, 7), elu, Dense(7, 1)) - hparams = HyperParams(100, 10, 2000, 1e-2, Normal(0.0f0, 1.0f0)) + hparams = HyperParams(100, 10, 4000, 1e-2, Normal(0.0f0, 1.0f0)) function real_model(ϵ) return rand(MixtureModel(Normal[Normal(5.0f0, 2.0f0), Normal(-1.0f0, 1.0f0)])) @@ -173,7 +173,7 @@ end; @testset "learning modal auto_adaptative_block_learning Normal(4.0f0, 2.0f0)" begin nn = Chain(Dense(1, 7), elu, Dense(7, 13), elu, Dense(13, 7), elu, Dense(7, 1)) hparams = AutoAdaptativeHyperParams(; - max_k=10, samples=1000, epochs=400, η=1e-2, transform=Normal(0.0f0, 1.0f0) + max_k=10, samples=1000, epochs=1000, η=1e-2, transform=Normal(0.0f0, 1.0f0) ) function real_model(ϵ)