content
stringlengths
6
1.03M
input_ids
sequencelengths
4
535k
ratio_char_token
float64
0.68
8.61
token_count
int64
4
535k
<reponame>josePereiro/SimTools.jl function run_OnDiskMonitor_tests() n = 1000 m = SimTools.OnDiskMonitor(@__DIR__, "monitor_test.jld2"; dt = 1.0) SimTools.reset!(m) SimTools.clear_file(m) @assert isempty(m.cache) @assert !isfile(m.file) # Watch task (It can be in another process) tests_results = [] cvals = [] @async SimTools.watch(m) do ddat isempty(ddat) && return check = true dvals = ddat[:vals] for dval in dvals check &= dval in cvals end push!(tests_results, check) end # Fake job to monitor for i in 1:n push!(cvals, i) SimTools.record!(m) do dat dat[:vals] = cvals end sleep(5.0/n) end SimTools.reset!(m) sleep(1.0) @test isempty(m.cache) @test length(cvals) == n @test all(tests_results) SimTools.clear_file(m) @test !isfile(m.file) end run_OnDiskMonitor_tests()
[ 27, 7856, 261, 480, 29, 73, 577, 47, 567, 7058, 14, 8890, 33637, 13, 20362, 198, 8818, 1057, 62, 2202, 40961, 35479, 62, 41989, 3419, 198, 220, 220, 220, 299, 796, 8576, 198, 220, 220, 220, 285, 796, 3184, 33637, 13, 2202, 40961, 35479, 7, 31, 834, 34720, 834, 11, 366, 41143, 62, 9288, 13, 73, 335, 17, 8172, 288, 83, 796, 352, 13, 15, 8, 198, 220, 220, 220, 3184, 33637, 13, 42503, 0, 7, 76, 8, 198, 220, 220, 220, 3184, 33637, 13, 20063, 62, 7753, 7, 76, 8, 198, 220, 220, 220, 2488, 30493, 318, 28920, 7, 76, 13, 23870, 8, 198, 220, 220, 220, 2488, 30493, 5145, 4468, 576, 7, 76, 13, 7753, 8, 628, 220, 220, 220, 1303, 6305, 4876, 357, 1026, 460, 307, 287, 1194, 1429, 8, 198, 220, 220, 220, 5254, 62, 43420, 796, 17635, 198, 220, 220, 220, 269, 12786, 796, 17635, 198, 220, 220, 220, 2488, 292, 13361, 3184, 33637, 13, 8340, 7, 76, 8, 466, 288, 19608, 198, 220, 220, 220, 220, 220, 220, 220, 318, 28920, 7, 1860, 265, 8, 11405, 1441, 198, 220, 220, 220, 220, 220, 220, 220, 2198, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 288, 12786, 796, 288, 19608, 58, 25, 12786, 60, 198, 220, 220, 220, 220, 220, 220, 220, 329, 288, 2100, 287, 288, 12786, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2198, 1222, 28, 288, 2100, 287, 269, 12786, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 41989, 62, 43420, 11, 2198, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1303, 33482, 1693, 284, 5671, 198, 220, 220, 220, 329, 1312, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 66, 12786, 11, 1312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3184, 33637, 13, 22105, 0, 7, 76, 8, 466, 4818, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4818, 58, 25, 12786, 60, 796, 269, 12786, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 3993, 7, 20, 13, 15, 14, 77, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 3184, 33637, 13, 42503, 0, 7, 76, 8, 198, 220, 220, 220, 3993, 7, 16, 13, 15, 8, 198, 220, 220, 220, 220, 198, 220, 220, 220, 2488, 9288, 318, 28920, 7, 76, 13, 23870, 8, 198, 220, 220, 220, 2488, 9288, 4129, 7, 66, 12786, 8, 6624, 299, 198, 220, 220, 220, 2488, 9288, 477, 7, 41989, 62, 43420, 8, 628, 220, 220, 220, 3184, 33637, 13, 20063, 62, 7753, 7, 76, 8, 198, 220, 220, 220, 2488, 9288, 5145, 4468, 576, 7, 76, 13, 7753, 8, 198, 437, 198, 5143, 62, 2202, 40961, 35479, 62, 41989, 3419 ]
2.010373
482
""" Subroutine dgpstep This subroutine computes the gradient projection step s = P[x + alpha*w] - x, where P is the projection on the n-dimensional interval [xl,xu]. """ function dgpstep(n,x,xl,xu,alpha,w,s) # TODO # This computation of the gradient projection step avoids # rouding errors for the components that are feasible. @inbounds for i=1:n if x[i] + alpha*w[i] < xl[i] s[i] = xl[i] - x[i] elseif x[i] + alpha*w[i] > xu[i] s[i] = xu[i] - x[i] else s[i] = alpha*w[i] end end return end
[ 37811, 198, 7004, 81, 28399, 288, 31197, 9662, 198, 198, 1212, 850, 81, 28399, 552, 1769, 262, 31312, 20128, 2239, 628, 220, 264, 796, 350, 58, 87, 1343, 17130, 9, 86, 60, 532, 2124, 11, 198, 198, 3003, 350, 318, 262, 20128, 319, 262, 299, 12, 19577, 16654, 685, 87, 75, 11, 87, 84, 4083, 198, 37811, 198, 8818, 288, 31197, 9662, 7, 77, 11, 87, 11, 87, 75, 11, 87, 84, 11, 26591, 11, 86, 11, 82, 8, 198, 220, 220, 220, 1303, 16926, 46, 198, 220, 220, 220, 1303, 770, 29964, 286, 262, 31312, 20128, 2239, 30940, 198, 220, 220, 220, 1303, 374, 2778, 278, 8563, 329, 262, 6805, 326, 389, 23498, 13, 628, 220, 220, 220, 2488, 259, 65, 3733, 329, 1312, 28, 16, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 611, 2124, 58, 72, 60, 1343, 17130, 9, 86, 58, 72, 60, 1279, 2124, 75, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 264, 58, 72, 60, 796, 2124, 75, 58, 72, 60, 532, 2124, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 361, 2124, 58, 72, 60, 1343, 17130, 9, 86, 58, 72, 60, 1875, 2124, 84, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 264, 58, 72, 60, 796, 2124, 84, 58, 72, 60, 532, 2124, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 264, 58, 72, 60, 796, 17130, 9, 86, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 198, 437, 198 ]
2.034483
290
<reponame>JuliaCollections/Tries.jl using Compat.Test using Tries import Compat: Nothing tests = ["trie"] if length(ARGS) > 0 tests = ARGS end @testset "Tries" begin for t in tests fp = joinpath(dirname(@__FILE__), "test_$t.jl") println("$fp ...") include(fp) end end # @testset
[ 27, 7856, 261, 480, 29, 16980, 544, 5216, 26448, 14, 51, 1678, 13, 20362, 198, 3500, 3082, 265, 13, 14402, 198, 3500, 309, 1678, 198, 198, 11748, 3082, 265, 25, 10528, 628, 198, 41989, 796, 14631, 83, 5034, 8973, 198, 198, 361, 4129, 7, 1503, 14313, 8, 1875, 657, 198, 220, 220, 220, 5254, 796, 5923, 14313, 198, 437, 198, 198, 31, 9288, 2617, 366, 51, 1678, 1, 2221, 198, 198, 1640, 256, 287, 5254, 198, 220, 220, 220, 277, 79, 796, 4654, 6978, 7, 15908, 3672, 7, 31, 834, 25664, 834, 828, 366, 9288, 62, 3, 83, 13, 20362, 4943, 198, 220, 220, 220, 44872, 7203, 3, 46428, 35713, 8, 198, 220, 220, 220, 2291, 7, 46428, 8, 198, 437, 198, 198, 437, 1303, 2488, 9288, 2617, 198 ]
2.341085
129
<filename>v1/src/systems/trace_test_pencil.jl export TraceTestPencil """ TraceTestPencil(F, p₀, v) <: AbstractSystem The system `H(x,t) := [F(x, p₀+x[end]v); l ⋅[x[1:end-1];1] * λ + τ*γ)`. """ struct TraceTestPencil{S<:AbstractSystem,T} <: AbstractSystem F::TraceTestSystem{S,T} l::Vector{T} γ::T end function TraceTestPencil(F::TraceTestSystem, l) TraceTestPencil(F, l, cis(2π * rand())) end struct TraceTestPencilCache{SC<:TraceTestSystemCache} <: AbstractSystemCache cache::SC end function cache(F::TraceTestPencil, x, τ) c = cache(F.F, x, F.l) TraceTestPencilCache(c) end Base.size(F::TraceTestPencil) = size(F.F) function evaluate!(u, F::TraceTestPencil, x, τ, c::TraceTestPencilCache) λ = x[end] evaluate!(u, F.F, x, F.l, c.cache) u[end] = u[end] * λ + τ[1] * F.γ u end function evaluate(F::TraceTestPencil, x, τ, c::TraceTestPencilCache) evaluate!(evaluate(F.F, x, F.l, c.cache), F, x, τ, c) end function jacobian!(U, F::TraceTestPencil, x, τ, c::TraceTestPencilCache) λ = x[end] jacobian!(U, F.F, x, F.l, c.cache) for j = 1:length(x)-1 U[end, j] *= λ end U[end, end] = F.l[end] for i = 1:length(x)-1 U[end, end] += F.l[i] * x[i] end U end function jacobian(F::TraceTestPencil, x, τ, c::TraceTestPencilCache) jacobian!(jacobian(F.F, x, F.l, c.cache), F, x, τ, c) end function evaluate_and_jacobian!(u, U, F::TraceTestPencil, x, τ, c::TraceTestPencilCache) λ = x[end] evaluate_and_jacobian!(u, U, F.F, x, F.l, c.cache) u[end] = u[end] * λ + τ[1] * F.γ for j = 1:length(x)-1 U[end, j] *= λ end U[end, end] = F.l[end] for i = 1:length(x)-1 U[end, end] += F.l[i] * x[i] end nothing end function differentiate_parameters!(u, F::TraceTestPencil, x, τ, c::TraceTestPencilCache) u .= zero(eltype(u)) u[end, 1] = F.γ u end function differentiate_parameters(F::TraceTestPencil, x, τ, c::TraceTestPencilCache) u = similar(c.cache.u, size(F)[1], 1) differentiate_parameters!(u, F, x, τ, c) end
[ 27, 34345, 29, 85, 16, 14, 10677, 14, 10057, 82, 14, 40546, 62, 9288, 62, 3617, 2856, 13, 20362, 198, 39344, 34912, 14402, 25553, 2856, 198, 198, 37811, 198, 220, 220, 220, 34912, 14402, 25553, 2856, 7, 37, 11, 279, 158, 224, 222, 11, 410, 8, 1279, 25, 27741, 11964, 198, 198, 464, 1080, 4600, 39, 7, 87, 11, 83, 8, 19039, 685, 37, 7, 87, 11, 279, 158, 224, 222, 10, 87, 58, 437, 60, 85, 1776, 300, 2343, 233, 227, 58, 87, 58, 16, 25, 437, 12, 16, 11208, 16, 60, 1635, 7377, 119, 1343, 46651, 9, 42063, 8, 44646, 198, 37811, 198, 7249, 34912, 14402, 25553, 2856, 90, 50, 27, 25, 23839, 11964, 11, 51, 92, 1279, 25, 27741, 11964, 198, 220, 220, 220, 376, 3712, 2898, 558, 14402, 11964, 90, 50, 11, 51, 92, 198, 220, 220, 220, 300, 3712, 38469, 90, 51, 92, 198, 220, 220, 220, 7377, 111, 3712, 51, 198, 437, 198, 198, 8818, 34912, 14402, 25553, 2856, 7, 37, 3712, 2898, 558, 14402, 11964, 11, 300, 8, 198, 220, 220, 220, 34912, 14402, 25553, 2856, 7, 37, 11, 300, 11, 33325, 7, 17, 46582, 1635, 43720, 3419, 4008, 198, 437, 198, 198, 7249, 34912, 14402, 25553, 2856, 30562, 90, 6173, 27, 25, 2898, 558, 14402, 11964, 30562, 92, 1279, 25, 27741, 11964, 30562, 198, 220, 220, 220, 12940, 3712, 6173, 198, 437, 198, 198, 8818, 12940, 7, 37, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 8, 198, 220, 220, 220, 269, 796, 12940, 7, 37, 13, 37, 11, 2124, 11, 376, 13, 75, 8, 198, 220, 220, 220, 34912, 14402, 25553, 2856, 30562, 7, 66, 8, 198, 437, 198, 198, 14881, 13, 7857, 7, 37, 3712, 2898, 558, 14402, 25553, 2856, 8, 796, 2546, 7, 37, 13, 37, 8, 198, 198, 8818, 13446, 0, 7, 84, 11, 376, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 7377, 119, 796, 2124, 58, 437, 60, 198, 220, 220, 220, 13446, 0, 7, 84, 11, 376, 13, 37, 11, 2124, 11, 376, 13, 75, 11, 269, 13, 23870, 8, 198, 220, 220, 220, 334, 58, 437, 60, 796, 334, 58, 437, 60, 1635, 7377, 119, 1343, 46651, 58, 16, 60, 1635, 376, 13, 42063, 198, 220, 220, 220, 334, 198, 437, 198, 8818, 13446, 7, 37, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 13446, 0, 7, 49786, 7, 37, 13, 37, 11, 2124, 11, 376, 13, 75, 11, 269, 13, 23870, 828, 376, 11, 2124, 11, 46651, 11, 269, 8, 198, 437, 198, 198, 8818, 474, 330, 672, 666, 0, 7, 52, 11, 376, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 7377, 119, 796, 2124, 58, 437, 60, 198, 220, 220, 220, 474, 330, 672, 666, 0, 7, 52, 11, 376, 13, 37, 11, 2124, 11, 376, 13, 75, 11, 269, 13, 23870, 8, 198, 220, 220, 220, 329, 474, 796, 352, 25, 13664, 7, 87, 13219, 16, 198, 220, 220, 220, 220, 220, 220, 220, 471, 58, 437, 11, 474, 60, 1635, 28, 7377, 119, 198, 220, 220, 220, 886, 198, 220, 220, 220, 471, 58, 437, 11, 886, 60, 796, 376, 13, 75, 58, 437, 60, 198, 220, 220, 220, 329, 1312, 796, 352, 25, 13664, 7, 87, 13219, 16, 198, 220, 220, 220, 220, 220, 220, 220, 471, 58, 437, 11, 886, 60, 15853, 376, 13, 75, 58, 72, 60, 1635, 2124, 58, 72, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 471, 198, 437, 198, 8818, 474, 330, 672, 666, 7, 37, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 474, 330, 672, 666, 0, 7, 30482, 672, 666, 7, 37, 13, 37, 11, 2124, 11, 376, 13, 75, 11, 269, 13, 23870, 828, 376, 11, 2124, 11, 46651, 11, 269, 8, 198, 437, 198, 198, 8818, 13446, 62, 392, 62, 30482, 672, 666, 0, 7, 84, 11, 471, 11, 376, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 7377, 119, 796, 2124, 58, 437, 60, 198, 220, 220, 220, 13446, 62, 392, 62, 30482, 672, 666, 0, 7, 84, 11, 471, 11, 376, 13, 37, 11, 2124, 11, 376, 13, 75, 11, 269, 13, 23870, 8, 198, 220, 220, 220, 334, 58, 437, 60, 796, 334, 58, 437, 60, 1635, 7377, 119, 1343, 46651, 58, 16, 60, 1635, 376, 13, 42063, 198, 220, 220, 220, 329, 474, 796, 352, 25, 13664, 7, 87, 13219, 16, 198, 220, 220, 220, 220, 220, 220, 220, 471, 58, 437, 11, 474, 60, 1635, 28, 7377, 119, 198, 220, 220, 220, 886, 198, 220, 220, 220, 471, 58, 437, 11, 886, 60, 796, 376, 13, 75, 58, 437, 60, 198, 220, 220, 220, 329, 1312, 796, 352, 25, 13664, 7, 87, 13219, 16, 198, 220, 220, 220, 220, 220, 220, 220, 471, 58, 437, 11, 886, 60, 15853, 376, 13, 75, 58, 72, 60, 1635, 2124, 58, 72, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2147, 198, 437, 198, 198, 8818, 28754, 62, 17143, 7307, 0, 7, 84, 11, 376, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 334, 764, 28, 6632, 7, 417, 4906, 7, 84, 4008, 198, 220, 220, 220, 334, 58, 437, 11, 352, 60, 796, 376, 13, 42063, 198, 220, 220, 220, 334, 198, 437, 198, 198, 8818, 28754, 62, 17143, 7307, 7, 37, 3712, 2898, 558, 14402, 25553, 2856, 11, 2124, 11, 46651, 11, 269, 3712, 2898, 558, 14402, 25553, 2856, 30562, 8, 198, 220, 220, 220, 334, 796, 2092, 7, 66, 13, 23870, 13, 84, 11, 2546, 7, 37, 38381, 16, 4357, 352, 8, 198, 220, 220, 220, 28754, 62, 17143, 7307, 0, 7, 84, 11, 376, 11, 2124, 11, 46651, 11, 269, 8, 198, 437, 198 ]
1.986603
1,045
# --- PRIVATE METHODS --------------------------------------------------------------------------------------- # function _compute_crr_index_array(numberOfLevels::Int64) # ok, so lets build an index array - number_items_per_level = [(i+1) for i=0:numberOfLevels] tmp_array = Array{Int64,1}() theta = 0 for value in number_items_per_level for index = 1:value push!(tmp_array,theta) end theta = theta + 1 end N = sum(number_items_per_level[1:(numberOfLevels-1)]) index_array = Array{Int64,2}(undef,N,3) for row_index = 1:N #index_array[row_index,1] = tmp_array[row_index] index_array[row_index,1] = row_index index_array[row_index,2] = row_index + 1 + tmp_array[row_index] index_array[row_index,3] = row_index + 2 + tmp_array[row_index] end return index_array end function _compute_full_binomial_index_array(numberOfLevels::Int64) number_of_elements = (2^(Int(numberOfLevels))) - 1 index_array = Array{Int64,2}(undef,number_of_elements,3) # populate the index array - for index = 1:number_of_elements # compute the child indexs - left_child_index = 2*(index - 1) + 2 right_child_index = 2*(index - 1) + 3 # grab and go - index_array[index,1] = index index_array[index,2] = left_child_index index_array[index,3] = right_child_index end # return - return index_array end # array based - function _build_binary_lattice_intrinsic_value_array(contractSet::Set{PSAbstractAsset}, binaryPriceArray::Array{Float64,1})::PSResult # initialize - intrinsic_value_array = similar(binaryPriceArray) # ok, so lets go through each price, compute the intrinsic value - and then store for (index,price) in enumerate(binaryPriceArray) # ok, get the underlying price - underlying_price_value = binaryPriceArray[index] # compute the intrinsic value - result = intrinsic_value(contractSet,underlying_price_value) if (isa(result.value,Exception) == true) return result end iv_value = result.value # add the iv to the array - index should work out intrinsic_value_array[index] = iv_value end # return - return PSResult{Array{Float64,1}}(intrinsic_value_array) end function _build_binary_lattice_underlying_price_array(basePrice::Float64, volatility::Float64, timeToExercise::Float64; numberOfLevels::Int64 = 100)::PSResult # compute up and down perturbations - Δt = (timeToExercise/numberOfLevels) U = exp(volatility * √Δt) D = 1 / U # compute the index array = index_array = _compute_crr_index_array(numberOfLevels); max_element = index_array[end,end] N = index_array[end,1] # compute price array - priceArray = zeros(max_element) priceArray[1] = basePrice for row_index = 1:N # parent index - parent_index = index_array[row_index,1] left_child_index = index_array[row_index,2] right_child_index = index_array[row_index,3] # get the basePrice - basePrice = priceArray[parent_index] # compute the prices - down_price = basePrice*D priceArray[right_child_index] = down_price up_price = basePrice*U priceArray[left_child_index] = up_price end # return the price array - return PSResult{Array{Float64,1}}(priceArray) end function _build_binary_lattice_option_value_array(intrinsicValueArray::Array{Float64,1}, latticeModel::PSBinaryLatticeModel; earlyExcercise::Bool = true, numberOfLevels::Int64 = 100)::PSResult # initialize - contract_price_array = copy(intrinsicValueArray) # get stuff from the lattice model - volatility = latticeModel.volatility timeToExercise = latticeModel.timeToExercise riskFreeRate = latticeModel.riskFreeRate dividendRate = latticeModel.dividendRate # compute up and down perturbations - Δt = (timeToExercise/numberOfLevels) U = exp(volatility * √Δt) D = 1 / U p = (exp((riskFreeRate - dividendRate)*Δt) - D)/(U - D) DF = exp(-riskFreeRate*Δt) # create a index table - index_table = _compute_crr_index_array(numberOfLevels) N = index_table[end,1] # ok, so now lets compute the value for the nodes - for compute_index = 1:N # get the indexs - parent_node_index = index_table[compute_index,1] child_left_index = index_table[compute_index,2] child_right_index = index_table[compute_index,3] # compute - contract_price = DF*(p*contract_price_array[child_left_index]+(1-p)*contract_price_array[child_right_index]) if (earlyExcercise == false) contract_price_array[parent_node_index] = contract_price else excercise_value = contract_price_array[parent_node_index] contract_price_array[parent_node_index] = max(excercise_value,contract_price) end end # setup the results tuple - results_tuple = (option_index_table=index_table, option_contract_price_array=contract_price_array, U=U, D=D, PUP=p, PDOWN=(1-p), DF=DF) # return - return PSResult(results_tuple) end # ----------------------------------------------------------------------------------------------------------- # # --- PUBLIC METHODS ---------------------------------------------------------------------------------------- # function compute_underlying_price_distribution(timeStepIndex::Int64,latticeModel::PSBinaryLatticeModel, baseUnderlyingPrice::Float64, movementFunction::Function)::PooksoftBase.PSResult # initialize - priceDistributionArray = Array{Float64,2}(undef,(timeStepIndex+1), 4) riskFreeRate = latticeModel.riskFreeRate kIndexVector = range(0,stop=timeStepIndex,step=1) |> collect # compute the up and downmove values - (u,d) = movementFunction(latticeModel) # compute the probability p of an *up* move - p = ((1 + riskFreeRate) - d)/(u - d) # main loop - for (index,k) in enumerate(kIndexVector) # compute the price - price = baseUnderlyingPrice*(u^k)*(d^(timeStepIndex - k)) # compute the probability - prob = binomial(timeStepIndex,k)*(p^k)*((1 - p)^(timeStepIndex-k)) # package - priceDistributionArray[index,1] = timeStepIndex priceDistributionArray[index,2] = k priceDistributionArray[index,3] = prob priceDistributionArray[index,4] = price end # return - return PSResult{Array{Float64,2}}(priceDistributionArray) end """ option_contract_price(contractSet::Set{PSAbstractAsset}, latticeModel::PSBinaryLatticeModel, baseUnderlyingPrice::Float64; earlyExercise::Bool = false)::PooksoftBase.PSResult Estimate the price of a contract using a binary lattice pricing model. """ function option_contract_price(contractSet::Set{PSAbstractAsset}, latticeModel::PSBinaryLatticeModel, baseUnderlyingPrice::Float64; earlyExercise::Bool = true)::PooksoftBase.PSResult # initialize - option_contract_price = 0.0 # we need to get some stuff from the lattice model - volatility = latticeModel.volatility timeToExercise = latticeModel.timeToExercise numberOfLevels = latticeModel.numberOfLevels # compute the price array - result = _build_binary_lattice_underlying_price_array(baseUnderlyingPrice, volatility, timeToExercise; numberOfLevels = numberOfLevels) if (isa(result.value,Exception) == true) return result end lattice_price_array = result.value # compute the intrinsic value array - result = _build_binary_lattice_intrinsic_value_array(contractSet,lattice_price_array) if (isa(result.value,Exception) == true) return result end iv_array = result.value # ok, let's build the option value array - result = _build_binary_lattice_option_value_array(iv_array, latticeModel; earlyExcercise = earlyExercise, numberOfLevels = numberOfLevels) if (isa(result.value,Exception) == true) return result end cost_calc_tuple = result.value # create a named tuple and return the results - results_tuple = (lattice_price_array=lattice_price_array, intrinsic_value_array = iv_array, cost_calculation_result=cost_calc_tuple) # return - return PSResult(results_tuple) end # ----------------------------------------------------------------------------------------------------------- #
[ 2, 11420, 4810, 3824, 6158, 337, 36252, 50, 16529, 19351, 6329, 1303, 198, 8818, 4808, 5589, 1133, 62, 6098, 81, 62, 9630, 62, 18747, 7, 17618, 5189, 4971, 82, 3712, 5317, 2414, 8, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1303, 12876, 11, 523, 8781, 1382, 281, 6376, 7177, 532, 198, 220, 220, 220, 1271, 62, 23814, 62, 525, 62, 5715, 796, 47527, 72, 10, 16, 8, 329, 1312, 28, 15, 25, 17618, 5189, 4971, 82, 60, 198, 220, 220, 220, 45218, 62, 18747, 796, 15690, 90, 5317, 2414, 11, 16, 92, 3419, 198, 220, 220, 220, 262, 8326, 796, 657, 198, 220, 220, 220, 329, 1988, 287, 1271, 62, 23814, 62, 525, 62, 5715, 198, 220, 220, 220, 220, 220, 220, 220, 329, 6376, 796, 352, 25, 8367, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 22065, 62, 18747, 11, 1169, 8326, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 262, 8326, 796, 262, 8326, 1343, 352, 198, 220, 220, 220, 886, 628, 220, 220, 220, 399, 796, 2160, 7, 17618, 62, 23814, 62, 525, 62, 5715, 58, 16, 37498, 17618, 5189, 4971, 82, 12, 16, 8, 12962, 198, 220, 220, 220, 6376, 62, 18747, 796, 15690, 90, 5317, 2414, 11, 17, 92, 7, 917, 891, 11, 45, 11, 18, 8, 198, 220, 220, 220, 329, 5752, 62, 9630, 796, 352, 25, 45, 198, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 9630, 62, 18747, 58, 808, 62, 9630, 11, 16, 60, 796, 45218, 62, 18747, 58, 808, 62, 9630, 60, 198, 220, 220, 220, 220, 220, 220, 220, 6376, 62, 18747, 58, 808, 62, 9630, 11, 16, 60, 796, 5752, 62, 9630, 198, 220, 220, 220, 220, 220, 220, 220, 6376, 62, 18747, 58, 808, 62, 9630, 11, 17, 60, 796, 5752, 62, 9630, 1343, 352, 1343, 45218, 62, 18747, 58, 808, 62, 9630, 60, 198, 220, 220, 220, 220, 220, 220, 220, 6376, 62, 18747, 58, 808, 62, 9630, 11, 18, 60, 796, 5752, 62, 9630, 1343, 362, 1343, 45218, 62, 18747, 58, 808, 62, 9630, 60, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1441, 6376, 62, 18747, 198, 437, 198, 198, 8818, 4808, 5589, 1133, 62, 12853, 62, 8800, 49070, 62, 9630, 62, 18747, 7, 17618, 5189, 4971, 82, 3712, 5317, 2414, 8, 628, 220, 220, 220, 1271, 62, 1659, 62, 68, 3639, 796, 357, 17, 61, 7, 5317, 7, 17618, 5189, 4971, 82, 22305, 532, 352, 198, 220, 220, 220, 6376, 62, 18747, 796, 15690, 90, 5317, 2414, 11, 17, 92, 7, 917, 891, 11, 17618, 62, 1659, 62, 68, 3639, 11, 18, 8, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1303, 48040, 262, 6376, 7177, 532, 198, 220, 220, 220, 329, 6376, 796, 352, 25, 17618, 62, 1659, 62, 68, 3639, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 262, 1200, 6376, 82, 532, 198, 220, 220, 220, 220, 220, 220, 220, 1364, 62, 9410, 62, 9630, 796, 362, 9, 7, 9630, 532, 352, 8, 1343, 362, 198, 220, 220, 220, 220, 220, 220, 220, 826, 62, 9410, 62, 9630, 796, 362, 9, 7, 9630, 532, 352, 8, 1343, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 5552, 290, 467, 532, 198, 220, 220, 220, 220, 220, 220, 220, 6376, 62, 18747, 58, 9630, 11, 16, 60, 796, 6376, 198, 220, 220, 220, 220, 220, 220, 220, 6376, 62, 18747, 58, 9630, 11, 17, 60, 796, 1364, 62, 9410, 62, 9630, 198, 220, 220, 220, 220, 220, 220, 220, 6376, 62, 18747, 58, 9630, 11, 18, 60, 796, 826, 62, 9410, 62, 9630, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1303, 1441, 532, 198, 220, 220, 220, 1441, 6376, 62, 18747, 198, 437, 198, 198, 2, 7177, 1912, 532, 198, 8818, 4808, 11249, 62, 39491, 62, 75, 1078, 501, 62, 600, 81, 1040, 291, 62, 8367, 62, 18747, 7, 28484, 7248, 3712, 7248, 90, 3705, 23839, 45869, 5512, 13934, 18124, 19182, 3712, 19182, 90, 43879, 2414, 11, 16, 92, 2599, 25, 3705, 23004, 628, 220, 220, 220, 1303, 41216, 532, 198, 220, 220, 220, 28327, 62, 8367, 62, 18747, 796, 2092, 7, 39491, 18124, 19182, 8, 628, 220, 220, 220, 1303, 12876, 11, 523, 8781, 467, 832, 1123, 2756, 11, 24061, 262, 28327, 1988, 532, 290, 788, 3650, 220, 198, 220, 220, 220, 329, 357, 9630, 11, 20888, 8, 287, 27056, 378, 7, 39491, 18124, 19182, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 12876, 11, 651, 262, 10238, 2756, 532, 198, 220, 220, 220, 220, 220, 220, 220, 10238, 62, 20888, 62, 8367, 796, 13934, 18124, 19182, 58, 9630, 60, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 262, 28327, 1988, 532, 198, 220, 220, 220, 220, 220, 220, 220, 1255, 796, 28327, 62, 8367, 7, 28484, 7248, 11, 4625, 3157, 62, 20888, 62, 8367, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 357, 9160, 7, 20274, 13, 8367, 11, 16922, 8, 6624, 2081, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 1255, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 21628, 62, 8367, 796, 1255, 13, 8367, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 751, 262, 21628, 284, 262, 7177, 532, 6376, 815, 670, 503, 198, 220, 220, 220, 220, 220, 220, 220, 28327, 62, 8367, 62, 18747, 58, 9630, 60, 796, 21628, 62, 8367, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1303, 1441, 532, 198, 220, 220, 220, 1441, 6599, 23004, 90, 19182, 90, 43879, 2414, 11, 16, 11709, 7, 600, 81, 1040, 291, 62, 8367, 62, 18747, 8, 198, 437, 198, 198, 8818, 4808, 11249, 62, 39491, 62, 75, 1078, 501, 62, 4625, 3157, 62, 20888, 62, 18747, 7, 8692, 18124, 3712, 43879, 2414, 11, 30772, 3712, 43879, 2414, 11, 640, 2514, 3109, 23697, 3712, 43879, 2414, 26, 198, 220, 220, 220, 1271, 5189, 4971, 82, 3712, 5317, 2414, 796, 1802, 2599, 25, 3705, 23004, 628, 220, 220, 220, 1303, 24061, 510, 290, 866, 22146, 5945, 602, 532, 198, 220, 220, 220, 37455, 83, 796, 357, 2435, 2514, 3109, 23697, 14, 17618, 5189, 4971, 82, 8, 220, 220, 220, 220, 198, 220, 220, 220, 471, 796, 1033, 7, 10396, 18486, 1635, 18872, 248, 138, 242, 83, 8, 198, 220, 220, 220, 360, 796, 352, 1220, 471, 628, 220, 220, 220, 1303, 24061, 262, 6376, 7177, 796, 198, 220, 220, 220, 6376, 62, 18747, 796, 4808, 5589, 1133, 62, 6098, 81, 62, 9630, 62, 18747, 7, 17618, 5189, 4971, 82, 1776, 198, 220, 220, 220, 3509, 62, 30854, 796, 6376, 62, 18747, 58, 437, 11, 437, 60, 198, 220, 220, 220, 399, 796, 6376, 62, 18747, 58, 437, 11, 16, 60, 628, 220, 220, 220, 1303, 24061, 2756, 7177, 532, 198, 220, 220, 220, 2756, 19182, 796, 1976, 27498, 7, 9806, 62, 30854, 8, 198, 220, 220, 220, 2756, 19182, 58, 16, 60, 796, 2779, 18124, 198, 220, 220, 220, 329, 5752, 62, 9630, 796, 352, 25, 45, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 2560, 6376, 532, 198, 220, 220, 220, 220, 220, 220, 220, 2560, 62, 9630, 796, 6376, 62, 18747, 58, 808, 62, 9630, 11, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1364, 62, 9410, 62, 9630, 796, 6376, 62, 18747, 58, 808, 62, 9630, 11, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 826, 62, 9410, 62, 9630, 796, 6376, 62, 18747, 58, 808, 62, 9630, 11, 18, 60, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 651, 262, 2779, 18124, 532, 198, 220, 220, 220, 220, 220, 220, 220, 2779, 18124, 796, 2756, 19182, 58, 8000, 62, 9630, 60, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 262, 4536, 532, 198, 220, 220, 220, 220, 220, 220, 220, 866, 62, 20888, 796, 2779, 18124, 9, 35, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 19182, 58, 3506, 62, 9410, 62, 9630, 60, 796, 866, 62, 20888, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 510, 62, 20888, 796, 2779, 18124, 9, 52, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 19182, 58, 9464, 62, 9410, 62, 9630, 60, 796, 510, 62, 20888, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1303, 1441, 262, 2756, 7177, 532, 198, 220, 220, 220, 1441, 6599, 23004, 90, 19182, 90, 43879, 2414, 11, 16, 11709, 7, 20888, 19182, 8, 198, 437, 198, 198, 8818, 4808, 11249, 62, 39491, 62, 75, 1078, 501, 62, 18076, 62, 8367, 62, 18747, 7, 600, 81, 1040, 291, 11395, 19182, 3712, 19182, 90, 43879, 2414, 11, 16, 5512, 47240, 501, 17633, 3712, 3705, 33, 3219, 43, 1078, 501, 17633, 26, 220, 198, 220, 220, 220, 1903, 3109, 2189, 37561, 3712, 33, 970, 796, 2081, 11, 1271, 5189, 4971, 82, 3712, 5317, 2414, 796, 1802, 2599, 25, 3705, 23004, 628, 220, 220, 220, 1303, 41216, 532, 198, 220, 220, 220, 2775, 62, 20888, 62, 18747, 796, 4866, 7, 600, 81, 1040, 291, 11395, 19182, 8, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1303, 651, 3404, 422, 262, 47240, 501, 2746, 532, 198, 220, 220, 220, 30772, 796, 47240, 501, 17633, 13, 10396, 18486, 198, 220, 220, 220, 640, 2514, 3109, 23697, 796, 47240, 501, 17633, 13, 2435, 2514, 3109, 23697, 198, 220, 220, 220, 2526, 11146, 32184, 796, 47240, 501, 17633, 13, 19121, 11146, 32184, 198, 220, 220, 220, 30494, 32184, 796, 47240, 501, 17633, 13, 67, 1699, 437, 32184, 628, 220, 220, 220, 1303, 24061, 510, 290, 866, 22146, 5945, 602, 532, 198, 220, 220, 220, 37455, 83, 796, 357, 2435, 2514, 3109, 23697, 14, 17618, 5189, 4971, 82, 8, 220, 220, 220, 198, 220, 220, 220, 471, 796, 1033, 7, 10396, 18486, 1635, 18872, 248, 138, 242, 83, 8, 198, 220, 220, 220, 360, 796, 352, 1220, 471, 198, 220, 220, 220, 279, 796, 357, 11201, 19510, 19121, 11146, 32184, 532, 30494, 32184, 27493, 138, 242, 83, 8, 532, 360, 20679, 7, 52, 532, 360, 8, 198, 220, 220, 220, 36323, 796, 1033, 32590, 19121, 11146, 32184, 9, 138, 242, 83, 8, 628, 220, 220, 220, 1303, 2251, 257, 6376, 3084, 532, 198, 220, 220, 220, 6376, 62, 11487, 796, 4808, 5589, 1133, 62, 6098, 81, 62, 9630, 62, 18747, 7, 17618, 5189, 4971, 82, 8, 198, 220, 220, 220, 399, 796, 6376, 62, 11487, 58, 437, 11, 16, 60, 628, 220, 220, 220, 1303, 12876, 11, 523, 783, 8781, 24061, 262, 1988, 329, 262, 13760, 532, 198, 220, 220, 220, 329, 24061, 62, 9630, 796, 352, 25, 45, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 651, 262, 6376, 82, 532, 198, 220, 220, 220, 220, 220, 220, 220, 2560, 62, 17440, 62, 9630, 796, 6376, 62, 11487, 58, 5589, 1133, 62, 9630, 11, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1200, 62, 9464, 62, 9630, 796, 6376, 62, 11487, 58, 5589, 1133, 62, 9630, 11, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1200, 62, 3506, 62, 9630, 796, 6376, 62, 11487, 58, 5589, 1133, 62, 9630, 11, 18, 60, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 532, 198, 220, 220, 220, 220, 220, 220, 220, 2775, 62, 20888, 796, 36323, 9, 7, 79, 9, 28484, 62, 20888, 62, 18747, 58, 9410, 62, 9464, 62, 9630, 60, 33747, 16, 12, 79, 27493, 28484, 62, 20888, 62, 18747, 58, 9410, 62, 3506, 62, 9630, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 611, 357, 11458, 3109, 2189, 37561, 6624, 3991, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2775, 62, 20888, 62, 18747, 58, 8000, 62, 17440, 62, 9630, 60, 796, 2775, 62, 20888, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 409, 2189, 37561, 62, 8367, 796, 2775, 62, 20888, 62, 18747, 58, 8000, 62, 17440, 62, 9630, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2775, 62, 20888, 62, 18747, 58, 8000, 62, 17440, 62, 9630, 60, 796, 3509, 7, 1069, 2189, 37561, 62, 8367, 11, 28484, 62, 20888, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1303, 9058, 262, 2482, 46545, 532, 198, 220, 220, 220, 2482, 62, 83, 29291, 796, 357, 18076, 62, 9630, 62, 11487, 28, 9630, 62, 11487, 11, 3038, 62, 28484, 62, 20888, 62, 18747, 28, 28484, 62, 20888, 62, 18747, 11, 471, 28, 52, 11, 360, 28, 35, 11, 350, 8577, 28, 79, 11, 14340, 14165, 16193, 16, 12, 79, 828, 36323, 28, 8068, 8, 628, 220, 220, 220, 1303, 1441, 532, 198, 220, 220, 220, 1441, 6599, 23004, 7, 43420, 62, 83, 29291, 8, 198, 437, 198, 2, 16529, 3880, 32284, 1303, 628, 198, 2, 11420, 44731, 337, 36252, 50, 16529, 22369, 1303, 198, 198, 8818, 24061, 62, 4625, 3157, 62, 20888, 62, 17080, 3890, 7, 2435, 8600, 15732, 3712, 5317, 2414, 11, 75, 1078, 501, 17633, 3712, 3705, 33, 3219, 43, 1078, 501, 17633, 11, 2779, 9203, 3157, 18124, 3712, 43879, 2414, 11, 220, 198, 220, 220, 220, 3356, 22203, 3712, 22203, 2599, 25, 47, 566, 4215, 14881, 13, 3705, 23004, 628, 220, 220, 220, 1303, 41216, 532, 198, 220, 220, 220, 2756, 20344, 3890, 19182, 796, 15690, 90, 43879, 2414, 11, 17, 92, 7, 917, 891, 11, 7, 2435, 8600, 15732, 10, 16, 828, 604, 8, 198, 220, 220, 220, 2526, 11146, 32184, 796, 47240, 501, 17633, 13, 19121, 11146, 32184, 198, 220, 220, 220, 479, 15732, 38469, 796, 2837, 7, 15, 11, 11338, 28, 2435, 8600, 15732, 11, 9662, 28, 16, 8, 930, 29, 2824, 628, 220, 220, 220, 1303, 24061, 262, 510, 290, 866, 21084, 3815, 532, 198, 220, 220, 220, 357, 84, 11, 67, 8, 796, 3356, 22203, 7, 75, 1078, 501, 17633, 8, 628, 220, 220, 220, 1303, 24061, 262, 12867, 279, 286, 281, 1635, 929, 9, 1445, 532, 198, 220, 220, 220, 279, 796, 14808, 16, 1343, 2526, 11146, 32184, 8, 532, 288, 20679, 7, 84, 532, 288, 8, 628, 220, 220, 220, 1303, 1388, 9052, 532, 198, 220, 220, 220, 329, 357, 9630, 11, 74, 8, 287, 27056, 378, 7, 74, 15732, 38469, 8, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 262, 2756, 532, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2779, 9203, 3157, 18124, 9, 7, 84, 61, 74, 27493, 7, 67, 61, 7, 2435, 8600, 15732, 532, 479, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 262, 12867, 532, 198, 220, 220, 220, 220, 220, 220, 220, 1861, 796, 9874, 49070, 7, 2435, 8600, 15732, 11, 74, 27493, 7, 79, 61, 74, 27493, 19510, 16, 532, 279, 8, 61, 7, 2435, 8600, 15732, 12, 74, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 5301, 532, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 20344, 3890, 19182, 58, 9630, 11, 16, 60, 796, 640, 8600, 15732, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 20344, 3890, 19182, 58, 9630, 11, 17, 60, 796, 479, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 20344, 3890, 19182, 58, 9630, 11, 18, 60, 796, 1861, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 20344, 3890, 19182, 58, 9630, 11, 19, 60, 796, 2756, 198, 220, 220, 220, 886, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1303, 1441, 532, 198, 220, 220, 220, 1441, 6599, 23004, 90, 19182, 90, 43879, 2414, 11, 17, 11709, 7, 20888, 20344, 3890, 19182, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 3038, 62, 28484, 62, 20888, 7, 28484, 7248, 3712, 7248, 90, 3705, 23839, 45869, 5512, 47240, 501, 17633, 3712, 3705, 33, 3219, 43, 1078, 501, 17633, 11, 2779, 9203, 3157, 18124, 3712, 43879, 2414, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1903, 3109, 23697, 3712, 33, 970, 796, 3991, 2599, 25, 47, 566, 4215, 14881, 13, 3705, 23004, 198, 198, 22362, 1920, 262, 2756, 286, 257, 2775, 1262, 257, 13934, 47240, 501, 13045, 2746, 13, 198, 37811, 198, 8818, 3038, 62, 28484, 62, 20888, 7, 28484, 7248, 3712, 7248, 90, 3705, 23839, 45869, 5512, 47240, 501, 17633, 3712, 3705, 33, 3219, 43, 1078, 501, 17633, 11, 2779, 9203, 3157, 18124, 3712, 43879, 2414, 26, 220, 198, 220, 220, 220, 1903, 3109, 23697, 3712, 33, 970, 796, 2081, 2599, 25, 47, 566, 4215, 14881, 13, 3705, 23004, 628, 220, 220, 220, 1303, 41216, 532, 198, 220, 220, 220, 3038, 62, 28484, 62, 20888, 796, 657, 13, 15, 628, 220, 220, 220, 1303, 356, 761, 284, 651, 617, 3404, 422, 262, 47240, 501, 2746, 532, 198, 220, 220, 220, 30772, 796, 47240, 501, 17633, 13, 10396, 18486, 198, 220, 220, 220, 640, 2514, 3109, 23697, 796, 47240, 501, 17633, 13, 2435, 2514, 3109, 23697, 198, 220, 220, 220, 1271, 5189, 4971, 82, 796, 47240, 501, 17633, 13, 17618, 5189, 4971, 82, 628, 220, 220, 220, 1303, 24061, 262, 2756, 7177, 532, 198, 220, 220, 220, 1255, 796, 4808, 11249, 62, 39491, 62, 75, 1078, 501, 62, 4625, 3157, 62, 20888, 62, 18747, 7, 8692, 9203, 3157, 18124, 11, 30772, 11, 640, 2514, 3109, 23697, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1271, 5189, 4971, 82, 796, 1271, 5189, 4971, 82, 8, 198, 220, 220, 220, 611, 357, 9160, 7, 20274, 13, 8367, 11, 16922, 8, 6624, 2081, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 1255, 198, 220, 220, 220, 886, 198, 220, 220, 220, 47240, 501, 62, 20888, 62, 18747, 796, 1255, 13, 8367, 628, 220, 220, 220, 1303, 24061, 262, 28327, 1988, 7177, 532, 198, 220, 220, 220, 1255, 796, 4808, 11249, 62, 39491, 62, 75, 1078, 501, 62, 600, 81, 1040, 291, 62, 8367, 62, 18747, 7, 28484, 7248, 11, 75, 1078, 501, 62, 20888, 62, 18747, 8, 198, 220, 220, 220, 611, 357, 9160, 7, 20274, 13, 8367, 11, 16922, 8, 6624, 2081, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 1255, 198, 220, 220, 220, 886, 198, 220, 220, 220, 21628, 62, 18747, 796, 1255, 13, 8367, 628, 220, 220, 220, 1303, 12876, 11, 1309, 338, 1382, 262, 3038, 1988, 7177, 532, 198, 220, 220, 220, 1255, 796, 4808, 11249, 62, 39491, 62, 75, 1078, 501, 62, 18076, 62, 8367, 62, 18747, 7, 452, 62, 18747, 11, 47240, 501, 17633, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 1903, 3109, 2189, 37561, 796, 1903, 3109, 23697, 11, 1271, 5189, 4971, 82, 796, 1271, 5189, 4971, 82, 8, 198, 220, 220, 220, 611, 357, 9160, 7, 20274, 13, 8367, 11, 16922, 8, 6624, 2081, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 1255, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1575, 62, 9948, 66, 62, 83, 29291, 796, 1255, 13, 8367, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1303, 2251, 257, 3706, 46545, 290, 1441, 262, 2482, 532, 198, 220, 220, 220, 2482, 62, 83, 29291, 796, 357, 75, 1078, 501, 62, 20888, 62, 18747, 28, 75, 1078, 501, 62, 20888, 62, 18747, 11, 28327, 62, 8367, 62, 18747, 796, 21628, 62, 18747, 11, 1575, 62, 9948, 14902, 62, 20274, 28, 15805, 62, 9948, 66, 62, 83, 29291, 8, 628, 220, 220, 220, 1303, 1441, 532, 198, 220, 220, 220, 1441, 6599, 23004, 7, 43420, 62, 83, 29291, 8, 198, 437, 628, 198, 2, 16529, 3880, 32284, 1303 ]
2.599577
3,309
<reponame>UnofficialJuliaMirror/Merlin.jl-80f3d04f-b880-5e6d-8e06-6a7e799169ac<gh_stars>100-1000 export pack, unpack function pack(xs::Vector{Var}; pad=0) T = eltype(xs[1]) N = ndims(xs[1]) maxdims = zeros(Int, N) for x in xs s = size(x) for i = 1:N maxdims[i] < s[i] && (maxdims[i] = s[i]) end end y = fill(T(pad), maxdims..., length(xs)) st = stride(y, N+1) yi = 1 for x in xs copyto!(y, yi, x.data, 1) yi += st end Var(y, (pack,xs)) end pack(x::Node) = Node(pack, x) function unpack(x::A, sizes::Vector) where A ys = map(A, sizes) for i = 1:length(sizes) ys[i] = x[s...,i] end ys end
[ 27, 7856, 261, 480, 29, 3118, 16841, 16980, 544, 27453, 1472, 14, 13102, 2815, 13, 20362, 12, 1795, 69, 18, 67, 3023, 69, 12, 65, 41655, 12, 20, 68, 21, 67, 12, 23, 68, 3312, 12, 21, 64, 22, 68, 45455, 22172, 330, 27, 456, 62, 30783, 29, 3064, 12, 12825, 198, 39344, 2353, 11, 555, 8002, 198, 198, 8818, 2353, 7, 34223, 3712, 38469, 90, 19852, 19629, 14841, 28, 15, 8, 198, 220, 220, 220, 309, 796, 1288, 4906, 7, 34223, 58, 16, 12962, 198, 220, 220, 220, 399, 796, 299, 67, 12078, 7, 34223, 58, 16, 12962, 198, 220, 220, 220, 3509, 67, 12078, 796, 1976, 27498, 7, 5317, 11, 399, 8, 198, 220, 220, 220, 329, 2124, 287, 2124, 82, 198, 220, 220, 220, 220, 220, 220, 220, 264, 796, 2546, 7, 87, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 796, 352, 25, 45, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3509, 67, 12078, 58, 72, 60, 1279, 264, 58, 72, 60, 11405, 357, 9806, 67, 12078, 58, 72, 60, 796, 264, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 331, 796, 6070, 7, 51, 7, 15636, 828, 3509, 67, 12078, 986, 11, 4129, 7, 34223, 4008, 198, 220, 220, 220, 336, 796, 33769, 7, 88, 11, 399, 10, 16, 8, 198, 220, 220, 220, 331, 72, 796, 352, 198, 220, 220, 220, 329, 2124, 287, 2124, 82, 198, 220, 220, 220, 220, 220, 220, 220, 4866, 1462, 0, 7, 88, 11, 331, 72, 11, 2124, 13, 7890, 11, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 331, 72, 15853, 336, 198, 220, 220, 220, 886, 198, 220, 220, 220, 12372, 7, 88, 11, 357, 8002, 11, 34223, 4008, 198, 437, 198, 8002, 7, 87, 3712, 19667, 8, 796, 19081, 7, 8002, 11, 2124, 8, 198, 198, 8818, 555, 8002, 7, 87, 3712, 32, 11, 10620, 3712, 38469, 8, 810, 317, 198, 220, 220, 220, 331, 82, 796, 3975, 7, 32, 11, 10620, 8, 198, 220, 220, 220, 329, 1312, 796, 352, 25, 13664, 7, 82, 4340, 8, 198, 220, 220, 220, 220, 220, 220, 220, 331, 82, 58, 72, 60, 796, 2124, 58, 82, 986, 11, 72, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 331, 82, 198, 437, 198 ]
1.775
400
<filename>AutomotiveDrivingModels/hdCSX/src/1d/definitions.jl<gh_stars>1-10 baremodule AgentClass const MOTORCYCLE = 1 const CAR = 2 const TRUCK = 3 const PEDESTRIAN = 4 end """ Vehicle definition which contains a class and a bounding box. """ struct VehicleDef class::Int64 # ∈ AgentClass length::Float64 width::Float64 end function VehicleDef(; class::Int=AgentClass.CAR, length::Float64=4.0, width::Float64=1.8, ) VehicleDef(class, length, width) end const NULL_VEHICLEDEF = VehicleDef(AgentClass.CAR, NaN, NaN) function Base.show(io::IO, d::VehicleDef) class = d.class == AgentClass.CAR ? "CAR" : d.class == AgentClass.MOTORCYCLE ? "MOTORCYCLE" : d.class == AgentClass.TRUCK ? "TRUCK" : d.class == AgentClass.PEDESTRIAN ? "PEDESTRIAN" : "UNKNOWN" @printf(io, "VehicleDef(%s, %.3f, %.3f)", class, d.length, d.width) end Base.write(io::IO, ::MIME"text/plain", def::VehicleDef) = @printf(io, "%d %.16e %.16e", def.class, def.length, def.width) function Base.read(io::IO, ::MIME"text/plain", ::Type{VehicleDef}) tokens = split(strip(readline(io)), ' ') class = parse(Int, tokens[1]) length = parse(Float64, tokens[2]) width = parse(Float64, tokens[3]) return VehicleDef(class, length, width) end
[ 27, 34345, 29, 38062, 19138, 20564, 1075, 5841, 1424, 14, 31298, 7902, 55, 14, 10677, 14, 16, 67, 14, 4299, 50101, 13, 20362, 27, 456, 62, 30783, 29, 16, 12, 940, 198, 49382, 21412, 15906, 9487, 198, 220, 220, 220, 1500, 42982, 1581, 34, 56, 29931, 796, 352, 198, 220, 220, 220, 1500, 17368, 220, 220, 220, 220, 220, 220, 220, 796, 362, 198, 220, 220, 220, 1500, 7579, 16696, 220, 220, 220, 220, 220, 796, 513, 198, 220, 220, 220, 1500, 350, 1961, 1546, 5446, 16868, 796, 604, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 21501, 6770, 543, 4909, 257, 1398, 290, 257, 5421, 278, 3091, 13, 198, 37811, 198, 7249, 21501, 7469, 198, 220, 220, 220, 1398, 3712, 5317, 2414, 1303, 18872, 230, 15906, 9487, 198, 220, 220, 220, 4129, 3712, 43879, 2414, 198, 220, 220, 220, 9647, 3712, 43879, 2414, 198, 437, 198, 8818, 21501, 7469, 7, 26, 198, 220, 220, 220, 1398, 3712, 5317, 28, 36772, 9487, 13, 20034, 11, 198, 220, 220, 220, 4129, 3712, 43879, 2414, 28, 19, 13, 15, 11, 198, 220, 220, 220, 9647, 3712, 43879, 2414, 28, 16, 13, 23, 11, 198, 220, 220, 220, 1267, 628, 220, 220, 220, 21501, 7469, 7, 4871, 11, 4129, 11, 9647, 8, 198, 437, 198, 198, 9979, 15697, 62, 6089, 39, 2149, 30465, 25425, 796, 21501, 7469, 7, 36772, 9487, 13, 20034, 11, 11013, 45, 11, 11013, 45, 8, 198, 198, 8818, 7308, 13, 12860, 7, 952, 3712, 9399, 11, 288, 3712, 37870, 1548, 7469, 8, 198, 220, 220, 220, 1398, 796, 288, 13, 4871, 6624, 15906, 9487, 13, 20034, 5633, 366, 20034, 1, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 13, 4871, 6624, 15906, 9487, 13, 44, 2394, 1581, 34, 56, 29931, 5633, 366, 44, 2394, 1581, 34, 56, 29931, 1, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 13, 4871, 6624, 15906, 9487, 13, 5446, 16696, 5633, 366, 5446, 16696, 1, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 13, 4871, 6624, 15906, 9487, 13, 47, 1961, 1546, 5446, 16868, 5633, 366, 47, 1961, 1546, 5446, 16868, 1, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 4944, 44706, 1, 198, 220, 220, 220, 2488, 37435, 7, 952, 11, 366, 37870, 1548, 7469, 7, 4, 82, 11, 4064, 13, 18, 69, 11, 4064, 13, 18, 69, 42501, 1398, 11, 288, 13, 13664, 11, 288, 13, 10394, 8, 198, 437, 198, 14881, 13, 13564, 7, 952, 3712, 9399, 11, 7904, 44, 12789, 1, 5239, 14, 25638, 1600, 825, 3712, 37870, 1548, 7469, 8, 796, 2488, 37435, 7, 952, 11, 36521, 67, 4064, 13, 1433, 68, 4064, 13, 1433, 68, 1600, 825, 13, 4871, 11, 825, 13, 13664, 11, 825, 13, 10394, 8, 198, 8818, 7308, 13, 961, 7, 952, 3712, 9399, 11, 7904, 44, 12789, 1, 5239, 14, 25638, 1600, 7904, 6030, 90, 37870, 1548, 7469, 30072, 198, 220, 220, 220, 16326, 796, 6626, 7, 36311, 7, 961, 1370, 7, 952, 36911, 705, 705, 8, 198, 220, 220, 220, 1398, 796, 21136, 7, 5317, 11, 16326, 58, 16, 12962, 198, 220, 220, 220, 4129, 796, 21136, 7, 43879, 2414, 11, 16326, 58, 17, 12962, 198, 220, 220, 220, 9647, 796, 21136, 7, 43879, 2414, 11, 16326, 58, 18, 12962, 198, 220, 220, 220, 1441, 21501, 7469, 7, 4871, 11, 4129, 11, 9647, 8, 198, 437 ]
2.336842
570
#= To improve: -Only one possible best alignment calculated... Revise so that all possible alignments are calculated -Improve speed -More user input options? =# using ArgParse cli = ArgParseSettings() @add_arg_table cli begin "--match" help = "match score" arg_type = Int default = 1 "--mismatch" help = "mismatch score" arg_type = Int default = -1 "--gap" help = "gap score" arg_type = Int default = -1 end arg = parse_args(ARGS, cli) seq1 = "AGGTCC" seq2 = "AGTTC" match = arg["match"] mismatch = arg["mismatch"] gap = arg["gap"] function solvenw(seq_1, seq_2, match, mismatch, gap) #Info println("""seq1: $(seq1) seq2: $(seq2) """) println(""" match score = $(match) mismatch score = $(mismatch) gap score = $(gap) """) #Initializing Matrix seq1_length = sizeof(seq1) seq2_length = sizeof(seq2) workspace = fill(0,(seq1_length+1,seq2_length+1)) #Initialization for i in 2:seq1_length+1, j in 2:seq2_length+1 workspace[i,1] = workspace[i-1,1]+gap workspace[1,j] = workspace[1,j-1]+gap end #Fill for i in 2:seq1_length+1 for j in 2:seq2_length+1 left_gap = workspace[i,j-1]+gap top_gap = workspace[i-1,j]+gap if seq1[i-1] == seq2[j-1] match_mismatch = workspace[i-1,j-1]+match else match_mismatch = workspace[i-1,j-1]+mismatch end workspace[i,j]=max(left_gap,top_gap,match_mismatch) end end #Display println("Matrix: ") display(workspace) #Trace Back x = seq1_length+1 y = seq2_length+1 traceback = String[] score = 0 while x!=1 trace_gap = workspace[x,y] - gap if seq1[x-1] == seq2[y-1] trace_diagnal = workspace[x,y] - match local_mm = match else trace_diagnal = workspace[x,y] - mismatch local_mm = mismatch end if trace_diagnal == workspace[x-1,y-1] push!(traceback, "match/mismatch") x = x-1 y = y-1 score += local_mm elseif trace_gap == workspace[x,y-1] push!(traceback,"left_gap") y = y-1 score += gap elseif trace_gap == workspace[x-1,y] push!(traceback,"top_gap") x = x-1 score += gap end end println("\r", traceback) aligned_seq1 = "" aligned_seq2 = "" counter_seq1 = 1 counter_seq2 = 1 for i in length(traceback):-1:1 if traceback[i] == "match/mismatch" aligned_seq1 *= seq1[counter_seq1] aligned_seq2 *= seq2[counter_seq2] counter_seq1 += 1 counter_seq2 += 1 elseif traceback[i] == "left_gap" aligned_seq1 *= '-' aligned_seq2 *= seq2[counter_seq2] counter_seq2 += 1 elseif traceback[i] == "top_gap" aligned_seq2 *= '-' aligned_seq1 *= seq1[counter_seq1] counter_seq1 +=1 end end println(aligned_seq1) println(aligned_seq2) #Score println("score = $(score)") end solvenw(seq1, seq2, match, mismatch, gap)
[ 2, 28, 198, 2514, 2987, 25, 198, 12, 10049, 530, 1744, 1266, 19114, 10488, 986, 5416, 786, 523, 326, 477, 1744, 10548, 902, 389, 10488, 198, 12, 47531, 2866, 198, 12, 5167, 2836, 5128, 3689, 30, 198, 46249, 198, 3500, 20559, 10044, 325, 198, 198, 44506, 796, 20559, 10044, 325, 26232, 3419, 198, 31, 2860, 62, 853, 62, 11487, 537, 72, 2221, 198, 197, 1, 438, 15699, 1, 198, 197, 197, 16794, 796, 366, 15699, 4776, 1, 198, 197, 197, 853, 62, 4906, 796, 2558, 198, 197, 197, 12286, 796, 352, 198, 197, 1, 438, 76, 1042, 963, 1, 198, 197, 197, 16794, 796, 366, 76, 1042, 963, 4776, 1, 198, 197, 197, 853, 62, 4906, 796, 2558, 198, 197, 197, 12286, 796, 532, 16, 198, 197, 1, 438, 43554, 1, 197, 198, 197, 197, 16794, 796, 366, 43554, 4776, 1, 198, 197, 197, 853, 62, 4906, 796, 2558, 198, 197, 197, 12286, 796, 532, 16, 198, 437, 198, 853, 796, 21136, 62, 22046, 7, 1503, 14313, 11, 537, 72, 8, 198, 198, 41068, 16, 796, 366, 4760, 19555, 4093, 1, 198, 41068, 17, 796, 366, 4760, 51, 4825, 1, 198, 198, 15699, 796, 1822, 14692, 15699, 8973, 198, 76, 1042, 963, 796, 1822, 14692, 76, 1042, 963, 8973, 198, 43554, 796, 1822, 14692, 43554, 8973, 198, 198, 8818, 1540, 574, 86, 7, 41068, 62, 16, 11, 33756, 62, 17, 11, 2872, 11, 46318, 11, 7625, 8, 198, 197, 2, 12360, 198, 197, 198, 197, 198, 197, 35235, 7203, 15931, 41068, 16, 25, 29568, 41068, 16, 8, 198, 197, 197, 41068, 17, 25, 29568, 41068, 17, 8, 198, 197, 197, 15931, 4943, 628, 197, 35235, 7203, 15931, 198, 197, 197, 15699, 4776, 796, 29568, 15699, 8, 198, 197, 197, 76, 1042, 963, 4776, 796, 29568, 76, 1042, 963, 8, 198, 197, 197, 43554, 4776, 796, 29568, 43554, 8, 198, 197, 197, 15931, 4943, 198, 197, 198, 197, 2, 24243, 2890, 24936, 220, 198, 197, 41068, 16, 62, 13664, 796, 39364, 7, 41068, 16, 8, 198, 197, 41068, 17, 62, 13664, 796, 39364, 7, 41068, 17, 8, 628, 197, 5225, 10223, 796, 6070, 7, 15, 11, 7, 41068, 16, 62, 13664, 10, 16, 11, 41068, 17, 62, 13664, 10, 16, 4008, 628, 197, 2, 24243, 1634, 198, 197, 1640, 1312, 287, 362, 25, 41068, 16, 62, 13664, 10, 16, 11, 474, 287, 362, 25, 41068, 17, 62, 13664, 10, 16, 198, 197, 197, 5225, 10223, 58, 72, 11, 16, 60, 796, 44573, 58, 72, 12, 16, 11, 16, 48688, 43554, 198, 197, 197, 5225, 10223, 58, 16, 11, 73, 60, 796, 44573, 58, 16, 11, 73, 12, 16, 48688, 43554, 198, 197, 437, 198, 197, 198, 197, 2, 33762, 198, 197, 1640, 1312, 287, 362, 25, 41068, 16, 62, 13664, 10, 16, 198, 197, 197, 1640, 474, 287, 362, 25, 41068, 17, 62, 13664, 10, 16, 198, 197, 197, 197, 9464, 62, 43554, 796, 44573, 58, 72, 11, 73, 12, 16, 48688, 43554, 198, 197, 197, 197, 4852, 62, 43554, 796, 44573, 58, 72, 12, 16, 11, 73, 48688, 43554, 198, 197, 197, 197, 361, 33756, 16, 58, 72, 12, 16, 60, 6624, 33756, 17, 58, 73, 12, 16, 60, 198, 197, 197, 197, 197, 15699, 62, 76, 1042, 963, 796, 44573, 58, 72, 12, 16, 11, 73, 12, 16, 48688, 15699, 198, 197, 197, 197, 17772, 198, 197, 197, 197, 197, 15699, 62, 76, 1042, 963, 796, 44573, 58, 72, 12, 16, 11, 73, 12, 16, 48688, 76, 1042, 963, 198, 197, 197, 197, 437, 198, 197, 197, 197, 5225, 10223, 58, 72, 11, 73, 22241, 9806, 7, 9464, 62, 43554, 11, 4852, 62, 43554, 11, 15699, 62, 76, 1042, 963, 8, 198, 197, 197, 437, 198, 197, 437, 198, 197, 198, 197, 2, 23114, 198, 197, 35235, 7203, 46912, 25, 366, 8, 198, 197, 13812, 7, 5225, 10223, 8, 198, 197, 198, 197, 2, 2898, 558, 5157, 198, 197, 87, 796, 33756, 16, 62, 13664, 10, 16, 198, 197, 88, 796, 33756, 17, 62, 13664, 10, 16, 198, 197, 198, 197, 198, 197, 40546, 1891, 796, 10903, 21737, 198, 197, 26675, 796, 657, 220, 198, 197, 4514, 2124, 0, 28, 16, 198, 197, 197, 40546, 62, 43554, 796, 44573, 58, 87, 11, 88, 60, 532, 7625, 198, 197, 197, 361, 33756, 16, 58, 87, 12, 16, 60, 6624, 33756, 17, 58, 88, 12, 16, 60, 198, 197, 197, 197, 40546, 62, 47356, 282, 796, 44573, 58, 87, 11, 88, 60, 532, 2872, 198, 197, 197, 197, 12001, 62, 3020, 796, 2872, 198, 197, 197, 17772, 198, 197, 197, 197, 40546, 62, 47356, 282, 796, 44573, 58, 87, 11, 88, 60, 532, 46318, 198, 197, 197, 197, 12001, 62, 3020, 796, 46318, 198, 197, 197, 437, 628, 198, 197, 197, 361, 12854, 62, 47356, 282, 6624, 44573, 58, 87, 12, 16, 11, 88, 12, 16, 60, 198, 197, 197, 197, 14689, 0, 7, 40546, 1891, 11, 366, 15699, 14, 76, 1042, 963, 4943, 198, 197, 197, 197, 87, 796, 2124, 12, 16, 198, 197, 197, 197, 88, 796, 331, 12, 16, 198, 197, 197, 197, 26675, 15853, 1957, 62, 3020, 198, 197, 197, 17772, 361, 12854, 62, 43554, 6624, 44573, 58, 87, 11, 88, 12, 16, 60, 198, 197, 197, 197, 14689, 0, 7, 40546, 1891, 553, 9464, 62, 43554, 4943, 198, 197, 197, 197, 88, 796, 331, 12, 16, 198, 197, 197, 197, 26675, 15853, 7625, 198, 197, 197, 17772, 361, 12854, 62, 43554, 6624, 44573, 58, 87, 12, 16, 11, 88, 60, 198, 197, 197, 197, 14689, 0, 7, 40546, 1891, 553, 4852, 62, 43554, 4943, 198, 197, 197, 197, 87, 796, 2124, 12, 16, 198, 197, 197, 197, 26675, 15853, 7625, 198, 197, 197, 437, 198, 197, 437, 198, 197, 198, 197, 35235, 7203, 59, 81, 1600, 12854, 1891, 8, 628, 197, 41634, 62, 41068, 16, 796, 13538, 198, 197, 41634, 62, 41068, 17, 796, 13538, 198, 197, 24588, 62, 41068, 16, 796, 352, 198, 197, 24588, 62, 41068, 17, 796, 352, 198, 197, 198, 197, 1640, 1312, 287, 4129, 7, 40546, 1891, 2599, 12, 16, 25, 16, 198, 197, 197, 361, 12854, 1891, 58, 72, 60, 6624, 366, 15699, 14, 76, 1042, 963, 1, 198, 197, 197, 197, 41634, 62, 41068, 16, 1635, 28, 33756, 16, 58, 24588, 62, 41068, 16, 60, 198, 197, 197, 197, 41634, 62, 41068, 17, 1635, 28, 33756, 17, 58, 24588, 62, 41068, 17, 60, 198, 197, 197, 197, 24588, 62, 41068, 16, 15853, 352, 198, 197, 197, 197, 24588, 62, 41068, 17, 15853, 352, 198, 197, 197, 17772, 361, 12854, 1891, 58, 72, 60, 6624, 366, 9464, 62, 43554, 1, 198, 197, 197, 197, 41634, 62, 41068, 16, 1635, 28, 705, 19355, 198, 197, 197, 197, 41634, 62, 41068, 17, 1635, 28, 33756, 17, 58, 24588, 62, 41068, 17, 60, 198, 197, 197, 197, 24588, 62, 41068, 17, 15853, 352, 198, 197, 197, 17772, 361, 12854, 1891, 58, 72, 60, 6624, 366, 4852, 62, 43554, 1, 198, 197, 197, 197, 41634, 62, 41068, 17, 1635, 28, 705, 19355, 198, 197, 197, 197, 41634, 62, 41068, 16, 1635, 28, 33756, 16, 58, 24588, 62, 41068, 16, 60, 198, 197, 197, 197, 24588, 62, 41068, 16, 15853, 16, 198, 197, 197, 437, 198, 197, 437, 198, 197, 198, 197, 35235, 7, 41634, 62, 41068, 16, 8, 198, 197, 35235, 7, 41634, 62, 41068, 17, 8, 198, 197, 198, 197, 2, 26595, 198, 197, 35235, 7203, 26675, 796, 29568, 26675, 8, 4943, 198, 197, 198, 197, 198, 437, 628, 198, 34453, 574, 86, 7, 41068, 16, 11, 33756, 17, 11, 2872, 11, 46318, 11, 7625, 8, 628, 628, 628 ]
2.181675
1,266
using Test using UAPIC using FFTW using LinearAlgebra include("test_efd.jl") include("test_poisson.jl") include("test_particles.jl") include("bupdate.jl")
[ 3500, 6208, 198, 3500, 471, 2969, 2149, 198, 3500, 376, 9792, 54, 198, 3500, 44800, 2348, 29230, 198, 198, 17256, 7203, 9288, 62, 891, 67, 13, 20362, 4943, 198, 17256, 7203, 9288, 62, 7501, 30927, 13, 20362, 4943, 198, 17256, 7203, 9288, 62, 3911, 2983, 13, 20362, 4943, 198, 17256, 7203, 65, 19119, 13, 20362, 4943, 628 ]
2.754386
57
module ArrowTypes export ArrowType, NullType, PrimitiveType, ListType, FixedSizeListType, MapType, StructType, UnionType, DictEncodedType abstract type ArrowType end ArrowType(x::T) where {T} = ArrowType(T) ArrowType(::Type{T}) where {T} = isprimitivetype(T) ? PrimitiveType() : StructType() function arrowconvert end arrowconvert(T, x) = convert(T, x) arrowconvert(::Type{Union{T, Missing}}, x) where {T} = arrowconvert(T, x) arrowconvert(::Type{Union{T, Missing}}, ::Missing) where {T} = missing struct NullType <: ArrowType end ArrowType(::Type{Missing}) = NullType() struct PrimitiveType <: ArrowType end ArrowType(::Type{<:Integer}) = PrimitiveType() ArrowType(::Type{<:AbstractFloat}) = PrimitiveType() ArrowType(::Type{Bool}) = PrimitiveType() struct ListType <: ArrowType end isstringtype(T) = false isstringtype(::Type{Union{T, Missing}}) where {T} = isstringtype(T) ArrowType(::Type{<:AbstractString}) = ListType() isstringtype(::Type{<:AbstractString}) = true ArrowType(::Type{Symbol}) = ListType() isstringtype(::Type{Symbol}) = true arrowconvert(::Type{Symbol}, x::String) = Symbol(x) arrowconvert(::Type{String}, x::Symbol) = String(x) ArrowType(::Type{<:AbstractArray}) = ListType() struct FixedSizeListType <: ArrowType end ArrowType(::Type{NTuple{N, T}}) where {N, T} = FixedSizeListType() getsize(::Type{NTuple{N, T}}) where {N, T} = N struct MapType <: ArrowType end ArrowType(::Type{<:Dict}) = MapType() struct StructType <: ArrowType end ArrowType(::Type{<:NamedTuple}) = StructType() @enum STRUCT_TYPES NAMEDTUPLE STRUCT # KEYWORDARGS structtype(::Type{NamedTuple{N, T}}) where {N, T} = NAMEDTUPLE structtype(::Type{T}) where {T} = STRUCT struct UnionType <: ArrowType end ArrowType(::Union) = UnionType() struct DictEncodedType <: ArrowType end """ There are a couple places when writing arrow buffers where we need to write a "dummy" value; it doesn't really matter what we write, but we need to write something of a specific type. So each supported writing type needs to define `default`. """ function default end default(T) = zero(T) default(::Type{Symbol}) = Symbol() default(::Type{Char}) = '\0' default(::Type{String}) = "" function default(::Type{A}) where {A <: AbstractVector{T}} where {T} a = similar(A, 1) a[1] = default(T) return a end default(::Type{NTuple{N, T}}) where {N, T} = ntuple(i -> default(T), N) default(::Type{T}) where {T <: Tuple} = Tuple(default(fieldtype(T, i)) for i = 1:fieldcount(T)) default(::Type{Dict{K, V}}) where {K, V} = Dict{K, V}() default(::Type{NamedTuple{names, types}}) where {names, types} = NamedTuple{names}(Tuple(default(fieldtype(types, i)) for i = 1:length(names))) const JULIA_TO_ARROW_TYPE_MAPPING = Dict{Type, Tuple{String, Type}}( Char => ("JuliaLang.Char", UInt32), Symbol => ("JuliaLang.Symbol", String), ) istyperegistered(::Type{T}) where {T} = haskey(JULIA_TO_ARROW_TYPE_MAPPING, T) function getarrowtype!(meta, ::Type{T}) where {T} arrowname, arrowtype = JULIA_TO_ARROW_TYPE_MAPPING[T] meta["ARROW:extension:name"] = arrowname meta["ARROW:extension:metadata"] = "" return arrowtype end const ARROW_TO_JULIA_TYPE_MAPPING = Dict{String, Tuple{Type, Type}}( "JuliaLang.Char" => (Char, UInt32), "JuliaLang.Symbol" => (Symbol, String), ) function extensiontype(meta) if haskey(meta, "ARROW:extension:name") typename = meta["ARROW:extension:name"] if haskey(ARROW_TO_JULIA_TYPE_MAPPING, typename) return ARROW_TO_JULIA_TYPE_MAPPING[typename][1] else @warn "unsupported ARROW:extension:name type: \"$typename\"" end end return nothing end function registertype!(juliatype::Type, arrowtype::Type, arrowname::String=string("JuliaLang.", string(juliatype))) # TODO: validate that juliatype isn't already default arrow type JULIA_TO_ARROW_TYPE_MAPPING[juliatype] = (arrowname, arrowtype) ARROW_TO_JULIA_TYPE_MAPPING[arrowname] = (juliatype, arrowtype) return end end # module ArrowTypes
[ 21412, 19408, 31431, 198, 198, 39344, 19408, 6030, 11, 35886, 6030, 11, 11460, 1800, 6030, 11, 7343, 6030, 11, 10832, 10699, 8053, 6030, 11, 9347, 6030, 11, 32112, 6030, 11, 4479, 6030, 11, 360, 713, 27195, 9043, 6030, 198, 198, 397, 8709, 2099, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 87, 3712, 51, 8, 810, 1391, 51, 92, 796, 19408, 6030, 7, 51, 8, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 51, 30072, 810, 1391, 51, 92, 796, 318, 19795, 1800, 4906, 7, 51, 8, 5633, 11460, 1800, 6030, 3419, 1058, 32112, 6030, 3419, 198, 198, 8818, 15452, 1102, 1851, 886, 198, 198, 6018, 1102, 1851, 7, 51, 11, 2124, 8, 796, 10385, 7, 51, 11, 2124, 8, 198, 6018, 1102, 1851, 7, 3712, 6030, 90, 38176, 90, 51, 11, 25639, 92, 5512, 2124, 8, 810, 1391, 51, 92, 796, 15452, 1102, 1851, 7, 51, 11, 2124, 8, 198, 6018, 1102, 1851, 7, 3712, 6030, 90, 38176, 90, 51, 11, 25639, 92, 5512, 7904, 43730, 8, 810, 1391, 51, 92, 796, 4814, 198, 198, 7249, 35886, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 43730, 30072, 796, 35886, 6030, 3419, 198, 198, 7249, 11460, 1800, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 27, 25, 46541, 30072, 796, 11460, 1800, 6030, 3419, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 27, 25, 23839, 43879, 30072, 796, 11460, 1800, 6030, 3419, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 33, 970, 30072, 796, 11460, 1800, 6030, 3419, 198, 198, 7249, 7343, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 271, 8841, 4906, 7, 51, 8, 796, 3991, 198, 271, 8841, 4906, 7, 3712, 6030, 90, 38176, 90, 51, 11, 25639, 11709, 8, 810, 1391, 51, 92, 796, 318, 8841, 4906, 7, 51, 8, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 27, 25, 23839, 10100, 30072, 796, 7343, 6030, 3419, 198, 271, 8841, 4906, 7, 3712, 6030, 90, 27, 25, 23839, 10100, 30072, 796, 2081, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 13940, 23650, 30072, 796, 7343, 6030, 3419, 198, 271, 8841, 4906, 7, 3712, 6030, 90, 13940, 23650, 30072, 796, 2081, 198, 6018, 1102, 1851, 7, 3712, 6030, 90, 13940, 23650, 5512, 2124, 3712, 10100, 8, 796, 38357, 7, 87, 8, 198, 6018, 1102, 1851, 7, 3712, 6030, 90, 10100, 5512, 2124, 3712, 13940, 23650, 8, 796, 10903, 7, 87, 8, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 27, 25, 23839, 19182, 30072, 796, 7343, 6030, 3419, 198, 198, 7249, 10832, 10699, 8053, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 11251, 29291, 90, 45, 11, 309, 11709, 8, 810, 1391, 45, 11, 309, 92, 796, 10832, 10699, 8053, 6030, 3419, 198, 11407, 1096, 7, 3712, 6030, 90, 11251, 29291, 90, 45, 11, 309, 11709, 8, 810, 1391, 45, 11, 309, 92, 796, 399, 198, 198, 7249, 9347, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 27, 25, 35, 713, 30072, 796, 9347, 6030, 3419, 198, 198, 7249, 32112, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 3712, 6030, 90, 27, 25, 45, 2434, 51, 29291, 30072, 796, 32112, 6030, 3419, 198, 198, 31, 44709, 19269, 18415, 62, 9936, 47, 1546, 399, 2390, 1961, 51, 8577, 2538, 19269, 18415, 1303, 35374, 54, 12532, 1503, 14313, 198, 198, 7249, 4906, 7, 3712, 6030, 90, 45, 2434, 51, 29291, 90, 45, 11, 309, 11709, 8, 810, 1391, 45, 11, 309, 92, 796, 399, 2390, 1961, 51, 8577, 2538, 198, 7249, 4906, 7, 3712, 6030, 90, 51, 30072, 810, 1391, 51, 92, 796, 19269, 18415, 198, 198, 7249, 4479, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 3163, 808, 6030, 7, 3712, 38176, 8, 796, 4479, 6030, 3419, 198, 198, 7249, 360, 713, 27195, 9043, 6030, 1279, 25, 19408, 6030, 886, 198, 198, 37811, 198, 1858, 389, 257, 3155, 4113, 618, 3597, 15452, 39334, 810, 198, 732, 761, 284, 3551, 257, 366, 67, 13513, 1, 1988, 26, 340, 1595, 470, 1107, 2300, 198, 10919, 356, 3551, 11, 475, 356, 761, 284, 3551, 1223, 286, 257, 2176, 198, 4906, 13, 1406, 1123, 4855, 3597, 2099, 2476, 284, 8160, 4600, 12286, 44646, 198, 37811, 198, 8818, 4277, 886, 198, 198, 12286, 7, 51, 8, 796, 6632, 7, 51, 8, 198, 12286, 7, 3712, 6030, 90, 13940, 23650, 30072, 796, 38357, 3419, 198, 12286, 7, 3712, 6030, 90, 12441, 30072, 796, 705, 59, 15, 6, 198, 12286, 7, 3712, 6030, 90, 10100, 30072, 796, 13538, 198, 198, 8818, 4277, 7, 3712, 6030, 90, 32, 30072, 810, 1391, 32, 1279, 25, 27741, 38469, 90, 51, 11709, 810, 1391, 51, 92, 198, 220, 220, 220, 257, 796, 2092, 7, 32, 11, 352, 8, 198, 220, 220, 220, 257, 58, 16, 60, 796, 4277, 7, 51, 8, 198, 220, 220, 220, 1441, 257, 198, 437, 198, 198, 12286, 7, 3712, 6030, 90, 11251, 29291, 90, 45, 11, 309, 11709, 8, 810, 1391, 45, 11, 309, 92, 796, 299, 83, 29291, 7, 72, 4613, 4277, 7, 51, 828, 399, 8, 198, 12286, 7, 3712, 6030, 90, 51, 30072, 810, 1391, 51, 1279, 25, 309, 29291, 92, 796, 309, 29291, 7, 12286, 7, 3245, 4906, 7, 51, 11, 1312, 4008, 329, 1312, 796, 352, 25, 3245, 9127, 7, 51, 4008, 198, 12286, 7, 3712, 6030, 90, 35, 713, 90, 42, 11, 569, 11709, 8, 810, 1391, 42, 11, 569, 92, 796, 360, 713, 90, 42, 11, 569, 92, 3419, 198, 12286, 7, 3712, 6030, 90, 45, 2434, 51, 29291, 90, 14933, 11, 3858, 11709, 8, 810, 1391, 14933, 11, 3858, 92, 796, 34441, 51, 29291, 90, 14933, 92, 7, 51, 29291, 7, 12286, 7, 3245, 4906, 7, 19199, 11, 1312, 4008, 329, 1312, 796, 352, 25, 13664, 7, 14933, 22305, 198, 198, 9979, 49349, 3539, 62, 10468, 62, 26465, 3913, 62, 25216, 62, 44, 24805, 2751, 796, 360, 713, 90, 6030, 11, 309, 29291, 90, 10100, 11, 5994, 11709, 7, 198, 220, 220, 220, 3178, 5218, 5855, 16980, 544, 43, 648, 13, 12441, 1600, 471, 5317, 2624, 828, 198, 220, 220, 220, 38357, 5218, 5855, 16980, 544, 43, 648, 13, 13940, 23650, 1600, 10903, 828, 198, 8, 198, 198, 396, 2981, 33736, 7, 3712, 6030, 90, 51, 30072, 810, 1391, 51, 92, 796, 468, 2539, 7, 41, 6239, 3539, 62, 10468, 62, 26465, 3913, 62, 25216, 62, 44, 24805, 2751, 11, 309, 8, 198, 198, 8818, 651, 6018, 4906, 0, 7, 28961, 11, 7904, 6030, 90, 51, 30072, 810, 1391, 51, 92, 198, 220, 220, 220, 610, 2053, 480, 11, 15452, 4906, 796, 49349, 3539, 62, 10468, 62, 26465, 3913, 62, 25216, 62, 44, 24805, 2751, 58, 51, 60, 198, 220, 220, 220, 13634, 14692, 26465, 3913, 25, 2302, 3004, 25, 3672, 8973, 796, 610, 2053, 480, 198, 220, 220, 220, 13634, 14692, 26465, 3913, 25, 2302, 3004, 25, 38993, 8973, 796, 13538, 198, 220, 220, 220, 1441, 15452, 4906, 198, 437, 198, 198, 9979, 5923, 49, 3913, 62, 10468, 62, 41, 6239, 3539, 62, 25216, 62, 44, 24805, 2751, 796, 360, 713, 90, 10100, 11, 309, 29291, 90, 6030, 11, 5994, 11709, 7, 198, 220, 220, 220, 366, 16980, 544, 43, 648, 13, 12441, 1, 5218, 357, 12441, 11, 471, 5317, 2624, 828, 198, 220, 220, 220, 366, 16980, 544, 43, 648, 13, 13940, 23650, 1, 5218, 357, 13940, 23650, 11, 10903, 828, 198, 8, 198, 198, 8818, 7552, 4906, 7, 28961, 8, 198, 220, 220, 220, 611, 468, 2539, 7, 28961, 11, 366, 26465, 3913, 25, 2302, 3004, 25, 3672, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 2170, 12453, 796, 13634, 14692, 26465, 3913, 25, 2302, 3004, 25, 3672, 8973, 198, 220, 220, 220, 220, 220, 220, 220, 611, 468, 2539, 7, 26465, 3913, 62, 10468, 62, 41, 6239, 3539, 62, 25216, 62, 44, 24805, 2751, 11, 2170, 12453, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 5923, 49, 3913, 62, 10468, 62, 41, 6239, 3539, 62, 25216, 62, 44, 24805, 2751, 58, 774, 3617, 480, 7131, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 40539, 366, 403, 15999, 5923, 49, 3913, 25, 2302, 3004, 25, 3672, 2099, 25, 19990, 3, 774, 3617, 480, 7879, 1, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 2147, 198, 437, 198, 198, 8818, 7881, 4906, 0, 7, 73, 377, 5375, 2981, 3712, 6030, 11, 15452, 4906, 3712, 6030, 11, 610, 2053, 480, 3712, 10100, 28, 8841, 7203, 16980, 544, 43, 648, 33283, 4731, 7, 73, 377, 5375, 2981, 22305, 198, 220, 220, 220, 1303, 16926, 46, 25, 26571, 326, 474, 377, 5375, 2981, 2125, 470, 1541, 4277, 15452, 2099, 198, 220, 220, 220, 49349, 3539, 62, 10468, 62, 26465, 3913, 62, 25216, 62, 44, 24805, 2751, 58, 73, 377, 5375, 2981, 60, 796, 357, 283, 2053, 480, 11, 15452, 4906, 8, 198, 220, 220, 220, 5923, 49, 3913, 62, 10468, 62, 41, 6239, 3539, 62, 25216, 62, 44, 24805, 2751, 58, 283, 2053, 480, 60, 796, 357, 73, 377, 5375, 2981, 11, 15452, 4906, 8, 198, 220, 220, 220, 1441, 198, 437, 198, 198, 437, 1303, 8265, 19408, 31431 ]
2.574904
1,562
<filename>src/google/plugin_pb.jl<gh_stars>0 # syntax: proto2 using ProtoBuf import ProtoBuf.meta mutable struct Version <: ProtoType major::Int32 minor::Int32 patch::Int32 suffix::AbstractString Version(; kwargs...) = (o=new(); fillunset(o); isempty(kwargs) || ProtoBuf._protobuild(o, kwargs); o) end #mutable struct Version mutable struct CodeGeneratorRequest <: ProtoType file_to_generate::Base.Vector{AbstractString} parameter::AbstractString proto_file::Base.Vector{ProtoBuf.GoogleProtoBuf.FileDescriptorProto} compiler_version::Version CodeGeneratorRequest(; kwargs...) = (o=new(); fillunset(o); isempty(kwargs) || ProtoBuf._protobuild(o, kwargs); o) end #mutable struct CodeGeneratorRequest const __fnum_CodeGeneratorRequest = Int[1,2,15,3] meta(t::Type{CodeGeneratorRequest}) = meta(t, ProtoBuf.DEF_REQ, __fnum_CodeGeneratorRequest, ProtoBuf.DEF_VAL, true, ProtoBuf.DEF_PACK, ProtoBuf.DEF_WTYPES, ProtoBuf.DEF_ONEOFS, ProtoBuf.DEF_ONEOF_NAMES, ProtoBuf.DEF_FIELD_TYPES) mutable struct CodeGeneratorResponse_File <: ProtoType name::AbstractString insertion_point::AbstractString content::AbstractString CodeGeneratorResponse_File(; kwargs...) = (o=new(); fillunset(o); isempty(kwargs) || ProtoBuf._protobuild(o, kwargs); o) end #mutable struct CodeGeneratorResponse_File const __fnum_CodeGeneratorResponse_File = Int[1,2,15] meta(t::Type{CodeGeneratorResponse_File}) = meta(t, ProtoBuf.DEF_REQ, __fnum_CodeGeneratorResponse_File, ProtoBuf.DEF_VAL, true, ProtoBuf.DEF_PACK, ProtoBuf.DEF_WTYPES, ProtoBuf.DEF_ONEOFS, ProtoBuf.DEF_ONEOF_NAMES, ProtoBuf.DEF_FIELD_TYPES) mutable struct CodeGeneratorResponse <: ProtoType error::AbstractString file::Base.Vector{CodeGeneratorResponse_File} CodeGeneratorResponse(; kwargs...) = (o=new(); fillunset(o); isempty(kwargs) || ProtoBuf._protobuild(o, kwargs); o) end #mutable struct CodeGeneratorResponse const __fnum_CodeGeneratorResponse = Int[1,15] meta(t::Type{CodeGeneratorResponse}) = meta(t, ProtoBuf.DEF_REQ, __fnum_CodeGeneratorResponse, ProtoBuf.DEF_VAL, true, ProtoBuf.DEF_PACK, ProtoBuf.DEF_WTYPES, ProtoBuf.DEF_ONEOFS, ProtoBuf.DEF_ONEOF_NAMES, ProtoBuf.DEF_FIELD_TYPES) export Version, CodeGeneratorRequest, CodeGeneratorResponse_File, CodeGeneratorResponse
[ 27, 34345, 29, 10677, 14, 13297, 14, 33803, 62, 40842, 13, 20362, 27, 456, 62, 30783, 29, 15, 198, 2, 15582, 25, 44876, 17, 198, 3500, 45783, 33, 3046, 198, 11748, 45783, 33, 3046, 13, 28961, 198, 198, 76, 18187, 2878, 10628, 1279, 25, 45783, 6030, 198, 220, 220, 220, 1688, 3712, 5317, 2624, 198, 220, 220, 220, 4159, 3712, 5317, 2624, 198, 220, 220, 220, 8529, 3712, 5317, 2624, 198, 220, 220, 220, 35488, 3712, 23839, 10100, 198, 220, 220, 220, 10628, 7, 26, 479, 86, 22046, 23029, 796, 357, 78, 28, 3605, 9783, 6070, 403, 2617, 7, 78, 1776, 318, 28920, 7, 46265, 22046, 8, 8614, 45783, 33, 3046, 13557, 11235, 672, 3547, 7, 78, 11, 479, 86, 22046, 1776, 267, 8, 198, 437, 1303, 76, 18187, 2878, 10628, 198, 198, 76, 18187, 2878, 6127, 8645, 1352, 18453, 1279, 25, 45783, 6030, 198, 220, 220, 220, 2393, 62, 1462, 62, 8612, 378, 3712, 14881, 13, 38469, 90, 23839, 10100, 92, 198, 220, 220, 220, 11507, 3712, 23839, 10100, 198, 220, 220, 220, 44876, 62, 7753, 3712, 14881, 13, 38469, 90, 2964, 1462, 33, 3046, 13, 11708, 2964, 1462, 33, 3046, 13, 8979, 24564, 1968, 273, 2964, 1462, 92, 198, 220, 220, 220, 17050, 62, 9641, 3712, 14815, 198, 220, 220, 220, 6127, 8645, 1352, 18453, 7, 26, 479, 86, 22046, 23029, 796, 357, 78, 28, 3605, 9783, 6070, 403, 2617, 7, 78, 1776, 318, 28920, 7, 46265, 22046, 8, 8614, 45783, 33, 3046, 13557, 11235, 672, 3547, 7, 78, 11, 479, 86, 22046, 1776, 267, 8, 198, 437, 1303, 76, 18187, 2878, 6127, 8645, 1352, 18453, 198, 9979, 11593, 22184, 388, 62, 10669, 8645, 1352, 18453, 796, 2558, 58, 16, 11, 17, 11, 1314, 11, 18, 60, 198, 28961, 7, 83, 3712, 6030, 90, 10669, 8645, 1352, 18453, 30072, 796, 13634, 7, 83, 11, 45783, 33, 3046, 13, 32988, 62, 2200, 48, 11, 11593, 22184, 388, 62, 10669, 8645, 1352, 18453, 11, 45783, 33, 3046, 13, 32988, 62, 23428, 11, 2081, 11, 45783, 33, 3046, 13, 32988, 62, 47, 8120, 11, 45783, 33, 3046, 13, 32988, 62, 54, 9936, 47, 1546, 11, 45783, 33, 3046, 13, 32988, 62, 1340, 4720, 10652, 11, 45783, 33, 3046, 13, 32988, 62, 1340, 4720, 37, 62, 45, 29559, 11, 45783, 33, 3046, 13, 32988, 62, 44603, 62, 9936, 47, 1546, 8, 198, 198, 76, 18187, 2878, 6127, 8645, 1352, 31077, 62, 8979, 1279, 25, 45783, 6030, 198, 220, 220, 220, 1438, 3712, 23839, 10100, 198, 220, 220, 220, 36075, 62, 4122, 3712, 23839, 10100, 198, 220, 220, 220, 2695, 3712, 23839, 10100, 198, 220, 220, 220, 6127, 8645, 1352, 31077, 62, 8979, 7, 26, 479, 86, 22046, 23029, 796, 357, 78, 28, 3605, 9783, 6070, 403, 2617, 7, 78, 1776, 318, 28920, 7, 46265, 22046, 8, 8614, 45783, 33, 3046, 13557, 11235, 672, 3547, 7, 78, 11, 479, 86, 22046, 1776, 267, 8, 198, 437, 1303, 76, 18187, 2878, 6127, 8645, 1352, 31077, 62, 8979, 198, 9979, 11593, 22184, 388, 62, 10669, 8645, 1352, 31077, 62, 8979, 796, 2558, 58, 16, 11, 17, 11, 1314, 60, 198, 28961, 7, 83, 3712, 6030, 90, 10669, 8645, 1352, 31077, 62, 8979, 30072, 796, 13634, 7, 83, 11, 45783, 33, 3046, 13, 32988, 62, 2200, 48, 11, 11593, 22184, 388, 62, 10669, 8645, 1352, 31077, 62, 8979, 11, 45783, 33, 3046, 13, 32988, 62, 23428, 11, 2081, 11, 45783, 33, 3046, 13, 32988, 62, 47, 8120, 11, 45783, 33, 3046, 13, 32988, 62, 54, 9936, 47, 1546, 11, 45783, 33, 3046, 13, 32988, 62, 1340, 4720, 10652, 11, 45783, 33, 3046, 13, 32988, 62, 1340, 4720, 37, 62, 45, 29559, 11, 45783, 33, 3046, 13, 32988, 62, 44603, 62, 9936, 47, 1546, 8, 198, 198, 76, 18187, 2878, 6127, 8645, 1352, 31077, 1279, 25, 45783, 6030, 198, 220, 220, 220, 4049, 3712, 23839, 10100, 198, 220, 220, 220, 2393, 3712, 14881, 13, 38469, 90, 10669, 8645, 1352, 31077, 62, 8979, 92, 198, 220, 220, 220, 6127, 8645, 1352, 31077, 7, 26, 479, 86, 22046, 23029, 796, 357, 78, 28, 3605, 9783, 6070, 403, 2617, 7, 78, 1776, 318, 28920, 7, 46265, 22046, 8, 8614, 45783, 33, 3046, 13557, 11235, 672, 3547, 7, 78, 11, 479, 86, 22046, 1776, 267, 8, 198, 437, 1303, 76, 18187, 2878, 6127, 8645, 1352, 31077, 198, 9979, 11593, 22184, 388, 62, 10669, 8645, 1352, 31077, 796, 2558, 58, 16, 11, 1314, 60, 198, 28961, 7, 83, 3712, 6030, 90, 10669, 8645, 1352, 31077, 30072, 796, 13634, 7, 83, 11, 45783, 33, 3046, 13, 32988, 62, 2200, 48, 11, 11593, 22184, 388, 62, 10669, 8645, 1352, 31077, 11, 45783, 33, 3046, 13, 32988, 62, 23428, 11, 2081, 11, 45783, 33, 3046, 13, 32988, 62, 47, 8120, 11, 45783, 33, 3046, 13, 32988, 62, 54, 9936, 47, 1546, 11, 45783, 33, 3046, 13, 32988, 62, 1340, 4720, 10652, 11, 45783, 33, 3046, 13, 32988, 62, 1340, 4720, 37, 62, 45, 29559, 11, 45783, 33, 3046, 13, 32988, 62, 44603, 62, 9936, 47, 1546, 8, 198, 198, 39344, 10628, 11, 6127, 8645, 1352, 18453, 11, 6127, 8645, 1352, 31077, 62, 8979, 11, 6127, 8645, 1352, 31077, 198 ]
2.681499
854
<gh_stars>100-1000 using BenchmarkTools SUITE = BenchmarkGroup() for file in readdir(@__DIR__) if startswith(file, "bench_") && endswith(file, ".jl") SUITE[file[length("bench_") + 1:end - length(".jl")]] = include(file) end end
[ 27, 456, 62, 30783, 29, 3064, 12, 12825, 198, 3500, 25187, 4102, 33637, 198, 12564, 12709, 796, 25187, 4102, 13247, 3419, 198, 1640, 2393, 287, 1100, 15908, 7, 31, 834, 34720, 834, 8, 198, 220, 220, 220, 611, 923, 2032, 342, 7, 7753, 11, 366, 26968, 62, 4943, 11405, 886, 2032, 342, 7, 7753, 11, 27071, 20362, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 13558, 12709, 58, 7753, 58, 13664, 7203, 26968, 62, 4943, 1343, 352, 25, 437, 532, 4129, 7, 1911, 20362, 4943, 11907, 796, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2291, 7, 7753, 8, 198, 220, 220, 220, 886, 198, 437, 198 ]
2.285714
112
<gh_stars>0 module Cards using Genie, Stipple, StippleUI, StippleUI.API import Genie.Renderer.Html: HTMLString, normal_element, register_normal_element export card, card_section, card_actions register_normal_element("q__card", context = @__MODULE__) register_normal_element("q__card__section", context = @__MODULE__) register_normal_element("q__card__actions", context = @__MODULE__) function card(args...; wrap::Function = StippleUI.DEFAULT_WRAPPER, kwargs...) wrap() do q__card(args...; kwargs...) end end function card_section(args...; kwargs...) q__card__section(args...; kwargs...) end function card_actions(args...; kwargs...) q__card__actions(args...; kwargs...) end end
[ 27, 456, 62, 30783, 29, 15, 198, 21412, 15824, 198, 198, 3500, 49405, 11, 520, 18793, 11, 520, 18793, 10080, 11, 520, 18793, 10080, 13, 17614, 198, 11748, 49405, 13, 49, 437, 11882, 13, 39, 20369, 25, 11532, 10100, 11, 3487, 62, 30854, 11, 7881, 62, 11265, 62, 30854, 198, 198, 39344, 2657, 11, 2657, 62, 5458, 11, 2657, 62, 4658, 198, 198, 30238, 62, 11265, 62, 30854, 7203, 80, 834, 9517, 1600, 4732, 796, 2488, 834, 33365, 24212, 834, 8, 198, 30238, 62, 11265, 62, 30854, 7203, 80, 834, 9517, 834, 5458, 1600, 4732, 796, 2488, 834, 33365, 24212, 834, 8, 198, 30238, 62, 11265, 62, 30854, 7203, 80, 834, 9517, 834, 4658, 1600, 4732, 796, 2488, 834, 33365, 24212, 834, 8, 198, 198, 8818, 2657, 7, 22046, 986, 26, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 14441, 3712, 22203, 796, 520, 18793, 10080, 13, 7206, 38865, 62, 18564, 2969, 18973, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 86, 22046, 23029, 198, 220, 14441, 3419, 466, 198, 220, 220, 220, 10662, 834, 9517, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 220, 886, 198, 437, 198, 198, 8818, 2657, 62, 5458, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 220, 10662, 834, 9517, 834, 5458, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 437, 198, 198, 8818, 2657, 62, 4658, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 220, 10662, 834, 9517, 834, 4658, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 437, 198, 198, 437, 198 ]
2.695167
269
<filename>src/_deriv2.jl """ Module: SymbolicDiff (Symbolic Operation for Arithmetic) """ """ seval(f, (dvar1, dver2), env, cache) Return the second derivative of expr f with respect to dvar1 and dver2 """ function seval(f, dvar::Tuple{Symbol,Symbol}) seval(f, dvar, globalenv, SymbolicCache()) end function seval(f, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv) seval(f, dvar, env, SymbolicCache()) end function seval(f, dvar::Tuple{Symbol,Symbol}, cache::SymbolicCache) seval(f, dvar, globalenv, cache) end ### function seval(f, dvar::Tuple{SymbolicVariable{Tv},SymbolicVariable{Tv}}) where Tv seval(f, (dvar[1].var, dvar[2].var)) end function seval(f, dvar::Tuple{SymbolicVariable{Tv},SymbolicVariable{Tv}}, env::SymbolicEnv) where Tv seval(f, (dvar[1].var, dvar[2].var), env) end function seval(f, dvar::Tuple{SymbolicVariable{Tv},SymbolicVariable{Tv}}, cache::SymbolicCache) where Tv seval(f, (dvar[1].var, dvar[2].var), cache) end function seval(f, dvar::Tuple{SymbolicVariable{Tv},SymbolicVariable{Tv}}, env::SymbolicEnv, cache::SymbolicCache) where Tv seval(f, (dvar[1].var, dvar[2].var), env, cache) end ### function seval(f::SymbolicValue{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv 0 end function seval(f::SymbolicVariable{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv 0 end function seval(f::AbstractNumberSymbolic{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv (dvar[1] in f.params) || (dvar[2] in f.params) || return Tv(0) get(cache, (f,dvar)) do retval = _eval(Val(f.op), f, dvar, env, cache) cache[(f,dvar)] = retval end end """ _eval(::Val{xx}, dvar, f, env, cache) Dispached function to evaluate the second derivative of f """ function _eval(::Val{:+}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv args = [seval(x, dvar, env, cache) for x = f.args] +(args...) end function _eval(::Val{:-}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv args = [seval(x, dvar, env, cache) for x = f.args] -(args...) end function _eval(::Val{:*}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv args = [seval(x, env, cache) for x = f.args] dargs_a = [seval(x, dvar[1], env, cache) for x = f.args] dargs_b = [seval(x, dvar[2], env, cache) for x = f.args] dargs_ab = [seval(x, dvar, env, cache) for x = f.args] ret = dargs_ab[1] s = args[1] s_a = dargs_a[1] s_b = dargs_b[1] for i = 2:length(args) ret *= args[i] ret += s * dargs_ab[i] ret += s_a * dargs_b[i] ret += s_b * dargs_a[i] (i == length(args)) && break s_a *= args[i] s_b *= args[i] s_a += s * dargs_a[i] s_b += s * dargs_b[i] s *= args[i] end ret end function _eval(::Val{:/}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv x,y = [seval(x, env, cache) for x = f.args] dx_a,dy_a = [seval(x, dvar[1], env, cache) for x = f.args] dx_b,dy_b = [seval(x, dvar[2], env, cache) for x = f.args] dx_ab,dy_ab = [seval(x, dvar, env, cache) for x = f.args] ((dx_ab * y - dx_a * dy_b - dx_b * dy_a - x * dy_ab) * y + 2 * x * dy_a * dy_b) / y^3 end function _eval(::Val{:^}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv x,y = [seval(x, env, cache) for x = f.args] dx_a,dy_a = [seval(x, dvar[1], env, cache) for x = f.args] dx_b,dy_b = [seval(x, dvar[2], env, cache) for x = f.args] dx_ab,dy_ab = [seval(x, dvar, env, cache) for x = f.args] f = x^y f_a = f * (dy_a * x * log(x) + y * dx_a) / x f_b = f * (dy_b * x * log(x) + y * dx_b) / x f_ab = (f_b * (dy_a * x * log(x) + y * dx_a) - f_a * dx_b + f * (dy_ab * x * log(x) + dy_a * dx_b * (1 + log(x)) + dx_a * dy_b + y * dx_ab)) / x f_ab end function _eval(::Val{:exp}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv x, = [seval(x, env, cache) for x = f.args] dx_a, = [seval(x, dvar[1], env, cache) for x = f.args] dx_b, = [seval(x, dvar[2], env, cache) for x = f.args] dx_ab, = [seval(x, dvar, env, cache) for x = f.args] exp(x) * (dx_b * dx_a + dx_ab) end function _eval(::Val{:log}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv x, = [seval(x, env, cache) for x = f.args] dx_a, = [seval(x, dvar[1], env, cache) for x = f.args] dx_b, = [seval(x, dvar[2], env, cache) for x = f.args] dx_ab, = [seval(x, dvar, env, cache) for x = f.args] (dx_ab * x - dx_a * dx_b) / x^2 end function _eval(::Val{:sqrt}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv x, = [seval(x, env, cache) for x = f.args] dx_a, = [seval(x, dvar[1], env, cache) for x = f.args] dx_b, = [seval(x, dvar[2], env, cache) for x = f.args] dx_ab, = [seval(x, dvar, env, cache) for x = f.args] sqrt(x) * (dx_ab * 2 - dx_a * dx_b) / (4*x) end function _eval(::Val{:sum}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv dx_ab, = [seval(x, dvar, env, cache) for x = f.args] sum(dx_ab) end function _eval(::Val{:dot}, f::SymbolicExpression{Tv}, dvar::Tuple{Symbol,Symbol}, env::SymbolicEnv, cache::SymbolicCache)::Tv where Tv x,y = [seval(x, env, cache) for x = f.args] dx_a,dy_a = [seval(x, dvar[1], env, cache) for x = f.args] dx_b,dy_b = [seval(x, dvar[2], env, cache) for x = f.args] dx_ab,dy_ab = [seval(x, dvar, env, cache) for x = f.args] dot(x,dy_ab) + dot(dx_b,dy_a) + dot(dx_a,dy_b) + dot(dx_ab,y) end
[ 27, 34345, 29, 10677, 47835, 1082, 452, 17, 13, 20362, 198, 37811, 198, 26796, 25, 41327, 4160, 28813, 357, 13940, 2022, 4160, 14680, 329, 943, 29848, 8, 198, 37811, 198, 198, 37811, 198, 325, 2100, 7, 69, 11, 357, 67, 7785, 16, 11, 288, 332, 17, 828, 17365, 11, 12940, 8, 198, 13615, 262, 1218, 27255, 286, 44052, 277, 351, 2461, 284, 288, 7785, 16, 290, 288, 332, 17, 198, 37811, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 30072, 198, 220, 220, 220, 384, 2100, 7, 69, 11, 288, 7785, 11, 3298, 24330, 11, 41327, 4160, 30562, 28955, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 8, 198, 220, 220, 220, 384, 2100, 7, 69, 11, 288, 7785, 11, 17365, 11, 41327, 4160, 30562, 28955, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 12940, 3712, 13940, 2022, 4160, 30562, 8, 198, 220, 220, 220, 384, 2100, 7, 69, 11, 288, 7785, 11, 3298, 24330, 11, 12940, 8, 198, 437, 198, 198, 21017, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 2022, 4160, 43015, 90, 51, 85, 5512, 13940, 2022, 4160, 43015, 90, 51, 85, 11709, 8, 810, 309, 85, 198, 220, 220, 220, 384, 2100, 7, 69, 11, 357, 67, 7785, 58, 16, 4083, 7785, 11, 288, 7785, 58, 17, 4083, 7785, 4008, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 2022, 4160, 43015, 90, 51, 85, 5512, 13940, 2022, 4160, 43015, 90, 51, 85, 92, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 8, 810, 309, 85, 198, 220, 220, 220, 384, 2100, 7, 69, 11, 357, 67, 7785, 58, 16, 4083, 7785, 11, 288, 7785, 58, 17, 4083, 7785, 828, 17365, 8, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 2022, 4160, 43015, 90, 51, 85, 5512, 13940, 2022, 4160, 43015, 90, 51, 85, 92, 5512, 12940, 3712, 13940, 2022, 4160, 30562, 8, 810, 309, 85, 198, 220, 220, 220, 384, 2100, 7, 69, 11, 357, 67, 7785, 58, 16, 4083, 7785, 11, 288, 7785, 58, 17, 4083, 7785, 828, 12940, 8, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 11, 288, 7785, 3712, 51, 29291, 90, 13940, 2022, 4160, 43015, 90, 51, 85, 5512, 13940, 2022, 4160, 43015, 90, 51, 85, 92, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 8, 810, 309, 85, 198, 220, 220, 220, 220, 220, 220, 220, 384, 2100, 7, 69, 11, 357, 67, 7785, 58, 16, 4083, 7785, 11, 288, 7785, 58, 17, 4083, 7785, 828, 17365, 11, 12940, 8, 198, 437, 198, 198, 21017, 198, 198, 8818, 384, 2100, 7, 69, 3712, 13940, 2022, 4160, 11395, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 657, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 3712, 13940, 2022, 4160, 43015, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 657, 198, 437, 198, 198, 8818, 384, 2100, 7, 69, 3712, 23839, 15057, 13940, 2022, 4160, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 357, 67, 7785, 58, 16, 60, 287, 277, 13, 37266, 8, 8614, 357, 67, 7785, 58, 17, 60, 287, 277, 13, 37266, 8, 8614, 1441, 309, 85, 7, 15, 8, 198, 220, 220, 220, 651, 7, 23870, 11, 357, 69, 11, 67, 7785, 4008, 466, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 2100, 796, 4808, 18206, 7, 7762, 7, 69, 13, 404, 828, 277, 11, 288, 7785, 11, 17365, 11, 12940, 8, 198, 220, 220, 220, 220, 220, 220, 220, 12940, 58, 7, 69, 11, 67, 7785, 15437, 796, 1005, 2100, 198, 220, 220, 220, 886, 198, 437, 198, 198, 37811, 198, 62, 18206, 7, 3712, 7762, 90, 5324, 5512, 288, 7785, 11, 277, 11, 17365, 11, 12940, 8, 198, 198, 7279, 79, 2317, 2163, 284, 13446, 262, 1218, 27255, 286, 277, 198, 37811, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 10, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 26498, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 1343, 7, 22046, 23029, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 21912, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 26498, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 532, 7, 22046, 23029, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 9, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 26498, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 288, 22046, 62, 64, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 288, 22046, 62, 65, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 288, 22046, 62, 397, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 628, 220, 220, 220, 1005, 796, 288, 22046, 62, 397, 58, 16, 60, 198, 220, 220, 220, 264, 796, 26498, 58, 16, 60, 198, 220, 220, 220, 264, 62, 64, 796, 288, 22046, 62, 64, 58, 16, 60, 198, 220, 220, 220, 264, 62, 65, 796, 288, 22046, 62, 65, 58, 16, 60, 198, 220, 220, 220, 329, 1312, 796, 362, 25, 13664, 7, 22046, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 1635, 28, 26498, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 15853, 264, 1635, 288, 22046, 62, 397, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 15853, 264, 62, 64, 1635, 288, 22046, 62, 65, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 15853, 264, 62, 65, 1635, 288, 22046, 62, 64, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 357, 72, 6624, 4129, 7, 22046, 4008, 11405, 2270, 198, 220, 220, 220, 220, 220, 220, 220, 264, 62, 64, 1635, 28, 26498, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 264, 62, 65, 1635, 28, 26498, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 264, 62, 64, 15853, 264, 1635, 288, 22046, 62, 64, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 264, 62, 65, 15853, 264, 1635, 288, 22046, 62, 65, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 264, 1635, 28, 26498, 58, 72, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1005, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 14079, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 2124, 11, 88, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 64, 11, 9892, 62, 64, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 65, 11, 9892, 62, 65, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 397, 11, 9892, 62, 397, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 14808, 34350, 62, 397, 1635, 331, 532, 44332, 62, 64, 1635, 20268, 62, 65, 220, 532, 44332, 62, 65, 1635, 20268, 62, 64, 532, 2124, 1635, 20268, 62, 397, 8, 1635, 331, 1343, 362, 1635, 2124, 1635, 20268, 62, 64, 1635, 20268, 62, 65, 8, 1220, 331, 61, 18, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 61, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 2124, 11, 88, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 64, 11, 9892, 62, 64, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 65, 11, 9892, 62, 65, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 397, 11, 9892, 62, 397, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 277, 796, 2124, 61, 88, 198, 220, 220, 220, 277, 62, 64, 796, 277, 1635, 357, 9892, 62, 64, 1635, 2124, 1635, 2604, 7, 87, 8, 1343, 331, 1635, 44332, 62, 64, 8, 1220, 2124, 198, 220, 220, 220, 277, 62, 65, 796, 277, 1635, 357, 9892, 62, 65, 1635, 2124, 1635, 2604, 7, 87, 8, 1343, 331, 1635, 44332, 62, 65, 8, 1220, 2124, 198, 220, 220, 220, 277, 62, 397, 796, 357, 69, 62, 65, 1635, 357, 9892, 62, 64, 1635, 2124, 1635, 2604, 7, 87, 8, 1343, 331, 1635, 44332, 62, 64, 8, 532, 277, 62, 64, 1635, 44332, 62, 65, 1343, 277, 1635, 357, 9892, 62, 397, 1635, 2124, 1635, 2604, 7, 87, 8, 1343, 20268, 62, 64, 1635, 44332, 62, 65, 1635, 357, 16, 1343, 2604, 7, 87, 4008, 1343, 44332, 62, 64, 1635, 20268, 62, 65, 1343, 331, 1635, 44332, 62, 397, 4008, 1220, 2124, 198, 220, 220, 220, 277, 62, 397, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 11201, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 2124, 11, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 64, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 65, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 397, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 1033, 7, 87, 8, 1635, 357, 34350, 62, 65, 1635, 44332, 62, 64, 1343, 44332, 62, 397, 8, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 6404, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 2124, 11, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 64, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 65, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 397, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 357, 34350, 62, 397, 1635, 2124, 532, 44332, 62, 64, 1635, 44332, 62, 65, 8, 1220, 2124, 61, 17, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 31166, 17034, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 2124, 11, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 64, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 65, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 397, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 19862, 17034, 7, 87, 8, 1635, 357, 34350, 62, 397, 1635, 362, 532, 44332, 62, 64, 1635, 44332, 62, 65, 8, 1220, 357, 19, 9, 87, 8, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 16345, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 44332, 62, 397, 11, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 2160, 7, 34350, 62, 397, 8, 198, 437, 198, 198, 8818, 4808, 18206, 7, 3712, 7762, 90, 25, 26518, 5512, 277, 3712, 13940, 2022, 4160, 16870, 2234, 90, 51, 85, 5512, 288, 7785, 3712, 51, 29291, 90, 13940, 23650, 11, 13940, 23650, 5512, 17365, 3712, 13940, 2022, 4160, 4834, 85, 11, 12940, 3712, 13940, 2022, 4160, 30562, 2599, 25, 51, 85, 810, 309, 85, 198, 220, 220, 220, 2124, 11, 88, 796, 685, 325, 2100, 7, 87, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 64, 11, 9892, 62, 64, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 16, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 65, 11, 9892, 62, 65, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 58, 17, 4357, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 44332, 62, 397, 11, 9892, 62, 397, 796, 685, 325, 2100, 7, 87, 11, 288, 7785, 11, 17365, 11, 12940, 8, 329, 2124, 796, 277, 13, 22046, 60, 198, 220, 220, 220, 16605, 7, 87, 11, 9892, 62, 397, 8, 1343, 16605, 7, 34350, 62, 65, 11, 9892, 62, 64, 8, 1343, 16605, 7, 34350, 62, 64, 11, 9892, 62, 65, 8, 1343, 16605, 7, 34350, 62, 397, 11, 88, 8, 198, 437, 198 ]
2.066644
2,911
""" module ViewerGL 3D `interactive Viewer` for geometric and topological data. Helper module for Julia's native ``OpenGL visualization``, forked from [Plasm.jl](https://github.com/plasm-language/pyplasm/tree/master/src/plasm.jl). To be used with geometric models and geometric expressions from [LinearAlgebraicRepresentation.jl](https://github.com/cvdlab/LinearAlgebraicRepresentation.jl), the simplest data structures for geometric and solid modeling :-) """ module ViewerGL using LinearAlgebra,StaticArrays using ModernGL using GLFW import Base:* include("Point.jl") include("Box.jl") include("Matrix.jl") include("Quaternion.jl") include("Frustum.jl") include("GLUtils.jl") include("GLVertexBuffer.jl") include("GLVertexArray.jl") include("GLMesh.jl") include("GLShader.jl") include("GLPhongShader.jl") include("Viewer.jl") include("Geometry.jl") include("GLText.jl") include("GLColorBuffer.jl") const GLFrame2 = GLAxis(Point3d(0,0,0),Point3d(1,1,0)) const GLFrame = GLAxis(Point3d(0,0,0),Point3d(1,1,1)) end # module
[ 37811, 198, 197, 21412, 3582, 263, 8763, 198, 198, 18, 35, 4600, 3849, 5275, 3582, 263, 63, 329, 38445, 290, 1353, 2770, 1366, 13, 198, 198, 47429, 8265, 329, 22300, 338, 6868, 7559, 11505, 8763, 32704, 15506, 11, 329, 9091, 422, 685, 3646, 8597, 13, 20362, 16151, 5450, 1378, 12567, 13, 785, 14, 489, 8597, 12, 16129, 14, 9078, 489, 8597, 14, 21048, 14, 9866, 14, 10677, 14, 489, 8597, 13, 20362, 737, 1675, 307, 973, 351, 38445, 4981, 290, 38445, 14700, 422, 685, 14993, 451, 2348, 29230, 291, 40171, 341, 13, 20362, 16151, 5450, 1378, 12567, 13, 785, 14, 66, 20306, 23912, 14, 14993, 451, 2348, 29230, 291, 40171, 341, 13, 20362, 828, 262, 24043, 1366, 8573, 329, 38445, 290, 4735, 21128, 47226, 198, 37811, 198, 21412, 3582, 263, 8763, 628, 197, 3500, 44800, 2348, 29230, 11, 45442, 3163, 20477, 198, 197, 3500, 12495, 8763, 198, 197, 3500, 10188, 24160, 198, 197, 11748, 7308, 25, 9, 628, 197, 17256, 7203, 12727, 13, 20362, 4943, 198, 197, 17256, 7203, 14253, 13, 20362, 4943, 198, 197, 17256, 7203, 46912, 13, 20362, 4943, 198, 197, 17256, 7203, 4507, 9205, 295, 13, 20362, 4943, 198, 197, 17256, 7203, 6732, 436, 388, 13, 20362, 4943, 628, 197, 17256, 7203, 8763, 18274, 4487, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 13414, 16886, 28632, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 13414, 16886, 19182, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 37031, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 2484, 5067, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 2725, 506, 2484, 5067, 13, 20362, 4943, 628, 197, 17256, 7203, 7680, 263, 13, 20362, 4943, 198, 197, 17256, 7203, 10082, 15748, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 8206, 13, 20362, 4943, 198, 197, 17256, 7203, 8763, 10258, 28632, 13, 20362, 4943, 628, 197, 9979, 10188, 19778, 17, 796, 10188, 31554, 271, 7, 12727, 18, 67, 7, 15, 11, 15, 11, 15, 828, 12727, 18, 67, 7, 16, 11, 16, 11, 15, 4008, 198, 197, 9979, 10188, 19778, 796, 10188, 31554, 271, 7, 12727, 18, 67, 7, 15, 11, 15, 11, 15, 828, 12727, 18, 67, 7, 16, 11, 16, 11, 16, 4008, 628, 198, 437, 1303, 8265, 198 ]
2.861413
368
<filename>examples/collisions/Simulate_SlidingAndRollingBall.jl """ module Simulate_SlidingAndRollingBall Simulates a ball that is first sliding and then rolling on a table. """ module Simulate_SlidingAndRollingBall using Modia3D import Modia3D.ModiaMath vmatSolids = Material(color="Red" , transparency=0.0) # material of solids vmatTable = Material(color="Green" , transparency=0.1) # material of table LxTable = 3.0 LyTable = 0.5 LzTable = 0.02 diameter = 0.06 solidBall = Solid(SolidSphere(diameter), "BilliardBall", vmatSolids; contactMaterial="BilliardBall") solidTable = Solid(SolidBox(LxTable, LyTable, LzTable) , "BilliardTable", vmatTable; contactMaterial = "BilliardTable") @assembly RollingBall() begin world = Object3D() table = Object3D(world, solidTable, fixed=true , r=[1.5, 0.0, -LzTable/2]) ball = Object3D(world, solidBall , fixed=false, r=[0.2, 0.0, diameter/2], v_start=[3.0, 0.0, 0.0], visualizeFrame=true ) end gravField = UniformGravityField(g=9.81, n=[0,0,-1]) rollingBall = RollingBall(sceneOptions=SceneOptions(gravityField=gravField, visualizeFrames=false, defaultFrameLength=0.1, enableContactDetection=true)) # Modia3D.visualizeAssembly!( rollingBall ) model = SimulationModel(rollingBall) result = ModiaMath.simulate!(model; stopTime=0.5, tolerance=1e-8, log=false) ModiaMath.plot(result, [ "ball.r[1]" "ball.v[1]" "ball.r[3]" "ball.w[2]"]) println("... success of examples/collisions/Simulate_SlidingAndRollingBall.jl!") end
[ 27, 34345, 29, 1069, 12629, 14, 26000, 3279, 14, 8890, 5039, 62, 11122, 2530, 1870, 26869, 278, 23410, 13, 20362, 198, 37811, 198, 220, 220, 220, 8265, 3184, 5039, 62, 11122, 2530, 1870, 26869, 278, 23410, 198, 198, 8890, 15968, 257, 2613, 326, 318, 717, 22292, 290, 788, 10708, 319, 257, 3084, 13, 198, 37811, 198, 21412, 3184, 5039, 62, 11122, 2530, 1870, 26869, 278, 23410, 198, 198, 3500, 220, 3401, 544, 18, 35, 198, 11748, 3401, 544, 18, 35, 13, 5841, 544, 37372, 628, 198, 85, 6759, 36949, 2340, 220, 220, 796, 14633, 7, 8043, 2625, 7738, 1, 220, 220, 220, 220, 220, 220, 837, 13902, 28, 15, 13, 15, 8, 220, 220, 220, 1303, 2587, 286, 1540, 2340, 198, 85, 6759, 10962, 220, 220, 220, 796, 14633, 7, 8043, 2625, 13719, 1, 220, 220, 220, 220, 837, 13902, 28, 15, 13, 16, 8, 220, 220, 220, 1303, 2587, 286, 3084, 198, 198, 43, 87, 10962, 220, 796, 513, 13, 15, 198, 31633, 10962, 220, 796, 657, 13, 20, 198, 43, 89, 10962, 220, 796, 657, 13, 2999, 198, 67, 13173, 796, 657, 13, 3312, 198, 198, 39390, 23410, 220, 796, 15831, 7, 46933, 38882, 7, 67, 13173, 828, 366, 17798, 42425, 23410, 1600, 410, 6759, 36949, 2340, 26, 2800, 17518, 2625, 17798, 42425, 23410, 4943, 198, 39390, 10962, 796, 15831, 7, 46933, 14253, 7, 43, 87, 10962, 11, 9334, 10962, 11, 406, 89, 10962, 8, 837, 366, 17798, 42425, 10962, 1600, 410, 6759, 10962, 26, 2800, 17518, 796, 366, 17798, 42425, 10962, 4943, 628, 198, 31, 41873, 21567, 23410, 3419, 2221, 198, 220, 995, 796, 9515, 18, 35, 3419, 198, 220, 3084, 796, 9515, 18, 35, 7, 6894, 11, 4735, 10962, 11, 5969, 28, 7942, 837, 374, 41888, 16, 13, 20, 11, 657, 13, 15, 11, 532, 43, 89, 10962, 14, 17, 12962, 198, 220, 2613, 220, 796, 9515, 18, 35, 7, 6894, 11, 4735, 23410, 837, 5969, 28, 9562, 11, 374, 41888, 15, 13, 17, 11, 657, 13, 15, 11, 14753, 14, 17, 4357, 410, 62, 9688, 41888, 18, 13, 15, 11, 657, 13, 15, 11, 657, 13, 15, 4357, 38350, 19778, 28, 7942, 1267, 198, 437, 198, 198, 70, 4108, 15878, 220, 220, 796, 35712, 38, 16995, 15878, 7, 70, 28, 24, 13, 6659, 11, 299, 41888, 15, 11, 15, 12095, 16, 12962, 198, 18886, 23410, 796, 21567, 23410, 7, 29734, 29046, 28, 36542, 29046, 7, 46453, 15878, 28, 70, 4108, 15878, 11, 38350, 35439, 28, 9562, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4277, 19778, 24539, 28, 15, 13, 16, 11, 7139, 17829, 11242, 3213, 28, 7942, 4008, 198, 198, 2, 3401, 544, 18, 35, 13, 41464, 1096, 49670, 0, 7, 10708, 23410, 1267, 198, 19849, 796, 41798, 17633, 7, 18886, 23410, 8, 198, 198, 20274, 796, 3401, 544, 37372, 13, 14323, 5039, 0, 7, 19849, 26, 2245, 7575, 28, 15, 13, 20, 11, 15621, 28, 16, 68, 12, 23, 11, 2604, 28, 9562, 8, 198, 198, 5841, 544, 37372, 13, 29487, 7, 20274, 11, 685, 366, 1894, 13, 81, 58, 16, 30866, 220, 366, 1894, 13, 85, 58, 16, 30866, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 1894, 13, 81, 58, 18, 30866, 220, 366, 1894, 13, 86, 58, 17, 60, 8973, 8, 198, 198, 35235, 7203, 986, 1943, 286, 6096, 14, 26000, 3279, 14, 8890, 5039, 62, 11122, 2530, 1870, 26869, 278, 23410, 13, 20362, 2474, 8, 198, 437, 198 ]
2.512658
632
""" SteMDerivative(x::Vector{Float64}, y::Vector{Float64}) This function evaluates the numerical derivative according to the SteM algorithm, [Camera et al. 2017](https://arxiv.org/abs/1606.03451): - a linear regression over ``x`` and ``y`` is performed - if the points obtained with the fit are close enough (less than 0.01 relative difference) the linear ansatz is satisfied and the slope gives the derivative - if the linear ansatz is not satisfied, the external couple of points and the linear regression is performed again till the linear ansatz is satisfied """ function SteMDerivative(x::Vector{Float64}, y::Vector{Float64}) x_copy = deepcopy(x) y_copy = deepcopy(y) if minimum(y) == maximum(y) der = 0 else nonlinear = true while nonlinear coefficients = CustomRegression(x_copy, y_copy) y_fit = zeros(length(x_copy)) percent_diff = zeros(length(x_copy)) y_fit .= coefficients[1] .+ x_copy .* coefficients[2] percent_diff = abs.((y_copy .- y_fit) ./ y_copy) if all(percent_diff .<= 0.01) || length(x_copy) < 3 nonlinear = false der = coefficients[2] else pop!(x_copy) pop!(y_copy) popfirst!(y_copy) popfirst!(x_copy) end end end return der end
[ 37811, 198, 220, 220, 220, 2441, 12740, 263, 452, 876, 7, 87, 3712, 38469, 90, 43879, 2414, 5512, 331, 3712, 38469, 90, 43879, 2414, 30072, 198, 198, 1212, 2163, 47850, 262, 29052, 27255, 1864, 284, 262, 2441, 44, 198, 282, 42289, 11, 685, 35632, 2123, 435, 13, 2177, 16151, 5450, 1378, 283, 87, 452, 13, 2398, 14, 8937, 14, 1433, 3312, 13, 3070, 36330, 2599, 198, 198, 12, 257, 14174, 20683, 625, 7559, 87, 15506, 290, 7559, 88, 15506, 318, 6157, 198, 198, 12, 611, 262, 2173, 6492, 351, 262, 4197, 389, 1969, 1576, 357, 1203, 621, 657, 13, 486, 3585, 198, 26069, 1945, 8, 262, 14174, 9093, 27906, 318, 11378, 290, 262, 22638, 3607, 262, 27255, 198, 198, 12, 611, 262, 14174, 9093, 27906, 318, 407, 11378, 11, 262, 7097, 3155, 286, 2173, 290, 262, 198, 29127, 20683, 318, 6157, 757, 10597, 262, 14174, 9093, 27906, 318, 11378, 198, 37811, 198, 8818, 2441, 12740, 263, 452, 876, 7, 87, 3712, 38469, 90, 43879, 2414, 5512, 331, 3712, 38469, 90, 43879, 2414, 30072, 198, 220, 220, 220, 2124, 62, 30073, 796, 2769, 30073, 7, 87, 8, 198, 220, 220, 220, 331, 62, 30073, 796, 2769, 30073, 7, 88, 8, 198, 220, 220, 220, 611, 5288, 7, 88, 8, 6624, 5415, 7, 88, 8, 198, 220, 220, 220, 220, 220, 220, 220, 4587, 796, 657, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 1729, 29127, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 981, 1729, 29127, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 44036, 796, 8562, 8081, 2234, 7, 87, 62, 30073, 11, 331, 62, 30073, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 62, 11147, 796, 1976, 27498, 7, 13664, 7, 87, 62, 30073, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1411, 62, 26069, 796, 1976, 27498, 7, 13664, 7, 87, 62, 30073, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 62, 11147, 764, 28, 44036, 58, 16, 60, 764, 10, 2124, 62, 30073, 764, 9, 44036, 58, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1411, 62, 26069, 796, 2352, 12195, 7, 88, 62, 30073, 764, 12, 331, 62, 11147, 8, 24457, 331, 62, 30073, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 477, 7, 25067, 62, 26069, 764, 27, 28, 657, 13, 486, 8, 8614, 4129, 7, 87, 62, 30073, 8, 1279, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1729, 29127, 796, 3991, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4587, 796, 44036, 58, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1461, 0, 7, 87, 62, 30073, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1461, 0, 7, 88, 62, 30073, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1461, 11085, 0, 7, 88, 62, 30073, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1461, 11085, 0, 7, 87, 62, 30073, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 4587, 198, 437, 198 ]
2.29902
612
<filename>examples/loltools/featured-games.jl<gh_stars>1-10 using LOLTools.SpectatorV4 api_key = get(ENV, "RIOT_TOKEN", "") platform = "kr" featured = SpectatorV4.featured_games(api_key, platform) # @info featured @info sort(featured.gameList, by = x -> x.gameId)[1].participants
[ 27, 34345, 29, 1069, 12629, 14, 75, 5978, 10141, 14, 69, 20980, 12, 19966, 13, 20362, 27, 456, 62, 30783, 29, 16, 12, 940, 198, 3500, 35513, 33637, 13, 49738, 1352, 53, 19, 198, 198, 15042, 62, 2539, 796, 651, 7, 1677, 53, 11, 366, 7112, 2394, 62, 10468, 43959, 1600, 366, 4943, 198, 24254, 796, 366, 38584, 1, 198, 69, 20980, 796, 13058, 1352, 53, 19, 13, 69, 20980, 62, 19966, 7, 15042, 62, 2539, 11, 3859, 8, 198, 2, 2488, 10951, 8096, 198, 31, 10951, 3297, 7, 69, 20980, 13, 6057, 8053, 11, 416, 796, 2124, 4613, 2124, 13, 6057, 7390, 38381, 16, 4083, 48013, 1187, 198 ]
2.577982
109
function boardtest{Lib<:PolyhedraLibrary}(lib::Lib) A1 = -eye(Int, 9) # x >= 0 b1 = zeros(Int, 9) A2 = eye(Int, 9) # x <= 1 b2 = ones(Int, 9) A3 = zeros(Int, 9, 9) b3 = 3 * ones(Int, 9) i = 1 for a = 1:3 for b = (a+1):3 for c = 1:3 for d = (c+1):3 ac = a + (c-1) * 3 ad = a + (d-1) * 3 bc = b + (c-1) * 3 bd = b + (d-1) * 3 A3[i, ac] = 1 A3[i, ad] = 1 A3[i, bc] = 1 A3[i, bd] = 1 i += 1 end end end end A = [A1; A2; A3] b = [b1; b2; b3] ine = SimpleHRepresentation(A, b) poly = polyhedron(ine, lib) @test !isempty(poly) ext = SimpleVRepresentation(getgenerators(poly)) target = ones(Int, 9) * (3 // 4) ok = false for i = 1:size(ext.V, 1) # In julia v0.4 [i,:] returns a row matrix and in v0.5 it is # a 1D vector hence the use of vec if vec(ext.V[i,:]) == target ok = true end end @test ok cutA = ones(Int, 1, 9) cutb = 6 Acut = [cutA; A] bcut = [cutb; b] inecut = SimpleHRepresentation(Acut, bcut) polycut = polyhedron(inecut, lib) @test !isempty(polycut) #(isredundant, certificate) = isredundantinequality(polycut, 1) #@test !isredundant #@test certificate == target @test !isredundantinequality(polycut, 1) @test IntSet([]) == getredundantinequalities(polycut) #(issredundant, scertificate) = isstronglyredundantinequality(polycut, 1) #@test !issredundant #@test scertificate == target #@test IntSet([]) == getstronglyredundantinequalities(polycut) end
[ 8818, 3096, 9288, 90, 25835, 27, 25, 34220, 704, 430, 23377, 92, 7, 8019, 3712, 25835, 8, 198, 220, 317, 16, 796, 532, 25379, 7, 5317, 11, 860, 8, 1303, 2124, 18189, 657, 198, 220, 275, 16, 796, 1976, 27498, 7, 5317, 11, 860, 8, 198, 220, 317, 17, 796, 4151, 7, 5317, 11, 860, 8, 1303, 2124, 19841, 352, 198, 220, 275, 17, 796, 3392, 7, 5317, 11, 860, 8, 198, 220, 317, 18, 796, 1976, 27498, 7, 5317, 11, 860, 11, 860, 8, 198, 220, 275, 18, 796, 513, 1635, 3392, 7, 5317, 11, 860, 8, 198, 220, 1312, 796, 352, 198, 220, 329, 257, 796, 352, 25, 18, 198, 220, 220, 220, 329, 275, 796, 357, 64, 10, 16, 2599, 18, 198, 220, 220, 220, 220, 220, 329, 269, 796, 352, 25, 18, 198, 220, 220, 220, 220, 220, 220, 220, 329, 288, 796, 357, 66, 10, 16, 2599, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 936, 796, 257, 1343, 357, 66, 12, 16, 8, 1635, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 512, 796, 257, 1343, 357, 67, 12, 16, 8, 1635, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 47125, 796, 275, 1343, 357, 66, 12, 16, 8, 1635, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 67, 796, 275, 1343, 357, 67, 12, 16, 8, 1635, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 317, 18, 58, 72, 11, 936, 60, 796, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 317, 18, 58, 72, 11, 512, 60, 796, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 317, 18, 58, 72, 11, 47125, 60, 796, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 317, 18, 58, 72, 11, 275, 67, 60, 796, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1312, 15853, 352, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 886, 198, 220, 317, 796, 685, 32, 16, 26, 317, 17, 26, 317, 18, 60, 198, 220, 275, 796, 685, 65, 16, 26, 275, 17, 26, 275, 18, 60, 198, 220, 287, 68, 796, 17427, 39, 40171, 341, 7, 32, 11, 275, 8, 198, 220, 7514, 796, 7514, 704, 1313, 7, 500, 11, 9195, 8, 198, 220, 2488, 9288, 5145, 271, 28920, 7, 35428, 8, 198, 220, 1070, 220, 796, 17427, 53, 40171, 341, 7, 1136, 8612, 2024, 7, 35428, 4008, 198, 220, 2496, 796, 3392, 7, 5317, 11, 860, 8, 1635, 357, 18, 3373, 604, 8, 198, 220, 12876, 796, 3991, 198, 220, 329, 1312, 796, 352, 25, 7857, 7, 2302, 13, 53, 11, 352, 8, 198, 220, 220, 220, 1303, 554, 474, 43640, 410, 15, 13, 19, 685, 72, 11, 47715, 5860, 257, 5752, 17593, 290, 287, 410, 15, 13, 20, 340, 318, 198, 220, 220, 220, 1303, 257, 352, 35, 15879, 12891, 262, 779, 286, 43030, 198, 220, 220, 220, 611, 43030, 7, 2302, 13, 53, 58, 72, 11, 25, 12962, 6624, 2496, 198, 220, 220, 220, 220, 220, 12876, 796, 2081, 198, 220, 220, 220, 886, 198, 220, 886, 198, 220, 2488, 9288, 12876, 628, 220, 2005, 32, 796, 3392, 7, 5317, 11, 352, 11, 860, 8, 198, 220, 2005, 65, 796, 718, 198, 220, 4013, 315, 796, 685, 8968, 32, 26, 317, 60, 198, 220, 275, 8968, 796, 685, 8968, 65, 26, 275, 60, 198, 220, 287, 721, 315, 796, 17427, 39, 40171, 341, 7, 32, 8968, 11, 275, 8968, 8, 198, 220, 7514, 8968, 796, 7514, 704, 1313, 7, 500, 8968, 11, 9195, 8, 198, 220, 2488, 9288, 5145, 271, 28920, 7, 35428, 8968, 8, 198, 220, 1303, 7, 271, 445, 917, 415, 11, 10703, 8, 796, 318, 445, 917, 29003, 13237, 7, 35428, 8968, 11, 352, 8, 198, 220, 1303, 31, 9288, 5145, 271, 445, 917, 415, 198, 220, 1303, 31, 9288, 10703, 6624, 2496, 198, 220, 2488, 9288, 5145, 271, 445, 917, 29003, 13237, 7, 35428, 8968, 11, 352, 8, 198, 220, 2488, 9288, 2558, 7248, 26933, 12962, 6624, 651, 445, 917, 29003, 13255, 871, 7, 35428, 8968, 8, 198, 1303, 7, 747, 445, 917, 415, 11, 629, 861, 22460, 8, 796, 318, 11576, 306, 445, 917, 29003, 13237, 7, 35428, 8968, 11, 352, 8, 198, 1303, 31, 9288, 5145, 747, 445, 917, 415, 198, 1303, 31, 9288, 629, 861, 22460, 6624, 2496, 198, 1303, 31, 9288, 2558, 7248, 26933, 12962, 6624, 651, 11576, 306, 445, 917, 29003, 13255, 871, 7, 35428, 8968, 8, 198, 437, 198 ]
2.029639
776
""" Oscillator{T<:Float64} Custom type to represent a SDOF oscillator. The type has two fields: - `f_n` is the natural frequency of the oscillator - `ζ_n` is the damping ratio # Examples ```julia-repl sdof = Oscillator( 1.0, 0.05 ) ``` """ struct Oscillator{T<:Float64} f_n::T ζ_n::T end """ Oscillator(f_n) Default initializer setting the damping ratio to 5% of critical - `f_n` is the natural frequency of the oscillator (in Hz) # Examples ```julia-repl f_n = 2.0 sdof = Oscillator(f_n) ``` """ Oscillator(f_n::T) where {T<:Float64} = Oscillator(f_n, 0.05) """ period(sdof::Oscillator) Natural period (s) of the sdof Oscillator. """ function period(sdof::Oscillator) return 1.0/sdof.f_n end @doc raw""" transfer(f::T, sdof::Oscillator) where {T<:Real} Compute the modulus of the transfer function for a SDOF system. The transfer function is defined as: ```math |H(f,f_n,\zeta_n)| = \frac{1}{\sqrt{ \left(1 - \beta^2 \right)^2 + \left(2\zeta_n\beta\right)^2 }} ``` where ``\beta`` is the tuning ratio defined by ``f/f_n``. # Examples ```julia-repl f = 2.0 sdof = Oscillator(1.0, 0.05) Hf = transfer(f, sdof) ``` See also: [`squared_transfer`](@ref) """ function transfer(f, sdof::Oscillator) # tuning ratio β = f / sdof.f_n return 1.0 / sqrt( (1.0 - β^2)^2 + (2sdof.ζ_n*β)^2 ) end """ squared_transfer(f, sdof::Oscillator) Compute the square of the transfer function for a SDOF system, `sdof`, at frequency `f`. # Examples ```julia-repl f = 2.0 # create sdof with natural frequency f_n=1.0 and damping ζ=0.05 sdof = Oscillator( 1.0, 0.05 ) Hf2 = squared_transfer( f, sdof ) ``` See also: [`transfer`](@ref) """ function squared_transfer(f, sdof::Oscillator) # tuning ratio β = f / sdof.f_n return 1.0 / ( (1.0 - β^2)^2 + (2sdof.ζ_n*β)^2 ) end """ transfer(f::Vector{T}, sdof::Oscillator) where T<:Real Computes the modulus of the transfer function of a SDOF for a vector of frequencies - `f::Vector` is the vector of frequencies - `sdof::Oscillator` is the oscillator instance # Examples ```julia-repl f = collect(range(0.1, stop=10.0, step=0.01)) sdof = Oscillator(1.0) Hf = transfer(f, sdof) ``` """ function transfer(f::Vector{T}, sdof::Oscillator) where T<:Real # tuning ratio Hf = similar(f) for i in 1:length(f) @inbounds Hf[i] = transfer(f[i], sdof) end return Hf end """ transfer!(Hf::Vector{T}, f::Vector{T}, sdof::Oscillator) where T<:Real Computes the modulus of the transfer function of a SDOF for a vector of frequencies in place - `Hf::Vector` is the pre-allocated vector into which the results are stored - `f::Vector` is the vector of frequencies - `sdof::Oscillator` is the oscillator instance # Examples ```julia-repl f = collect(range(0.1, stop=10.0, step=0.01)) sdof = Oscillator(1.0) Hf = similar(f) transfer!(Hf, f, sdof) ``` """ function transfer!(Hf::Vector{T}, f::Vector{T}, sdof::Oscillator) where T<:Real for i in 1:length(f) @inbounds Hf[i] = transfer(f[i],sdof) end return nothing end """ squared_transfer!(Hf2::Vector{T}, f::Vector{T}, sdof::Oscillator) where T<:Real Computes the square of the modulus of the transfer function of a SDOF for a vector of frequencies in place: - `Hf2::Vector` is the pre-allocated vector into which the results are stored - `f::Vector` is the vector of frequencies - `sdof::Oscillator` is the oscillator instance Inputs derive from the `Real` type and so are differentiable. # Examples ```julia-repl f = collect(range(0.1, stop=10.0, step=0.01)) sdof = Oscillator(1.0) Hf2 = similar(f) squared_transfer!(Hf2, f, sdof) ``` """ function squared_transfer!(Hf2::Vector{T}, f::Vector{T}, sdof::Oscillator) where T<:Real for i in 1:length(f) @inbounds Hf2[i] = squared_transfer(f[i],sdof) end return nothing end """ squared_transfer!(Hf2::Vector, f::Vector, sdof::Oscillator) Computes the square of the modulus of the transfer function of a SDOF for a vector of frequencies in place: - `Hf2::Vector` is the pre-allocated vector into which the results are stored - `f::Vector` is the vector of frequencies - `sdof::Oscillator` is the oscillator instance # Examples ```julia-repl f = collect(range(0.1, stop=10.0, step=0.01)) sdof = Oscillator(1.0) Hf2 = similar(f) squared_transfer!(Hf2, f, sdof) ``` """ function squared_transfer!(Hf2::Vector, f::Vector, sdof::Oscillator) for i in 1:length(f) Hf2[i] = squared_transfer(f[i],sdof) end return nothing end
[ 198, 37811, 198, 220, 220, 220, 440, 22360, 1352, 90, 51, 27, 25, 43879, 2414, 92, 198, 198, 15022, 2099, 284, 2380, 257, 9834, 19238, 24969, 1352, 13, 383, 2099, 468, 734, 7032, 25, 198, 220, 532, 4600, 69, 62, 77, 63, 318, 262, 3288, 8373, 286, 262, 24969, 1352, 198, 220, 532, 4600, 138, 114, 62, 77, 63, 318, 262, 21151, 278, 8064, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 220, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 352, 13, 15, 11, 657, 13, 2713, 1267, 198, 15506, 63, 198, 37811, 198, 7249, 440, 22360, 1352, 90, 51, 27, 25, 43879, 2414, 92, 198, 220, 220, 220, 277, 62, 77, 3712, 51, 198, 220, 220, 220, 7377, 114, 62, 77, 3712, 51, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 440, 22360, 1352, 7, 69, 62, 77, 8, 198, 198, 19463, 4238, 7509, 4634, 262, 21151, 278, 8064, 284, 642, 4, 286, 4688, 198, 220, 532, 4600, 69, 62, 77, 63, 318, 262, 3288, 8373, 286, 262, 24969, 1352, 357, 259, 26109, 8, 198, 198, 2, 1849, 27730, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 220, 220, 277, 62, 77, 796, 362, 13, 15, 198, 220, 220, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 69, 62, 77, 8, 198, 15506, 63, 198, 37811, 198, 46, 22360, 1352, 7, 69, 62, 77, 3712, 51, 8, 810, 1391, 51, 27, 25, 43879, 2414, 92, 796, 440, 22360, 1352, 7, 69, 62, 77, 11, 657, 13, 2713, 8, 628, 198, 37811, 198, 197, 41007, 7, 21282, 1659, 3712, 46, 22360, 1352, 8, 198, 198, 35364, 2278, 357, 82, 8, 286, 262, 45647, 1659, 440, 22360, 1352, 13, 198, 37811, 198, 8818, 2278, 7, 21282, 1659, 3712, 46, 22360, 1352, 8, 198, 197, 7783, 352, 13, 15, 14, 21282, 1659, 13, 69, 62, 77, 198, 437, 198, 198, 31, 15390, 8246, 37811, 198, 220, 220, 220, 4351, 7, 69, 3712, 51, 11, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 1391, 51, 27, 25, 15633, 92, 198, 198, 7293, 1133, 262, 953, 23515, 286, 262, 4351, 2163, 329, 257, 9834, 19238, 1080, 13, 198, 198, 464, 4351, 2163, 318, 5447, 355, 25, 198, 15506, 63, 11018, 198, 91, 39, 7, 69, 11, 69, 62, 77, 11, 59, 89, 17167, 62, 77, 14726, 796, 3467, 31944, 90, 16, 18477, 59, 31166, 17034, 90, 3467, 9464, 7, 16, 532, 3467, 31361, 61, 17, 3467, 3506, 8, 61, 17, 1343, 3467, 9464, 7, 17, 59, 89, 17167, 62, 77, 59, 31361, 59, 3506, 8, 61, 17, 34949, 198, 15506, 63, 198, 3003, 7559, 59, 31361, 15506, 318, 262, 24549, 8064, 5447, 416, 7559, 69, 14, 69, 62, 77, 15506, 13, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 220, 220, 277, 796, 362, 13, 15, 198, 220, 220, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 16, 13, 15, 11, 657, 13, 2713, 8, 198, 220, 220, 220, 367, 69, 796, 4351, 7, 69, 11, 45647, 1659, 8, 198, 15506, 63, 198, 198, 6214, 635, 25, 685, 63, 16485, 1144, 62, 39437, 63, 16151, 31, 5420, 8, 198, 37811, 198, 8818, 4351, 7, 69, 11, 45647, 1659, 3712, 46, 22360, 1352, 8, 198, 220, 220, 220, 1303, 24549, 8064, 198, 220, 220, 220, 27169, 796, 277, 1220, 45647, 1659, 13, 69, 62, 77, 198, 220, 220, 220, 1441, 352, 13, 15, 1220, 19862, 17034, 7, 357, 16, 13, 15, 532, 27169, 61, 17, 8, 61, 17, 1343, 357, 17, 21282, 1659, 13, 138, 114, 62, 77, 9, 26638, 8, 61, 17, 1267, 198, 437, 628, 198, 37811, 198, 197, 16485, 1144, 62, 39437, 7, 69, 11, 45647, 1659, 3712, 46, 22360, 1352, 8, 198, 198, 7293, 1133, 262, 6616, 286, 262, 4351, 2163, 329, 257, 9834, 19238, 1080, 11, 4600, 21282, 1659, 47671, 379, 8373, 4600, 69, 44646, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 197, 69, 796, 362, 13, 15, 198, 197, 2, 2251, 45647, 1659, 351, 3288, 8373, 277, 62, 77, 28, 16, 13, 15, 290, 21151, 278, 7377, 114, 28, 15, 13, 2713, 198, 197, 21282, 1659, 796, 440, 22360, 1352, 7, 352, 13, 15, 11, 657, 13, 2713, 1267, 198, 197, 39, 69, 17, 796, 44345, 62, 39437, 7, 277, 11, 45647, 1659, 1267, 198, 15506, 63, 198, 198, 6214, 635, 25, 685, 63, 39437, 63, 16151, 31, 5420, 8, 198, 37811, 198, 8818, 44345, 62, 39437, 7, 69, 11, 45647, 1659, 3712, 46, 22360, 1352, 8, 198, 220, 220, 220, 1303, 24549, 8064, 198, 220, 220, 220, 27169, 796, 277, 1220, 45647, 1659, 13, 69, 62, 77, 198, 220, 220, 220, 1441, 352, 13, 15, 1220, 357, 357, 16, 13, 15, 532, 27169, 61, 17, 8, 61, 17, 1343, 357, 17, 21282, 1659, 13, 138, 114, 62, 77, 9, 26638, 8, 61, 17, 1267, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 4351, 7, 69, 3712, 38469, 90, 51, 5512, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 309, 27, 25, 15633, 198, 198, 7293, 1769, 262, 953, 23515, 286, 262, 4351, 2163, 286, 257, 9834, 19238, 329, 257, 15879, 286, 19998, 198, 220, 532, 4600, 69, 3712, 38469, 63, 318, 262, 15879, 286, 19998, 198, 220, 532, 4600, 21282, 1659, 3712, 46, 22360, 1352, 63, 318, 262, 24969, 1352, 4554, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 277, 796, 2824, 7, 9521, 7, 15, 13, 16, 11, 2245, 28, 940, 13, 15, 11, 2239, 28, 15, 13, 486, 4008, 198, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 16, 13, 15, 8, 198, 220, 367, 69, 796, 4351, 7, 69, 11, 45647, 1659, 8, 198, 15506, 63, 198, 37811, 198, 8818, 4351, 7, 69, 3712, 38469, 90, 51, 5512, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 309, 27, 25, 15633, 198, 220, 220, 220, 1303, 24549, 8064, 198, 220, 220, 220, 367, 69, 796, 2092, 7, 69, 8, 198, 220, 220, 220, 329, 1312, 287, 352, 25, 13664, 7, 69, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 259, 65, 3733, 367, 69, 58, 72, 60, 796, 4351, 7, 69, 58, 72, 4357, 45647, 1659, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 367, 69, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 4351, 0, 7, 39, 69, 3712, 38469, 90, 51, 5512, 277, 3712, 38469, 90, 51, 5512, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 309, 27, 25, 15633, 198, 198, 7293, 1769, 262, 953, 23515, 286, 262, 4351, 2163, 286, 257, 9834, 19238, 329, 257, 15879, 286, 19998, 287, 1295, 198, 197, 12, 4600, 39, 69, 3712, 38469, 63, 318, 262, 662, 12, 439, 10533, 15879, 656, 543, 262, 2482, 389, 8574, 198, 220, 220, 220, 532, 4600, 69, 3712, 38469, 63, 318, 262, 15879, 286, 19998, 198, 220, 220, 220, 532, 4600, 21282, 1659, 3712, 46, 22360, 1352, 63, 318, 262, 24969, 1352, 4554, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 220, 220, 277, 796, 2824, 7, 9521, 7, 15, 13, 16, 11, 2245, 28, 940, 13, 15, 11, 2239, 28, 15, 13, 486, 4008, 198, 220, 220, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 16, 13, 15, 8, 198, 220, 220, 220, 367, 69, 796, 2092, 7, 69, 8, 198, 220, 220, 220, 4351, 0, 7, 39, 69, 11, 277, 11, 45647, 1659, 8, 198, 15506, 63, 198, 37811, 198, 8818, 4351, 0, 7, 39, 69, 3712, 38469, 90, 51, 5512, 277, 3712, 38469, 90, 51, 5512, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 309, 27, 25, 15633, 198, 197, 1640, 1312, 287, 352, 25, 13664, 7, 69, 8, 198, 197, 197, 31, 259, 65, 3733, 367, 69, 58, 72, 60, 796, 4351, 7, 69, 58, 72, 4357, 21282, 1659, 8, 198, 197, 437, 198, 197, 7783, 2147, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 44345, 62, 39437, 0, 7, 39, 69, 17, 3712, 38469, 90, 51, 5512, 277, 3712, 38469, 90, 51, 5512, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 309, 27, 25, 15633, 198, 198, 7293, 1769, 262, 6616, 286, 262, 953, 23515, 286, 262, 4351, 2163, 286, 257, 9834, 19238, 329, 257, 15879, 286, 19998, 287, 1295, 25, 198, 197, 12, 4600, 39, 69, 17, 3712, 38469, 63, 318, 262, 662, 12, 439, 10533, 15879, 656, 543, 262, 2482, 389, 8574, 198, 220, 220, 220, 532, 4600, 69, 3712, 38469, 63, 318, 262, 15879, 286, 19998, 198, 220, 220, 220, 532, 4600, 21282, 1659, 3712, 46, 22360, 1352, 63, 318, 262, 24969, 1352, 4554, 198, 20560, 82, 27099, 422, 262, 4600, 15633, 63, 2099, 290, 523, 389, 1180, 3379, 13, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 220, 220, 277, 796, 2824, 7, 9521, 7, 15, 13, 16, 11, 2245, 28, 940, 13, 15, 11, 2239, 28, 15, 13, 486, 4008, 198, 220, 220, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 16, 13, 15, 8, 198, 220, 220, 220, 367, 69, 17, 796, 2092, 7, 69, 8, 198, 220, 220, 220, 44345, 62, 39437, 0, 7, 39, 69, 17, 11, 277, 11, 45647, 1659, 8, 198, 15506, 63, 198, 37811, 198, 8818, 44345, 62, 39437, 0, 7, 39, 69, 17, 3712, 38469, 90, 51, 5512, 277, 3712, 38469, 90, 51, 5512, 45647, 1659, 3712, 46, 22360, 1352, 8, 810, 309, 27, 25, 15633, 198, 197, 1640, 1312, 287, 352, 25, 13664, 7, 69, 8, 198, 197, 197, 31, 259, 65, 3733, 367, 69, 17, 58, 72, 60, 796, 44345, 62, 39437, 7, 69, 58, 72, 4357, 21282, 1659, 8, 198, 197, 437, 198, 197, 7783, 2147, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 44345, 62, 39437, 0, 7, 39, 69, 17, 3712, 38469, 11, 277, 3712, 38469, 11, 45647, 1659, 3712, 46, 22360, 1352, 8, 198, 198, 7293, 1769, 262, 6616, 286, 262, 953, 23515, 286, 262, 4351, 2163, 286, 257, 9834, 19238, 329, 257, 15879, 286, 19998, 287, 1295, 25, 198, 197, 12, 4600, 39, 69, 17, 3712, 38469, 63, 318, 262, 662, 12, 439, 10533, 15879, 656, 543, 262, 2482, 389, 8574, 198, 220, 220, 220, 532, 4600, 69, 3712, 38469, 63, 318, 262, 15879, 286, 19998, 198, 220, 220, 220, 532, 4600, 21282, 1659, 3712, 46, 22360, 1352, 63, 318, 262, 24969, 1352, 4554, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 12, 35666, 198, 220, 220, 220, 277, 796, 2824, 7, 9521, 7, 15, 13, 16, 11, 2245, 28, 940, 13, 15, 11, 2239, 28, 15, 13, 486, 4008, 198, 220, 220, 220, 45647, 1659, 796, 440, 22360, 1352, 7, 16, 13, 15, 8, 198, 220, 220, 220, 367, 69, 17, 796, 2092, 7, 69, 8, 198, 220, 220, 220, 44345, 62, 39437, 0, 7, 39, 69, 17, 11, 277, 11, 45647, 1659, 8, 198, 15506, 63, 198, 37811, 198, 8818, 44345, 62, 39437, 0, 7, 39, 69, 17, 3712, 38469, 11, 277, 3712, 38469, 11, 45647, 1659, 3712, 46, 22360, 1352, 8, 198, 197, 1640, 1312, 287, 352, 25, 13664, 7, 69, 8, 198, 197, 197, 39, 69, 17, 58, 72, 60, 796, 44345, 62, 39437, 7, 69, 58, 72, 4357, 21282, 1659, 8, 198, 197, 437, 198, 197, 7783, 2147, 198, 437, 198 ]
2.426978
1,883
using ModelingToolkit using SteadyStateDiffEq using Test @parameters t r @variables x(t) @derivatives D'~t eqs = [D(x) ~ x^2-r] de = ODESystem(eqs) for factor in [1e-1, 1e0, 1e10], u0_p in [(2.34,2.676),(22.34,1.632),(.3,15.676),(0.3,0.006)] u0 = [x => factor*u0_p[1]] p = [r => factor*u0_p[2]] ss_prob = SteadyStateProblem(de,u0,p) sol = solve(ss_prob,SSRootfind()).u[1] @test abs(sol^2 - factor*u0_p[2]) < 1e-8 ss_prob = SteadyStateProblemExpr(de,u0,p) sol_expr = solve(eval(ss_prob),SSRootfind()).u[1] @test all(x->x==0,sol-sol_expr) end
[ 3500, 9104, 278, 25391, 15813, 198, 3500, 45445, 88, 9012, 28813, 36, 80, 198, 3500, 6208, 198, 198, 31, 17143, 7307, 256, 374, 198, 31, 25641, 2977, 2124, 7, 83, 8, 198, 31, 1082, 452, 2929, 360, 6, 93, 83, 198, 27363, 82, 796, 685, 35, 7, 87, 8, 5299, 2124, 61, 17, 12, 81, 60, 198, 2934, 796, 440, 30910, 6781, 7, 27363, 82, 8, 198, 198, 1640, 5766, 287, 685, 16, 68, 12, 16, 11, 352, 68, 15, 11, 352, 68, 940, 4357, 334, 15, 62, 79, 287, 47527, 17, 13, 2682, 11, 17, 13, 42548, 828, 7, 1828, 13, 2682, 11, 16, 13, 21, 2624, 828, 7, 13, 18, 11, 1314, 13, 42548, 828, 7, 15, 13, 18, 11, 15, 13, 28041, 15437, 198, 220, 220, 220, 334, 15, 796, 685, 87, 5218, 5766, 9, 84, 15, 62, 79, 58, 16, 11907, 198, 220, 220, 220, 279, 796, 685, 81, 5218, 5766, 9, 84, 15, 62, 79, 58, 17, 11907, 198, 220, 220, 220, 37786, 62, 1676, 65, 796, 45445, 88, 9012, 40781, 7, 2934, 11, 84, 15, 11, 79, 8, 198, 220, 220, 220, 1540, 796, 8494, 7, 824, 62, 1676, 65, 11, 5432, 30016, 19796, 3419, 737, 84, 58, 16, 60, 198, 220, 220, 220, 2488, 9288, 2352, 7, 34453, 61, 17, 532, 5766, 9, 84, 15, 62, 79, 58, 17, 12962, 1279, 352, 68, 12, 23, 198, 220, 220, 220, 37786, 62, 1676, 65, 796, 45445, 88, 9012, 40781, 3109, 1050, 7, 2934, 11, 84, 15, 11, 79, 8, 198, 220, 220, 220, 1540, 62, 31937, 796, 8494, 7, 18206, 7, 824, 62, 1676, 65, 828, 5432, 30016, 19796, 3419, 737, 84, 58, 16, 60, 198, 220, 220, 220, 2488, 9288, 477, 7, 87, 3784, 87, 855, 15, 11, 34453, 12, 34453, 62, 31937, 8, 198, 437, 198 ]
1.891447
304
<filename>src/multiTracer.jl #= ============================================ Generate 𝐹 and ∇ₓ𝐹 from user input ============================================ =# # TODO replace this with DiffEqOperators when possible struct LinearOperators{T<:Tuple} ops::T end LinearOperators(ops...) = LinearOperators((ops...,)) SparseArrays.blockdiag(As::LinearOperators...) = blockdiag([sum(A.ops) for A in As]...) function LinearAlgebra.mul!(du, A::LinearOperators, u, α, β) for (i, op) in enumerate(A.ops) (i==1) ? mul!(du, op, u, α, β) : mul!(du, op, u, α, 1) end du end LinearAlgebra.factorize(A::LinearOperators) = factorize(sum(A.ops)) Base.:\(A::LinearOperators, u::AbstractArray) = factorize(A) \ u Base.:+(A::LinearOperators, B::AbstractSparseArray) = LinearOperators(A.ops..., B) Base.:+(B::AbstractSparseArray, A::LinearOperators) = A + B function Base.:*(A::LinearOperators, u::AbstractArray) # has to be same type! du = similar(u) mul!(du, A, u, 1, 0) end export LinearOperators # AIBECSFunction creates an ODEFunction from the Ts and Gs AIBECSFunction(T::AbstractSparseArray, G::Function) = AIBECSFunction(p -> T, G, T.n) AIBECSFunction(T::Function, G::Function, nb::Int) = AIBECSFunction(T, (G,), nb) function AIBECSFunction(T::Function, Gs::Tuple, nb::Int) nt = length(Gs) # if a single T is given, then nt is given by the number of Gs Tidx = ones(Int64, nt) # and all the tracers share the same T AIBECSFunction((T,), Gs, nb, nt, Tidx) end function AIBECSFunction(Ts::Tuple, Gs::Tuple, nb::Int, nt::Int=length(Ts), Tidx::AbstractVector=1:nt) if all(isinplace(G, nt + 2) for G in Gs) # +2 to account for dx and p iipAIBECSFunction(Ts, Gs, nb, nt, Tidx) else oopAIBECSFunction(Ts, Gs, nb, nt, Tidx) end end function iipAIBECSFunction(Ts, Gs, nb, nt=length(Ts), Tidx=1:nt) tracers(u) = state_to_tracers(u, nb, nt) tracer(u, i) = state_to_tracer(u, nb, nt, i) function G(du, u, p) for j in 1:nt Gs[j](tracer(du, j), tracers(u)..., p) end du end function f(du, u, p, t=0) G(du, u, p) for jT in eachindex(Ts) op = Ts[jT](p) for j in findall(Tidx .== jT) mul!(tracer(du, j), op, tracer(u, j), -1, 1) end end du end # Jacobian ∇ₓG(u, p) = inplace_local_jacobian(Gs, u, p, nt, nb) function T(p) uniqueTs = [Tⱼ(p) for Tⱼ in Ts] blockdiag([uniqueTs[Tidx[j]] for j in 1:nt]...) end jac(u, p, t=0) = ∇ₓG(u, p) - T(p) return ODEFunction{true}(f, jac=jac) end function oopAIBECSFunction(Ts, Gs, nb, nt=length(Ts), Tidx=1:nt) tracers(u) = state_to_tracers(u, nb, nt) tracer(u, i) = state_to_tracer(u, nb, nt, i) G(u, p) = reduce(vcat, Gⱼ(tracers(u)..., p) for Gⱼ in Gs) function f(u, p, t=0) du = copy(G(u, p)) for jT in eachindex(Ts) op = Ts[jT](p) for j in findall(Tidx .== jT) mul!(tracer(du, j), op, tracer(u, j), -1, 1) end end du end # Jacobian ∇ₓG(u, p) = local_jacobian(Gs, u, p, nt, nb) function T(p) uniqueTs = [Tⱼ(p) for Tⱼ in Ts] blockdiag([uniqueTs[Tidx[j]] for j in 1:nt]...) end jac(u, p, t=0) = ∇ₓG(u, p) - T(p) return ODEFunction(f, jac=jac) end # AIBECSFunction calls itself to allow for both λ::Vector and p::APar function AIBECSFunction(Ts, Gs, nb::Int, ::Type{P}) where {P <: APar} AIBECSFunction(AIBECSFunction(Ts, Gs, nb), P) end function AIBECSFunction(fun::ODEFunction{false}, ::Type{P}) where {P <: APar} jac(u, p::P, t=0) = fun.jac(u, p, t) jac(u, λ::Vector, t=0) = fun.jac(u, λ2p(P, λ), t) f(u, p::P, t=0) = fun.f(u, p, t) f(u, λ::Vector, t=0) = fun.f(u, λ2p(P, λ), t) return ODEFunction{false}(f, jac=jac) end function AIBECSFunction(fun::ODEFunction{true}, ::Type{P}) where {P <: APar} jac(u, p::P, t=0) = fun.jac(u, p, t) jac(u, λ::Vector, t=0) = fun.jac(u, λ2p(P, λ), t) f(du, u, p::P, t=0) = fun.f(du, u, p, t) f(du, u, λ::Vector, t=0) = fun.f(du, u, λ2p(P, λ), t) return ODEFunction{true}(f, jac=jac) end export AIBECSFunction """ F, ∇ₓF = F_and_∇ₓF(Ts, Gs, nb) Returns the state function `F` and its Jacobian, `∇ₓF`. F, ∇ₓF = F_and_∇ₓF(T, Gs, nb) Returns the state function `F` and its Jacobian, `∇ₓF` (with all tracers transported by single `T`). This function is deprecated. Use F = AIBECSFunction(Ts, Gs, nb) instead. You can then call `F(x,p)` for the tendencies, and `F(Val{:jac},x,p)` for the Jacobian. """ function F_and_∇ₓF(fun::ODEFunction) Base.depwarn("""Deprecation: F, ∇ₓF = F_and_∇ₓF(args...) is deprecated. Use F = AIBECSFunction(args...) instead! (And then you can still call `F(x,p)`.) """, :F_and_∇ₓF, force=true) fun.f, fun.jac end F_and_∇ₓF(args...) = F_and_∇ₓF(AIBECSFunction(args...)) export F_and_∇ₓF """ localderivative(G, x, p) localderivative(Gᵢ, xs, i, p) localderivative(Gᵢ, dx, xs, i, p) Returns the "local" derivative of `G` (or `Gᵢ`), i.e., equivalent to the vector ``` ∇ₓG(x,p) * ones(size(x)) ``` but using ForwardDiff's Jacobian instead. """ function localderivative(G, x, p) # for single tracer return ForwardDiff.derivative(λ -> G(x .+ λ, p), 0.0) end function localderivative(Gᵢ, xs, j, p) # for multiple tracers return ForwardDiff.derivative(λ -> Gᵢ(perturb_tracer(xs, j, λ)..., p), 0.0) end function localderivative(Gᵢ!, dx, xs, j, p) # if Gᵢ are in-place return ForwardDiff.derivative((dx, λ) -> Gᵢ!(dx, perturb_tracer(xs, j, λ)..., p), dx, 0.0) end perturb_tracer(xs, j, λ) = (xs[1:j - 1]..., xs[j] .+ λ, xs[j + 1:end]...) """ F, L, NL, ∇ₓF, ∇ₓL, ∇ₓNL, T = split_state_function_and_Jacobian(Ts, Ls, NLs, nb) Returns the state function `F` and its jacobian, `∇ₓF`, as well as a collection of split operators. This is experimental. Use at your own risk! """ function split_state_function_and_Jacobian(Ts::Tuple, Ls::Tuple, NLs::Tuple, nb) nt = length(Ts) tracers(x) = state_to_tracers(x, nb, nt) T(p) = blockdiag([Tⱼ(p) for Tⱼ in Ts]...) # Big T (linear part) NL(x, p) = reduce(vcat, NLⱼ(tracers(x)..., p) for NLⱼ in NLs) # nonlinear part L(x, p) = reduce(vcat, Lⱼ(tracers(x)..., p) for Lⱼ in Ls) # nonlinear part F(x, p) = NL(x, p) + L(x, p) - T(p) * x # full 𝐹(𝑥) = -T 𝑥 + 𝐺(𝑥) ∇ₓNL(x, p) = local_jacobian(NLs, x, p, nt, nb) # Jacobian of nonlinear part ∇ₓL(p) = local_jacobian(Ls, zeros(nt * nb), p, nt, nb) # Jacobian of nonlinear part ∇ₓF(x, p) = ∇ₓNL(x, p) + ∇ₓL(p) - T(p) # full Jacobian ∇ₓ𝐹(𝑥) = -T + ∇ₓ𝐺(𝑥) return F, L, NL, ∇ₓF, ∇ₓL, ∇ₓNL, T end function split_state_function_and_Jacobian(T, L, NL, nb) F(x, p) = NL(x, p) + L(x, p) - T(p) * x # full 𝐹(𝑥) ∇ₓNL(x, p) = sparse(Diagonal(localderivative(NL, x, p))) # Jacobian of nonlinear part ∇ₓL(p) = sparse(Diagonal(localderivative(L, zeros(nb), p))) # Jacobian of nonlinear part ∇ₓF(x, p) = ∇ₓNL(x, p) + ∇ₓL(p) - T(p) # full Jacobian ∇ₓ𝐹(𝑥) = -T + ∇ₓ𝐺(𝑥) return F, L, NL, ∇ₓF, ∇ₓL, ∇ₓNL, T end export split_state_function_and_Jacobian function local_jacobian(Gs, x, p, nt, nb) return reduce(vcat, local_jacobian_row(Gⱼ, x, p, nt, nb) for Gⱼ in Gs) end function inplace_local_jacobian(Gs, x, p, nt, nb) return reduce(vcat, inplace_local_jacobian_row(Gⱼ!, x, p, nt, nb) for Gⱼ! in Gs) end function local_jacobian_row(Gᵢ, x, p, nt, nb) tracers(x) = state_to_tracers(x, nb, nt) return reduce(hcat, sparse(Diagonal(localderivative(Gᵢ, tracers(x), j, p))) for j in 1:nt) end function inplace_local_jacobian_row(Gᵢ!, x, p, nt, nb) tracers(x) = state_to_tracers(x, nb, nt) dx = Vector{Float64}(undef, nb) return reduce(hcat, sparse(Diagonal(localderivative(Gᵢ!, dx, tracers(x), j, p))) for j in 1:nt) end #= ============================================ Generate 𝑓 and derivatives from user input ============================================ =# function generate_f(ωs, μx, σ²x, v, ωp, ::Type{T}) where {T <: APar} nt, nb = length(ωs), length(v) tracers(x) = state_to_tracers(x, nb, nt) f(x, λorp) = ωp * mismatch(T, λorp) + sum([ωⱼ * mismatch(xⱼ, μⱼ, σⱼ², v) for (ωⱼ, xⱼ, μⱼ, σⱼ²) in zip(ωs, tracers(x), μx, σ²x)]) return f end function generate_f(ωs, ωp, grd, obs, ::Type{T}; kwargs...) where {T <: APar} nt, nb = length(ωs), count(iswet(grd)) tracers(x) = state_to_tracers(x, nb, nt) Ms = [interpolationmatrix(grd, obsⱼ) for obsⱼ in obs] cs = get(kwargs, :cs, (collect(identity for i in 1:nt)...,)) f(x, λorp) = ωp * mismatch(T, λorp) + sum([ωⱼ * mismatch(xⱼ, grd, obsⱼ, M=Mⱼ, c=cⱼ) for (ωⱼ, xⱼ, obsⱼ, Mⱼ, cⱼ) in zip(ωs, tracers(x), obs, Ms, cs)]) return f end function generate_f(ωs, ωp, grd, modify::Function, obs, ::Type{T}) where {T <: APar} nt, nb = length(ωs), count(iswet(grd)) Ms = [interpolationmatrix(grd, obsⱼ) for obsⱼ in obs] iwets = [iswet(grd, obsⱼ) for obsⱼ in obs] function f(x, λorp) xs = unpack_tracers(x, grd) return ωp * mismatch(T, λorp) + sum([ωᵢ * indirectmismatch(xs, grd, modify, obs, i, Mᵢ, iwetᵢ) for (i, (ωᵢ, Mᵢ, iwetᵢ)) in enumerate(zip(ωs, Ms, iwets))]) end return f end function generate_∇ₓf(ωs, μx, σ²x, v) nt, nb = length(ωs), length(v) tracers(x) = state_to_tracers(x, nb, nt) ∇ₓf(x) = reduce(hcat, ωⱼ * ∇mismatch(xⱼ, μⱼ, σⱼ², v) for (ωⱼ, xⱼ, μⱼ, σⱼ²) in zip(ωs, tracers(x), μx, σ²x)) ∇ₓf(x, p) = ∇ₓf(x) return ∇ₓf end function generate_∇ₓf(ωs, grd, obs; kwargs...) nt, nb = length(ωs), count(iswet(grd)) tracers(x) = state_to_tracers(x, nb, nt) Ms = [interpolationmatrix(grd, obsⱼ) for obsⱼ in obs] cs = get(kwargs, :cs, (collect(identity for i in 1:nt)...,)) ∇ₓf(x) = reduce(hcat, ωⱼ * ∇mismatch(xⱼ, grd, obsⱼ, M=Mⱼ, c=cⱼ) for (ωⱼ, xⱼ, obsⱼ, Mⱼ, cⱼ) in zip(ωs, tracers(x), obs, Ms, cs)) ∇ₓf(x, p) = ∇ₓf(x) return ∇ₓf end function generate_∇ₓf(ωs, grd, modify::Function, obs) nt, nb = length(ωs), count(iswet(grd)) Ms = [interpolationmatrix(grd, obsⱼ) for obsⱼ in obs] iwets = [iswet(grd, obsⱼ) for obsⱼ in obs] function ∇ₓf(x) xs = unpack_tracers(x, grd) sum([ωᵢ * ∇indirectmismatch(unpack_tracers(x, grd), grd, modify, obs, i, Mᵢ, iwetᵢ) for (i, (ωᵢ, Mᵢ, iwetᵢ)) in enumerate(zip(ωs, Ms, iwets))]) end ∇ₓf(x, p) = ∇ₓf(x) return ∇ₓf end function f_and_∇ₓf(ωs, μx, σ²x, v, ωp, ::Type{T}) where {T <: APar} generate_f(ωs, μx, σ²x, v, ωp, T), generate_∇ₓf(ωs, μx, σ²x, v) end function f_and_∇ₓf(ωs, ωp, grd, obs, ::Type{T}; kwargs...) where {T <: APar} generate_f(ωs, ωp, grd, obs, T; kwargs...), generate_∇ₓf(ωs, grd, obs; kwargs...) end function f_and_∇ₓf(ωs, ωp, grd, modify::Function, obs, ::Type{T}) where {T <: APar} generate_f(ωs, ωp, grd, modify, obs, T), generate_∇ₓf(ωs, grd, modify, obs) end export f_and_∇ₓf """ mismatch(x, xobs, σ²xobs, v) Volume-weighted mismatch of modelled tracer `x` against observed mean, `xobs`, given observed variance, `σ²xobs`, and volumes `v`. """ function mismatch(x, xobs, σ²xobs, v) δx = x - xobs W = Diagonal(v ./ σ²xobs) return 0.5 * transpose(δx) * W * δx / (transpose(xobs) * W * xobs) end mismatch(x, ::Missing, args...) = 0 """ ∇mismatch(x, xobs, σ²xobs, v) Adjoint of the gradient of `mismatch(x, xobs, σ²xobs, v)`. """ function ∇mismatch(x, xobs, σ²xobs, v) δx = x - xobs W = Diagonal(v ./ σ²xobs) return transpose(W * δx) / (transpose(xobs) * W * xobs) end ∇mismatch(x, ::Missing, args...) = transpose(zeros(length(x))) ## new functions for more generic obs packages # TODO Add an optional function argument to transform the data before computingn the mismatch # Example if for isotope tracers X where one ususally wants to minimize the mismatch in δ or ε. function mismatch(x, grd::OceanGrid, obs; c=identity, W=I, M=interpolationmatrix(grd, obs), iwet=iswet(grd, obs)) o = view(obs, iwet) δx = M * c(x) - o return 0.5 * transpose(δx) * W * δx / (transpose(o) * W * o) end mismatch(x, grd::OceanGrid, ::Missing; kwargs...) = 0 function ∇mismatch(x, grd::OceanGrid, obs; c=identity, W=I, M=interpolationmatrix(grd, obs), iwet=iswet(grd, obs)) ∇c = Diagonal(ForwardDiff.derivative(λ -> c(x .+ λ), 0.0)) o = view(obs, iwet) δx = M * c(x) - o return transpose(W * δx) * M * ∇c / (transpose(o) * W * o) end ∇mismatch(x, grd::OceanGrid, ::Missing; kwargs...) = transpose(zeros(length(x))) # In case the mismatch is not based on the tracer but on some function of it # TODO Add option for correlation matrix for Bayesian inferenece function indirectmismatch(xs::Tuple, grd::OceanGrid, modify::Function, obs, i, M=interpolationmatrix(grd, obs[i]), iwet=iswet(grd, obs[i])) x2 = modify(xs...) out = 0.0 o = obs[i][iwet, :value] δx = M * x2[i] - o return 0.5 * transpose(δx) * δx / (transpose(o) * o) end function ∇indirectmismatch(xs::Tuple, grd::OceanGrid, modify::Function, obs, i, M=interpolationmatrix(grd, obs[i]), iwet=iswet(grd, obs[i])) x2 = modify(xs...) o = obs[i][iwet, :value] δx = M * x2[i] - o ∇modᵢ = ∇modify(modify, xs, i) return transpose(δx) * M * ∇modᵢ / (transpose(o) * o) end # TODO think of more efficient way to avoid recomputing ∇modify whole for each i function ∇modify(modify, xs, i, j) return sparse(Diagonal(ForwardDiff.derivative(λ -> modify(perturb_tracer(xs, j, λ)...)[i], 0.0))) end ∇modify(modify, xs, i) = reduce(hcat, ∇modify(modify, xs, i, j) for j in 1:length(xs)) #= ============================================ multi-tracer norm ============================================ =# function volumeweighted_norm(nt, v) w = repeat(v, nt) return nrm(x) = transpose(x) * Diagonal(w) * x end #= ============================================ unpacking of multi-tracers ============================================ =# state_to_tracers(x, nb, nt) = ntuple(i -> state_to_tracer(x, nb, nt, i), nt) state_to_tracer(x, nb, nt, i) = view(x, tracer_indices(nb, nt, i)) function state_to_tracers(x, grd) nb = number_of_wet_boxes(grd) nt = Int(round(length(x) / nb)) return state_to_tracers(x, nb, nt) end tracer_indices(nb, nt, i) = (i - 1) * nb + 1:i * nb tracers_to_state(xs) = reduce(vcat, xs) export state_to_tracers, state_to_tracer, tracers_to_state, tracer_indices # Alias for better name unpack_tracers = state_to_tracers export unpack_tracers
[ 27, 34345, 29, 10677, 14, 41684, 2898, 11736, 13, 20362, 628, 628, 198, 2, 28, 46111, 2559, 18604, 198, 8645, 378, 220, 47728, 238, 117, 290, 18872, 229, 158, 224, 241, 47728, 238, 117, 422, 2836, 5128, 198, 10052, 25609, 796, 2, 198, 198, 2, 16926, 46, 6330, 428, 351, 10631, 36, 80, 18843, 2024, 618, 1744, 198, 7249, 44800, 18843, 2024, 90, 51, 27, 25, 51, 29291, 92, 198, 220, 220, 220, 39628, 3712, 51, 198, 437, 198, 14993, 451, 18843, 2024, 7, 2840, 23029, 796, 44800, 18843, 2024, 19510, 2840, 986, 11, 4008, 198, 50, 29572, 3163, 20477, 13, 9967, 10989, 363, 7, 1722, 3712, 14993, 451, 18843, 2024, 23029, 796, 2512, 10989, 363, 26933, 16345, 7, 32, 13, 2840, 8, 329, 317, 287, 1081, 60, 23029, 198, 8818, 44800, 2348, 29230, 13, 76, 377, 0, 7, 646, 11, 317, 3712, 14993, 451, 18843, 2024, 11, 334, 11, 26367, 11, 27169, 8, 198, 220, 220, 220, 329, 357, 72, 11, 1034, 8, 287, 27056, 378, 7, 32, 13, 2840, 8, 198, 220, 220, 220, 220, 220, 220, 220, 357, 72, 855, 16, 8, 5633, 35971, 0, 7, 646, 11, 1034, 11, 334, 11, 26367, 11, 27169, 8, 1058, 35971, 0, 7, 646, 11, 1034, 11, 334, 11, 26367, 11, 352, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 7043, 198, 437, 198, 14993, 451, 2348, 29230, 13, 31412, 1096, 7, 32, 3712, 14993, 451, 18843, 2024, 8, 796, 5766, 1096, 7, 16345, 7, 32, 13, 2840, 4008, 198, 14881, 13, 7479, 7, 32, 3712, 14993, 451, 18843, 2024, 11, 334, 3712, 23839, 19182, 8, 796, 5766, 1096, 7, 32, 8, 3467, 334, 198, 14881, 11207, 33747, 32, 3712, 14993, 451, 18843, 2024, 11, 347, 3712, 23839, 50, 29572, 19182, 8, 796, 44800, 18843, 2024, 7, 32, 13, 2840, 986, 11, 347, 8, 198, 14881, 11207, 33747, 33, 3712, 23839, 50, 29572, 19182, 11, 317, 3712, 14993, 451, 18843, 2024, 8, 796, 317, 1343, 347, 198, 8818, 7308, 11207, 9, 7, 32, 3712, 14993, 451, 18843, 2024, 11, 334, 3712, 23839, 19182, 8, 1303, 468, 284, 307, 976, 2099, 0, 198, 220, 220, 220, 7043, 796, 2092, 7, 84, 8, 198, 220, 220, 220, 35971, 0, 7, 646, 11, 317, 11, 334, 11, 352, 11, 657, 8, 198, 437, 198, 39344, 44800, 18843, 2024, 198, 198, 2, 9552, 33, 2943, 20802, 4575, 8075, 281, 440, 7206, 22203, 422, 262, 13146, 290, 402, 82, 198, 32, 9865, 2943, 20802, 4575, 7, 51, 3712, 23839, 50, 29572, 19182, 11, 402, 3712, 22203, 8, 796, 9552, 33, 2943, 20802, 4575, 7, 79, 4613, 309, 11, 402, 11, 309, 13, 77, 8, 198, 32, 9865, 2943, 20802, 4575, 7, 51, 3712, 22203, 11, 402, 3712, 22203, 11, 299, 65, 3712, 5317, 8, 796, 9552, 33, 2943, 20802, 4575, 7, 51, 11, 357, 38, 11, 828, 299, 65, 8, 198, 8818, 9552, 33, 2943, 20802, 4575, 7, 51, 3712, 22203, 11, 402, 82, 3712, 51, 29291, 11, 299, 65, 3712, 5317, 8, 198, 220, 220, 220, 299, 83, 796, 4129, 7, 33884, 8, 1303, 611, 257, 2060, 309, 318, 1813, 11, 788, 299, 83, 318, 1813, 416, 262, 1271, 286, 402, 82, 198, 220, 220, 220, 48957, 87, 796, 3392, 7, 5317, 2414, 11, 299, 83, 8, 1303, 290, 477, 262, 491, 49908, 2648, 262, 976, 309, 198, 220, 220, 220, 9552, 33, 2943, 20802, 4575, 19510, 51, 11, 828, 402, 82, 11, 299, 65, 11, 299, 83, 11, 48957, 87, 8, 198, 437, 198, 8818, 9552, 33, 2943, 20802, 4575, 7, 33758, 3712, 51, 29291, 11, 402, 82, 3712, 51, 29291, 11, 299, 65, 3712, 5317, 11, 299, 83, 3712, 5317, 28, 13664, 7, 33758, 828, 48957, 87, 3712, 23839, 38469, 28, 16, 25, 429, 8, 198, 220, 220, 220, 611, 477, 7, 45763, 5372, 7, 38, 11, 299, 83, 1343, 362, 8, 329, 402, 287, 402, 82, 8, 1303, 1343, 17, 284, 1848, 329, 44332, 290, 279, 198, 220, 220, 220, 220, 220, 220, 220, 1312, 541, 32, 9865, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 11, 299, 83, 11, 48957, 87, 8, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 267, 404, 32, 9865, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 11, 299, 83, 11, 48957, 87, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 8818, 1312, 541, 32, 9865, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 11, 299, 83, 28, 13664, 7, 33758, 828, 48957, 87, 28, 16, 25, 429, 8, 198, 220, 220, 220, 491, 49908, 7, 84, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 84, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 491, 11736, 7, 84, 11, 1312, 8, 796, 1181, 62, 1462, 62, 2213, 11736, 7, 84, 11, 299, 65, 11, 299, 83, 11, 1312, 8, 198, 220, 220, 220, 2163, 402, 7, 646, 11, 334, 11, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 474, 287, 352, 25, 429, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 402, 82, 58, 73, 16151, 2213, 11736, 7, 646, 11, 474, 828, 491, 49908, 7, 84, 26513, 11, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 7043, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2163, 277, 7, 646, 11, 334, 11, 279, 11, 256, 28, 15, 8, 198, 220, 220, 220, 220, 220, 220, 220, 402, 7, 646, 11, 334, 11, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 474, 51, 287, 1123, 9630, 7, 33758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1034, 796, 13146, 58, 73, 51, 16151, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 474, 287, 1064, 439, 7, 51, 312, 87, 764, 855, 474, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35971, 0, 7, 2213, 11736, 7, 646, 11, 474, 828, 1034, 11, 491, 11736, 7, 84, 11, 474, 828, 532, 16, 11, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 7043, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1303, 12806, 666, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 38, 7, 84, 11, 279, 8, 796, 287, 5372, 62, 12001, 62, 30482, 672, 666, 7, 33884, 11, 334, 11, 279, 11, 299, 83, 11, 299, 65, 8, 198, 220, 220, 220, 2163, 309, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3748, 33758, 796, 685, 51, 158, 109, 120, 7, 79, 8, 329, 309, 158, 109, 120, 287, 13146, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2512, 10989, 363, 26933, 34642, 33758, 58, 51, 312, 87, 58, 73, 11907, 329, 474, 287, 352, 25, 429, 60, 23029, 198, 220, 220, 220, 886, 198, 220, 220, 220, 474, 330, 7, 84, 11, 279, 11, 256, 28, 15, 8, 796, 18872, 229, 158, 224, 241, 38, 7, 84, 11, 279, 8, 532, 309, 7, 79, 8, 198, 220, 220, 220, 1441, 440, 7206, 22203, 90, 7942, 92, 7, 69, 11, 474, 330, 28, 30482, 8, 198, 437, 198, 8818, 267, 404, 32, 9865, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 11, 299, 83, 28, 13664, 7, 33758, 828, 48957, 87, 28, 16, 25, 429, 8, 198, 220, 220, 220, 491, 49908, 7, 84, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 84, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 491, 11736, 7, 84, 11, 1312, 8, 796, 1181, 62, 1462, 62, 2213, 11736, 7, 84, 11, 299, 65, 11, 299, 83, 11, 1312, 8, 198, 220, 220, 220, 402, 7, 84, 11, 279, 8, 796, 4646, 7, 85, 9246, 11, 402, 158, 109, 120, 7, 2213, 49908, 7, 84, 26513, 11, 279, 8, 329, 402, 158, 109, 120, 287, 402, 82, 8, 198, 220, 220, 220, 2163, 277, 7, 84, 11, 279, 11, 256, 28, 15, 8, 198, 220, 220, 220, 220, 220, 220, 220, 7043, 796, 4866, 7, 38, 7, 84, 11, 279, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 329, 474, 51, 287, 1123, 9630, 7, 33758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1034, 796, 13146, 58, 73, 51, 16151, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 474, 287, 1064, 439, 7, 51, 312, 87, 764, 855, 474, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35971, 0, 7, 2213, 11736, 7, 646, 11, 474, 828, 1034, 11, 491, 11736, 7, 84, 11, 474, 828, 532, 16, 11, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 7043, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1303, 12806, 666, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 38, 7, 84, 11, 279, 8, 796, 1957, 62, 30482, 672, 666, 7, 33884, 11, 334, 11, 279, 11, 299, 83, 11, 299, 65, 8, 198, 220, 220, 220, 2163, 309, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3748, 33758, 796, 685, 51, 158, 109, 120, 7, 79, 8, 329, 309, 158, 109, 120, 287, 13146, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2512, 10989, 363, 26933, 34642, 33758, 58, 51, 312, 87, 58, 73, 11907, 329, 474, 287, 352, 25, 429, 60, 23029, 198, 220, 220, 220, 886, 198, 220, 220, 220, 474, 330, 7, 84, 11, 279, 11, 256, 28, 15, 8, 796, 18872, 229, 158, 224, 241, 38, 7, 84, 11, 279, 8, 532, 309, 7, 79, 8, 198, 220, 220, 220, 1441, 440, 7206, 22203, 7, 69, 11, 474, 330, 28, 30482, 8, 198, 437, 198, 2, 9552, 33, 2943, 20802, 4575, 3848, 2346, 284, 1249, 329, 1111, 7377, 119, 3712, 38469, 290, 279, 3712, 2969, 283, 198, 8818, 9552, 33, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 3712, 5317, 11, 7904, 6030, 90, 47, 30072, 810, 1391, 47, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 9552, 33, 2943, 20802, 4575, 7, 32, 9865, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 828, 350, 8, 198, 437, 198, 8818, 9552, 33, 2943, 20802, 4575, 7, 12543, 3712, 16820, 22203, 90, 9562, 5512, 7904, 6030, 90, 47, 30072, 810, 1391, 47, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 474, 330, 7, 84, 11, 279, 3712, 47, 11, 256, 28, 15, 8, 796, 1257, 13, 30482, 7, 84, 11, 279, 11, 256, 8, 198, 220, 220, 220, 474, 330, 7, 84, 11, 7377, 119, 3712, 38469, 11, 256, 28, 15, 8, 796, 1257, 13, 30482, 7, 84, 11, 7377, 119, 17, 79, 7, 47, 11, 7377, 119, 828, 256, 8, 198, 220, 220, 220, 277, 7, 84, 11, 279, 3712, 47, 11, 256, 28, 15, 8, 796, 1257, 13, 69, 7, 84, 11, 279, 11, 256, 8, 198, 220, 220, 220, 277, 7, 84, 11, 7377, 119, 3712, 38469, 11, 256, 28, 15, 8, 796, 1257, 13, 69, 7, 84, 11, 7377, 119, 17, 79, 7, 47, 11, 7377, 119, 828, 256, 8, 198, 220, 220, 220, 1441, 440, 7206, 22203, 90, 9562, 92, 7, 69, 11, 474, 330, 28, 30482, 8, 198, 437, 198, 8818, 9552, 33, 2943, 20802, 4575, 7, 12543, 3712, 16820, 22203, 90, 7942, 5512, 7904, 6030, 90, 47, 30072, 810, 1391, 47, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 474, 330, 7, 84, 11, 279, 3712, 47, 11, 256, 28, 15, 8, 796, 1257, 13, 30482, 7, 84, 11, 279, 11, 256, 8, 198, 220, 220, 220, 474, 330, 7, 84, 11, 7377, 119, 3712, 38469, 11, 256, 28, 15, 8, 796, 1257, 13, 30482, 7, 84, 11, 7377, 119, 17, 79, 7, 47, 11, 7377, 119, 828, 256, 8, 198, 220, 220, 220, 277, 7, 646, 11, 334, 11, 279, 3712, 47, 11, 256, 28, 15, 8, 796, 1257, 13, 69, 7, 646, 11, 334, 11, 279, 11, 256, 8, 198, 220, 220, 220, 277, 7, 646, 11, 334, 11, 7377, 119, 3712, 38469, 11, 256, 28, 15, 8, 796, 1257, 13, 69, 7, 646, 11, 334, 11, 7377, 119, 17, 79, 7, 47, 11, 7377, 119, 828, 256, 8, 198, 220, 220, 220, 1441, 440, 7206, 22203, 90, 7942, 92, 7, 69, 11, 474, 330, 28, 30482, 8, 198, 437, 198, 198, 39344, 9552, 33, 2943, 20802, 4575, 198, 198, 37811, 198, 220, 220, 220, 376, 11, 18872, 229, 158, 224, 241, 37, 796, 376, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 7, 33758, 11, 402, 82, 11, 299, 65, 8, 198, 198, 35561, 262, 1181, 2163, 4600, 37, 63, 290, 663, 12806, 666, 11, 4600, 24861, 229, 158, 224, 241, 37, 44646, 628, 220, 220, 220, 376, 11, 18872, 229, 158, 224, 241, 37, 796, 376, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 7, 51, 11, 402, 82, 11, 299, 65, 8, 198, 198, 35561, 262, 1181, 2163, 4600, 37, 63, 290, 663, 12806, 666, 11, 4600, 24861, 229, 158, 224, 241, 37, 63, 357, 4480, 477, 491, 49908, 18665, 416, 2060, 4600, 51, 63, 737, 198, 198, 1212, 2163, 318, 39224, 13, 5765, 628, 220, 220, 220, 376, 796, 9552, 33, 2943, 20802, 4575, 7, 33758, 11, 402, 82, 11, 299, 65, 8, 198, 198, 38070, 13, 198, 1639, 460, 788, 869, 4600, 37, 7, 87, 11, 79, 8, 63, 329, 262, 25671, 11, 290, 4600, 37, 7, 7762, 90, 25, 30482, 5512, 87, 11, 79, 8, 63, 329, 262, 12806, 666, 13, 198, 37811, 198, 8818, 376, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 7, 12543, 3712, 16820, 22203, 8, 198, 220, 220, 220, 7308, 13, 10378, 40539, 7203, 15931, 12156, 8344, 341, 25, 198, 220, 220, 220, 220, 220, 220, 220, 376, 11, 18872, 229, 158, 224, 241, 37, 796, 376, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 7, 22046, 23029, 198, 220, 220, 220, 318, 39224, 13, 5765, 198, 220, 220, 220, 220, 220, 220, 220, 376, 796, 9552, 33, 2943, 20802, 4575, 7, 22046, 23029, 198, 220, 220, 220, 2427, 0, 357, 1870, 788, 345, 460, 991, 869, 4600, 37, 7, 87, 11, 79, 8, 63, 2014, 198, 220, 220, 220, 13538, 1600, 1058, 37, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 11, 2700, 28, 7942, 8, 198, 220, 220, 220, 1257, 13, 69, 11, 1257, 13, 30482, 198, 437, 198, 37, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 7, 22046, 23029, 796, 376, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 7, 32, 9865, 2943, 20802, 4575, 7, 22046, 986, 4008, 198, 39344, 376, 62, 392, 62, 24861, 229, 158, 224, 241, 37, 628, 628, 198, 37811, 198, 220, 220, 220, 1957, 1082, 452, 876, 7, 38, 11, 2124, 11, 279, 8, 198, 220, 220, 220, 1957, 1082, 452, 876, 7, 38, 39611, 95, 11, 2124, 82, 11, 1312, 11, 279, 8, 198, 220, 220, 220, 1957, 1082, 452, 876, 7, 38, 39611, 95, 11, 44332, 11, 2124, 82, 11, 1312, 11, 279, 8, 198, 198, 35561, 262, 366, 12001, 1, 27255, 286, 4600, 38, 63, 357, 273, 4600, 38, 39611, 95, 63, 828, 1312, 13, 68, 1539, 7548, 284, 262, 15879, 198, 198, 15506, 63, 198, 24861, 229, 158, 224, 241, 38, 7, 87, 11, 79, 8, 1635, 3392, 7, 7857, 7, 87, 4008, 198, 15506, 63, 198, 198, 4360, 1262, 19530, 28813, 338, 12806, 666, 2427, 13, 198, 37811, 198, 8818, 1957, 1082, 452, 876, 7, 38, 11, 2124, 11, 279, 8, 1303, 329, 2060, 491, 11736, 198, 220, 220, 220, 1441, 19530, 28813, 13, 1082, 452, 876, 7, 39377, 4613, 402, 7, 87, 764, 10, 7377, 119, 11, 279, 828, 657, 13, 15, 8, 198, 437, 198, 8818, 1957, 1082, 452, 876, 7, 38, 39611, 95, 11, 2124, 82, 11, 474, 11, 279, 8, 1303, 329, 3294, 491, 49908, 198, 220, 220, 220, 1441, 19530, 28813, 13, 1082, 452, 876, 7, 39377, 4613, 402, 39611, 95, 7, 11766, 5945, 62, 2213, 11736, 7, 34223, 11, 474, 11, 7377, 119, 26513, 11, 279, 828, 657, 13, 15, 8, 198, 437, 198, 8818, 1957, 1082, 452, 876, 7, 38, 39611, 95, 28265, 44332, 11, 2124, 82, 11, 474, 11, 279, 8, 1303, 611, 402, 39611, 95, 389, 287, 12, 5372, 198, 220, 220, 220, 1441, 19530, 28813, 13, 1082, 452, 876, 19510, 34350, 11, 7377, 119, 8, 4613, 402, 39611, 95, 0, 7, 34350, 11, 22146, 5945, 62, 2213, 11736, 7, 34223, 11, 474, 11, 7377, 119, 26513, 11, 279, 828, 44332, 11, 657, 13, 15, 8, 198, 437, 198, 11766, 5945, 62, 2213, 11736, 7, 34223, 11, 474, 11, 7377, 119, 8, 796, 357, 34223, 58, 16, 25, 73, 532, 352, 60, 986, 11, 2124, 82, 58, 73, 60, 764, 10, 7377, 119, 11, 2124, 82, 58, 73, 1343, 352, 25, 437, 60, 23029, 628, 198, 198, 37811, 198, 220, 220, 220, 376, 11, 406, 11, 22879, 11, 18872, 229, 158, 224, 241, 37, 11, 18872, 229, 158, 224, 241, 43, 11, 18872, 229, 158, 224, 241, 32572, 11, 309, 796, 6626, 62, 5219, 62, 8818, 62, 392, 62, 46751, 666, 7, 33758, 11, 406, 82, 11, 22879, 82, 11, 299, 65, 8, 198, 198, 35561, 262, 1181, 2163, 4600, 37, 63, 290, 663, 474, 330, 672, 666, 11, 4600, 24861, 229, 158, 224, 241, 37, 47671, 355, 880, 355, 257, 4947, 286, 6626, 12879, 13, 770, 318, 11992, 13, 5765, 379, 534, 898, 2526, 0, 198, 37811, 198, 8818, 6626, 62, 5219, 62, 8818, 62, 392, 62, 46751, 666, 7, 33758, 3712, 51, 29291, 11, 406, 82, 3712, 51, 29291, 11, 22879, 82, 3712, 51, 29291, 11, 299, 65, 8, 198, 220, 220, 220, 299, 83, 796, 4129, 7, 33758, 8, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 309, 7, 79, 8, 796, 2512, 10989, 363, 26933, 51, 158, 109, 120, 7, 79, 8, 329, 309, 158, 109, 120, 287, 13146, 60, 23029, 1303, 4403, 309, 357, 29127, 636, 8, 198, 220, 220, 220, 22879, 7, 87, 11, 279, 8, 796, 4646, 7, 85, 9246, 11, 22879, 158, 109, 120, 7, 2213, 49908, 7, 87, 26513, 11, 279, 8, 329, 22879, 158, 109, 120, 287, 22879, 82, 8, 1303, 1729, 29127, 636, 198, 220, 220, 220, 406, 7, 87, 11, 279, 8, 796, 4646, 7, 85, 9246, 11, 406, 158, 109, 120, 7, 2213, 49908, 7, 87, 26513, 11, 279, 8, 329, 406, 158, 109, 120, 287, 406, 82, 8, 1303, 1729, 29127, 636, 198, 220, 220, 220, 376, 7, 87, 11, 279, 8, 796, 22879, 7, 87, 11, 279, 8, 1343, 406, 7, 87, 11, 279, 8, 532, 309, 7, 79, 8, 1635, 2124, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1336, 220, 47728, 238, 117, 7, 47728, 239, 98, 8, 796, 532, 51, 220, 47728, 239, 98, 1343, 220, 47728, 238, 118, 7, 47728, 239, 98, 8, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 32572, 7, 87, 11, 279, 8, 796, 1957, 62, 30482, 672, 666, 7, 32572, 82, 11, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 220, 220, 220, 220, 1303, 12806, 666, 286, 1729, 29127, 636, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 43, 7, 79, 8, 796, 1957, 62, 30482, 672, 666, 7, 43, 82, 11, 1976, 27498, 7, 429, 1635, 299, 65, 828, 279, 11, 299, 83, 11, 299, 65, 8, 220, 220, 220, 220, 1303, 12806, 666, 286, 1729, 29127, 636, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 37, 7, 87, 11, 279, 8, 796, 18872, 229, 158, 224, 241, 32572, 7, 87, 11, 279, 8, 1343, 18872, 229, 158, 224, 241, 43, 7, 79, 8, 532, 309, 7, 79, 8, 220, 220, 220, 220, 220, 220, 1303, 1336, 12806, 666, 18872, 229, 158, 224, 241, 47728, 238, 117, 7, 47728, 239, 98, 8, 796, 532, 51, 1343, 18872, 229, 158, 224, 241, 47728, 238, 118, 7, 47728, 239, 98, 8, 198, 220, 220, 220, 1441, 376, 11, 406, 11, 22879, 11, 18872, 229, 158, 224, 241, 37, 11, 18872, 229, 158, 224, 241, 43, 11, 18872, 229, 158, 224, 241, 32572, 11, 309, 198, 437, 198, 8818, 6626, 62, 5219, 62, 8818, 62, 392, 62, 46751, 666, 7, 51, 11, 406, 11, 22879, 11, 299, 65, 8, 198, 220, 220, 220, 376, 7, 87, 11, 279, 8, 796, 22879, 7, 87, 11, 279, 8, 1343, 406, 7, 87, 11, 279, 8, 532, 309, 7, 79, 8, 1635, 2124, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1336, 220, 47728, 238, 117, 7, 47728, 239, 98, 8, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 32572, 7, 87, 11, 279, 8, 796, 29877, 7, 18683, 27923, 7, 12001, 1082, 452, 876, 7, 32572, 11, 2124, 11, 279, 22305, 1303, 12806, 666, 286, 1729, 29127, 636, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 43, 7, 79, 8, 796, 29877, 7, 18683, 27923, 7, 12001, 1082, 452, 876, 7, 43, 11, 1976, 27498, 7, 46803, 828, 279, 22305, 220, 220, 220, 220, 1303, 12806, 666, 286, 1729, 29127, 636, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 37, 7, 87, 11, 279, 8, 796, 18872, 229, 158, 224, 241, 32572, 7, 87, 11, 279, 8, 1343, 18872, 229, 158, 224, 241, 43, 7, 79, 8, 532, 309, 7, 79, 8, 220, 220, 220, 220, 220, 220, 1303, 1336, 12806, 666, 18872, 229, 158, 224, 241, 47728, 238, 117, 7, 47728, 239, 98, 8, 796, 532, 51, 1343, 18872, 229, 158, 224, 241, 47728, 238, 118, 7, 47728, 239, 98, 8, 198, 220, 220, 220, 1441, 376, 11, 406, 11, 22879, 11, 18872, 229, 158, 224, 241, 37, 11, 18872, 229, 158, 224, 241, 43, 11, 18872, 229, 158, 224, 241, 32572, 11, 309, 198, 437, 198, 39344, 6626, 62, 5219, 62, 8818, 62, 392, 62, 46751, 666, 198, 198, 8818, 1957, 62, 30482, 672, 666, 7, 33884, 11, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 198, 220, 220, 220, 1441, 4646, 7, 85, 9246, 11, 1957, 62, 30482, 672, 666, 62, 808, 7, 38, 158, 109, 120, 11, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 329, 402, 158, 109, 120, 287, 402, 82, 8, 198, 437, 198, 8818, 287, 5372, 62, 12001, 62, 30482, 672, 666, 7, 33884, 11, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 198, 220, 220, 220, 1441, 4646, 7, 85, 9246, 11, 287, 5372, 62, 12001, 62, 30482, 672, 666, 62, 808, 7, 38, 158, 109, 120, 28265, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 329, 402, 158, 109, 120, 0, 287, 402, 82, 8, 198, 437, 198, 198, 8818, 1957, 62, 30482, 672, 666, 62, 808, 7, 38, 39611, 95, 11, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 1441, 4646, 7, 71, 9246, 11, 29877, 7, 18683, 27923, 7, 12001, 1082, 452, 876, 7, 38, 39611, 95, 11, 491, 49908, 7, 87, 828, 474, 11, 279, 22305, 329, 474, 287, 352, 25, 429, 8, 198, 437, 198, 8818, 287, 5372, 62, 12001, 62, 30482, 672, 666, 62, 808, 7, 38, 39611, 95, 28265, 2124, 11, 279, 11, 299, 83, 11, 299, 65, 8, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 44332, 796, 20650, 90, 43879, 2414, 92, 7, 917, 891, 11, 299, 65, 8, 198, 220, 220, 220, 1441, 4646, 7, 71, 9246, 11, 29877, 7, 18683, 27923, 7, 12001, 1082, 452, 876, 7, 38, 39611, 95, 28265, 44332, 11, 491, 49908, 7, 87, 828, 474, 11, 279, 22305, 329, 474, 287, 352, 25, 429, 8, 198, 437, 198, 198, 2, 28, 46111, 2559, 18604, 198, 8645, 378, 220, 47728, 239, 241, 290, 28486, 422, 2836, 5128, 198, 10052, 25609, 796, 2, 198, 198, 8818, 7716, 62, 69, 7, 49535, 82, 11, 18919, 87, 11, 18074, 225, 31185, 87, 11, 410, 11, 18074, 231, 79, 11, 7904, 6030, 90, 51, 30072, 810, 1391, 51, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 299, 83, 11, 299, 65, 796, 4129, 7, 49535, 82, 828, 4129, 7, 85, 8, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 277, 7, 87, 11, 7377, 119, 16300, 8, 796, 18074, 231, 79, 1635, 46318, 7, 51, 11, 7377, 119, 16300, 8, 1343, 198, 220, 220, 220, 220, 220, 220, 220, 2160, 26933, 49535, 158, 109, 120, 1635, 46318, 7, 87, 158, 109, 120, 11, 18919, 158, 109, 120, 11, 18074, 225, 158, 109, 120, 31185, 11, 410, 8, 329, 357, 49535, 158, 109, 120, 11, 2124, 158, 109, 120, 11, 18919, 158, 109, 120, 11, 18074, 225, 158, 109, 120, 31185, 8, 287, 19974, 7, 49535, 82, 11, 491, 49908, 7, 87, 828, 18919, 87, 11, 18074, 225, 31185, 87, 8, 12962, 198, 220, 220, 220, 1441, 277, 198, 437, 198, 8818, 7716, 62, 69, 7, 49535, 82, 11, 18074, 231, 79, 11, 1036, 67, 11, 10201, 11, 7904, 6030, 90, 51, 19629, 479, 86, 22046, 23029, 810, 1391, 51, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 299, 83, 11, 299, 65, 796, 4129, 7, 49535, 82, 828, 954, 7, 271, 86, 316, 7, 2164, 67, 4008, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 6997, 796, 685, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 158, 109, 120, 8, 329, 10201, 158, 109, 120, 287, 10201, 60, 198, 220, 220, 220, 50115, 796, 651, 7, 46265, 22046, 11, 1058, 6359, 11, 357, 33327, 7, 738, 414, 329, 1312, 287, 352, 25, 429, 26513, 11, 4008, 198, 220, 220, 220, 277, 7, 87, 11, 7377, 119, 16300, 8, 796, 18074, 231, 79, 1635, 46318, 7, 51, 11, 7377, 119, 16300, 8, 1343, 198, 220, 220, 220, 220, 220, 220, 220, 2160, 26933, 49535, 158, 109, 120, 1635, 46318, 7, 87, 158, 109, 120, 11, 1036, 67, 11, 10201, 158, 109, 120, 11, 337, 28, 44, 158, 109, 120, 11, 269, 28, 66, 158, 109, 120, 8, 329, 357, 49535, 158, 109, 120, 11, 2124, 158, 109, 120, 11, 10201, 158, 109, 120, 11, 337, 158, 109, 120, 11, 269, 158, 109, 120, 8, 287, 19974, 7, 49535, 82, 11, 491, 49908, 7, 87, 828, 10201, 11, 6997, 11, 50115, 8, 12962, 198, 220, 220, 220, 1441, 277, 198, 437, 198, 8818, 7716, 62, 69, 7, 49535, 82, 11, 18074, 231, 79, 11, 1036, 67, 11, 13096, 3712, 22203, 11, 10201, 11, 7904, 6030, 90, 51, 30072, 810, 1391, 51, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 299, 83, 11, 299, 65, 796, 4129, 7, 49535, 82, 828, 954, 7, 271, 86, 316, 7, 2164, 67, 4008, 198, 220, 220, 220, 6997, 796, 685, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 158, 109, 120, 8, 329, 10201, 158, 109, 120, 287, 10201, 60, 198, 220, 220, 220, 1312, 86, 1039, 796, 685, 271, 86, 316, 7, 2164, 67, 11, 10201, 158, 109, 120, 8, 329, 10201, 158, 109, 120, 287, 10201, 60, 198, 220, 220, 220, 2163, 277, 7, 87, 11, 7377, 119, 16300, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2124, 82, 796, 555, 8002, 62, 2213, 49908, 7, 87, 11, 1036, 67, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 18074, 231, 79, 1635, 46318, 7, 51, 11, 7377, 119, 16300, 8, 1343, 2160, 26933, 49535, 39611, 95, 1635, 12913, 76, 1042, 963, 7, 34223, 11, 1036, 67, 11, 13096, 11, 10201, 11, 1312, 11, 337, 39611, 95, 11, 1312, 86, 316, 39611, 95, 8, 329, 357, 72, 11, 357, 49535, 39611, 95, 11, 337, 39611, 95, 11, 1312, 86, 316, 39611, 95, 4008, 287, 27056, 378, 7, 13344, 7, 49535, 82, 11, 6997, 11, 1312, 86, 1039, 4008, 12962, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 277, 198, 437, 628, 628, 198, 8818, 7716, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 18919, 87, 11, 18074, 225, 31185, 87, 11, 410, 8, 198, 220, 220, 220, 299, 83, 11, 299, 65, 796, 4129, 7, 49535, 82, 828, 4129, 7, 85, 8, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 69, 7, 87, 8, 796, 4646, 7, 71, 9246, 11, 18074, 231, 158, 109, 120, 1635, 18872, 229, 76, 1042, 963, 7, 87, 158, 109, 120, 11, 18919, 158, 109, 120, 11, 18074, 225, 158, 109, 120, 31185, 11, 410, 8, 329, 357, 49535, 158, 109, 120, 11, 2124, 158, 109, 120, 11, 18919, 158, 109, 120, 11, 18074, 225, 158, 109, 120, 31185, 8, 287, 19974, 7, 49535, 82, 11, 491, 49908, 7, 87, 828, 18919, 87, 11, 18074, 225, 31185, 87, 4008, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 69, 7, 87, 11, 279, 8, 796, 18872, 229, 158, 224, 241, 69, 7, 87, 8, 198, 220, 220, 220, 1441, 18872, 229, 158, 224, 241, 69, 198, 437, 198, 8818, 7716, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 1036, 67, 11, 10201, 26, 479, 86, 22046, 23029, 198, 220, 220, 220, 299, 83, 11, 299, 65, 796, 4129, 7, 49535, 82, 828, 954, 7, 271, 86, 316, 7, 2164, 67, 4008, 198, 220, 220, 220, 491, 49908, 7, 87, 8, 796, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 220, 220, 220, 6997, 796, 685, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 158, 109, 120, 8, 329, 10201, 158, 109, 120, 287, 10201, 60, 198, 220, 220, 220, 50115, 796, 651, 7, 46265, 22046, 11, 1058, 6359, 11, 357, 33327, 7, 738, 414, 329, 1312, 287, 352, 25, 429, 26513, 11, 4008, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 69, 7, 87, 8, 796, 4646, 7, 71, 9246, 11, 18074, 231, 158, 109, 120, 1635, 18872, 229, 76, 1042, 963, 7, 87, 158, 109, 120, 11, 1036, 67, 11, 10201, 158, 109, 120, 11, 337, 28, 44, 158, 109, 120, 11, 269, 28, 66, 158, 109, 120, 8, 329, 357, 49535, 158, 109, 120, 11, 2124, 158, 109, 120, 11, 10201, 158, 109, 120, 11, 337, 158, 109, 120, 11, 269, 158, 109, 120, 8, 287, 19974, 7, 49535, 82, 11, 491, 49908, 7, 87, 828, 10201, 11, 6997, 11, 50115, 4008, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 69, 7, 87, 11, 279, 8, 796, 18872, 229, 158, 224, 241, 69, 7, 87, 8, 198, 220, 220, 220, 1441, 18872, 229, 158, 224, 241, 69, 198, 437, 198, 8818, 7716, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 1036, 67, 11, 13096, 3712, 22203, 11, 10201, 8, 198, 220, 220, 220, 299, 83, 11, 299, 65, 796, 4129, 7, 49535, 82, 828, 954, 7, 271, 86, 316, 7, 2164, 67, 4008, 198, 220, 220, 220, 6997, 796, 685, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 158, 109, 120, 8, 329, 10201, 158, 109, 120, 287, 10201, 60, 198, 220, 220, 220, 1312, 86, 1039, 796, 685, 271, 86, 316, 7, 2164, 67, 11, 10201, 158, 109, 120, 8, 329, 10201, 158, 109, 120, 287, 10201, 60, 198, 220, 220, 220, 2163, 18872, 229, 158, 224, 241, 69, 7, 87, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2124, 82, 796, 555, 8002, 62, 2213, 49908, 7, 87, 11, 1036, 67, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2160, 26933, 49535, 39611, 95, 1635, 18872, 229, 521, 1060, 76, 1042, 963, 7, 403, 8002, 62, 2213, 49908, 7, 87, 11, 1036, 67, 828, 1036, 67, 11, 13096, 11, 10201, 11, 1312, 11, 337, 39611, 95, 11, 1312, 86, 316, 39611, 95, 8, 329, 357, 72, 11, 357, 49535, 39611, 95, 11, 337, 39611, 95, 11, 1312, 86, 316, 39611, 95, 4008, 287, 27056, 378, 7, 13344, 7, 49535, 82, 11, 6997, 11, 1312, 86, 1039, 4008, 12962, 198, 220, 220, 220, 886, 198, 220, 220, 220, 18872, 229, 158, 224, 241, 69, 7, 87, 11, 279, 8, 796, 18872, 229, 158, 224, 241, 69, 7, 87, 8, 198, 220, 220, 220, 1441, 18872, 229, 158, 224, 241, 69, 198, 437, 628, 198, 8818, 277, 62, 392, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 18919, 87, 11, 18074, 225, 31185, 87, 11, 410, 11, 18074, 231, 79, 11, 7904, 6030, 90, 51, 30072, 810, 1391, 51, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 7716, 62, 69, 7, 49535, 82, 11, 18919, 87, 11, 18074, 225, 31185, 87, 11, 410, 11, 18074, 231, 79, 11, 309, 828, 7716, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 18919, 87, 11, 18074, 225, 31185, 87, 11, 410, 8, 198, 437, 198, 8818, 277, 62, 392, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 18074, 231, 79, 11, 1036, 67, 11, 10201, 11, 7904, 6030, 90, 51, 19629, 479, 86, 22046, 23029, 810, 1391, 51, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 7716, 62, 69, 7, 49535, 82, 11, 18074, 231, 79, 11, 1036, 67, 11, 10201, 11, 309, 26, 479, 86, 22046, 986, 828, 7716, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 1036, 67, 11, 10201, 26, 479, 86, 22046, 23029, 198, 437, 198, 8818, 277, 62, 392, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 18074, 231, 79, 11, 1036, 67, 11, 13096, 3712, 22203, 11, 10201, 11, 7904, 6030, 90, 51, 30072, 810, 1391, 51, 1279, 25, 3486, 283, 92, 198, 220, 220, 220, 7716, 62, 69, 7, 49535, 82, 11, 18074, 231, 79, 11, 1036, 67, 11, 13096, 11, 10201, 11, 309, 828, 7716, 62, 24861, 229, 158, 224, 241, 69, 7, 49535, 82, 11, 1036, 67, 11, 13096, 11, 10201, 8, 198, 437, 198, 39344, 277, 62, 392, 62, 24861, 229, 158, 224, 241, 69, 198, 198, 37811, 198, 220, 220, 220, 46318, 7, 87, 11, 2124, 8158, 11, 18074, 225, 31185, 87, 8158, 11, 410, 8, 198, 198, 31715, 12, 6551, 276, 46318, 286, 953, 11978, 491, 11736, 4600, 87, 63, 1028, 6515, 1612, 11, 4600, 87, 8158, 47671, 1813, 6515, 24198, 11, 4600, 38392, 31185, 87, 8158, 47671, 290, 15343, 4600, 85, 44646, 198, 37811, 198, 8818, 46318, 7, 87, 11, 2124, 8158, 11, 18074, 225, 31185, 87, 8158, 11, 410, 8, 198, 220, 220, 220, 7377, 112, 87, 796, 2124, 532, 2124, 8158, 198, 220, 220, 220, 370, 796, 6031, 27923, 7, 85, 24457, 18074, 225, 31185, 87, 8158, 8, 198, 220, 220, 220, 1441, 657, 13, 20, 1635, 1007, 3455, 7, 138, 112, 87, 8, 1635, 370, 1635, 7377, 112, 87, 1220, 357, 7645, 3455, 7, 87, 8158, 8, 1635, 370, 1635, 2124, 8158, 8, 198, 437, 198, 76, 1042, 963, 7, 87, 11, 7904, 43730, 11, 26498, 23029, 796, 657, 198, 198, 37811, 198, 220, 220, 220, 18872, 229, 76, 1042, 963, 7, 87, 11, 2124, 8158, 11, 18074, 225, 31185, 87, 8158, 11, 410, 8, 198, 198, 2782, 73, 1563, 286, 262, 31312, 286, 4600, 76, 1042, 963, 7, 87, 11, 2124, 8158, 11, 18074, 225, 31185, 87, 8158, 11, 410, 8, 44646, 198, 37811, 198, 8818, 18872, 229, 76, 1042, 963, 7, 87, 11, 2124, 8158, 11, 18074, 225, 31185, 87, 8158, 11, 410, 8, 198, 220, 220, 220, 7377, 112, 87, 796, 2124, 532, 2124, 8158, 198, 220, 220, 220, 370, 796, 6031, 27923, 7, 85, 24457, 18074, 225, 31185, 87, 8158, 8, 198, 220, 220, 220, 1441, 1007, 3455, 7, 54, 1635, 7377, 112, 87, 8, 1220, 357, 7645, 3455, 7, 87, 8158, 8, 1635, 370, 1635, 2124, 8158, 8, 198, 437, 198, 24861, 229, 76, 1042, 963, 7, 87, 11, 7904, 43730, 11, 26498, 23029, 796, 1007, 3455, 7, 9107, 418, 7, 13664, 7, 87, 22305, 628, 628, 198, 2235, 649, 5499, 329, 517, 14276, 10201, 10392, 198, 2, 16926, 46, 3060, 281, 11902, 2163, 4578, 284, 6121, 262, 1366, 878, 14492, 77, 262, 46318, 198, 2, 17934, 611, 329, 31624, 3008, 491, 49908, 1395, 810, 530, 514, 385, 453, 3382, 284, 17775, 262, 46318, 287, 7377, 112, 393, 7377, 113, 13, 198, 8818, 46318, 7, 87, 11, 1036, 67, 3712, 46607, 41339, 11, 10201, 26, 269, 28, 738, 414, 11, 370, 28, 40, 11, 337, 28, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 828, 1312, 86, 316, 28, 271, 86, 316, 7, 2164, 67, 11, 10201, 4008, 198, 220, 220, 220, 267, 796, 1570, 7, 8158, 11, 1312, 86, 316, 8, 198, 220, 220, 220, 7377, 112, 87, 796, 337, 1635, 269, 7, 87, 8, 532, 267, 198, 220, 220, 220, 1441, 657, 13, 20, 1635, 1007, 3455, 7, 138, 112, 87, 8, 1635, 370, 1635, 7377, 112, 87, 1220, 357, 7645, 3455, 7, 78, 8, 1635, 370, 1635, 267, 8, 198, 437, 198, 76, 1042, 963, 7, 87, 11, 1036, 67, 3712, 46607, 41339, 11, 7904, 43730, 26, 479, 86, 22046, 23029, 796, 657, 198, 8818, 18872, 229, 76, 1042, 963, 7, 87, 11, 1036, 67, 3712, 46607, 41339, 11, 10201, 26, 269, 28, 738, 414, 11, 370, 28, 40, 11, 337, 28, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 828, 1312, 86, 316, 28, 271, 86, 316, 7, 2164, 67, 11, 10201, 4008, 198, 220, 220, 220, 18872, 229, 66, 796, 6031, 27923, 7, 39746, 28813, 13, 1082, 452, 876, 7, 39377, 4613, 269, 7, 87, 764, 10, 7377, 119, 828, 657, 13, 15, 4008, 198, 220, 220, 220, 267, 796, 1570, 7, 8158, 11, 1312, 86, 316, 8, 198, 220, 220, 220, 7377, 112, 87, 796, 337, 1635, 269, 7, 87, 8, 532, 267, 198, 220, 220, 220, 1441, 1007, 3455, 7, 54, 1635, 7377, 112, 87, 8, 1635, 337, 1635, 18872, 229, 66, 1220, 357, 7645, 3455, 7, 78, 8, 1635, 370, 1635, 267, 8, 198, 437, 198, 24861, 229, 76, 1042, 963, 7, 87, 11, 1036, 67, 3712, 46607, 41339, 11, 7904, 43730, 26, 479, 86, 22046, 23029, 796, 1007, 3455, 7, 9107, 418, 7, 13664, 7, 87, 22305, 198, 198, 2, 554, 1339, 262, 46318, 318, 407, 1912, 319, 262, 491, 11736, 475, 319, 617, 2163, 286, 340, 198, 2, 16926, 46, 3060, 3038, 329, 16096, 17593, 329, 4696, 35610, 1167, 567, 710, 344, 198, 8818, 12913, 76, 1042, 963, 7, 34223, 3712, 51, 29291, 11, 1036, 67, 3712, 46607, 41339, 11, 13096, 3712, 22203, 11, 10201, 11, 1312, 11, 337, 28, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 58, 72, 46570, 1312, 86, 316, 28, 271, 86, 316, 7, 2164, 67, 11, 10201, 58, 72, 60, 4008, 198, 220, 220, 220, 2124, 17, 796, 13096, 7, 34223, 23029, 198, 220, 220, 220, 503, 796, 657, 13, 15, 198, 220, 220, 220, 267, 796, 10201, 58, 72, 7131, 14246, 316, 11, 1058, 8367, 60, 198, 220, 220, 220, 7377, 112, 87, 796, 337, 1635, 2124, 17, 58, 72, 60, 532, 267, 198, 220, 220, 220, 1441, 657, 13, 20, 1635, 1007, 3455, 7, 138, 112, 87, 8, 1635, 7377, 112, 87, 1220, 357, 7645, 3455, 7, 78, 8, 1635, 267, 8, 198, 437, 198, 8818, 18872, 229, 521, 1060, 76, 1042, 963, 7, 34223, 3712, 51, 29291, 11, 1036, 67, 3712, 46607, 41339, 11, 13096, 3712, 22203, 11, 10201, 11, 1312, 11, 337, 28, 3849, 16104, 341, 6759, 8609, 7, 2164, 67, 11, 10201, 58, 72, 46570, 1312, 86, 316, 28, 271, 86, 316, 7, 2164, 67, 11, 10201, 58, 72, 60, 4008, 198, 220, 220, 220, 2124, 17, 796, 13096, 7, 34223, 23029, 198, 220, 220, 220, 267, 796, 10201, 58, 72, 7131, 14246, 316, 11, 1058, 8367, 60, 198, 220, 220, 220, 7377, 112, 87, 796, 337, 1635, 2124, 17, 58, 72, 60, 532, 267, 198, 220, 220, 220, 18872, 229, 4666, 39611, 95, 796, 18872, 229, 4666, 1958, 7, 4666, 1958, 11, 2124, 82, 11, 1312, 8, 198, 220, 220, 220, 1441, 1007, 3455, 7, 138, 112, 87, 8, 1635, 337, 1635, 18872, 229, 4666, 39611, 95, 1220, 357, 7645, 3455, 7, 78, 8, 1635, 267, 8, 198, 437, 198, 2, 16926, 46, 892, 286, 517, 6942, 835, 284, 3368, 664, 296, 48074, 18872, 229, 4666, 1958, 2187, 329, 1123, 1312, 198, 8818, 18872, 229, 4666, 1958, 7, 4666, 1958, 11, 2124, 82, 11, 1312, 11, 474, 8, 198, 220, 220, 220, 1441, 29877, 7, 18683, 27923, 7, 39746, 28813, 13, 1082, 452, 876, 7, 39377, 4613, 13096, 7, 11766, 5945, 62, 2213, 11736, 7, 34223, 11, 474, 11, 7377, 119, 8, 23029, 58, 72, 4357, 657, 13, 15, 22305, 198, 437, 198, 24861, 229, 4666, 1958, 7, 4666, 1958, 11, 2124, 82, 11, 1312, 8, 796, 4646, 7, 71, 9246, 11, 18872, 229, 4666, 1958, 7, 4666, 1958, 11, 2124, 82, 11, 1312, 11, 474, 8, 329, 474, 287, 352, 25, 13664, 7, 34223, 4008, 628, 198, 2, 28, 46111, 2559, 18604, 198, 41684, 12, 2213, 11736, 2593, 198, 10052, 25609, 796, 2, 198, 198, 8818, 2322, 388, 413, 26022, 276, 62, 27237, 7, 429, 11, 410, 8, 198, 220, 220, 220, 266, 796, 9585, 7, 85, 11, 299, 83, 8, 198, 220, 220, 220, 1441, 299, 26224, 7, 87, 8, 796, 1007, 3455, 7, 87, 8, 1635, 6031, 27923, 7, 86, 8, 1635, 2124, 198, 437, 628, 198, 2, 28, 46111, 2559, 18604, 198, 403, 41291, 286, 5021, 12, 2213, 49908, 198, 10052, 25609, 796, 2, 198, 198, 5219, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 796, 299, 83, 29291, 7, 72, 4613, 1181, 62, 1462, 62, 2213, 11736, 7, 87, 11, 299, 65, 11, 299, 83, 11, 1312, 828, 299, 83, 8, 198, 5219, 62, 1462, 62, 2213, 11736, 7, 87, 11, 299, 65, 11, 299, 83, 11, 1312, 8, 796, 1570, 7, 87, 11, 491, 11736, 62, 521, 1063, 7, 46803, 11, 299, 83, 11, 1312, 4008, 198, 8818, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 1036, 67, 8, 198, 220, 220, 220, 299, 65, 796, 1271, 62, 1659, 62, 86, 316, 62, 29305, 7, 2164, 67, 8, 198, 220, 220, 220, 299, 83, 796, 2558, 7, 744, 7, 13664, 7, 87, 8, 1220, 299, 65, 4008, 198, 220, 220, 220, 1441, 1181, 62, 1462, 62, 2213, 49908, 7, 87, 11, 299, 65, 11, 299, 83, 8, 198, 437, 198, 2213, 11736, 62, 521, 1063, 7, 46803, 11, 299, 83, 11, 1312, 8, 796, 357, 72, 532, 352, 8, 1635, 299, 65, 1343, 352, 25, 72, 1635, 299, 65, 198, 2213, 49908, 62, 1462, 62, 5219, 7, 34223, 8, 796, 4646, 7, 85, 9246, 11, 2124, 82, 8, 198, 39344, 1181, 62, 1462, 62, 2213, 49908, 11, 1181, 62, 1462, 62, 2213, 11736, 11, 491, 49908, 62, 1462, 62, 5219, 11, 491, 11736, 62, 521, 1063, 198, 2, 978, 4448, 329, 1365, 1438, 198, 403, 8002, 62, 2213, 49908, 796, 1181, 62, 1462, 62, 2213, 49908, 198, 39344, 555, 8002, 62, 2213, 49908, 628, 628, 198 ]
1.962407
7,395
<gh_stars>1-10 """ l1_adaptive_trend_filter{T<:Float64, S<:Int}(y::Vector{T}, components::Vector{S}; f::Vector{T} = Vector{T}(0), numλ::S=S(40), numγ::S=S(10), MAXITER::S=S(500), verbose::Bool=false,lower_bounds::Vector{T}=-10e+7*ones(T, TOTALCOMPONENTS), upper_bounds::Vector{T}=10e+7*ones(T, TOTALCOMPONENTS) ) The function `l1_adaptive_trend_filter` performs the filtering via coordinate descent and takes the following required inputs: * y : Signal or time-series to be filtered; (Must be a vector of reals) * components: List of integers corresponding to the types of components to be considered. (must be a vector of integers containing some of the following numbers: 1 = Step, 2 = Spike, 3 = Slope, 4 = Sine, 5 = Cossine ) Optional inputs: * f: Vector of overcomplete frequencies (Default=ø); * numλ: Size of the regularizer path for the parameter λ (Default=40); * numγ: Size of the regularizer path for the parameter γ (Default=10); * MAXITER: Maximum number of iterations (Default=500); * verbose: Boolean flag for displaying progress of algorithm (Default=false); * lower_bounds: List of lower bounds for each component type (Default=[-∞,-∞,-∞,-∞,-∞]); * upper_bounds: List of upper bpunds for each component type (Default=[+∞,+∞,+∞,+∞,+∞]). This function returns: * β_path: Path of components coefficients; * y_path: Path of filtered signals; * β_best: Best components coefficients according to the EBIC criteria; * y_best: Best filtered signal according to the EBIC criteria; * λ_best: Best value for the λ regularizer according to the EBIC criteria; * γ_best: Best value for the γ regularizer according to the EBIC criteria. ## Example ``` y = rand(18) # some inputs components = [1,3] #(meaning we only consider step and slope components) # run the algorithm beta_path, y_path, beta_best, y_best, lambda_best, gamma_best = l1_adaptive_trend_filter(y,components) ``` """ function l1_adaptive_trend_filter{T<:Float64, S<:Int}( y::Vector{T}, components::Vector{S}; f::Vector{T} = Vector{T}(0), numλ::S=S(40), numγ::S=S(10), MAXITER::S=S(500), verbose::Bool=false, lower_bounds::Vector{T}=-10e+7*ones(T, TOTALCOMPONENTS), upper_bounds::Vector{T}=10e+7*ones(T, TOTALCOMPONENTS) ) # subtracting the mean y_mean = mean(y) y = y - y_mean # prepare check for dimension sizes const N = length(y) # iterator IT = initIT_range(N, components, f, MAXITER=MAXITER)::iterator # compute moments const d = initData(IT, f, f)::dataCD # inner products between response y and components const xdy = initXDY(IT, y, d) # build regularization path for λ (same path shape, different λs) path, λ_max = compute_λ_path(IT, xdy, numλ, d) # build regularization path for γ (unique path) const Γ = compute_γ_path(IT, xdy, numγ, d) # initialize weights w = Vector{Float64}[] for i in 1:TOTALCOMPONENTS if in(i,IT.components) push!(w, ones(IT.nelements[i])) else push!(w, ones(0)) end end # lasso pass @fastmath β_path, y_path, β_best, y_best, λ_best, γ_best = coordinate_descent( IT, d, xdy, path, λ_max, [1.0,] , y, lower_bounds, upper_bounds, w, verbose ) # exclude the components the lasso has set to zero update_components!(IT, w, β_best, d, xdy) @fastmath β_path, y_path, β_best, y_best, λ_best, γ_best = coordinate_descent( IT, d, xdy, path, λ_max, Γ, y, lower_bounds, upper_bounds, w, verbose ) # adding back the mean y_best = y_best + y_mean if verbose print(string( "best regularization according to BIC was (λ=", round(λ_best, 3), ", γ=", round(γ_best, 3), ") \n" )) end return β_path, y_path, β_best, y_best, λ_best, γ_best end # coordinate descent algorithm for the regularization path (Λ x Γ) function coordinate_descent( IT::iterator, d::dataCD, xdy::Vector{Vector{Float64}}, path::Vector{Float64}, λ_max::Vector{Float64}, Γ::Vector{Float64}, y::Vector{Float64}, lower_bounds::Vector{Float64}, upper_bounds::Vector{Float64}, w::Vector{Vector{Float64}}, verbose::Bool; sparse::Int = 0 ) const N = IT.obs # initializations #if sparse == 1 # β_path, β_tilde, β, activeSet = initSparse(IT) #else β_path, β_tilde, β, activeSet = initDense(IT) #end # memory allocation BIC = Inf::Float64 β_ols = 0.0::Float64 partial_fit = 0.0 β_best = 0.0 y_best = 0 λ_best = 0.0 γ_best = 0.0 path_iteration = 0 y_path = Vector{Float64}[] #for i in 1:TOTALCOMPONENTS # push!(w, zeros(IT.nelements[i])) #end # regularization path @inbounds for γ in Γ # clear warm-start clear_warmstart!(β_tilde, IT) @inbounds for path_iter in path λ = path_iter * λ_max change_flag = true if verbose path_iteration += 1 print(string( "regularizers = (", round(λ, 3), ", ", round(γ, 3), ") path iteration = ", path_iteration, ".\n" )) end # loop until active set converges @inbounds for iter in 1:IT.maxIter if verbose println(iter) end # convergence check if !change_flag break end change_flag = false # cycle through every component @inbounds for c1 in IT.components, j in IT.elements[c1] # consider hoisting means and variaces, for better memoru use # compute the partial fit with the components in the active set partial_fit = 0.0 @inbounds for c2 in IT.components, l in IT.elements[c2] @inbounds if activeSet[c2][l] && (c1, j) != (c2, l) @inbounds partial_fit += GM2(c1, c2, j, l, d, N) * β_tilde[c2][l] end end # univariate ordinary leasts squares coefficient inner_prod_partial_residual = (xdy[c1][j] - partial_fit) / IT.obs # weighted penalty #w[c1][j] = 1.0 / (abs(β_ols)^γ) # w[c1][j] = 1.0 / abs(inner_prod_partial_residual) # # soft thresholding operator # if abs(inner_prod_partial_residual) <= λ[c1] * w[c1][j]^γ # if activeSet[c1][j] # β_tilde[c1][j] = 0.0 # activeSet[c1][j] = false # change_flag = true # #println("$(c1) , $(j)") # end # else # β_tilde[c1][j] = sign(inner_prod_partial_residual) * (abs(inner_prod_partial_residual) - λ[c1] * w[c1][j]^γ) / (d.σ[c1][j]^2) # # projection onto the box constraints [lower_bound, upper_bound] # β_tilde[c1][j] = max(β_tilde[c1][j], lower_bounds[c1]) # β_tilde[c1][j] = min(β_tilde[c1][j], upper_bounds[c1]) # if !activeSet[c1][j] #&& β_tilde[c1][j] != 0.0 # activeSet[c1][j] = true # change_flag = true # #println("$(c1) , $(j)") # end # end change_flag = soft_treshold(j, inner_prod_partial_residual, λ[c1], γ, w[c1][j], activeSet[c1], β_tilde[c1], d.σ[c1][j], lower_bounds[c1], upper_bounds[c1]) end end push!(β_path, deepcopy(β_tilde)) # bayesian information criterion BIC_new, y_hat = compute_BIC(y, β_tilde, activeSet, IT, d, xdy) push!(y_path, copy(y_hat)) if verbose print(string(" BIC = ", BIC_new)) end # save the best fit so far if BIC_new < BIC BIC = BIC_new y_best = copy(y_hat) β_best = deepcopy(β_tilde) λ_best = λ γ_best = γ end end end return β_path, y_path, β_best, y_best, λ_best, γ_best end function clear_warmstart!(β_tilde::Vector{Vector{Float64}}, IT::iterator) # clear warm-start for i in IT.components for j in IT.elements[i] β_tilde[i][j] = 0.0 end end nothing end function soft_treshold(j::Int, residual::Float64, λ::Float64, γ::Float64, w::Float64, activeSet::Vector{Bool}, β_tilde::Vector{Float64}, var::Float64, lb::Float64, ub::Float64 )::Bool if abs(residual) <= λ * w^γ if activeSet[j] β_tilde[j] = 0.0 activeSet[j] = false return true #println("$(c1) , $(j)") else return false end else β_tilde[j] = sign(residual) * (abs(residual) - λ * w^γ) / (var^2) # projection onto the box constraints [lower_bound, upper_bound] β_tilde[j] = max(β_tilde[j], lb) β_tilde[j] = min(β_tilde[j], ub) if !activeSet[j] #&& β_tilde[c1][j] != 0.0 activeSet[j] = true return true #println("$(c1) , $(j)") else return false end end return false end function update_components!(IT, w, β, d, xdy) # clear given iterator for c in IT.components IT.elements[c] = Int[] end for c in IT.components for j in 1:IT.nelements[c] if β[c][j] != 0.0 # pre-compute weight w[c][j] = abs(1.0 / β[c][j]) #/ (d.σ[c][j]^2) β[c][j] = 0.0 # update iterator only with nonzero elements push!(IT.elements[c], j) end end end return nothing end
[ 27, 456, 62, 30783, 29, 16, 12, 940, 198, 37811, 198, 75, 16, 62, 42552, 425, 62, 83, 10920, 62, 24455, 90, 51, 27, 25, 43879, 2414, 11, 311, 27, 25, 5317, 92, 7, 88, 3712, 38469, 90, 51, 5512, 6805, 3712, 38469, 90, 50, 19629, 277, 3712, 38469, 90, 51, 92, 796, 20650, 90, 51, 92, 7, 15, 828, 997, 39377, 3712, 50, 28, 50, 7, 1821, 828, 997, 42063, 3712, 50, 28, 50, 7, 940, 828, 25882, 2043, 1137, 3712, 50, 28, 50, 7, 4059, 828, 15942, 577, 3712, 33, 970, 28, 9562, 11, 21037, 62, 65, 3733, 3712, 38469, 90, 51, 92, 10779, 940, 68, 10, 22, 9, 1952, 7, 51, 11, 36247, 9858, 47, 1340, 15365, 828, 6727, 62, 65, 3733, 3712, 38469, 90, 51, 92, 28, 940, 68, 10, 22, 9, 1952, 7, 51, 11, 36247, 9858, 47, 1340, 15365, 8, 1267, 198, 198, 464, 2163, 4600, 75, 16, 62, 42552, 425, 62, 83, 10920, 62, 24455, 63, 17706, 262, 25431, 2884, 20435, 18598, 290, 2753, 262, 1708, 2672, 17311, 25, 198, 198, 9, 331, 1058, 26484, 393, 640, 12, 25076, 284, 307, 29083, 26, 357, 34320, 307, 257, 15879, 286, 302, 874, 8, 198, 9, 6805, 25, 7343, 286, 37014, 11188, 284, 262, 3858, 286, 6805, 284, 307, 3177, 13, 357, 27238, 307, 257, 15879, 286, 37014, 7268, 617, 286, 262, 1708, 3146, 25, 352, 796, 5012, 11, 362, 796, 26309, 11, 513, 796, 3454, 3008, 11, 604, 796, 311, 500, 11, 642, 796, 327, 793, 500, 1267, 198, 220, 220, 220, 220, 198, 198, 30719, 17311, 25, 198, 198, 9, 277, 25, 20650, 286, 625, 20751, 19998, 357, 19463, 28, 24172, 1776, 198, 9, 997, 39377, 25, 12849, 286, 262, 3218, 7509, 3108, 329, 262, 11507, 7377, 119, 357, 19463, 28, 1821, 1776, 198, 9, 997, 42063, 25, 12849, 286, 262, 3218, 7509, 3108, 329, 262, 11507, 7377, 111, 357, 19463, 28, 940, 1776, 198, 9, 25882, 2043, 1137, 25, 22246, 1271, 286, 34820, 357, 19463, 28, 4059, 1776, 198, 9, 15942, 577, 25, 41146, 6056, 329, 19407, 4371, 286, 11862, 357, 19463, 28, 9562, 1776, 198, 9, 2793, 62, 65, 3733, 25, 7343, 286, 2793, 22303, 329, 1123, 7515, 2099, 357, 19463, 41888, 12, 24861, 252, 12095, 24861, 252, 12095, 24861, 252, 12095, 24861, 252, 12095, 24861, 252, 36563, 198, 9, 6727, 62, 65, 3733, 25, 7343, 286, 6727, 275, 79, 917, 82, 329, 1123, 7515, 2099, 357, 19463, 41888, 10, 24861, 252, 11, 10, 24861, 252, 11, 10, 24861, 252, 11, 10, 24861, 252, 11, 10, 24861, 252, 35944, 198, 198, 1212, 2163, 5860, 25, 198, 198, 9, 220, 27169, 62, 6978, 25, 10644, 286, 6805, 44036, 26, 198, 9, 220, 331, 62, 6978, 25, 10644, 286, 29083, 10425, 26, 198, 9, 220, 27169, 62, 13466, 25, 6705, 6805, 44036, 1864, 284, 262, 43374, 2149, 9987, 26, 198, 9, 220, 331, 62, 13466, 25, 6705, 29083, 6737, 1864, 284, 262, 43374, 2149, 9987, 26, 198, 9, 220, 7377, 119, 62, 13466, 25, 6705, 1988, 329, 262, 7377, 119, 3218, 7509, 1864, 284, 262, 43374, 2149, 9987, 26, 198, 9, 220, 7377, 111, 62, 13466, 25, 6705, 1988, 329, 262, 7377, 111, 3218, 7509, 1864, 284, 262, 43374, 2149, 9987, 13, 198, 198, 2235, 17934, 198, 198, 15506, 63, 198, 88, 796, 43720, 7, 1507, 8, 1303, 617, 17311, 198, 5589, 3906, 796, 685, 16, 11, 18, 60, 1303, 7, 24815, 356, 691, 2074, 2239, 290, 22638, 6805, 8, 198, 198, 2, 1057, 262, 11862, 198, 31361, 62, 6978, 11, 331, 62, 6978, 11, 12159, 62, 13466, 11, 331, 62, 13466, 11, 37456, 62, 13466, 11, 34236, 62, 13466, 796, 300, 16, 62, 42552, 425, 62, 83, 10920, 62, 24455, 7, 88, 11, 5589, 3906, 8, 198, 15506, 63, 198, 198, 37811, 198, 8818, 300, 16, 62, 42552, 425, 62, 83, 10920, 62, 24455, 90, 51, 27, 25, 43879, 2414, 11, 311, 27, 25, 5317, 92, 7, 198, 220, 220, 220, 331, 3712, 38469, 90, 51, 5512, 6805, 3712, 38469, 90, 50, 19629, 277, 3712, 38469, 90, 51, 92, 796, 20650, 90, 51, 92, 7, 15, 828, 997, 39377, 3712, 50, 28, 50, 7, 1821, 828, 997, 42063, 3712, 50, 28, 50, 7, 940, 828, 25882, 2043, 1137, 3712, 50, 28, 50, 7, 4059, 828, 15942, 577, 3712, 33, 970, 28, 9562, 11, 198, 220, 220, 220, 2793, 62, 65, 3733, 3712, 38469, 90, 51, 92, 10779, 940, 68, 10, 22, 9, 1952, 7, 51, 11, 36247, 9858, 47, 1340, 15365, 828, 6727, 62, 65, 3733, 3712, 38469, 90, 51, 92, 28, 940, 68, 10, 22, 9, 1952, 7, 51, 11, 36247, 9858, 47, 1340, 15365, 8, 1267, 628, 220, 220, 220, 1303, 34128, 278, 262, 1612, 198, 220, 220, 220, 331, 62, 32604, 796, 1612, 7, 88, 8, 198, 220, 220, 220, 331, 796, 331, 532, 331, 62, 32604, 628, 220, 220, 220, 1303, 8335, 2198, 329, 15793, 10620, 198, 220, 220, 220, 1500, 399, 796, 4129, 7, 88, 8, 628, 220, 220, 220, 1303, 41313, 198, 220, 220, 220, 7283, 796, 2315, 2043, 62, 9521, 7, 45, 11, 6805, 11, 277, 11, 25882, 2043, 1137, 28, 22921, 2043, 1137, 2599, 25, 48727, 628, 220, 220, 220, 1303, 24061, 7188, 198, 220, 220, 220, 1500, 288, 796, 2315, 6601, 7, 2043, 11, 277, 11, 277, 2599, 25, 7890, 8610, 628, 220, 220, 220, 1303, 8434, 3186, 1022, 2882, 331, 290, 6805, 198, 220, 220, 220, 1500, 2124, 9892, 796, 2315, 55, 35, 56, 7, 2043, 11, 331, 11, 288, 8, 628, 220, 220, 220, 1303, 1382, 3218, 1634, 3108, 329, 7377, 119, 357, 31642, 3108, 5485, 11, 1180, 7377, 119, 82, 8, 198, 220, 220, 220, 3108, 11, 7377, 119, 62, 9806, 796, 24061, 62, 39377, 62, 6978, 7, 2043, 11, 2124, 9892, 11, 997, 39377, 11, 288, 8, 628, 220, 220, 220, 1303, 1382, 3218, 1634, 3108, 329, 7377, 111, 357, 34642, 3108, 8, 198, 220, 220, 220, 1500, 7377, 241, 796, 24061, 62, 42063, 62, 6978, 7, 2043, 11, 2124, 9892, 11, 997, 42063, 11, 288, 8, 628, 220, 220, 220, 1303, 41216, 19590, 198, 220, 220, 220, 266, 796, 20650, 90, 43879, 2414, 92, 21737, 198, 220, 220, 220, 329, 1312, 287, 352, 25, 51, 27510, 9858, 47, 1340, 15365, 198, 220, 220, 220, 220, 220, 220, 220, 611, 287, 7, 72, 11, 2043, 13, 5589, 3906, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 86, 11, 3392, 7, 2043, 13, 710, 3639, 58, 72, 60, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 86, 11, 3392, 7, 15, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1303, 300, 28372, 1208, 198, 220, 220, 220, 2488, 7217, 11018, 27169, 62, 6978, 11, 331, 62, 6978, 11, 27169, 62, 13466, 11, 331, 62, 13466, 11, 7377, 119, 62, 13466, 11, 7377, 111, 62, 13466, 796, 20435, 62, 8906, 1087, 7, 198, 220, 220, 220, 220, 220, 7283, 11, 288, 11, 2124, 9892, 11, 3108, 11, 7377, 119, 62, 9806, 11, 685, 16, 13, 15, 11, 60, 837, 331, 11, 2793, 62, 65, 3733, 11, 6727, 62, 65, 3733, 11, 266, 11, 15942, 577, 198, 220, 220, 220, 220, 220, 1267, 628, 220, 220, 220, 1303, 19607, 262, 6805, 262, 300, 28372, 468, 900, 284, 6632, 198, 220, 220, 220, 4296, 62, 5589, 3906, 0, 7, 2043, 11, 266, 11, 27169, 62, 13466, 11, 288, 11, 2124, 9892, 8, 628, 220, 220, 220, 2488, 7217, 11018, 27169, 62, 6978, 11, 331, 62, 6978, 11, 27169, 62, 13466, 11, 331, 62, 13466, 11, 7377, 119, 62, 13466, 11, 7377, 111, 62, 13466, 796, 20435, 62, 8906, 1087, 7, 198, 220, 220, 220, 220, 220, 7283, 11, 288, 11, 2124, 9892, 11, 3108, 11, 7377, 119, 62, 9806, 11, 7377, 241, 11, 331, 11, 2793, 62, 65, 3733, 11, 6727, 62, 65, 3733, 11, 266, 11, 15942, 577, 198, 220, 220, 220, 1267, 628, 220, 220, 220, 1303, 4375, 736, 262, 1612, 198, 220, 220, 220, 331, 62, 13466, 796, 331, 62, 13466, 1343, 331, 62, 32604, 628, 220, 220, 220, 611, 15942, 577, 198, 220, 220, 220, 220, 220, 3601, 7, 8841, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 13466, 3218, 1634, 1864, 284, 347, 2149, 373, 357, 39377, 28, 1600, 2835, 7, 39377, 62, 13466, 11, 513, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33172, 7377, 111, 28, 1600, 2835, 7, 42063, 62, 13466, 11, 513, 828, 366, 8, 3467, 77, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15306, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1441, 27169, 62, 6978, 11, 331, 62, 6978, 11, 27169, 62, 13466, 11, 331, 62, 13466, 11, 7377, 119, 62, 13466, 11, 7377, 111, 62, 13466, 198, 437, 198, 198, 2, 20435, 18598, 11862, 329, 262, 3218, 1634, 3108, 357, 138, 249, 2124, 7377, 241, 8, 198, 8818, 20435, 62, 8906, 1087, 7, 198, 220, 220, 220, 7283, 3712, 48727, 11, 288, 3712, 7890, 8610, 11, 2124, 9892, 3712, 38469, 90, 38469, 90, 43879, 2414, 92, 5512, 3108, 3712, 38469, 90, 43879, 2414, 5512, 7377, 119, 62, 9806, 3712, 38469, 90, 43879, 2414, 5512, 7377, 241, 3712, 38469, 90, 43879, 2414, 5512, 198, 220, 220, 220, 331, 3712, 38469, 90, 43879, 2414, 5512, 2793, 62, 65, 3733, 3712, 38469, 90, 43879, 2414, 5512, 6727, 62, 65, 3733, 3712, 38469, 90, 43879, 2414, 5512, 266, 3712, 38469, 90, 38469, 90, 43879, 2414, 92, 5512, 15942, 577, 3712, 33, 970, 26, 29877, 3712, 5317, 796, 657, 198, 220, 220, 220, 1267, 628, 220, 1500, 399, 796, 7283, 13, 8158, 628, 220, 1303, 4238, 4582, 198, 220, 1303, 361, 29877, 6624, 352, 198, 220, 1303, 220, 27169, 62, 6978, 11, 27169, 62, 83, 44725, 11, 27169, 11, 4075, 7248, 796, 2315, 50, 29572, 7, 2043, 8, 198, 220, 1303, 17772, 198, 220, 27169, 62, 6978, 11, 27169, 62, 83, 44725, 11, 27169, 11, 4075, 7248, 796, 2315, 35, 1072, 7, 2043, 8, 198, 220, 1303, 437, 628, 220, 1303, 4088, 20157, 198, 220, 347, 2149, 796, 4806, 3712, 43879, 2414, 198, 220, 27169, 62, 10220, 796, 657, 13, 15, 3712, 43879, 2414, 198, 220, 13027, 62, 11147, 796, 657, 13, 15, 198, 220, 27169, 62, 13466, 796, 657, 13, 15, 198, 220, 331, 62, 13466, 796, 657, 198, 220, 7377, 119, 62, 13466, 796, 657, 13, 15, 198, 220, 7377, 111, 62, 13466, 796, 657, 13, 15, 198, 220, 3108, 62, 2676, 341, 796, 657, 628, 220, 331, 62, 6978, 796, 20650, 90, 43879, 2414, 92, 21737, 198, 220, 1303, 1640, 1312, 287, 352, 25, 51, 27510, 9858, 47, 1340, 15365, 198, 220, 1303, 220, 4574, 0, 7, 86, 11, 1976, 27498, 7, 2043, 13, 710, 3639, 58, 72, 60, 4008, 198, 220, 1303, 437, 628, 220, 1303, 3218, 1634, 3108, 198, 220, 2488, 259, 65, 3733, 329, 7377, 111, 287, 7377, 241, 628, 220, 220, 220, 1303, 1598, 5814, 12, 9688, 198, 220, 220, 220, 1598, 62, 31975, 9688, 0, 7, 26638, 62, 83, 44725, 11, 7283, 8, 628, 220, 220, 220, 2488, 259, 65, 3733, 329, 3108, 62, 2676, 287, 3108, 628, 220, 220, 220, 220, 220, 7377, 119, 796, 3108, 62, 2676, 1635, 7377, 119, 62, 9806, 628, 220, 220, 220, 220, 220, 1487, 62, 32109, 796, 2081, 628, 220, 220, 220, 220, 220, 611, 15942, 577, 198, 220, 220, 220, 220, 220, 220, 220, 3108, 62, 2676, 341, 15853, 352, 198, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 8841, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 16338, 11341, 796, 357, 1600, 2835, 7, 39377, 11, 513, 828, 33172, 33172, 2835, 7, 42063, 11, 513, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 8, 3108, 24415, 796, 33172, 3108, 62, 2676, 341, 11, 27071, 59, 77, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15306, 198, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 1303, 9052, 1566, 4075, 900, 6718, 3212, 198, 220, 220, 220, 220, 220, 2488, 259, 65, 3733, 329, 11629, 287, 352, 25, 2043, 13, 9806, 29993, 628, 220, 220, 220, 220, 220, 220, 220, 611, 15942, 577, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 2676, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 40826, 2198, 198, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 3803, 62, 32109, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2270, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1487, 62, 32109, 796, 3991, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 6772, 832, 790, 7515, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 259, 65, 3733, 329, 269, 16, 287, 7283, 13, 5589, 3906, 11, 474, 287, 7283, 13, 68, 3639, 58, 66, 16, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 2074, 8169, 9665, 1724, 290, 5553, 2114, 11, 329, 1365, 16181, 84, 779, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 24061, 262, 13027, 4197, 351, 262, 6805, 287, 262, 4075, 900, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 13027, 62, 11147, 796, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 259, 65, 3733, 329, 269, 17, 287, 7283, 13, 5589, 3906, 11, 300, 287, 7283, 13, 68, 3639, 58, 66, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 259, 65, 3733, 611, 4075, 7248, 58, 66, 17, 7131, 75, 60, 11405, 357, 66, 16, 11, 474, 8, 14512, 357, 66, 17, 11, 300, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 259, 65, 3733, 13027, 62, 11147, 15853, 6951, 17, 7, 66, 16, 11, 269, 17, 11, 474, 11, 300, 11, 288, 11, 399, 8, 1635, 27169, 62, 83, 44725, 58, 66, 17, 7131, 75, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 555, 42524, 8850, 1551, 82, 24438, 35381, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8434, 62, 1676, 67, 62, 47172, 62, 411, 312, 723, 796, 357, 87, 9892, 58, 66, 16, 7131, 73, 60, 532, 13027, 62, 11147, 8, 1220, 7283, 13, 8158, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 26356, 7389, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 86, 58, 66, 16, 7131, 73, 60, 796, 352, 13, 15, 1220, 357, 8937, 7, 26638, 62, 10220, 8, 61, 42063, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 266, 58, 66, 16, 7131, 73, 60, 796, 352, 13, 15, 1220, 2352, 7, 5083, 62, 1676, 67, 62, 47172, 62, 411, 312, 723, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1303, 2705, 11387, 278, 10088, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 611, 2352, 7, 5083, 62, 1676, 67, 62, 47172, 62, 411, 312, 723, 8, 19841, 7377, 119, 58, 66, 16, 60, 1635, 266, 58, 66, 16, 7131, 73, 60, 61, 42063, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 611, 4075, 7248, 58, 66, 16, 7131, 73, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 66, 16, 7131, 73, 60, 796, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 4075, 7248, 58, 66, 16, 7131, 73, 60, 796, 3991, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 1487, 62, 32109, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 35235, 7203, 3, 7, 66, 16, 8, 220, 837, 29568, 73, 8, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 66, 16, 7131, 73, 60, 796, 1051, 7, 5083, 62, 1676, 67, 62, 47172, 62, 411, 312, 723, 8, 1635, 357, 8937, 7, 5083, 62, 1676, 67, 62, 47172, 62, 411, 312, 723, 8, 532, 7377, 119, 58, 66, 16, 60, 1635, 266, 58, 66, 16, 7131, 73, 60, 61, 42063, 8, 1220, 357, 67, 13, 38392, 58, 66, 16, 7131, 73, 60, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 1303, 20128, 4291, 262, 3091, 17778, 685, 21037, 62, 7784, 11, 6727, 62, 7784, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 66, 16, 7131, 73, 60, 796, 3509, 7, 26638, 62, 83, 44725, 58, 66, 16, 7131, 73, 4357, 2793, 62, 65, 3733, 58, 66, 16, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 66, 16, 7131, 73, 60, 796, 949, 7, 26638, 62, 83, 44725, 58, 66, 16, 7131, 73, 4357, 6727, 62, 65, 3733, 58, 66, 16, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 611, 5145, 5275, 7248, 58, 66, 16, 7131, 73, 60, 1303, 25226, 27169, 62, 83, 44725, 58, 66, 16, 7131, 73, 60, 14512, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 4075, 7248, 58, 66, 16, 7131, 73, 60, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 1487, 62, 32109, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 35235, 7203, 3, 7, 66, 16, 8, 220, 837, 29568, 73, 8, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1487, 62, 32109, 796, 2705, 62, 83, 10126, 7, 73, 11, 8434, 62, 1676, 67, 62, 47172, 62, 411, 312, 723, 11, 7377, 119, 58, 66, 16, 4357, 7377, 111, 11, 266, 58, 66, 16, 7131, 73, 4357, 4075, 7248, 58, 66, 16, 4357, 27169, 62, 83, 44725, 58, 66, 16, 4357, 288, 13, 38392, 58, 66, 16, 7131, 73, 4357, 2793, 62, 65, 3733, 58, 66, 16, 4357, 6727, 62, 65, 3733, 58, 66, 16, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 886, 628, 198, 220, 220, 220, 220, 220, 4574, 0, 7, 26638, 62, 6978, 11, 2769, 30073, 7, 26638, 62, 83, 44725, 4008, 628, 220, 220, 220, 220, 220, 1303, 15489, 35610, 1321, 34054, 198, 220, 220, 220, 220, 220, 347, 2149, 62, 3605, 11, 331, 62, 5183, 796, 24061, 62, 33, 2149, 7, 88, 11, 27169, 62, 83, 44725, 11, 4075, 7248, 11, 7283, 11, 288, 11, 2124, 9892, 8, 628, 220, 220, 220, 220, 220, 4574, 0, 7, 88, 62, 6978, 11, 4866, 7, 88, 62, 5183, 4008, 198, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 611, 15942, 577, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 8841, 7203, 347, 2149, 796, 33172, 347, 2149, 62, 3605, 4008, 198, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 1303, 3613, 262, 1266, 4197, 523, 1290, 198, 220, 220, 220, 220, 220, 611, 347, 2149, 62, 3605, 1279, 347, 2149, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 347, 2149, 796, 347, 2149, 62, 3605, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 62, 13466, 796, 4866, 7, 88, 62, 5183, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 13466, 796, 2769, 30073, 7, 26638, 62, 83, 44725, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 7377, 119, 62, 13466, 796, 7377, 119, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 7377, 111, 62, 13466, 796, 7377, 111, 198, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 886, 198, 220, 886, 628, 220, 1441, 27169, 62, 6978, 11, 331, 62, 6978, 11, 27169, 62, 13466, 11, 331, 62, 13466, 11, 7377, 119, 62, 13466, 11, 7377, 111, 62, 13466, 198, 437, 198, 198, 8818, 1598, 62, 31975, 9688, 0, 7, 26638, 62, 83, 44725, 3712, 38469, 90, 38469, 90, 43879, 2414, 92, 5512, 7283, 3712, 48727, 8, 628, 220, 1303, 1598, 5814, 12, 9688, 198, 220, 220, 220, 329, 1312, 287, 7283, 13, 5589, 3906, 198, 220, 220, 220, 220, 220, 220, 220, 329, 474, 287, 7283, 13, 68, 3639, 58, 72, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 72, 7131, 73, 60, 796, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2147, 198, 437, 198, 198, 8818, 2705, 62, 83, 10126, 7, 73, 3712, 5317, 11, 29598, 3712, 43879, 2414, 11, 7377, 119, 3712, 43879, 2414, 11, 7377, 111, 3712, 43879, 2414, 11, 266, 3712, 43879, 2414, 11, 4075, 7248, 3712, 38469, 90, 33, 970, 5512, 27169, 62, 83, 44725, 3712, 38469, 90, 43879, 2414, 5512, 220, 198, 220, 220, 220, 1401, 3712, 43879, 2414, 11, 18360, 3712, 43879, 2414, 11, 20967, 3712, 43879, 2414, 1267, 3712, 33, 970, 628, 220, 220, 220, 611, 2352, 7, 411, 312, 723, 8, 19841, 7377, 119, 1635, 266, 61, 42063, 198, 220, 220, 220, 220, 220, 220, 220, 611, 4075, 7248, 58, 73, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 73, 60, 796, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4075, 7248, 58, 73, 60, 796, 3991, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 35235, 7203, 3, 7, 66, 16, 8, 220, 837, 29568, 73, 8, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 3991, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 73, 60, 796, 1051, 7, 411, 312, 723, 8, 1635, 357, 8937, 7, 411, 312, 723, 8, 532, 7377, 119, 1635, 266, 61, 42063, 8, 1220, 357, 7785, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 20128, 4291, 262, 3091, 17778, 685, 21037, 62, 7784, 11, 6727, 62, 7784, 60, 198, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 73, 60, 796, 3509, 7, 26638, 62, 83, 44725, 58, 73, 4357, 18360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 27169, 62, 83, 44725, 58, 73, 60, 796, 949, 7, 26638, 62, 83, 44725, 58, 73, 4357, 20967, 8, 628, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 5275, 7248, 58, 73, 60, 1303, 25226, 27169, 62, 83, 44725, 58, 66, 16, 7131, 73, 60, 14512, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4075, 7248, 58, 73, 60, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 35235, 7203, 3, 7, 66, 16, 8, 220, 837, 29568, 73, 8, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 3991, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 3991, 198, 437, 198, 198, 8818, 4296, 62, 5589, 3906, 0, 7, 2043, 11, 266, 11, 27169, 11, 288, 11, 2124, 9892, 8, 628, 220, 1303, 1598, 1813, 41313, 198, 220, 329, 269, 287, 7283, 13, 5589, 3906, 198, 220, 220, 220, 7283, 13, 68, 3639, 58, 66, 60, 796, 2558, 21737, 198, 220, 886, 628, 220, 329, 269, 287, 7283, 13, 5589, 3906, 198, 220, 220, 220, 329, 474, 287, 352, 25, 2043, 13, 710, 3639, 58, 66, 60, 628, 220, 220, 220, 220, 220, 611, 27169, 58, 66, 7131, 73, 60, 14512, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 662, 12, 5589, 1133, 3463, 198, 220, 220, 220, 220, 220, 220, 220, 266, 58, 66, 7131, 73, 60, 796, 2352, 7, 16, 13, 15, 1220, 27169, 58, 66, 7131, 73, 12962, 1303, 14, 357, 67, 13, 38392, 58, 66, 7131, 73, 60, 61, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 27169, 58, 66, 7131, 73, 60, 796, 657, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 4296, 41313, 691, 351, 1729, 22570, 4847, 198, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 2043, 13, 68, 3639, 58, 66, 4357, 474, 8, 198, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 886, 198, 220, 886, 628, 220, 1441, 2147, 198, 437, 198 ]
2.108545
4,459
# Surrogate functions hinge(x, ϑ::Real = 1) = max(zero(x), 1 + ϑ * x) quadratic(x, ϑ::Real = 1) = max(zero(x), 1 + ϑ * x)^2 # Objective functions struct FNRate <: Objective end Base.show(io::IO, ::FNRate) = print(io, "false-negative rate") function objective(::FNRate, y, s::AbstractArray{T}, t, surrogate) where {T<:Real} inds = zero(T) .+ (y .== 1) return sum(surrogate.(t .- s) .* inds; dims = 2) ./ sum(inds; dims = 2) end struct FPRate <: Objective end Base.show(io::IO, ::FPRate) = print(io, "false-positive rate") function objective(::FPRate, y, s::AbstractArray{T}, t, surrogate) where {T<:Real} inds = zero(T) .+ (y .== 1) return sum(surrogate.(s .- t) .* inds; dims = 2) ./ sum(inds; dims = 2) end struct FNFPRate <: Objective α::Real end function Base.show(io::IO, o::FNFPRate) return print(io, "$(o.α)⋅false-negative + $(1-o.α)⋅false-positive rate") end function objective(o::FNFPRate, y, s, t, surrogate) return o.α .* objective(FNRate(), y, s, t, surrogate) .+ (1 - o.α) .* objective(FPRate(), y, s, t, surrogate) end # Accuracy at Top formulation struct AccAtTop threshold_type::Threshold objective_type::Objective end function Base.show(io::IO, m::AccAtTop) println(io, "Accuracy at the top:") println(io, " - threshold: $(m.threshold_type)") print(io, " - objective function: $(m.objective_type)") return end function objective( m::AccAtTop, y::AbstractMatrix, s::AbstractMatrix; surrogate = hinge, agg = mean, update_buffer = true, ) if size(y) != size(s) throw(DimensionMismatch("dimensions must match: y has dims $(size(y)), s has dims $(size(s))")) end ts = threshold(m.threshold_type, y, s; update_buffer) return agg(objective(m.objective_type, y, s, ts, surrogate)) end function predict( m::AccAtTop, y::AbstractMatrix, s::AbstractMatrix; ts = threshold(m.threshold_type, y, s; update_buffer = false), ) if size(y) != size(s) throw(DimensionMismatch("dimensions must match: y has dims $(size(y)), s has dims $(size(s))")) end if length(ts) != size(s, 1) throw(DimensionMismatch("length of thresholds $(length(ts)) does not match first dim of scores $(size(s, 1))")) end return s .>= ts end # Basic models DeepTopPush() = AccAtTop(Maximum(Neg), FNRate()) DeepTopPushK(K) = AccAtTop(Kth(K, Neg), FNRate()) PatMat(τ::Real) = AccAtTop(Quantile(τ, All; rev = true), FNRate()) PatMat(sampler) = AccAtTop(SampledQuantile(sampler, All; rev = true), FNRate()) PatMatNP(τ::Real) = AccAtTop(Quantile(τ, Neg; rev = true), FNRate()) PatMatNP(sampler) = AccAtTop(SampledQuantile(sampler, Neg; rev = true), FNRate())
[ 2, 4198, 3828, 378, 5499, 198, 722, 68, 7, 87, 11, 18074, 239, 3712, 15633, 796, 352, 8, 796, 3509, 7, 22570, 7, 87, 828, 352, 1343, 18074, 239, 1635, 2124, 8, 198, 421, 41909, 1512, 7, 87, 11, 18074, 239, 3712, 15633, 796, 352, 8, 796, 3509, 7, 22570, 7, 87, 828, 352, 1343, 18074, 239, 1635, 2124, 8, 61, 17, 198, 198, 2, 37092, 5499, 198, 7249, 376, 24723, 378, 1279, 25, 37092, 886, 198, 198, 14881, 13, 12860, 7, 952, 3712, 9399, 11, 7904, 37, 24723, 378, 8, 796, 3601, 7, 952, 11, 366, 9562, 12, 31591, 2494, 4943, 198, 198, 8818, 9432, 7, 3712, 37, 24723, 378, 11, 331, 11, 264, 3712, 23839, 19182, 90, 51, 5512, 256, 11, 37660, 8, 810, 1391, 51, 27, 25, 15633, 92, 198, 220, 220, 220, 773, 82, 796, 6632, 7, 51, 8, 764, 10, 357, 88, 764, 855, 352, 8, 198, 220, 220, 220, 1441, 2160, 7, 11793, 3828, 378, 12195, 83, 764, 12, 220, 264, 8, 764, 9, 773, 82, 26, 5391, 82, 796, 362, 8, 24457, 2160, 7, 521, 82, 26, 5391, 82, 796, 362, 8, 198, 437, 198, 198, 7249, 376, 4805, 378, 1279, 25, 37092, 886, 198, 198, 14881, 13, 12860, 7, 952, 3712, 9399, 11, 7904, 37, 4805, 378, 8, 796, 3601, 7, 952, 11, 366, 9562, 12, 24561, 2494, 4943, 198, 198, 8818, 9432, 7, 3712, 37, 4805, 378, 11, 331, 11, 264, 3712, 23839, 19182, 90, 51, 5512, 256, 11, 37660, 8, 810, 1391, 51, 27, 25, 15633, 92, 198, 220, 220, 220, 773, 82, 796, 6632, 7, 51, 8, 764, 10, 357, 88, 764, 855, 352, 8, 198, 220, 220, 220, 1441, 2160, 7, 11793, 3828, 378, 12195, 82, 764, 12, 220, 256, 8, 764, 9, 773, 82, 26, 5391, 82, 796, 362, 8, 24457, 2160, 7, 521, 82, 26, 5391, 82, 796, 362, 8, 198, 437, 198, 198, 7249, 376, 21870, 4805, 378, 1279, 25, 37092, 198, 220, 220, 220, 26367, 3712, 15633, 198, 437, 198, 198, 8818, 7308, 13, 12860, 7, 952, 3712, 9399, 11, 267, 3712, 37, 21870, 4805, 378, 8, 198, 220, 220, 220, 1441, 3601, 7, 952, 11, 17971, 7, 78, 13, 17394, 8, 158, 233, 227, 9562, 12, 31591, 1343, 29568, 16, 12, 78, 13, 17394, 8, 158, 233, 227, 9562, 12, 24561, 2494, 4943, 198, 437, 198, 198, 8818, 9432, 7, 78, 3712, 37, 21870, 4805, 378, 11, 331, 11, 264, 11, 256, 11, 37660, 8, 198, 220, 220, 220, 1441, 267, 13, 17394, 764, 9, 9432, 7, 37, 24723, 378, 22784, 331, 11, 264, 11, 256, 11, 37660, 8, 764, 10, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 16, 532, 267, 13, 17394, 8, 764, 9, 9432, 7, 37, 4805, 378, 22784, 331, 11, 264, 11, 256, 11, 37660, 8, 198, 437, 198, 198, 2, 33222, 379, 5849, 31760, 198, 7249, 6366, 2953, 9126, 198, 220, 220, 220, 11387, 62, 4906, 3712, 817, 10126, 198, 220, 220, 220, 9432, 62, 4906, 3712, 10267, 425, 198, 437, 198, 198, 8818, 7308, 13, 12860, 7, 952, 3712, 9399, 11, 285, 3712, 17320, 2953, 9126, 8, 198, 220, 220, 220, 44872, 7, 952, 11, 366, 17320, 23843, 379, 262, 1353, 25, 4943, 198, 220, 220, 220, 44872, 7, 952, 11, 366, 532, 11387, 25, 29568, 76, 13, 400, 10126, 62, 4906, 8, 4943, 198, 220, 220, 220, 3601, 7, 952, 11, 366, 532, 9432, 2163, 25, 29568, 76, 13, 15252, 425, 62, 4906, 8, 4943, 198, 220, 220, 220, 1441, 198, 437, 198, 198, 8818, 9432, 7, 198, 220, 220, 220, 285, 3712, 17320, 2953, 9126, 11, 198, 220, 220, 220, 331, 3712, 23839, 46912, 11, 198, 220, 220, 220, 264, 3712, 23839, 46912, 26, 198, 220, 220, 220, 37660, 796, 41968, 11, 198, 220, 220, 220, 4194, 796, 1612, 11, 198, 220, 220, 220, 4296, 62, 22252, 796, 2081, 11, 198, 8, 628, 220, 220, 220, 611, 2546, 7, 88, 8, 14512, 2546, 7, 82, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3714, 7, 29271, 3004, 44, 1042, 963, 7203, 27740, 5736, 1276, 2872, 25, 331, 468, 5391, 82, 29568, 7857, 7, 88, 36911, 264, 468, 5391, 82, 29568, 7857, 7, 82, 4008, 48774, 198, 220, 220, 220, 886, 628, 220, 220, 220, 40379, 796, 11387, 7, 76, 13, 400, 10126, 62, 4906, 11, 331, 11, 264, 26, 4296, 62, 22252, 8, 198, 220, 220, 220, 1441, 4194, 7, 15252, 425, 7, 76, 13, 15252, 425, 62, 4906, 11, 331, 11, 264, 11, 40379, 11, 37660, 4008, 198, 437, 198, 198, 8818, 4331, 7, 198, 220, 220, 220, 285, 3712, 17320, 2953, 9126, 11, 198, 220, 220, 220, 331, 3712, 23839, 46912, 11, 198, 220, 220, 220, 264, 3712, 23839, 46912, 26, 198, 220, 220, 220, 40379, 796, 11387, 7, 76, 13, 400, 10126, 62, 4906, 11, 331, 11, 264, 26, 4296, 62, 22252, 796, 3991, 828, 198, 8, 628, 220, 220, 220, 611, 2546, 7, 88, 8, 14512, 2546, 7, 82, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3714, 7, 29271, 3004, 44, 1042, 963, 7203, 27740, 5736, 1276, 2872, 25, 331, 468, 5391, 82, 29568, 7857, 7, 88, 36911, 264, 468, 5391, 82, 29568, 7857, 7, 82, 4008, 48774, 198, 220, 220, 220, 886, 628, 220, 220, 220, 611, 4129, 7, 912, 8, 14512, 2546, 7, 82, 11, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3714, 7, 29271, 3004, 44, 1042, 963, 7203, 13664, 286, 40885, 29568, 13664, 7, 912, 4008, 857, 407, 2872, 717, 5391, 286, 8198, 29568, 7857, 7, 82, 11, 352, 4008, 48774, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 264, 764, 29, 28, 40379, 198, 437, 198, 198, 2, 14392, 4981, 198, 29744, 9126, 49222, 3419, 796, 6366, 2953, 9126, 7, 40541, 7, 32863, 828, 376, 24723, 378, 28955, 198, 29744, 9126, 49222, 42, 7, 42, 8, 796, 6366, 2953, 9126, 7, 42, 400, 7, 42, 11, 13496, 828, 376, 24723, 378, 28955, 198, 12130, 19044, 7, 32830, 3712, 15633, 8, 796, 6366, 2953, 9126, 7, 24915, 576, 7, 32830, 11, 1439, 26, 2710, 796, 2081, 828, 376, 24723, 378, 28955, 198, 12130, 19044, 7, 37687, 20053, 8, 796, 6366, 2953, 9126, 7, 16305, 10137, 24915, 576, 7, 37687, 20053, 11, 1439, 26, 2710, 796, 2081, 828, 376, 24723, 378, 28955, 198, 12130, 19044, 22182, 7, 32830, 3712, 15633, 8, 796, 6366, 2953, 9126, 7, 24915, 576, 7, 32830, 11, 13496, 26, 2710, 796, 2081, 828, 376, 24723, 378, 28955, 198, 12130, 19044, 22182, 7, 37687, 20053, 8, 796, 6366, 2953, 9126, 7, 16305, 10137, 24915, 576, 7, 37687, 20053, 11, 13496, 26, 2710, 796, 2081, 828, 376, 24723, 378, 28955, 198 ]
2.422182
1,118
<reponame>angus-lewis/DFQExamples.jl include((@__DIR__)*"/../preamble.jl") include("reflecting_model/model_def.jl") include("default_params.jl") # look at time to exit of the interval [0,1] # use the bounded fluid queue, but change the boundary to be at 1 model = BoundedFluidQueue( model.T[1:2,1:2],rates(model)[1:2],[0.0 1.0],[1.0 0.0],1.0, ) dg_model(order) = build_discretised_model(DGMesh{t},model,(1.0/3)/((order+1)/2),2) # order1_model(order) = build_discretised_model(DGMesh{t},model,1.0/3/order,1) # qbdrap_model(order) = build_discretised_model(FRAPMesh{t},model,1.0/3,order) d0_map_point_mass(dq) = (interior_point_mass(eps(),1,dq).coeffs) d0_map_exp(dq) = (SFMDistribution((x,i)->(i∈(1:2))*exp(-x)/(1-exp(-model.b))/2,dq).coeffs) # change d0_map here to do the make_approximations for ohter initial confitions # remember to change write directory below too models = make_approximations(orders,approx_types,d0_map_exp,(args...)->args[1]) for k1 in keys(models) for k2 in keys(models[k1]) models[k1][k2]["B"][1,:] = spzeros(1,size(models[k1][k2]["B"],2)) models[k1][k2]["B"][end,:] = spzeros(1,size(models[k1][k2]["B"],2)) droptol!(models[k1][k2]["B"],eps()*1000) end end pth = mkpath((@__DIR__)*"/hitting_times/data/exp") h = 0.005/3 t_vec = 0.0:h:10.0 hitting_times_cdf = zeros(length(t_vec),3) hitting_times_cdf[:,1] = t_vec for k1 in keys(models) for k2 in keys(models[k1]) for (c,t) in enumerate(t_vec) models[k1][k2]["coeffs_mapped"] = DiscretisedFluidQueues._integrate( models[k1][k2]["coeffs_mapped"], models[k1][k2]["B"], h, StableRK4(h), x->GeneralisedMUSCL.fun(x,GeneralisedMUSCL.generate_params(models[k1][k2]["dq"])...), ) hitting_times_cdf[c,2:3] = models[k1][k2]["coeffs_mapped"][[1;end]] end CSV.write( pth*"/order_"*string(k1)*"_model_"*string(k2)*".csv", DataFrame( t=hitting_times_cdf[:,1], phase_2=hitting_times_cdf[:,2], phase_1=hitting_times_cdf[:,3], ) ) end end
[ 27, 7856, 261, 480, 29, 648, 385, 12, 293, 86, 271, 14, 8068, 48, 27730, 13, 20362, 198, 17256, 19510, 31, 834, 34720, 834, 27493, 1, 14, 40720, 79, 1476, 903, 13, 20362, 4943, 220, 198, 198, 17256, 7203, 35051, 278, 62, 19849, 14, 19849, 62, 4299, 13, 20362, 4943, 198, 17256, 7203, 12286, 62, 37266, 13, 20362, 4943, 198, 198, 2, 804, 379, 640, 284, 8420, 286, 262, 16654, 685, 15, 11, 16, 60, 198, 2, 779, 262, 49948, 11711, 16834, 11, 475, 1487, 262, 18645, 284, 307, 379, 352, 198, 19849, 796, 347, 6302, 37, 2290, 312, 34991, 7, 198, 220, 220, 220, 2746, 13, 51, 58, 16, 25, 17, 11, 16, 25, 17, 4357, 9700, 7, 19849, 38381, 16, 25, 17, 38430, 15, 13, 15, 352, 13, 15, 38430, 16, 13, 15, 657, 13, 15, 4357, 16, 13, 15, 11, 198, 8, 198, 198, 67, 70, 62, 19849, 7, 2875, 8, 796, 1382, 62, 15410, 1186, 1417, 62, 19849, 7, 35, 15548, 5069, 90, 83, 5512, 19849, 11, 7, 16, 13, 15, 14, 18, 20679, 19510, 2875, 10, 16, 20679, 17, 828, 17, 8, 198, 2, 1502, 16, 62, 19849, 7, 2875, 8, 796, 1382, 62, 15410, 1186, 1417, 62, 19849, 7, 35, 15548, 5069, 90, 83, 5512, 19849, 11, 16, 13, 15, 14, 18, 14, 2875, 11, 16, 8, 198, 2, 10662, 17457, 2416, 62, 19849, 7, 2875, 8, 796, 1382, 62, 15410, 1186, 1417, 62, 19849, 7, 10913, 2969, 37031, 90, 83, 5512, 19849, 11, 16, 13, 15, 14, 18, 11, 2875, 8, 198, 198, 67, 15, 62, 8899, 62, 4122, 62, 22208, 7, 49506, 8, 796, 357, 3849, 1504, 62, 4122, 62, 22208, 7, 25386, 22784, 16, 11, 49506, 737, 1073, 14822, 82, 8, 198, 67, 15, 62, 8899, 62, 11201, 7, 49506, 8, 796, 357, 20802, 12740, 396, 3890, 19510, 87, 11, 72, 8, 3784, 7, 72, 24861, 230, 7, 16, 25, 17, 4008, 9, 11201, 32590, 87, 20679, 7, 16, 12, 11201, 32590, 19849, 13, 65, 4008, 14, 17, 11, 49506, 737, 1073, 14822, 82, 8, 198, 198, 2, 1487, 288, 15, 62, 8899, 994, 284, 466, 262, 787, 62, 1324, 13907, 320, 602, 329, 11752, 353, 4238, 1013, 1756, 198, 2, 3505, 284, 1487, 3551, 8619, 2174, 1165, 198, 27530, 796, 787, 62, 1324, 13907, 320, 602, 7, 6361, 11, 1324, 13907, 62, 19199, 11, 67, 15, 62, 8899, 62, 11201, 11, 7, 22046, 23029, 3784, 22046, 58, 16, 12962, 198, 198, 1640, 479, 16, 287, 8251, 7, 27530, 8, 198, 220, 220, 220, 329, 479, 17, 287, 8251, 7, 27530, 58, 74, 16, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 4981, 58, 74, 16, 7131, 74, 17, 7131, 1, 33, 1, 7131, 16, 11, 47715, 796, 599, 9107, 418, 7, 16, 11, 7857, 7, 27530, 58, 74, 16, 7131, 74, 17, 7131, 1, 33, 33116, 17, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 4981, 58, 74, 16, 7131, 74, 17, 7131, 1, 33, 1, 7131, 437, 11, 47715, 796, 599, 9107, 418, 7, 16, 11, 7857, 7, 27530, 58, 74, 16, 7131, 74, 17, 7131, 1, 33, 33116, 17, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 3102, 457, 349, 0, 7, 27530, 58, 74, 16, 7131, 74, 17, 7131, 1, 33, 33116, 25386, 3419, 9, 12825, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 79, 400, 796, 33480, 6978, 19510, 31, 834, 34720, 834, 27493, 1, 14, 48320, 62, 22355, 14, 7890, 14, 11201, 4943, 198, 198, 71, 796, 657, 13, 22544, 14, 18, 198, 83, 62, 35138, 796, 657, 13, 15, 25, 71, 25, 940, 13, 15, 198, 48320, 62, 22355, 62, 66, 7568, 796, 1976, 27498, 7, 13664, 7, 83, 62, 35138, 828, 18, 8, 220, 198, 48320, 62, 22355, 62, 66, 7568, 58, 45299, 16, 60, 796, 256, 62, 35138, 198, 1640, 479, 16, 287, 8251, 7, 27530, 8, 198, 220, 220, 220, 329, 479, 17, 287, 8251, 7, 27530, 58, 74, 16, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 329, 357, 66, 11, 83, 8, 287, 27056, 378, 7, 83, 62, 35138, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4981, 58, 74, 16, 7131, 74, 17, 7131, 1, 1073, 14822, 82, 62, 76, 6320, 8973, 796, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8444, 1186, 1417, 37, 2290, 312, 15681, 947, 13557, 18908, 4873, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4981, 58, 74, 16, 7131, 74, 17, 7131, 1, 1073, 14822, 82, 62, 76, 6320, 33116, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4981, 58, 74, 16, 7131, 74, 17, 7131, 1, 33, 33116, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 520, 540, 49, 42, 19, 7, 71, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2124, 3784, 12218, 1417, 44, 2937, 5097, 13, 12543, 7, 87, 11, 12218, 1417, 44, 2937, 5097, 13, 8612, 378, 62, 37266, 7, 27530, 58, 74, 16, 7131, 74, 17, 7131, 1, 49506, 8973, 26513, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9008, 62, 22355, 62, 66, 7568, 58, 66, 11, 17, 25, 18, 60, 796, 4981, 58, 74, 16, 7131, 74, 17, 7131, 1, 1073, 14822, 82, 62, 76, 6320, 1, 7131, 58, 16, 26, 437, 11907, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 44189, 13, 13564, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 400, 9, 1, 14, 2875, 62, 1, 9, 8841, 7, 74, 16, 27493, 1, 62, 19849, 62, 1, 9, 8841, 7, 74, 17, 27493, 1911, 40664, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 19778, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 28, 48320, 62, 22355, 62, 66, 7568, 58, 45299, 16, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 7108, 62, 17, 28, 48320, 62, 22355, 62, 66, 7568, 58, 45299, 17, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 7108, 62, 16, 28, 48320, 62, 22355, 62, 66, 7568, 58, 45299, 18, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 886, 198, 437, 628 ]
1.88955
1,177
<reponame>eviatarbach/ensemble_oscillation_correction using Serialization using Random Random.seed!(1234) include("models.jl") include("integrators.jl") include("enoc.jl") using .Models using .Integrators using .enoc M = 60 D = 3 k = 40 k_r = 30 window = 20 da = false inflation = 1.0 osc_vars = 1:D modes = 3:4 model = Models.chua_true model_err = Models.chua_err integrator = Integrators.rk4 outfreq = 1 Δt = 0.1 m = 20 cycles = 1000 record_length = 25000 ens_err_pct = 0.2 obs_err_pct = 0.1 transient = 3000 mp = 5 y0 = [-1.06095, 0.160678, 0.267729] varimax = true check_bounds = true test_time = 10.0 y_fcst = true α = 0.5 if !da info, ssa_info = enoc.run(model=model, model_err=model_err, M=M, D=D, k=k, k_r=k_r, modes=modes, osc_vars=osc_vars, integrator=integrator, outfreq=outfreq, Δt=Δt, m=m, cycles=1000, window=window, record_length=record_length, ens_err_pct=ens_err_pct, obs_err_pct=obs_err_pct, transient=transient, y0=y0, mp=mp, varimax=varimax, da=false, inflation=inflation, check_bounds=check_bounds, y_fcst=y_fcst, α=α, preload="chua") mp = argmin(enoc.optimal_ens(info)[1])[1] end Random.seed!(1234) info, ssa_info = enoc.run(model=model, model_err=model_err, M=M, D=D, k=k, k_r=k_r, modes=modes, osc_vars=osc_vars, integrator=integrator, outfreq=outfreq, Δt=Δt, m=m, cycles=cycles, window=window, record_length=record_length, ens_err_pct=ens_err_pct, obs_err_pct=obs_err_pct, transient=transient, y0=y0, mp=mp, varimax=varimax, da=da, inflation=inflation, check_bounds=check_bounds, y_fcst=y_fcst, α=α, preload="chua") serialize(open(string("out_chua_", ARGS[1]), "w"), info)
[ 27, 7856, 261, 480, 29, 1990, 5375, 283, 19496, 14, 1072, 11306, 62, 17500, 40903, 62, 10215, 8243, 198, 3500, 23283, 1634, 198, 3500, 14534, 198, 198, 29531, 13, 28826, 0, 7, 1065, 2682, 8, 198, 198, 17256, 7203, 27530, 13, 20362, 4943, 198, 17256, 7203, 18908, 18942, 13, 20362, 4943, 198, 17256, 7203, 268, 420, 13, 20362, 4943, 198, 3500, 764, 5841, 1424, 198, 3500, 764, 34500, 18942, 198, 3500, 764, 268, 420, 198, 198, 44, 796, 3126, 198, 35, 796, 513, 198, 74, 796, 2319, 198, 74, 62, 81, 796, 1542, 198, 198, 17497, 796, 1160, 198, 6814, 796, 3991, 198, 259, 33521, 796, 352, 13, 15, 198, 198, 17500, 62, 85, 945, 796, 352, 25, 35, 198, 76, 4147, 796, 513, 25, 19, 198, 19849, 796, 32329, 13, 354, 6413, 62, 7942, 198, 19849, 62, 8056, 796, 32329, 13, 354, 6413, 62, 8056, 198, 18908, 12392, 796, 15995, 18942, 13, 81, 74, 19, 198, 448, 19503, 80, 796, 352, 198, 138, 242, 83, 796, 657, 13, 16, 198, 76, 796, 1160, 198, 32503, 796, 8576, 198, 22105, 62, 13664, 796, 1679, 830, 198, 641, 62, 8056, 62, 79, 310, 796, 657, 13, 17, 198, 8158, 62, 8056, 62, 79, 310, 796, 657, 13, 16, 198, 7645, 1153, 796, 20343, 198, 3149, 796, 642, 198, 88, 15, 796, 25915, 16, 13, 41322, 3865, 11, 657, 13, 14198, 30924, 11, 657, 13, 2075, 3324, 1959, 60, 198, 7785, 320, 897, 796, 2081, 198, 9122, 62, 65, 3733, 796, 2081, 198, 9288, 62, 2435, 796, 838, 13, 15, 198, 88, 62, 16072, 301, 796, 2081, 198, 17394, 796, 657, 13, 20, 198, 198, 361, 5145, 6814, 198, 220, 220, 220, 7508, 11, 264, 11400, 62, 10951, 796, 551, 420, 13, 5143, 7, 19849, 28, 19849, 11, 2746, 62, 8056, 28, 19849, 62, 8056, 11, 337, 28, 44, 11, 360, 28, 35, 11, 479, 28, 74, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 62, 81, 28, 74, 62, 81, 11, 12881, 28, 76, 4147, 11, 267, 1416, 62, 85, 945, 28, 17500, 62, 85, 945, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4132, 12392, 28, 18908, 12392, 11, 503, 19503, 80, 28, 448, 19503, 80, 11, 37455, 83, 28, 138, 242, 83, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 285, 28, 76, 11, 16006, 28, 12825, 11, 4324, 28, 17497, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1700, 62, 13664, 28, 22105, 62, 13664, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3140, 62, 8056, 62, 79, 310, 28, 641, 62, 8056, 62, 79, 310, 11, 10201, 62, 8056, 62, 79, 310, 28, 8158, 62, 8056, 62, 79, 310, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 32361, 28, 7645, 1153, 11, 331, 15, 28, 88, 15, 11, 29034, 28, 3149, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1401, 320, 897, 28, 7785, 320, 897, 11, 12379, 28, 9562, 11, 10610, 28, 259, 33521, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2198, 62, 65, 3733, 28, 9122, 62, 65, 3733, 11, 331, 62, 16072, 301, 28, 88, 62, 16072, 301, 11, 26367, 28, 17394, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 662, 2220, 2625, 354, 6413, 4943, 628, 220, 220, 220, 29034, 796, 1822, 1084, 7, 268, 420, 13, 8738, 4402, 62, 641, 7, 10951, 38381, 16, 12962, 58, 16, 60, 198, 437, 198, 198, 29531, 13, 28826, 0, 7, 1065, 2682, 8, 198, 198, 10951, 11, 264, 11400, 62, 10951, 796, 551, 420, 13, 5143, 7, 19849, 28, 19849, 11, 2746, 62, 8056, 28, 19849, 62, 8056, 11, 337, 28, 44, 11, 360, 28, 35, 11, 479, 28, 74, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 62, 81, 28, 74, 62, 81, 11, 12881, 28, 76, 4147, 11, 267, 1416, 62, 85, 945, 28, 17500, 62, 85, 945, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4132, 12392, 28, 18908, 12392, 11, 503, 19503, 80, 28, 448, 19503, 80, 11, 37455, 83, 28, 138, 242, 83, 11, 285, 28, 76, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16006, 28, 32503, 11, 4324, 28, 17497, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1700, 62, 13664, 28, 22105, 62, 13664, 11, 3140, 62, 8056, 62, 79, 310, 28, 641, 62, 8056, 62, 79, 310, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10201, 62, 8056, 62, 79, 310, 28, 8158, 62, 8056, 62, 79, 310, 11, 32361, 28, 7645, 1153, 11, 331, 15, 28, 88, 15, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29034, 28, 3149, 11, 1401, 320, 897, 28, 7785, 320, 897, 11, 12379, 28, 6814, 11, 10610, 28, 259, 33521, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2198, 62, 65, 3733, 28, 9122, 62, 65, 3733, 11, 331, 62, 16072, 301, 28, 88, 62, 16072, 301, 11, 26367, 28, 17394, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 662, 2220, 2625, 354, 6413, 4943, 198, 198, 46911, 1096, 7, 9654, 7, 8841, 7203, 448, 62, 354, 6413, 62, 1600, 5923, 14313, 58, 16, 46570, 366, 86, 12340, 7508, 8, 198 ]
1.739203
1,204
<filename>examples/lru_test.jl # This file is a part of Julia. License is MIT: https://julialang.org/license using .LRUExample TestLRU = LRUExample.UnboundedLRU{String, String}() TestBLRU = LRUExample.BoundedLRU{String, String}(1000) get_str(i) = String(vcat(map(x->[x>>4; x&0x0F], reinterpret(UInt8, [Int32(i)]))...)) isbounded{L<:LRUExample.LRU}(::Type{L}) = any(map(n->n==:maxsize, fieldnames(L))) isbounded{L<:LRUExample.LRU}(l::L) = isbounded(L) nmax = round.(Int, logspace(2, 5, 4)) function lrutest() #println("LRU consistency tests") for lru in (TestLRU,TestBLRU) for n in nmax empty!(lru) #@printf(" %s, %d items\n", lru, n) #print(" Simple eviction: ") for i in 1:n str = get_str(i) lru[str] = str @assert lru.q[1].v == str if isbounded(lru) && length(lru) >= lru.maxsize tailstr = get_str(i-lru.maxsize+1) @assert lru.q[end].v == tailstr end end #println("pass") #print(" Lookup, random access: ") for i in 1:n str = get_str(rand(1:n)) if haskey(lru, str) # the bounded LRUs can have cache misses blah = lru[str] @assert lru.q[1].v == blah end end #println("pass") end empty!(lru) end end lrutest()
[ 27, 34345, 29, 1069, 12629, 14, 75, 622, 62, 9288, 13, 20362, 198, 2, 770, 2393, 318, 257, 636, 286, 22300, 13, 13789, 318, 17168, 25, 3740, 1378, 73, 377, 498, 648, 13, 2398, 14, 43085, 198, 198, 3500, 764, 35972, 52, 16281, 198, 198, 14402, 35972, 52, 796, 37491, 52, 16281, 13, 3118, 65, 6302, 35972, 52, 90, 10100, 11, 10903, 92, 3419, 198, 14402, 9148, 49, 52, 796, 37491, 52, 16281, 13, 33, 6302, 35972, 52, 90, 10100, 11, 10903, 92, 7, 12825, 8, 198, 198, 1136, 62, 2536, 7, 72, 8, 796, 10903, 7, 85, 9246, 7, 8899, 7, 87, 3784, 58, 87, 4211, 19, 26, 2124, 5, 15, 87, 15, 37, 4357, 302, 27381, 7, 52, 5317, 23, 11, 685, 5317, 2624, 7, 72, 15437, 4008, 986, 4008, 198, 198, 271, 65, 6302, 90, 43, 27, 25, 35972, 52, 16281, 13, 35972, 52, 92, 7, 3712, 6030, 90, 43, 30072, 796, 597, 7, 8899, 7, 77, 3784, 77, 855, 25, 9806, 7857, 11, 2214, 14933, 7, 43, 22305, 198, 271, 65, 6302, 90, 43, 27, 25, 35972, 52, 16281, 13, 35972, 52, 92, 7, 75, 3712, 43, 8, 796, 318, 65, 6302, 7, 43, 8, 198, 198, 77, 9806, 796, 2835, 12195, 5317, 11, 2604, 13200, 7, 17, 11, 642, 11, 604, 4008, 198, 198, 8818, 300, 81, 315, 395, 3419, 198, 220, 220, 220, 1303, 35235, 7203, 35972, 52, 15794, 5254, 4943, 198, 220, 220, 220, 329, 300, 622, 287, 357, 14402, 35972, 52, 11, 14402, 9148, 49, 52, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 299, 287, 299, 9806, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6565, 0, 7, 75, 622, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 31, 37435, 7203, 220, 4064, 82, 11, 4064, 67, 3709, 59, 77, 1600, 300, 622, 11, 299, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 4798, 7203, 220, 220, 220, 17427, 38738, 25, 366, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 965, 796, 651, 62, 2536, 7, 72, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 300, 622, 58, 2536, 60, 796, 965, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 30493, 300, 622, 13, 80, 58, 16, 4083, 85, 6624, 965, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 318, 65, 6302, 7, 75, 622, 8, 11405, 4129, 7, 75, 622, 8, 18189, 300, 622, 13, 9806, 7857, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 7894, 2536, 796, 651, 62, 2536, 7, 72, 12, 75, 622, 13, 9806, 7857, 10, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 30493, 300, 622, 13, 80, 58, 437, 4083, 85, 6624, 7894, 2536, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 35235, 7203, 6603, 4943, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 4798, 7203, 220, 220, 220, 6803, 929, 11, 4738, 1895, 25, 366, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 965, 796, 651, 62, 2536, 7, 25192, 7, 16, 25, 77, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 468, 2539, 7, 75, 622, 11, 965, 8, 1303, 262, 49948, 37491, 5842, 460, 423, 12940, 18297, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33367, 796, 300, 622, 58, 2536, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 30493, 300, 622, 13, 80, 58, 16, 4083, 85, 6624, 33367, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 35235, 7203, 6603, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 6565, 0, 7, 75, 622, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 14050, 315, 395, 3419, 198 ]
1.783234
835
""" ANLI For details, see the [GitHub page](https://github.com/facebookresearch/anli) or read the [2019 paper](https://arxiv.org/pdf/1910.14599.pdf). Available data: ```julia ANLI.R1_train_jsonl() ANLI.R1_dev_jsonl() ANLI.R1_test_jsonl() ANLI.R2_train_jsonl() ANLI.R2_dev_jsonl() ANLI.R2_test_jsonl() ANLI.R3_train_jsonl() ANLI.R3_dev_jsonl() ANLI.R3_test_jsonl() ``` """ module ANLI import ...register_data using DataDeps: @datadep_str, unpack anli_file(file, files...) = joinpath(datadep"ANLI", "anli_v0.1", file, files...) R1_train_jsonl() = anli_file("R1", "train.jsonl") R1_dev_jsonl() = anli_file("R1", "dev.jsonl") R1_test_jsonl() = anli_file("R1", "test.jsonl") R2_train_jsonl() = anli_file("R2", "train.jsonl") R2_dev_jsonl() = anli_file("R2", "dev.jsonl") R2_test_jsonl() = anli_file("R2", "test.jsonl") R3_train_jsonl() = anli_file("R3", "train.jsonl") R3_dev_jsonl() = anli_file("R3", "dev.jsonl") R3_test_jsonl() = anli_file("R3", "test.jsonl") function __init__() register_data( "ANLI", """ ANLI is the Adversarial Natural Language Inference Benchmark. ANLI is licensed under Creative Commons-Non Commercial 4.0. """, "https://dl.fbaipublicfiles.com/anli/anli_v0.1.zip", "16ac929a7e90ecf9093deaec89cc81fe86a379265a5320a150028efe50c5cde8", postfetch=unpack ) end end # module
[ 37811, 198, 220, 220, 220, 3537, 31271, 198, 198, 1890, 3307, 11, 766, 262, 685, 38, 270, 16066, 2443, 16151, 5450, 1378, 12567, 13, 785, 14, 19024, 34033, 14, 272, 4528, 8, 393, 1100, 262, 685, 23344, 3348, 16151, 5450, 1378, 283, 87, 452, 13, 2398, 14, 12315, 14, 1129, 940, 13, 18781, 2079, 13, 12315, 737, 198, 198, 10493, 1366, 25, 198, 15506, 63, 73, 43640, 198, 1565, 31271, 13, 49, 16, 62, 27432, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 16, 62, 7959, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 16, 62, 9288, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 17, 62, 27432, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 17, 62, 7959, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 17, 62, 9288, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 18, 62, 27432, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 18, 62, 7959, 62, 17752, 75, 3419, 198, 1565, 31271, 13, 49, 18, 62, 9288, 62, 17752, 75, 3419, 198, 15506, 63, 198, 37811, 198, 21412, 3537, 31271, 198, 198, 11748, 2644, 30238, 62, 7890, 198, 3500, 6060, 12156, 82, 25, 2488, 19608, 324, 538, 62, 2536, 11, 555, 8002, 198, 198, 272, 4528, 62, 7753, 7, 7753, 11, 3696, 23029, 796, 4654, 6978, 7, 19608, 324, 538, 1, 1565, 31271, 1600, 366, 272, 4528, 62, 85, 15, 13, 16, 1600, 2393, 11, 3696, 23029, 198, 198, 49, 16, 62, 27432, 62, 17752, 75, 3419, 796, 281, 4528, 62, 7753, 7203, 49, 16, 1600, 366, 27432, 13, 17752, 75, 4943, 198, 49, 16, 62, 7959, 62, 17752, 75, 3419, 220, 220, 796, 281, 4528, 62, 7753, 7203, 49, 16, 1600, 366, 7959, 13, 17752, 75, 4943, 198, 49, 16, 62, 9288, 62, 17752, 75, 3419, 220, 796, 281, 4528, 62, 7753, 7203, 49, 16, 1600, 366, 9288, 13, 17752, 75, 4943, 198, 49, 17, 62, 27432, 62, 17752, 75, 3419, 796, 281, 4528, 62, 7753, 7203, 49, 17, 1600, 366, 27432, 13, 17752, 75, 4943, 198, 49, 17, 62, 7959, 62, 17752, 75, 3419, 220, 220, 796, 281, 4528, 62, 7753, 7203, 49, 17, 1600, 366, 7959, 13, 17752, 75, 4943, 198, 49, 17, 62, 9288, 62, 17752, 75, 3419, 220, 796, 281, 4528, 62, 7753, 7203, 49, 17, 1600, 366, 9288, 13, 17752, 75, 4943, 198, 49, 18, 62, 27432, 62, 17752, 75, 3419, 796, 281, 4528, 62, 7753, 7203, 49, 18, 1600, 366, 27432, 13, 17752, 75, 4943, 198, 49, 18, 62, 7959, 62, 17752, 75, 3419, 220, 220, 796, 281, 4528, 62, 7753, 7203, 49, 18, 1600, 366, 7959, 13, 17752, 75, 4943, 198, 49, 18, 62, 9288, 62, 17752, 75, 3419, 220, 796, 281, 4528, 62, 7753, 7203, 49, 18, 1600, 366, 9288, 13, 17752, 75, 4943, 198, 198, 8818, 11593, 15003, 834, 3419, 198, 220, 220, 220, 7881, 62, 7890, 7, 198, 220, 220, 220, 220, 220, 220, 220, 366, 1565, 31271, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 37227, 198, 220, 220, 220, 220, 220, 220, 220, 3537, 31271, 318, 262, 1215, 690, 36098, 12068, 15417, 554, 4288, 25187, 4102, 13, 628, 220, 220, 220, 220, 220, 220, 220, 3537, 31271, 318, 11971, 739, 17404, 13815, 12, 15419, 22724, 604, 13, 15, 13, 198, 220, 220, 220, 220, 220, 220, 220, 13538, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 366, 5450, 1378, 25404, 13, 69, 7012, 541, 841, 16624, 13, 785, 14, 272, 4528, 14, 272, 4528, 62, 85, 15, 13, 16, 13, 13344, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 366, 1433, 330, 24, 1959, 64, 22, 68, 3829, 721, 69, 44675, 18, 2934, 64, 721, 4531, 535, 6659, 5036, 4521, 64, 29088, 22980, 64, 4310, 1238, 64, 33698, 2078, 22521, 1120, 66, 20, 66, 2934, 23, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 1281, 69, 7569, 28, 403, 8002, 198, 220, 220, 220, 1267, 198, 437, 198, 198, 437, 1303, 8265, 198 ]
2.081325
664
<reponame>Moelf/Hands-on-Design-Patterns-and-Best-Practices-with-Julia<filename>Chapter02/union_types.jl # Union type example using Dates: Date # abstract types from previous section abstract type Asset end abstract type Property <: Asset end abstract type Investment <: Asset end abstract type Cash <: Asset end abstract type House <: Property end abstract type Apartment <: Property end abstract type FixedIncome <: Investment end abstract type Equity <: Investment end # concrete types struct Stock <: Equity symbol::String name::String end # new hierarchy abstract type Art end struct Painting <: Art artist::String title::String end # union type struct BasketOfThings things::Vector{Union{Painting,Stock}} reason::String end #= REPL julia> stock = Stock("AAPL", "Apple, Inc.",) Stock("AAPL", "Apple, Inc.") julia> monalisa = Painting("<NAME>", "Monalisa") Painting("<NAME>", "Monalisa") julia> things = Union{Painting,Stock}[stock, monalisa] 2-element Array{Union{Painting, Stock},1}: Stock("AAPL", "Apple, Inc.") Painting("<NAME>", "Monalisa") julia> present = BasketOfThings(things, "Anniversary gift for my wife") BasketOfThings(Union{Painting, Stock}[Stock("AAPL", "Apple, Inc."), Painting("<NAME>", "Monalisa")], "Anniversary gift for my wife") =# # easier to read :-) const Thing = Union{Painting,Stock} struct BasketOfThings thing::Vector{Thing} reason::String end
[ 27, 7856, 261, 480, 29, 16632, 7046, 14, 39, 1746, 12, 261, 12, 23067, 12, 47546, 82, 12, 392, 12, 13014, 12, 49515, 1063, 12, 4480, 12, 16980, 544, 27, 34345, 29, 14126, 2999, 14, 24592, 62, 19199, 13, 20362, 198, 2, 4479, 2099, 1672, 198, 198, 3500, 44712, 25, 7536, 198, 198, 2, 12531, 3858, 422, 2180, 2665, 198, 397, 8709, 2099, 31433, 886, 198, 198, 397, 8709, 2099, 14161, 1279, 25, 31433, 886, 198, 397, 8709, 2099, 20877, 1279, 25, 31433, 886, 198, 397, 8709, 2099, 16210, 1279, 25, 31433, 886, 198, 198, 397, 8709, 2099, 2097, 1279, 25, 14161, 886, 198, 397, 8709, 2099, 5949, 1823, 1279, 25, 14161, 886, 198, 198, 397, 8709, 2099, 10832, 818, 2958, 1279, 25, 20877, 886, 198, 397, 8709, 2099, 35659, 1279, 25, 20877, 886, 198, 198, 2, 10017, 3858, 198, 198, 7249, 10500, 1279, 25, 35659, 198, 220, 220, 220, 6194, 3712, 10100, 198, 220, 220, 220, 1438, 3712, 10100, 198, 437, 198, 198, 2, 649, 18911, 198, 198, 397, 8709, 2099, 3683, 886, 198, 198, 7249, 48892, 1279, 25, 3683, 198, 220, 220, 220, 6802, 3712, 10100, 198, 220, 220, 220, 3670, 3712, 10100, 198, 437, 198, 198, 2, 6441, 2099, 198, 198, 7249, 347, 11715, 5189, 22248, 198, 220, 220, 220, 1243, 3712, 38469, 90, 38176, 90, 38490, 889, 11, 26207, 11709, 198, 220, 220, 220, 1738, 3712, 10100, 198, 437, 198, 198, 2, 28, 45285, 198, 73, 43640, 29, 4283, 796, 10500, 7203, 32, 2969, 43, 1600, 366, 16108, 11, 3457, 33283, 8, 198, 26207, 7203, 32, 2969, 43, 1600, 366, 16108, 11, 3457, 19570, 198, 198, 73, 43640, 29, 937, 282, 9160, 796, 48892, 7203, 27, 20608, 29, 1600, 366, 9069, 282, 9160, 4943, 198, 38490, 889, 7203, 27, 20608, 29, 1600, 366, 9069, 282, 9160, 4943, 198, 198, 73, 43640, 29, 1243, 796, 4479, 90, 38490, 889, 11, 26207, 92, 58, 13578, 11, 937, 282, 9160, 60, 198, 17, 12, 30854, 15690, 90, 38176, 90, 38490, 889, 11, 10500, 5512, 16, 38362, 198, 10500, 7203, 32, 2969, 43, 1600, 366, 16108, 11, 3457, 19570, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 198, 48892, 7203, 27, 20608, 29, 1600, 366, 9069, 282, 9160, 4943, 198, 198, 73, 43640, 29, 1944, 796, 347, 11715, 5189, 22248, 7, 27971, 11, 366, 18858, 9023, 6979, 329, 616, 3656, 4943, 198, 33, 11715, 5189, 22248, 7, 38176, 90, 38490, 889, 11, 10500, 92, 58, 26207, 7203, 32, 2969, 43, 1600, 366, 16108, 11, 3457, 526, 828, 48892, 7203, 27, 20608, 29, 1600, 366, 9069, 282, 9160, 4943, 4357, 366, 18858, 9023, 6979, 329, 616, 3656, 4943, 198, 46249, 198, 198, 2, 4577, 284, 1100, 47226, 198, 198, 9979, 21561, 796, 4479, 90, 38490, 889, 11, 26207, 92, 198, 198, 7249, 347, 11715, 5189, 22248, 198, 220, 220, 220, 1517, 3712, 38469, 90, 51, 722, 92, 198, 220, 220, 220, 1738, 3712, 10100, 198, 437, 198 ]
2.9389
491
<gh_stars>100-1000 let λ = Partition([5,4,2,2]), μ = Partition([2,1]) @test λ \ μ == SkewDiagram(λ, μ) @test leglength(λ, μ) == leglength(λ \ μ) == 3 end @test leglength(Partition(Int[]), Partition(Int[])) == -1 @test isrimhook(Partition([4,3,2]), Partition([2,2,2])) @test !isrimhook(Partition([4,3,2]), Partition([2,2,1])) @test !isrimhook(Partition([4,3,2]), Partition([1,1])) let λ = Partition([5,4,2,1]), μ = Partition([4,3,2,2,1]) @test partitionsequence(λ) == [1, 0, 1, 0, 1, 1, 0, 1, 0] @test character(λ, μ) == 0 end let λ = μ = Partition([1]) @test leglength(λ, μ) == -1 @test character(λ, μ) == 1 end
[ 27, 456, 62, 30783, 29, 3064, 12, 12825, 198, 1616, 7377, 119, 796, 2142, 653, 26933, 20, 11, 19, 11, 17, 11, 17, 46570, 18919, 796, 2142, 653, 26933, 17, 11, 16, 12962, 198, 220, 220, 220, 2488, 9288, 7377, 119, 3467, 18919, 6624, 19460, 86, 18683, 6713, 7, 39377, 11, 18919, 8, 198, 220, 220, 220, 2488, 9288, 1232, 13664, 7, 39377, 11, 18919, 8, 6624, 1232, 13664, 7, 39377, 3467, 18919, 8, 6624, 513, 198, 437, 198, 31, 9288, 1232, 13664, 7, 7841, 653, 7, 5317, 21737, 828, 2142, 653, 7, 5317, 21737, 4008, 6624, 532, 16, 198, 198, 31, 9288, 318, 3036, 25480, 7, 7841, 653, 26933, 19, 11, 18, 11, 17, 46570, 2142, 653, 26933, 17, 11, 17, 11, 17, 60, 4008, 198, 31, 9288, 5145, 271, 3036, 25480, 7, 7841, 653, 26933, 19, 11, 18, 11, 17, 46570, 2142, 653, 26933, 17, 11, 17, 11, 16, 60, 4008, 198, 31, 9288, 5145, 271, 3036, 25480, 7, 7841, 653, 26933, 19, 11, 18, 11, 17, 46570, 2142, 653, 26933, 16, 11, 16, 60, 4008, 198, 198, 1616, 7377, 119, 796, 2142, 653, 26933, 20, 11, 19, 11, 17, 11, 16, 46570, 18919, 796, 2142, 653, 26933, 19, 11, 18, 11, 17, 11, 17, 11, 16, 12962, 198, 220, 220, 220, 2488, 9288, 18398, 43167, 7, 39377, 8, 6624, 685, 16, 11, 657, 11, 352, 11, 657, 11, 352, 11, 352, 11, 657, 11, 352, 11, 657, 60, 198, 220, 220, 220, 2488, 9288, 2095, 7, 39377, 11, 18919, 8, 6624, 657, 198, 437, 198, 198, 1616, 7377, 119, 796, 18919, 796, 2142, 653, 26933, 16, 12962, 198, 220, 220, 220, 2488, 9288, 1232, 13664, 7, 39377, 11, 18919, 8, 6624, 532, 16, 198, 220, 220, 220, 2488, 9288, 2095, 7, 39377, 11, 18919, 8, 6624, 352, 198, 437, 198 ]
2.108911
303
import PipeLayout: sorted_edges, min_spanning_tree, topology_from_mst, digraph_from_topology using PipeLayout using LightGraphs @testset "compute MST from nodes" begin coords = [0 1 0; 0 0 2] nodes = Node[Node(coords[:,j]...) for j in 1:size(coords, 2)] n = length(nodes) @test n == 3 @testset "test sorted edges" begin edges = sorted_edges(nodes) m = n*(n-1)/2 @test m == 3 @test size(edges, 1) == 2 @test size(edges, 2) == m @test edges[:, 1] == Node[nodes[1], nodes[2]] @test edges[:, 2] == Node[nodes[1], nodes[3]] @test edges[:, 3] == Node[nodes[2], nodes[3]] end @testset "look at resulting MST" begin n = length(nodes) m = n - 1 # tree tree = nodes |> topology_from_mst |> digraph_from_topology @test isa(tree, DiGraph) @test is_directed(tree) @test nv(tree) == n @test ne(tree) == m @test is_weakly_connected(tree) @test has_edge(tree, 1, 2) @test has_edge(tree, 1, 3) end end
[ 11748, 36039, 32517, 25, 23243, 62, 276, 3212, 11, 949, 62, 12626, 768, 62, 21048, 11, 1353, 1435, 62, 6738, 62, 76, 301, 11, 3100, 1470, 62, 6738, 62, 4852, 1435, 198, 3500, 36039, 32517, 198, 3500, 4401, 37065, 82, 198, 198, 31, 9288, 2617, 366, 5589, 1133, 337, 2257, 422, 13760, 1, 2221, 198, 220, 220, 220, 763, 3669, 796, 685, 15, 352, 657, 26, 657, 657, 362, 60, 198, 220, 220, 220, 13760, 796, 19081, 58, 19667, 7, 1073, 3669, 58, 45299, 73, 60, 23029, 329, 474, 287, 352, 25, 7857, 7, 1073, 3669, 11, 362, 15437, 198, 220, 220, 220, 299, 796, 4129, 7, 77, 4147, 8, 198, 220, 220, 220, 2488, 9288, 299, 6624, 513, 628, 220, 220, 220, 2488, 9288, 2617, 366, 9288, 23243, 13015, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 13015, 796, 23243, 62, 276, 3212, 7, 77, 4147, 8, 198, 220, 220, 220, 220, 220, 220, 220, 285, 796, 299, 9, 7, 77, 12, 16, 20679, 17, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 285, 6624, 513, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2546, 7, 276, 3212, 11, 352, 8, 6624, 362, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2546, 7, 276, 3212, 11, 362, 8, 6624, 285, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 13015, 58, 45299, 352, 60, 6624, 19081, 58, 77, 4147, 58, 16, 4357, 13760, 58, 17, 11907, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 13015, 58, 45299, 362, 60, 6624, 19081, 58, 77, 4147, 58, 16, 4357, 13760, 58, 18, 11907, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 13015, 58, 45299, 513, 60, 6624, 19081, 58, 77, 4147, 58, 17, 4357, 13760, 58, 18, 11907, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 5460, 379, 7186, 337, 2257, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 299, 796, 4129, 7, 77, 4147, 8, 198, 220, 220, 220, 220, 220, 220, 220, 285, 796, 299, 532, 352, 1303, 5509, 628, 220, 220, 220, 220, 220, 220, 220, 5509, 796, 13760, 930, 29, 1353, 1435, 62, 6738, 62, 76, 301, 930, 29, 3100, 1470, 62, 6738, 62, 4852, 1435, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 64, 7, 21048, 11, 6031, 37065, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 62, 34762, 7, 21048, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 299, 85, 7, 21048, 8, 6624, 299, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 497, 7, 21048, 8, 6624, 285, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 62, 38695, 306, 62, 15236, 7, 21048, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 62, 14907, 7, 21048, 11, 352, 11, 362, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 62, 14907, 7, 21048, 11, 352, 11, 513, 8, 198, 220, 220, 220, 886, 198, 437, 198 ]
2.076023
513
<gh_stars>0 # included from Potentials.jl # part of the module JuLIP.Potentials using JuLIP: JVec, JMat, neighbourlist using LinearAlgebra: I using JuLIP.Chemistry: atomic_number using NeighbourLists export ZeroPairPotential, PairSitePotential, ZBLPotential, LennardJones, lennardjones, Morse, morse ## TODO: kill this one? grad(V::PairPotential, r::Real, R::JVec) = ((@D V(r)) / r) * R evaluate!(tmp, V::PairPotential, r::Union{Number, JVec}) = V(r) evaluate_d!(tmp, V::PairPotential, r::Union{Number, JVec}) = @D V(r) evaluate_dd!(tmp, V::PairPotential, r::Union{Number, JVec}) = @DD V(r) function evaluate!(tmp, V::PairPotential, R::AbstractVector{JVec{T}}) where {T} Es = zero(T) for i = 1:length(R) Es += T(0.5) * evaluate!(tmp, V, norm(R[i])) end return Es end function evaluate_d!(dEs, tmp, V::PairPotential, R::AbstractVector{JVec{T}}) where {T} for i = 1:length(R) r = norm(R[i]) dEs[i] = (T(0.5) * evaluate_d!(tmp, V, r) / r) * R[i] end return dEs end function evaluate_dd!(hEs, tmp, V::PairPotential, R::AbstractVector{<: JVec}) n = length(R) for i = 1:n hEs[i,i] = 0.5 * _hess!(tmp, V, norm(R[i]), R[i]) end return hEs end function _hess!(tmp, V::PairPotential, r::Number, R::JVec) R̂ = R/r P = R̂ * R̂' dV = evaluate_d!(tmp, V, r) / r ddV = evaluate_dd!(tmp, V, r) return (ddV - dV) * P + dV * I end function precon!(hEs, tmp, V::PairPotential, R::AbstractVector{<: JVec}, innerstab=T(0.0)) n = length(R) for i = 1:n hEs[i,i] = precon!(tmp, V, norm(R[i]), R[i], innerstab) end return hEs end # an FF preconditioner for pair potentials function precon!(tmp, V::PairPotential, r::T, R::JVec{T}, innerstab=T(0.1) ) where {T <: Number} r = norm(R) dV = evaluate_d!(tmp, V, r) ddV = evaluate_dd!(tmp, V, r) R̂ = R/r return (1-innerstab) * (abs(ddV) * R̂ * R̂' + abs(dV / r) * (I - R̂ * R̂')) + innerstab * (abs(ddV) + abs(dV / r)) * I end """ `LennardJones(σ, e0):` constructs the 6-12 Lennard-Jones potential [wiki](https://en.wikipedia.org/wiki/Lennard-Jones_potential) e0 * 4 * ( (σ/r)¹² - (σ/r)⁶ ) Constructor with kw arguments: `LennardJones(; kwargs...)` * `e0, σ` : standard LJ parameters, default `e0 = 1.0, σ = 1.0` * `r0` : equilibrium distance - if `r0` is specified then `σ` is ignored * `a0` : FCC lattice parameter, if `a0` is specified then `σ` is ignored (`r0, a0` cannot both be specified at the same time) """ LennardJones(σ, e0) = (@analytic r -> e0 * 4.0 * ((σ/r)^(12) - (σ/r)^(6))) function ljparams(; σ=1.0, e0=1.0, r0 = nothing, a0 = nothing) if r0 != nothing && a0 != nothing error("`LenndardJones`: cannot specify both `r0` and `a0`") end if a0 != nothing # r0 = nn-dist = a0/sqrt(2) in FCC r0 = a0 / sqrt(2) end if r0 != nothing # standard LJ is minimised at r = 2^(1/6) σ = r0 / 2^(1/6) end return σ, e0 end LennardJones(; kwargs...) = LennardJones(ljparams(;kwargs...)...) """ `lennardjones(; kwargs...)` simplified constructor for `LennardJones` (note this is type unstable!) In addition to the `kwargs` of `LennardJones`, this accepts also * `rcut` : default `:auto` which gives `rcut = (1.9*σ, 2.7*σ)`. Use `nothing` or `Inf` to specify no cutoff, or specify a tuple or array with two elements specifying the lower and upper cut-off radii to be used with `SplineCutoff`. """ function lennardjones(; rcut = :auto, kwargs...) σ, e0 = ljparams(; kwargs...) if (rcut == nothing || rcut == Inf) return LennardJones(σ, e0) elseif rcut == :auto rcut = (1.9*σ, 2.7*σ) end return SplineCutoff(rcut[1], rcut[2]) * LennardJones(σ, e0) end """ `Morse(A, e0, r0)` or `Morse(;A=4.0, e0=1.0, r0=1.0)`: constructs a `PairPotential` for ``` e0 ( exp( -2 A (r/r0 - 1) ) - 2 exp( - A (r/r0 - 1) ) ) ``` """ Morse(A, e0, r0) = @analytic( r -> e0 * ( exp(-(2.0*A) * (r/r0 - 1.0)) - 2.0 * exp(-A * (r/r0 - 1.0)) ) ) Morse(;A=4.0, e0=1.0, r0=1.0) = Morse(A, e0, r0) """ `morse(A=4.0, e0=1.0, r0=1.0, rcut=(1.9*r0, 2.7*r0))` simplified constructor for `Morse` (type unstable) """ morse(;A=4.0, e0=1.0, r0=1.0, rcut=(1.9*r0, 2.7*r0)) = ( (rcut == nothing || rcut == Inf) ? Morse(A, e0, r0) : SplineCutoff(rcut[1], rcut[2]) * Morse(A, e0, r0) ) """ `ZeroPairPotential()`: creates a potential that just returns zero """ struct ZeroPairPotential <: PairPotential end @pot ZeroPairPotential evaluate(p::ZeroPairPotential, r::T) where {T <: Number} = T(0.0) evaluate_d(p::ZeroPairPotential, r::T) where {T <: Number} = T(0.0) evaluate_dd(p::ZeroPairPotential, r::T) where {T <: Number} = T(0.0) cutoff(p::ZeroPairPotential) = Bool(0) # the weakest number type # ------------------------------------------------------------------------ # TODO: write more docs + tests for ZBL """ Implementation of the ZBL potential to model close approach. """ struct ZBLPotential{TV} <: PairPotential Z1::Int Z2::Int V::TV # analytic end @pot ZBLPotential evaluate(V::ZBLPotential, r::Number) = evaluate(V.V, r::Number) evaluate_d(V::ZBLPotential, r::Number) = evaluate_d(V.V, r::Number) cutoff(::ZBLPotential) = Inf ZBLPotential(Z1::Integer, Z2::Integer) = let Z1=Z1, Z2=Z2 au = 0.8854 * 0.529 / (Z1^0.23 + Z2^0.23) ϵ0 = 0.00552634940621 C = Z1*Z2/(4*π*ϵ0) E1, E2, E3, E4 = 0.1818, 0.5099, 0.2802, 0.02817 A1, A2, A3, A4 = 3.2/au, 0.9423/au, 0.4028/au, 0.2016/au V = @analytic(r -> C * (E1*exp(-A1*r) + E2*exp(-A2*r) + E3*exp(-A4*r) + E4*exp(-A4*r) ) / r) ZBLPotential(Z1, Z2, V) end ZBLPotential(Z::Integer) = ZBLPotential(Z, Z) ZBLPotential(s1::Symbol, s2::Symbol) = ZBLPotential(atomic_number(s1), atomic_number(s2)) ZBLPotential(s::Symbol) = ZBLPotential(s, s) Dict(V::ZBLPotential) = Dict("__id__" => "JuLIP_ZBLPotential", "Z1" => V.Z1, "Z2" => Z.Z2) ZBLPotential(D::Dict) = ZBLPotential(D["Z1"], D["Z2"]) Base.convert(::Val{:JuLIP_ZBLPotential}, D::Dict) = ZBLPotential(D) # ==================================================================== # A product of two pair potentials: primarily used for cutoff mechanisms "product of two pair potentials" mutable struct ProdPot{P1, P2} <: PairPotential p1::P1 p2::P2 end @pot ProdPot import Base.* *(p1::PairPotential, p2::PairPotential) = ProdPot(p1, p2) @inline evaluate(p::ProdPot, r::Number) = p.p1(r) * p.p2(r) evaluate_d(p::ProdPot, r::Number) = (p.p1(r) * (@D p.p2(r)) + (@D p.p1(r)) * p.p2(r)) evaluate_dd(p::ProdPot, r::Number) = (p.p1(r) * (@DD p.p2(r)) + 2 * (@D p.p1(r)) * (@D p.p2(r)) + (@DD p.p1(r)) * p.p2(r)) cutoff(p::ProdPot) = min(cutoff(p.p1), cutoff(p.p2)) # ==================================================================== """ `struct WrappedPairPotential` wraps a pairpotential using `FunctionWrappers` in order to allow type-stable storage of multiple potentials. This is the main technique required at the moment to work with multi-component systems. Otherwise, this is not advisable since it disables a range of possible compiler optimisations. """ struct WrappedPairPotential <: SimplePairPotential f::F64fun f_d::F64fun f_dd::F64fun rcut::Float64 end @pot WrappedPairPotential cutoff(V::WrappedPairPotential) = V.rcut # evaluate, etc are all derived from SimplePairPotential function WrappedPairPotential(V::AnalyticFunction, rcut) @assert (0 < rcut < Inf) f, f_d, f_dd = let V=V, rc = rcut (F64fun(r -> evaluate(V, r) * (r<rc)), F64fun(r -> evaluate_d(V, r) * (r<rc)), F64fun(r -> evaluate_dd(V, r) * (r<rc))) end return WrappedPairPotential(f, f_d, f_dd, cutoff(V)) end function WrappedPairPotential(V::PairPotential) @assert (0 < cutoff(V) < Inf) f, f_d, f_dd = let V=V, rc = cutoff(V) (F64fun(r -> evaluate(V, r) * (r<rc)), F64fun(r -> evaluate_d(V, r) * (r<rc)), F64fun(r -> evaluate_dd(V, r) * (r<rc))) end return WrappedPairPotential(f, f_d, f_dd, cutoff(V)) end
[ 27, 456, 62, 30783, 29, 15, 198, 2, 3017, 422, 6902, 14817, 13, 20362, 198, 2, 636, 286, 262, 8265, 12585, 43, 4061, 13, 25396, 14817, 198, 198, 3500, 12585, 43, 4061, 25, 449, 53, 721, 11, 449, 19044, 11, 12250, 4868, 198, 3500, 44800, 2348, 29230, 25, 314, 198, 3500, 12585, 43, 4061, 13, 41829, 4592, 25, 17226, 62, 17618, 198, 3500, 22505, 6084, 43, 1023, 198, 198, 39344, 12169, 47, 958, 25396, 1843, 11, 39645, 29123, 25396, 1843, 11, 1168, 9148, 25396, 1843, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 28423, 446, 25784, 11, 300, 1697, 446, 73, 1952, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 44049, 11, 2146, 325, 198, 198, 2235, 16926, 46, 25, 1494, 428, 530, 30, 198, 9744, 7, 53, 3712, 47, 958, 25396, 1843, 11, 374, 3712, 15633, 11, 371, 3712, 41697, 721, 8, 796, 14808, 31, 35, 569, 7, 81, 4008, 1220, 374, 8, 1635, 371, 628, 198, 49786, 0, 7, 22065, 11, 569, 3712, 47, 958, 25396, 1843, 11, 374, 3712, 38176, 90, 15057, 11, 449, 53, 721, 30072, 796, 569, 7, 81, 8, 198, 49786, 62, 67, 0, 7, 22065, 11, 569, 3712, 47, 958, 25396, 1843, 11, 374, 3712, 38176, 90, 15057, 11, 449, 53, 721, 30072, 796, 2488, 35, 569, 7, 81, 8, 198, 49786, 62, 1860, 0, 7, 22065, 11, 569, 3712, 47, 958, 25396, 1843, 11, 374, 3712, 38176, 90, 15057, 11, 449, 53, 721, 30072, 796, 2488, 16458, 569, 7, 81, 8, 198, 198, 8818, 13446, 0, 7, 22065, 11, 569, 3712, 47, 958, 25396, 1843, 11, 371, 3712, 23839, 38469, 90, 41697, 721, 90, 51, 11709, 8, 810, 1391, 51, 92, 198, 220, 220, 8678, 796, 6632, 7, 51, 8, 198, 220, 220, 329, 1312, 796, 352, 25, 13664, 7, 49, 8, 198, 220, 220, 220, 220, 220, 8678, 15853, 309, 7, 15, 13, 20, 8, 1635, 13446, 0, 7, 22065, 11, 569, 11, 2593, 7, 49, 58, 72, 60, 4008, 198, 220, 220, 886, 198, 220, 220, 1441, 8678, 198, 437, 198, 198, 8818, 13446, 62, 67, 0, 7, 67, 23041, 11, 45218, 11, 569, 3712, 47, 958, 25396, 1843, 11, 371, 3712, 23839, 38469, 90, 41697, 721, 90, 51, 11709, 8, 810, 1391, 51, 92, 198, 220, 220, 329, 1312, 796, 352, 25, 13664, 7, 49, 8, 198, 220, 220, 220, 220, 220, 374, 796, 2593, 7, 49, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 288, 23041, 58, 72, 60, 796, 357, 51, 7, 15, 13, 20, 8, 1635, 13446, 62, 67, 0, 7, 22065, 11, 569, 11, 374, 8, 1220, 374, 8, 1635, 371, 58, 72, 60, 198, 220, 220, 886, 198, 220, 220, 1441, 288, 23041, 198, 437, 198, 198, 8818, 13446, 62, 1860, 0, 7, 71, 23041, 11, 45218, 11, 569, 3712, 47, 958, 25396, 1843, 11, 371, 3712, 23839, 38469, 90, 27, 25, 449, 53, 721, 30072, 198, 220, 220, 299, 796, 4129, 7, 49, 8, 198, 220, 220, 329, 1312, 796, 352, 25, 77, 198, 220, 220, 220, 220, 220, 289, 23041, 58, 72, 11, 72, 60, 796, 657, 13, 20, 1635, 4808, 33979, 0, 7, 22065, 11, 569, 11, 2593, 7, 49, 58, 72, 46570, 371, 58, 72, 12962, 198, 220, 220, 886, 198, 220, 220, 1441, 289, 23041, 198, 437, 198, 198, 8818, 4808, 33979, 0, 7, 22065, 11, 569, 3712, 47, 958, 25396, 1843, 11, 374, 3712, 15057, 11, 371, 3712, 41697, 721, 8, 198, 220, 220, 371, 136, 224, 796, 371, 14, 81, 198, 220, 220, 350, 796, 371, 136, 224, 1635, 371, 136, 224, 6, 198, 220, 220, 288, 53, 796, 13446, 62, 67, 0, 7, 22065, 11, 569, 11, 374, 8, 1220, 374, 198, 220, 220, 49427, 53, 796, 13446, 62, 1860, 0, 7, 22065, 11, 569, 11, 374, 8, 198, 220, 220, 1441, 357, 1860, 53, 532, 288, 53, 8, 1635, 350, 1343, 288, 53, 1635, 314, 198, 437, 198, 198, 8818, 49394, 0, 7, 71, 23041, 11, 45218, 11, 569, 3712, 47, 958, 25396, 1843, 11, 371, 3712, 23839, 38469, 90, 27, 25, 449, 53, 721, 5512, 8434, 39029, 28, 51, 7, 15, 13, 15, 4008, 198, 220, 220, 299, 796, 4129, 7, 49, 8, 198, 220, 220, 329, 1312, 796, 352, 25, 77, 198, 220, 220, 220, 220, 220, 289, 23041, 58, 72, 11, 72, 60, 796, 49394, 0, 7, 22065, 11, 569, 11, 2593, 7, 49, 58, 72, 46570, 371, 58, 72, 4357, 8434, 39029, 8, 198, 220, 220, 886, 198, 220, 220, 1441, 289, 23041, 198, 437, 198, 198, 2, 281, 18402, 3718, 623, 653, 263, 329, 5166, 2785, 82, 198, 8818, 49394, 0, 7, 22065, 11, 569, 3712, 47, 958, 25396, 1843, 11, 374, 3712, 51, 11, 371, 3712, 41697, 721, 90, 51, 5512, 8434, 39029, 28, 51, 7, 15, 13, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 810, 1391, 51, 1279, 25, 7913, 92, 198, 220, 220, 374, 796, 2593, 7, 49, 8, 198, 220, 220, 288, 53, 796, 13446, 62, 67, 0, 7, 22065, 11, 569, 11, 374, 8, 198, 220, 220, 49427, 53, 796, 13446, 62, 1860, 0, 7, 22065, 11, 569, 11, 374, 8, 198, 220, 220, 371, 136, 224, 796, 371, 14, 81, 198, 220, 220, 1441, 357, 16, 12, 5083, 39029, 8, 1635, 357, 8937, 7, 1860, 53, 8, 1635, 371, 136, 224, 1635, 371, 136, 224, 6, 1343, 2352, 7, 67, 53, 1220, 374, 8, 1635, 357, 40, 532, 371, 136, 224, 1635, 371, 136, 224, 6, 4008, 1343, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8434, 39029, 220, 1635, 357, 8937, 7, 1860, 53, 8, 1343, 2352, 7, 67, 53, 1220, 374, 4008, 1635, 314, 198, 437, 628, 198, 198, 37811, 198, 63, 43, 1697, 446, 25784, 7, 38392, 11, 304, 15, 2599, 63, 34175, 262, 718, 12, 1065, 28423, 446, 12, 25784, 2785, 685, 15466, 16151, 5450, 1378, 268, 13, 31266, 13, 2398, 14, 15466, 14, 43, 1697, 446, 12, 25784, 62, 13059, 1843, 8, 628, 220, 220, 304, 15, 1635, 604, 1635, 357, 357, 38392, 14, 81, 8, 126, 117, 31185, 532, 357, 38392, 14, 81, 8, 46256, 114, 1267, 198, 198, 42316, 273, 351, 479, 86, 7159, 25, 4600, 43, 1697, 446, 25784, 7, 26, 479, 86, 22046, 23029, 63, 198, 198, 9, 4600, 68, 15, 11, 18074, 225, 63, 1058, 3210, 406, 41, 10007, 11, 4277, 4600, 68, 15, 796, 352, 13, 15, 11, 18074, 225, 796, 352, 13, 15, 63, 198, 9, 4600, 81, 15, 63, 1058, 29163, 5253, 532, 611, 4600, 81, 15, 63, 318, 7368, 788, 4600, 38392, 63, 318, 9514, 198, 9, 4600, 64, 15, 63, 1058, 15915, 47240, 501, 11507, 11, 611, 4600, 64, 15, 63, 318, 7368, 788, 4600, 38392, 63, 318, 9514, 198, 198, 7, 63, 81, 15, 11, 257, 15, 63, 2314, 1111, 307, 7368, 379, 262, 976, 640, 8, 198, 37811, 198, 43, 1697, 446, 25784, 7, 38392, 11, 304, 15, 8, 796, 4275, 38200, 13370, 374, 4613, 304, 15, 1635, 604, 13, 15, 1635, 14808, 38392, 14, 81, 8, 61, 7, 1065, 8, 532, 357, 38392, 14, 81, 8, 61, 7, 21, 22305, 628, 198, 8818, 300, 73, 37266, 7, 26, 18074, 225, 28, 16, 13, 15, 11, 304, 15, 28, 16, 13, 15, 11, 374, 15, 796, 2147, 11, 257, 15, 796, 2147, 8, 198, 220, 220, 611, 374, 15, 14512, 2147, 11405, 257, 15, 14512, 2147, 198, 220, 220, 220, 220, 220, 4049, 7203, 63, 30659, 358, 446, 25784, 63, 25, 2314, 11986, 1111, 4600, 81, 15, 63, 290, 4600, 64, 15, 63, 4943, 198, 220, 220, 886, 198, 220, 220, 611, 257, 15, 14512, 2147, 220, 220, 220, 1303, 374, 15, 796, 299, 77, 12, 17080, 796, 257, 15, 14, 31166, 17034, 7, 17, 8, 287, 15915, 198, 220, 220, 220, 220, 220, 374, 15, 796, 257, 15, 1220, 19862, 17034, 7, 17, 8, 198, 220, 220, 886, 198, 220, 220, 611, 374, 15, 14512, 2147, 220, 220, 220, 1303, 3210, 406, 41, 318, 10356, 1417, 379, 374, 796, 362, 61, 7, 16, 14, 21, 8, 198, 220, 220, 220, 220, 220, 18074, 225, 796, 220, 374, 15, 1220, 362, 61, 7, 16, 14, 21, 8, 198, 220, 220, 886, 198, 220, 220, 1441, 18074, 225, 11, 304, 15, 198, 437, 198, 198, 43, 1697, 446, 25784, 7, 26, 479, 86, 22046, 23029, 796, 28423, 446, 25784, 7, 75, 73, 37266, 7, 26, 46265, 22046, 23029, 23029, 628, 198, 37811, 198, 63, 75, 1697, 446, 73, 1952, 7, 26, 479, 86, 22046, 23029, 63, 198, 198, 14323, 489, 1431, 23772, 329, 4600, 43, 1697, 446, 25784, 63, 357, 11295, 428, 318, 2099, 21354, 8133, 198, 198, 818, 3090, 284, 262, 4600, 46265, 22046, 63, 286, 4600, 43, 1697, 446, 25784, 47671, 428, 18178, 635, 198, 198, 9, 4600, 6015, 315, 63, 1058, 4277, 4600, 25, 23736, 63, 543, 3607, 4600, 6015, 315, 796, 357, 16, 13, 24, 9, 38392, 11, 362, 13, 22, 9, 38392, 8, 44646, 5765, 198, 63, 22366, 63, 393, 4600, 18943, 63, 284, 11986, 645, 45616, 11, 393, 11986, 257, 46545, 393, 198, 18747, 351, 734, 4847, 31577, 262, 2793, 290, 6727, 2005, 12, 2364, 2511, 4178, 284, 307, 198, 1484, 351, 4600, 26568, 500, 26254, 2364, 44646, 198, 37811, 198, 8818, 300, 1697, 446, 73, 1952, 7, 26, 374, 8968, 796, 1058, 23736, 11, 479, 86, 22046, 23029, 198, 220, 220, 18074, 225, 11, 304, 15, 796, 300, 73, 37266, 7, 26, 479, 86, 22046, 23029, 198, 220, 220, 611, 357, 6015, 315, 6624, 2147, 8614, 374, 8968, 6624, 4806, 8, 198, 220, 220, 220, 220, 220, 1441, 28423, 446, 25784, 7, 38392, 11, 304, 15, 8, 198, 220, 220, 2073, 361, 374, 8968, 6624, 1058, 23736, 198, 220, 220, 220, 220, 220, 374, 8968, 796, 357, 16, 13, 24, 9, 38392, 11, 362, 13, 22, 9, 38392, 8, 198, 220, 220, 886, 198, 220, 220, 1441, 13341, 500, 26254, 2364, 7, 6015, 315, 58, 16, 4357, 374, 8968, 58, 17, 12962, 1635, 28423, 446, 25784, 7, 38392, 11, 304, 15, 8, 198, 437, 198, 198, 37811, 198, 63, 44, 7615, 7, 32, 11, 304, 15, 11, 374, 15, 8, 63, 393, 4600, 44, 7615, 7, 26, 32, 28, 19, 13, 15, 11, 304, 15, 28, 16, 13, 15, 11, 374, 15, 28, 16, 13, 15, 8, 63, 25, 34175, 257, 198, 63, 47, 958, 25396, 1843, 63, 329, 198, 15506, 63, 198, 220, 220, 304, 15, 357, 1033, 7, 532, 17, 317, 357, 81, 14, 81, 15, 532, 352, 8, 1267, 532, 362, 1033, 7, 532, 317, 357, 81, 14, 81, 15, 532, 352, 8, 1267, 1267, 198, 15506, 63, 198, 37811, 198, 44, 7615, 7, 32, 11, 304, 15, 11, 374, 15, 8, 796, 2488, 38200, 13370, 7, 198, 220, 220, 374, 4613, 304, 15, 1635, 357, 1033, 7, 30420, 17, 13, 15, 9, 32, 8, 1635, 357, 81, 14, 81, 15, 532, 352, 13, 15, 4008, 532, 362, 13, 15, 1635, 1033, 32590, 32, 1635, 357, 81, 14, 81, 15, 532, 352, 13, 15, 4008, 1267, 1267, 198, 44, 7615, 7, 26, 32, 28, 19, 13, 15, 11, 304, 15, 28, 16, 13, 15, 11, 374, 15, 28, 16, 13, 15, 8, 796, 44049, 7, 32, 11, 304, 15, 11, 374, 15, 8, 198, 198, 37811, 198, 63, 4491, 325, 7, 32, 28, 19, 13, 15, 11, 304, 15, 28, 16, 13, 15, 11, 374, 15, 28, 16, 13, 15, 11, 374, 8968, 16193, 16, 13, 24, 9, 81, 15, 11, 362, 13, 22, 9, 81, 15, 4008, 63, 198, 198, 14323, 489, 1431, 23772, 329, 4600, 44, 7615, 63, 357, 4906, 21354, 8, 198, 37811, 198, 4491, 325, 7, 26, 32, 28, 19, 13, 15, 11, 304, 15, 28, 16, 13, 15, 11, 374, 15, 28, 16, 13, 15, 11, 374, 8968, 16193, 16, 13, 24, 9, 81, 15, 11, 362, 13, 22, 9, 81, 15, 4008, 796, 357, 198, 220, 220, 357, 6015, 315, 6624, 2147, 8614, 374, 8968, 6624, 4806, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 5633, 220, 44049, 7, 32, 11, 304, 15, 11, 374, 15, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 220, 13341, 500, 26254, 2364, 7, 6015, 315, 58, 16, 4357, 374, 8968, 58, 17, 12962, 1635, 44049, 7, 32, 11, 304, 15, 11, 374, 15, 8, 1267, 628, 198, 37811, 198, 63, 28667, 47, 958, 25396, 1843, 3419, 63, 25, 8075, 257, 2785, 326, 655, 5860, 6632, 198, 37811, 198, 7249, 12169, 47, 958, 25396, 1843, 1279, 25, 39645, 25396, 1843, 886, 198, 198, 31, 13059, 12169, 47, 958, 25396, 1843, 198, 198, 49786, 7, 79, 3712, 28667, 47, 958, 25396, 1843, 11, 374, 3712, 51, 8, 810, 1391, 51, 1279, 25, 7913, 92, 796, 309, 7, 15, 13, 15, 8, 198, 49786, 62, 67, 7, 79, 3712, 28667, 47, 958, 25396, 1843, 11, 374, 3712, 51, 8, 810, 1391, 51, 1279, 25, 7913, 92, 796, 309, 7, 15, 13, 15, 8, 198, 49786, 62, 1860, 7, 79, 3712, 28667, 47, 958, 25396, 1843, 11, 374, 3712, 51, 8, 810, 1391, 51, 1279, 25, 7913, 92, 796, 309, 7, 15, 13, 15, 8, 198, 8968, 2364, 7, 79, 3712, 28667, 47, 958, 25396, 1843, 8, 796, 347, 970, 7, 15, 8, 1303, 262, 34968, 1271, 2099, 628, 198, 198, 2, 16529, 982, 198, 198, 2, 16926, 46, 25, 3551, 517, 34165, 1343, 5254, 329, 1168, 9148, 198, 198, 37811, 198, 3546, 32851, 286, 262, 1168, 9148, 2785, 284, 2746, 1969, 3164, 13, 198, 37811, 198, 7249, 1168, 9148, 25396, 1843, 90, 6849, 92, 1279, 25, 39645, 25396, 1843, 198, 220, 220, 1168, 16, 3712, 5317, 198, 220, 220, 1168, 17, 3712, 5317, 198, 220, 220, 569, 3712, 6849, 220, 220, 1303, 49166, 198, 437, 198, 198, 31, 13059, 1168, 9148, 25396, 1843, 198, 198, 49786, 7, 53, 3712, 57, 9148, 25396, 1843, 11, 374, 3712, 15057, 8, 796, 13446, 7, 53, 13, 53, 11, 374, 3712, 15057, 8, 198, 49786, 62, 67, 7, 53, 3712, 57, 9148, 25396, 1843, 11, 374, 3712, 15057, 8, 796, 13446, 62, 67, 7, 53, 13, 53, 11, 374, 3712, 15057, 8, 198, 8968, 2364, 7, 3712, 57, 9148, 25396, 1843, 8, 796, 4806, 198, 198, 57, 9148, 25396, 1843, 7, 57, 16, 3712, 46541, 11, 1168, 17, 3712, 46541, 8, 796, 198, 220, 220, 1309, 1168, 16, 28, 57, 16, 11, 1168, 17, 28, 57, 17, 198, 220, 220, 220, 220, 220, 35851, 796, 657, 13, 3459, 4051, 1635, 657, 13, 49721, 1220, 357, 57, 16, 61, 15, 13, 1954, 1343, 1168, 17, 61, 15, 13, 1954, 8, 198, 220, 220, 220, 220, 220, 18074, 113, 15, 796, 657, 13, 405, 2816, 2075, 27371, 29703, 2481, 198, 220, 220, 220, 220, 220, 327, 796, 1168, 16, 9, 57, 17, 29006, 19, 9, 46582, 9, 139, 113, 15, 8, 198, 220, 220, 220, 220, 220, 412, 16, 11, 412, 17, 11, 412, 18, 11, 412, 19, 796, 657, 13, 1507, 1507, 11, 657, 13, 1120, 2079, 11, 657, 13, 21033, 17, 11, 657, 13, 46957, 1558, 198, 220, 220, 220, 220, 220, 317, 16, 11, 317, 17, 11, 317, 18, 11, 317, 19, 796, 513, 13, 17, 14, 559, 11, 657, 13, 5824, 1954, 14, 559, 11, 657, 13, 1821, 2078, 14, 559, 11, 657, 13, 5304, 14, 559, 198, 220, 220, 220, 220, 220, 569, 796, 2488, 38200, 13370, 7, 81, 4613, 327, 1635, 357, 36, 16, 9, 11201, 32590, 32, 16, 9, 81, 8, 1343, 412, 17, 9, 11201, 32590, 32, 17, 9, 81, 8, 1343, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 412, 18, 9, 11201, 32590, 32, 19, 9, 81, 8, 1343, 412, 19, 9, 11201, 32590, 32, 19, 9, 81, 8, 1267, 1220, 374, 8, 198, 220, 220, 220, 220, 220, 1168, 9148, 25396, 1843, 7, 57, 16, 11, 1168, 17, 11, 569, 8, 198, 220, 220, 886, 628, 198, 57, 9148, 25396, 1843, 7, 57, 3712, 46541, 8, 796, 1168, 9148, 25396, 1843, 7, 57, 11, 1168, 8, 198, 57, 9148, 25396, 1843, 7, 82, 16, 3712, 13940, 23650, 11, 264, 17, 3712, 13940, 23650, 8, 796, 1168, 9148, 25396, 1843, 7, 47116, 62, 17618, 7, 82, 16, 828, 17226, 62, 17618, 7, 82, 17, 4008, 198, 57, 9148, 25396, 1843, 7, 82, 3712, 13940, 23650, 8, 796, 1168, 9148, 25396, 1843, 7, 82, 11, 264, 8, 198, 198, 35, 713, 7, 53, 3712, 57, 9148, 25396, 1843, 8, 796, 360, 713, 7203, 834, 312, 834, 1, 5218, 366, 33018, 43, 4061, 62, 57, 9148, 25396, 1843, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 57, 16, 1, 5218, 569, 13, 57, 16, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 57, 17, 1, 5218, 1168, 13, 57, 17, 8, 198, 57, 9148, 25396, 1843, 7, 35, 3712, 35, 713, 8, 796, 1168, 9148, 25396, 1843, 7, 35, 14692, 57, 16, 33116, 360, 14692, 57, 17, 8973, 8, 198, 14881, 13, 1102, 1851, 7, 3712, 7762, 90, 25, 33018, 43, 4061, 62, 57, 9148, 25396, 1843, 5512, 360, 3712, 35, 713, 8, 796, 1168, 9148, 25396, 1843, 7, 35, 8, 628, 198, 2, 38093, 18604, 198, 2, 220, 220, 317, 1720, 286, 734, 5166, 2785, 82, 25, 7525, 973, 329, 45616, 11701, 198, 198, 1, 11167, 286, 734, 5166, 2785, 82, 1, 198, 76, 18187, 2878, 1041, 67, 25396, 90, 47, 16, 11, 350, 17, 92, 1279, 25, 39645, 25396, 1843, 198, 220, 220, 279, 16, 3712, 47, 16, 198, 220, 220, 279, 17, 3712, 47, 17, 198, 437, 198, 198, 31, 13059, 1041, 67, 25396, 198, 198, 11748, 7308, 15885, 198, 9, 7, 79, 16, 3712, 47, 958, 25396, 1843, 11, 279, 17, 3712, 47, 958, 25396, 1843, 8, 796, 1041, 67, 25396, 7, 79, 16, 11, 279, 17, 8, 198, 31, 45145, 13446, 7, 79, 3712, 2964, 67, 25396, 11, 374, 3712, 15057, 8, 796, 279, 13, 79, 16, 7, 81, 8, 1635, 279, 13, 79, 17, 7, 81, 8, 198, 49786, 62, 67, 7, 79, 3712, 2964, 67, 25396, 11, 374, 3712, 15057, 8, 796, 357, 79, 13, 79, 16, 7, 81, 8, 1635, 4275, 35, 279, 13, 79, 17, 7, 81, 4008, 1343, 4275, 35, 279, 13, 79, 16, 7, 81, 4008, 1635, 279, 13, 79, 17, 7, 81, 4008, 198, 49786, 62, 1860, 7, 79, 3712, 2964, 67, 25396, 11, 374, 3712, 15057, 8, 796, 357, 79, 13, 79, 16, 7, 81, 8, 1635, 4275, 16458, 279, 13, 79, 17, 7, 81, 4008, 1343, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 362, 1635, 4275, 35, 279, 13, 79, 16, 7, 81, 4008, 1635, 4275, 35, 279, 13, 79, 17, 7, 81, 4008, 1343, 4275, 16458, 279, 13, 79, 16, 7, 81, 4008, 1635, 279, 13, 79, 17, 7, 81, 4008, 198, 8968, 2364, 7, 79, 3712, 2964, 67, 25396, 8, 796, 949, 7, 8968, 2364, 7, 79, 13, 79, 16, 828, 45616, 7, 79, 13, 79, 17, 4008, 198, 198, 2, 38093, 18604, 628, 198, 198, 37811, 198, 63, 7249, 27323, 1496, 47, 958, 25396, 1843, 63, 198, 198, 29988, 862, 257, 5166, 13059, 1843, 1262, 4600, 22203, 36918, 11799, 63, 287, 1502, 284, 1249, 198, 4906, 12, 31284, 6143, 286, 3294, 2785, 82, 13, 770, 318, 262, 1388, 8173, 198, 35827, 379, 262, 2589, 284, 670, 351, 5021, 12, 42895, 3341, 13, 198, 48059, 11, 428, 318, 407, 46511, 1201, 340, 595, 2977, 257, 2837, 286, 198, 79, 4733, 17050, 6436, 38189, 13, 198, 37811, 198, 7249, 27323, 1496, 47, 958, 25396, 1843, 1279, 25, 17427, 47, 958, 25396, 1843, 198, 220, 220, 277, 3712, 37, 2414, 12543, 198, 220, 220, 277, 62, 67, 3712, 37, 2414, 12543, 198, 220, 220, 277, 62, 1860, 3712, 37, 2414, 12543, 198, 220, 220, 374, 8968, 3712, 43879, 2414, 198, 437, 198, 198, 31, 13059, 27323, 1496, 47, 958, 25396, 1843, 198, 198, 8968, 2364, 7, 53, 3712, 36918, 1496, 47, 958, 25396, 1843, 8, 796, 569, 13, 6015, 315, 198, 2, 13446, 11, 3503, 389, 477, 10944, 422, 17427, 47, 958, 25396, 1843, 198, 198, 8818, 27323, 1496, 47, 958, 25396, 1843, 7, 53, 3712, 37702, 13370, 22203, 11, 374, 8968, 8, 198, 220, 220, 2488, 30493, 357, 15, 1279, 374, 8968, 1279, 4806, 8, 198, 220, 220, 277, 11, 277, 62, 67, 11, 277, 62, 1860, 796, 1309, 569, 28, 53, 11, 48321, 796, 374, 8968, 198, 220, 220, 220, 220, 220, 357, 37, 2414, 12543, 7, 81, 4613, 13446, 7, 53, 11, 374, 8, 1635, 357, 81, 27, 6015, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 376, 2414, 12543, 7, 81, 4613, 13446, 62, 67, 7, 53, 11, 374, 8, 1635, 357, 81, 27, 6015, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 376, 2414, 12543, 7, 81, 4613, 13446, 62, 1860, 7, 53, 11, 374, 8, 1635, 357, 81, 27, 6015, 22305, 198, 220, 220, 886, 198, 220, 220, 1441, 27323, 1496, 47, 958, 25396, 1843, 7, 69, 11, 277, 62, 67, 11, 277, 62, 1860, 11, 45616, 7, 53, 4008, 198, 437, 198, 198, 8818, 27323, 1496, 47, 958, 25396, 1843, 7, 53, 3712, 47, 958, 25396, 1843, 8, 198, 220, 220, 2488, 30493, 357, 15, 1279, 45616, 7, 53, 8, 1279, 4806, 8, 198, 220, 220, 277, 11, 277, 62, 67, 11, 277, 62, 1860, 796, 1309, 569, 28, 53, 11, 48321, 796, 45616, 7, 53, 8, 198, 220, 220, 220, 220, 220, 357, 37, 2414, 12543, 7, 81, 4613, 13446, 7, 53, 11, 374, 8, 1635, 357, 81, 27, 6015, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 376, 2414, 12543, 7, 81, 4613, 13446, 62, 67, 7, 53, 11, 374, 8, 1635, 357, 81, 27, 6015, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 376, 2414, 12543, 7, 81, 4613, 13446, 62, 1860, 7, 53, 11, 374, 8, 1635, 357, 81, 27, 6015, 22305, 198, 220, 220, 886, 198, 220, 220, 1441, 27323, 1496, 47, 958, 25396, 1843, 7, 69, 11, 277, 62, 67, 11, 277, 62, 1860, 11, 45616, 7, 53, 4008, 198, 437, 198 ]
2.144702
3,794
<filename>src/fda.jl struct Fda T::Array{Float64} P::Array{Float64} Tcenters::Array{Float64} eig::Vector{Float64} sstot::Number W::Matrix{Float64} xmeans::Vector{Float64} lev::AbstractVector ni::AbstractVector end """ fda(X, y; nlv, pseudo = false) Factorial discriminant analysis (FDA). * `X` : X-data. * `y` : y-data (class membership). * `nlv` : Nb. discriminant components. * `pseudo` : If true, a MP pseudo-inverse is used (instead of a usual inverse) for inverting W. Eigen factorization of Inverse(W) * B. The functions maximize the compromise p'Bp / p'Wp, i.e. max p'Bp with constraint p'Wp = 1. Vectors p (columns of P) are the linear discrimant coefficients "LD". `X` is internally centered. """ function fda(X, y; nlv, pseudo = false) fda!(copy(X), y; nlv = nlv, pseudo = pseudo) end function fda!(X, y; nlv, pseudo = false) X = ensure_mat(X) n, p = size(X) xmeans = colmeans(X) center!(X, xmeans) res = matW(X, y) lev = res.lev nlev = length(lev) ni = res.ni res.W .= res.W * n / (n - nlev) zres = matB(X, y) !pseudo ? Winv = LinearAlgebra.inv!(cholesky!(Hermitian(res.W))) : Winv = pinv(res.W) # Winv * B is not symmetric fm = eigen!(Winv * zres.B; sortby = x -> -abs(x)) nlv = min(nlv, n, p, nlev - 1) P = fm.vectors[:, 1:nlv] eig = fm.values P = real.(P) eig = real.(eig) sstot = sum(eig) norm_P = sqrt.(diag(P' * res.W * P)) scale!(P, norm_P) T = X * P Tcenters = zres.ct * P Fda(T, P, Tcenters, eig, sstot, res.W, xmeans, lev, ni) end """ fdasvd(X, y; nlv, pseudo = false) Factorial discriminant analysis (FDA). * `X` : X-data. * `y` : Univariate class membership. * `nlv` : Nb. discriminant components. * `pseudo` : If true, a MP pseudo-inverse is used (instead of a usual inverse) for inverting W. Weighted SVD factorization of the matrix of the class centers. `X` is internally centered. """ function fdasvd(X, y; nlv, pseudo = false) fdasvd!(copy(X), y; nlv = nlv, pseudo = pseudo) end function fdasvd!(X, y; nlv, pseudo = false) X = ensure_mat(X) n, p = size(X) xmeans = colmeans(X) center!(X, xmeans) res = matW(X, y) lev = res.lev nlev = length(lev) ni = res.ni res.W .= res.W * n / (n - nlev) !pseudo ? Winv = inv(res.W) : Winv = pinv(res.W) ct = aggstat(X, y; fun = mean).res Ut = cholesky!(Hermitian(Winv)).U' Zct = ct * Ut nlv = min(nlv, n, p, nlev - 1) fm = pcasvd(Zct, ni; nlv = nlv) Pz = fm.P Tcenters = Zct * Pz eig = (fm.sv).^2 sstot = sum(eig) P = Ut * Pz[:, 1:nlv] T = X * P Tcenters = ct * P Fda(T, P, Tcenters, eig, sstot, res.W, xmeans, lev, ni) end """ summary(object::Fda, X) Summarize the fitted model. * `object` : The fitted model. * `X` : The X-data that was used to fit the model. """ function Base.summary(object::Fda) nlv = size(object.T, 2) eig = object.eig[1:nlv] pvar = eig ./ sum(object.eig) cumpvar = cumsum(pvar) explvar = DataFrame(lv = 1:nlv, var = eig, pvar = pvar, cumpvar = cumpvar) (explvar = explvar,) end
[ 27, 34345, 29, 10677, 14, 69, 6814, 13, 20362, 198, 7249, 376, 6814, 198, 220, 220, 220, 309, 3712, 19182, 90, 43879, 2414, 92, 198, 220, 220, 220, 350, 3712, 19182, 90, 43879, 2414, 92, 198, 220, 220, 220, 309, 1087, 364, 3712, 19182, 90, 43879, 2414, 92, 198, 220, 220, 220, 304, 328, 3712, 38469, 90, 43879, 2414, 92, 198, 220, 220, 220, 264, 301, 313, 3712, 15057, 198, 220, 220, 220, 370, 3712, 46912, 90, 43879, 2414, 92, 198, 220, 220, 220, 2124, 1326, 504, 3712, 38469, 90, 43879, 2414, 92, 198, 220, 220, 220, 23145, 3712, 23839, 38469, 198, 220, 220, 220, 37628, 3712, 23839, 38469, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 277, 6814, 7, 55, 11, 331, 26, 299, 6780, 11, 24543, 796, 3991, 8, 198, 29054, 5132, 6534, 42483, 3781, 357, 37, 5631, 737, 198, 9, 4600, 55, 63, 1058, 1395, 12, 7890, 13, 198, 9, 4600, 88, 63, 1058, 331, 12, 7890, 357, 4871, 9931, 737, 198, 9, 4600, 77, 6780, 63, 1058, 399, 65, 13, 6534, 42483, 6805, 13, 198, 9, 4600, 7752, 12003, 63, 1058, 1002, 2081, 11, 257, 4904, 24543, 12, 259, 4399, 318, 973, 357, 38070, 198, 220, 220, 220, 286, 257, 6678, 34062, 8, 329, 40631, 889, 370, 13, 198, 198, 36, 9324, 5766, 1634, 286, 554, 4399, 7, 54, 8, 1635, 347, 13, 220, 198, 198, 464, 5499, 20487, 262, 13110, 279, 6, 33, 79, 1220, 279, 6, 54, 79, 11, 1312, 13, 68, 13, 3509, 279, 6, 33, 79, 351, 220, 198, 1102, 2536, 2913, 279, 6, 54, 79, 796, 352, 13, 569, 478, 669, 279, 357, 28665, 82, 286, 350, 8, 389, 262, 14174, 6534, 415, 220, 198, 1073, 41945, 366, 11163, 1911, 198, 198, 63, 55, 63, 318, 20947, 19254, 13, 220, 220, 198, 37811, 220, 198, 8818, 277, 6814, 7, 55, 11, 331, 26, 299, 6780, 11, 24543, 796, 3991, 8, 198, 220, 220, 220, 277, 6814, 0, 7, 30073, 7, 55, 828, 331, 26, 299, 6780, 796, 299, 6780, 11, 24543, 796, 24543, 8, 198, 437, 198, 198, 8818, 277, 6814, 0, 7, 55, 11, 331, 26, 299, 6780, 11, 24543, 796, 3991, 8, 198, 220, 220, 220, 1395, 796, 4155, 62, 6759, 7, 55, 8, 198, 220, 220, 220, 299, 11, 279, 796, 2546, 7, 55, 8, 198, 220, 220, 220, 2124, 1326, 504, 796, 951, 1326, 504, 7, 55, 8, 220, 198, 220, 220, 220, 3641, 0, 7, 55, 11, 2124, 1326, 504, 8, 198, 220, 220, 220, 581, 796, 2603, 54, 7, 55, 11, 331, 8, 198, 220, 220, 220, 23145, 796, 581, 13, 2768, 198, 220, 220, 220, 299, 2768, 796, 4129, 7, 2768, 8, 198, 220, 220, 220, 37628, 796, 581, 13, 8461, 198, 220, 220, 220, 581, 13, 54, 764, 28, 581, 13, 54, 1635, 299, 1220, 357, 77, 532, 299, 2768, 8, 198, 220, 220, 220, 1976, 411, 796, 2603, 33, 7, 55, 11, 331, 8, 198, 220, 220, 220, 5145, 7752, 12003, 5633, 7178, 85, 796, 44800, 2348, 29230, 13, 16340, 0, 7, 354, 4316, 2584, 0, 7, 9360, 2781, 666, 7, 411, 13, 54, 22305, 1058, 7178, 85, 796, 6757, 85, 7, 411, 13, 54, 8, 198, 220, 220, 220, 1303, 7178, 85, 1635, 347, 318, 407, 23606, 19482, 198, 220, 220, 220, 277, 76, 796, 304, 9324, 0, 7, 54, 16340, 1635, 1976, 411, 13, 33, 26, 3297, 1525, 796, 2124, 4613, 532, 8937, 7, 87, 4008, 198, 220, 220, 220, 299, 6780, 796, 949, 7, 77, 6780, 11, 299, 11, 279, 11, 299, 2768, 532, 352, 8, 198, 220, 220, 220, 350, 796, 277, 76, 13, 303, 5217, 58, 45299, 352, 25, 77, 6780, 60, 198, 220, 220, 220, 304, 328, 796, 277, 76, 13, 27160, 198, 220, 220, 220, 350, 796, 1103, 12195, 47, 8, 198, 220, 220, 220, 304, 328, 796, 1103, 12195, 68, 328, 8, 198, 220, 220, 220, 264, 301, 313, 796, 2160, 7, 68, 328, 8, 198, 220, 220, 220, 2593, 62, 47, 796, 19862, 17034, 12195, 10989, 363, 7, 47, 6, 1635, 581, 13, 54, 1635, 350, 4008, 198, 220, 220, 220, 5046, 0, 7, 47, 11, 2593, 62, 47, 8, 198, 220, 220, 220, 309, 796, 1395, 1635, 350, 198, 220, 220, 220, 309, 1087, 364, 796, 1976, 411, 13, 310, 1635, 350, 198, 220, 220, 220, 376, 6814, 7, 51, 11, 350, 11, 309, 1087, 364, 11, 304, 328, 11, 264, 301, 313, 11, 581, 13, 54, 11, 2124, 1326, 504, 11, 23145, 11, 37628, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 277, 67, 292, 20306, 7, 55, 11, 331, 26, 299, 6780, 11, 24543, 796, 3991, 8, 198, 29054, 5132, 6534, 42483, 3781, 357, 37, 5631, 737, 198, 9, 4600, 55, 63, 1058, 1395, 12, 7890, 13, 198, 9, 4600, 88, 63, 1058, 791, 42524, 1398, 9931, 13, 198, 9, 4600, 77, 6780, 63, 1058, 399, 65, 13, 6534, 42483, 6805, 13, 198, 9, 4600, 7752, 12003, 63, 1058, 1002, 2081, 11, 257, 4904, 24543, 12, 259, 4399, 318, 973, 357, 38070, 198, 220, 220, 220, 286, 257, 6678, 34062, 8, 329, 40631, 889, 370, 13, 198, 198, 25844, 276, 311, 8898, 5766, 1634, 286, 262, 17593, 286, 262, 1398, 10399, 13, 198, 198, 63, 55, 63, 318, 20947, 19254, 13, 220, 220, 198, 37811, 220, 198, 8818, 277, 67, 292, 20306, 7, 55, 11, 331, 26, 299, 6780, 11, 24543, 796, 3991, 8, 198, 220, 220, 220, 277, 67, 292, 20306, 0, 7, 30073, 7, 55, 828, 331, 26, 299, 6780, 796, 299, 6780, 11, 24543, 796, 24543, 8, 198, 437, 198, 198, 8818, 277, 67, 292, 20306, 0, 7, 55, 11, 331, 26, 299, 6780, 11, 24543, 796, 3991, 8, 198, 220, 220, 220, 1395, 796, 4155, 62, 6759, 7, 55, 8, 198, 220, 220, 220, 299, 11, 279, 796, 2546, 7, 55, 8, 198, 220, 220, 220, 2124, 1326, 504, 796, 951, 1326, 504, 7, 55, 8, 220, 198, 220, 220, 220, 3641, 0, 7, 55, 11, 2124, 1326, 504, 8, 198, 220, 220, 220, 581, 796, 2603, 54, 7, 55, 11, 331, 8, 198, 220, 220, 220, 23145, 796, 581, 13, 2768, 198, 220, 220, 220, 299, 2768, 796, 4129, 7, 2768, 8, 198, 220, 220, 220, 37628, 796, 581, 13, 8461, 198, 220, 220, 220, 581, 13, 54, 764, 28, 581, 13, 54, 1635, 299, 1220, 357, 77, 532, 299, 2768, 8, 198, 220, 220, 220, 5145, 7752, 12003, 5633, 7178, 85, 796, 800, 7, 411, 13, 54, 8, 1058, 7178, 85, 796, 6757, 85, 7, 411, 13, 54, 8, 198, 220, 220, 220, 269, 83, 796, 4194, 14269, 7, 55, 11, 331, 26, 1257, 796, 1612, 737, 411, 198, 220, 220, 220, 7273, 796, 442, 4316, 2584, 0, 7, 9360, 2781, 666, 7, 54, 16340, 29720, 52, 6, 198, 220, 220, 220, 1168, 310, 796, 269, 83, 1635, 7273, 198, 220, 220, 220, 299, 6780, 796, 949, 7, 77, 6780, 11, 299, 11, 279, 11, 299, 2768, 532, 352, 8, 198, 220, 220, 220, 277, 76, 796, 279, 34004, 20306, 7, 57, 310, 11, 37628, 26, 299, 6780, 796, 299, 6780, 8, 198, 220, 220, 220, 350, 89, 796, 277, 76, 13, 47, 198, 220, 220, 220, 309, 1087, 364, 796, 1168, 310, 1635, 350, 89, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 304, 328, 796, 357, 38353, 13, 21370, 737, 61, 17, 220, 198, 220, 220, 220, 264, 301, 313, 796, 2160, 7, 68, 328, 8, 198, 220, 220, 220, 350, 796, 7273, 1635, 350, 89, 58, 45299, 352, 25, 77, 6780, 60, 198, 220, 220, 220, 309, 796, 1395, 1635, 350, 198, 220, 220, 220, 309, 1087, 364, 796, 269, 83, 1635, 350, 198, 220, 220, 220, 376, 6814, 7, 51, 11, 350, 11, 309, 1087, 364, 11, 304, 328, 11, 264, 301, 313, 11, 581, 13, 54, 11, 2124, 1326, 504, 11, 23145, 11, 37628, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 10638, 7, 15252, 3712, 37, 6814, 11, 1395, 8, 198, 13065, 3876, 1096, 262, 18235, 2746, 13, 198, 9, 4600, 15252, 63, 1058, 383, 18235, 2746, 13, 198, 9, 4600, 55, 63, 1058, 383, 1395, 12, 7890, 326, 373, 973, 284, 4197, 262, 2746, 13, 198, 37811, 220, 198, 8818, 7308, 13, 49736, 7, 15252, 3712, 37, 6814, 8, 198, 220, 220, 220, 299, 6780, 796, 2546, 7, 15252, 13, 51, 11, 362, 8, 198, 220, 220, 220, 304, 328, 796, 2134, 13, 68, 328, 58, 16, 25, 77, 6780, 60, 198, 220, 220, 220, 279, 7785, 796, 220, 304, 328, 24457, 2160, 7, 15252, 13, 68, 328, 8, 198, 220, 220, 220, 269, 931, 7785, 796, 269, 5700, 388, 7, 79, 7785, 8, 198, 220, 220, 220, 1193, 7785, 796, 6060, 19778, 7, 6780, 796, 352, 25, 77, 6780, 11, 1401, 796, 304, 328, 11, 279, 7785, 796, 279, 7785, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 269, 931, 7785, 796, 269, 931, 7785, 8, 198, 220, 220, 220, 357, 20676, 7785, 796, 1193, 7785, 35751, 220, 220, 220, 220, 198, 437, 628, 628, 198 ]
2.097962
1,521
<gh_stars>0 using Test using Manifolds using Manifolds: _derivative, _derivative!, differential, differential!, gradient, gradient!, _gradient, _gradient! using FiniteDifferences using LinearAlgebra: Diagonal, dot @testset "Differentiation backend" begin fd51 = Manifolds.FiniteDifferencesBackend() @testset "diff_backend" begin @test diff_backend() isa Manifolds.FiniteDifferencesBackend @test length(diff_backends()) == 1 @test diff_backends()[1] isa Manifolds.FiniteDifferencesBackend @test length(fd51.method.grid) == 5 @test fd51.method.q == 1 fd71 = Manifolds.FiniteDifferencesBackend(central_fdm(7, 1)) @test diff_backend!(fd71) == fd71 @test diff_backend() == fd71 end using ForwardDiff fwd_diff = Manifolds.ForwardDiffBackend() @testset "ForwardDiff" begin @test diff_backend() isa Manifolds.FiniteDifferencesBackend @test length(diff_backends()) == 2 @test diff_backends()[1] isa Manifolds.FiniteDifferencesBackend @test diff_backends()[2] == fwd_diff @test diff_backend!(fwd_diff) == fwd_diff @test diff_backend() == fwd_diff @test diff_backend!(fd51) isa Manifolds.FiniteDifferencesBackend @test diff_backend() isa Manifolds.FiniteDifferencesBackend diff_backend!(fwd_diff) @test diff_backend() == fwd_diff diff_backend!(fd51) end using FiniteDiff finite_diff = Manifolds.FiniteDiffBackend() @testset "FiniteDiff" begin @test diff_backend() isa Manifolds.FiniteDifferencesBackend @test length(diff_backends()) == 3 @test diff_backends()[3] == finite_diff @test diff_backend!(finite_diff) == finite_diff @test diff_backend() == finite_diff @test diff_backend!(fd51) isa Manifolds.FiniteDifferencesBackend @test diff_backend() isa Manifolds.FiniteDifferencesBackend diff_backend!(finite_diff) @test diff_backend() == finite_diff diff_backend!(fd51) end @testset "gradient" begin diff_backend!(fd51) r2 = Euclidean(2) c1(t) = [sin(t), cos(t)] f1(x) = x[1] + x[2]^2 f2(x) = 3 * x[1] * x[2] + x[2]^3 @testset "Inference" begin v = [-1.0, -1.0] @test (@inferred _derivative(c1, 0.0, Manifolds.ForwardDiffBackend())) ≈ [1.0, 0.0] @test (@inferred _derivative!(c1, v, 0.0, Manifolds.ForwardDiffBackend())) === v @test v ≈ [1.0, 0.0] @test (@inferred _derivative(c1, 0.0, finite_diff)) ≈ [1.0, 0.0] @test (@inferred _gradient(f1, [1.0, -1.0], finite_diff)) ≈ [1.0, -2.0] end @testset for backend in [fd51, fwd_diff, finite_diff] diff_backend!(backend) @test _derivative(c1, 0.0) ≈ [1.0, 0.0] v = [-1.0, -1.0] @test _derivative!(c1, v, 0.0) === v @test isapprox(v, [1.0, 0.0]) @test _gradient(f1, [1.0, -1.0]) ≈ [1.0, -2.0] @test _gradient!(f1, v, [1.0, -1.0]) === v @test v ≈ [1.0, -2.0] end diff_backend!(Manifolds.NoneDiffBackend()) @testset for backend in [fd51, Manifolds.ForwardDiffBackend()] @test _derivative(c1, 0.0, backend) ≈ [1.0, 0.0] @test _gradient(f1, [1.0, -1.0], backend) ≈ [1.0, -2.0] end diff_backend!(fd51) end end rb_onb_default = RiemannianONBDiffBackend( diff_backend(), Manifolds.ExponentialRetraction(), Manifolds.LogarithmicInverseRetraction(), DefaultOrthonormalBasis(), ) rb_onb_fd51 = RiemannianONBDiffBackend( Manifolds.FiniteDifferencesBackend(), Manifolds.ExponentialRetraction(), Manifolds.LogarithmicInverseRetraction(), DefaultOrthonormalBasis(), ) rb_onb_fwd_diff = RiemannianONBDiffBackend( Manifolds.ForwardDiffBackend(), Manifolds.ExponentialRetraction(), Manifolds.LogarithmicInverseRetraction(), DefaultOrthonormalBasis(), ) rb_onb_finite_diff = RiemannianONBDiffBackend( Manifolds.FiniteDiffBackend(), Manifolds.ExponentialRetraction(), Manifolds.LogarithmicInverseRetraction(), DefaultOrthonormalBasis(), ) rb_onb_default2 = RiemannianONBDiffBackend( diff_backend(), Manifolds.ExponentialRetraction(), Manifolds.LogarithmicInverseRetraction(), CachedBasis( DefaultOrthonormalBasis(), [[0.0, -1.0, 0.0], [sqrt(2) / 2, 0.0, -sqrt(2) / 2]], ), ) rb_proj = Manifolds.RiemannianProjectionGradientBackend(diff_backend()) @testset "rdiff_ functions" begin @test Manifolds.rdifferential_backend() === Manifolds._current_rdifferential_backend.backend @test Manifolds.rgradient_backend() === Manifolds._current_rgradient_backend.backend tmp_diff = Manifolds.rdifferential_backend() Manifolds.rdifferential_backend!(rb_onb_finite_diff) @test Manifolds.rdifferential_backend() === rb_onb_finite_diff Manifolds.rdifferential_backend!(tmp_diff) tmp_grad = Manifolds.rgradient_backend() Manifolds.rgradient_backend!(rb_onb_finite_diff) @test Manifolds.rgradient_backend() === rb_onb_finite_diff Manifolds.rgradient_backend!(tmp_grad) end @testset "Riemannian differentials" begin s2 = Sphere(2) p = [0.0, 0.0, 1.0] q = [1.0, 0.0, 0.0] c1(t) = geodesic(s2, q, p, t) Xval = [-sqrt(2) / 2, 0.0, sqrt(2) / 2] @test isapprox(s2, c1(π / 4), differential(s2, c1, π / 4), Xval) X = similar(p) differential!(s2, c1, X, π / 4) @test isapprox(s2, c1(π / 4), X, Xval) @testset for backend in [rb_onb_fd51, rb_onb_fwd_diff, rb_onb_finite_diff] @test isapprox(s2, c1(π / 4), differential(s2, c1, π / 4, backend), Xval) X = similar(p) differential!(s2, c1, X, π / 4, backend) @test isapprox(s2, c1(π / 4), X, Xval) end end @testset "Riemannian gradients" begin s2 = Sphere(2) f1(p) = p[1] q = [sqrt(2) / 2, 0, sqrt(2) / 2] @test isapprox(s2, q, gradient(s2, f1, q), [0.5, 0.0, -0.5]) for backend in [rb_onb_default, rb_proj] @test isapprox(s2, q, gradient(s2, f1, q, backend), [0.5, 0.0, -0.5]) end X = similar(q) gradient!(s2, f1, X, q) @test isapprox(s2, q, X, [0.5, 0.0, -0.5]) for backend in [rb_onb_default, rb_proj] gradient!(s2, f1, X, q, backend) @test isapprox(s2, q, X, [0.5, 0.0, -0.5]) end end
[ 27, 456, 62, 30783, 29, 15, 198, 3500, 6208, 198, 3500, 1869, 361, 10119, 198, 3500, 1869, 361, 10119, 25, 198, 220, 220, 220, 4808, 1082, 452, 876, 11, 198, 220, 220, 220, 4808, 1082, 452, 876, 28265, 198, 220, 220, 220, 22577, 11, 198, 220, 220, 220, 22577, 28265, 198, 220, 220, 220, 31312, 11, 198, 220, 220, 220, 31312, 28265, 198, 220, 220, 220, 4808, 49607, 11, 198, 220, 220, 220, 4808, 49607, 0, 198, 198, 3500, 4463, 578, 28813, 4972, 198, 3500, 44800, 2348, 29230, 25, 6031, 27923, 11, 16605, 198, 198, 31, 9288, 2617, 366, 40341, 3920, 30203, 1, 2221, 198, 220, 220, 220, 277, 67, 4349, 796, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 3419, 198, 220, 220, 220, 2488, 9288, 2617, 366, 26069, 62, 1891, 437, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 26069, 62, 1891, 2412, 28955, 6624, 352, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 2412, 3419, 58, 16, 60, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 16344, 4349, 13, 24396, 13, 25928, 8, 6624, 642, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 277, 67, 4349, 13, 24396, 13, 80, 6624, 352, 198, 220, 220, 220, 220, 220, 220, 220, 277, 67, 4869, 796, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 7, 31463, 62, 16344, 76, 7, 22, 11, 352, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 0, 7, 16344, 4869, 8, 6624, 277, 67, 4869, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 6624, 277, 67, 4869, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1262, 19530, 28813, 628, 220, 220, 220, 277, 16993, 62, 26069, 796, 1869, 361, 10119, 13, 39746, 28813, 7282, 437, 3419, 198, 220, 220, 220, 2488, 9288, 2617, 366, 39746, 28813, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 26069, 62, 1891, 2412, 28955, 6624, 362, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 2412, 3419, 58, 16, 60, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 2412, 3419, 58, 17, 60, 6624, 277, 16993, 62, 26069, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 0, 7, 69, 16993, 62, 26069, 8, 6624, 277, 16993, 62, 26069, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 6624, 277, 16993, 62, 26069, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 0, 7, 16344, 4349, 8, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 628, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 69, 16993, 62, 26069, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 6624, 277, 16993, 62, 26069, 198, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 16344, 4349, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1262, 4463, 578, 28813, 628, 220, 220, 220, 27454, 62, 26069, 796, 1869, 361, 10119, 13, 37, 9504, 28813, 7282, 437, 3419, 198, 220, 220, 220, 2488, 9288, 2617, 366, 37, 9504, 28813, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 26069, 62, 1891, 2412, 28955, 6624, 513, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 2412, 3419, 58, 18, 60, 6624, 27454, 62, 26069, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 0, 7, 69, 9504, 62, 26069, 8, 6624, 27454, 62, 26069, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 6624, 27454, 62, 26069, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 0, 7, 16344, 4349, 8, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 318, 64, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 628, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 69, 9504, 62, 26069, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 814, 62, 1891, 437, 3419, 6624, 27454, 62, 26069, 198, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 16344, 4349, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 49607, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 16344, 4349, 8, 198, 220, 220, 220, 220, 220, 220, 220, 374, 17, 796, 48862, 485, 272, 7, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 269, 16, 7, 83, 8, 796, 685, 31369, 7, 83, 828, 8615, 7, 83, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 277, 16, 7, 87, 8, 796, 2124, 58, 16, 60, 1343, 2124, 58, 17, 60, 61, 17, 198, 220, 220, 220, 220, 220, 220, 220, 277, 17, 7, 87, 8, 796, 513, 1635, 2124, 58, 16, 60, 1635, 2124, 58, 17, 60, 1343, 2124, 58, 17, 60, 61, 18, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 818, 4288, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 410, 796, 25915, 16, 13, 15, 11, 532, 16, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4275, 259, 18186, 4808, 1082, 452, 876, 7, 66, 16, 11, 657, 13, 15, 11, 1869, 361, 10119, 13, 39746, 28813, 7282, 437, 3419, 4008, 15139, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 685, 16, 13, 15, 11, 657, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4275, 259, 18186, 4808, 1082, 452, 876, 0, 7, 66, 16, 11, 410, 11, 657, 13, 15, 11, 1869, 361, 10119, 13, 39746, 28813, 7282, 437, 3419, 4008, 24844, 410, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 410, 15139, 230, 685, 16, 13, 15, 11, 657, 13, 15, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4275, 259, 18186, 4808, 1082, 452, 876, 7, 66, 16, 11, 657, 13, 15, 11, 27454, 62, 26069, 4008, 15139, 230, 685, 16, 13, 15, 11, 657, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4275, 259, 18186, 4808, 49607, 7, 69, 16, 11, 685, 16, 13, 15, 11, 532, 16, 13, 15, 4357, 27454, 62, 26069, 4008, 15139, 230, 685, 16, 13, 15, 11, 532, 17, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 329, 30203, 287, 685, 16344, 4349, 11, 277, 16993, 62, 26069, 11, 27454, 62, 26069, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 1891, 437, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4808, 1082, 452, 876, 7, 66, 16, 11, 657, 13, 15, 8, 15139, 230, 685, 16, 13, 15, 11, 657, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 410, 796, 25915, 16, 13, 15, 11, 532, 16, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4808, 1082, 452, 876, 0, 7, 66, 16, 11, 410, 11, 657, 13, 15, 8, 24844, 410, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 85, 11, 685, 16, 13, 15, 11, 657, 13, 15, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4808, 49607, 7, 69, 16, 11, 685, 16, 13, 15, 11, 532, 16, 13, 15, 12962, 15139, 230, 685, 16, 13, 15, 11, 532, 17, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4808, 49607, 0, 7, 69, 16, 11, 410, 11, 685, 16, 13, 15, 11, 532, 16, 13, 15, 12962, 24844, 410, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 410, 15139, 230, 685, 16, 13, 15, 11, 532, 17, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 5124, 361, 10119, 13, 14202, 28813, 7282, 437, 28955, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 329, 30203, 287, 685, 16344, 4349, 11, 1869, 361, 10119, 13, 39746, 28813, 7282, 437, 3419, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4808, 1082, 452, 876, 7, 66, 16, 11, 657, 13, 15, 11, 30203, 8, 15139, 230, 685, 16, 13, 15, 11, 657, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4808, 49607, 7, 69, 16, 11, 685, 16, 13, 15, 11, 532, 16, 13, 15, 4357, 30203, 8, 15139, 230, 685, 16, 13, 15, 11, 532, 17, 13, 15, 60, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 814, 62, 1891, 437, 0, 7, 16344, 4349, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 26145, 62, 261, 65, 62, 12286, 796, 371, 26597, 1236, 666, 1340, 14529, 733, 7282, 437, 7, 198, 220, 220, 220, 814, 62, 1891, 437, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 16870, 35470, 9781, 7861, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 11187, 283, 342, 9383, 818, 4399, 9781, 7861, 22784, 198, 220, 220, 220, 15161, 5574, 400, 261, 6636, 15522, 271, 22784, 198, 8, 198, 198, 26145, 62, 261, 65, 62, 16344, 4349, 796, 371, 26597, 1236, 666, 1340, 14529, 733, 7282, 437, 7, 198, 220, 220, 220, 1869, 361, 10119, 13, 37, 9504, 28813, 4972, 7282, 437, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 16870, 35470, 9781, 7861, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 11187, 283, 342, 9383, 818, 4399, 9781, 7861, 22784, 198, 220, 220, 220, 15161, 5574, 400, 261, 6636, 15522, 271, 22784, 198, 8, 198, 198, 26145, 62, 261, 65, 62, 69, 16993, 62, 26069, 796, 371, 26597, 1236, 666, 1340, 14529, 733, 7282, 437, 7, 198, 220, 220, 220, 1869, 361, 10119, 13, 39746, 28813, 7282, 437, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 16870, 35470, 9781, 7861, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 11187, 283, 342, 9383, 818, 4399, 9781, 7861, 22784, 198, 220, 220, 220, 15161, 5574, 400, 261, 6636, 15522, 271, 22784, 198, 8, 198, 198, 26145, 62, 261, 65, 62, 69, 9504, 62, 26069, 796, 371, 26597, 1236, 666, 1340, 14529, 733, 7282, 437, 7, 198, 220, 220, 220, 1869, 361, 10119, 13, 37, 9504, 28813, 7282, 437, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 16870, 35470, 9781, 7861, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 11187, 283, 342, 9383, 818, 4399, 9781, 7861, 22784, 198, 220, 220, 220, 15161, 5574, 400, 261, 6636, 15522, 271, 22784, 198, 8, 198, 198, 26145, 62, 261, 65, 62, 12286, 17, 796, 371, 26597, 1236, 666, 1340, 14529, 733, 7282, 437, 7, 198, 220, 220, 220, 814, 62, 1891, 437, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 16870, 35470, 9781, 7861, 22784, 198, 220, 220, 220, 1869, 361, 10119, 13, 11187, 283, 342, 9383, 818, 4399, 9781, 7861, 22784, 198, 220, 220, 220, 327, 2317, 15522, 271, 7, 198, 220, 220, 220, 220, 220, 220, 220, 15161, 5574, 400, 261, 6636, 15522, 271, 22784, 198, 220, 220, 220, 220, 220, 220, 220, 16410, 15, 13, 15, 11, 532, 16, 13, 15, 11, 657, 13, 15, 4357, 685, 31166, 17034, 7, 17, 8, 1220, 362, 11, 657, 13, 15, 11, 532, 31166, 17034, 7, 17, 8, 1220, 362, 60, 4357, 198, 220, 220, 220, 10612, 198, 8, 198, 198, 26145, 62, 1676, 73, 796, 1869, 361, 10119, 13, 49, 26597, 1236, 666, 16775, 295, 42731, 1153, 7282, 437, 7, 26069, 62, 1891, 437, 28955, 198, 198, 31, 9288, 2617, 366, 4372, 733, 62, 5499, 1, 2221, 198, 220, 220, 220, 2488, 9288, 1869, 361, 10119, 13, 4372, 17125, 498, 62, 1891, 437, 3419, 24844, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1869, 361, 10119, 13557, 14421, 62, 4372, 17125, 498, 62, 1891, 437, 13, 1891, 437, 198, 220, 220, 220, 2488, 9288, 1869, 361, 10119, 13, 81, 49607, 62, 1891, 437, 3419, 24844, 1869, 361, 10119, 13557, 14421, 62, 81, 49607, 62, 1891, 437, 13, 1891, 437, 628, 220, 220, 220, 45218, 62, 26069, 796, 1869, 361, 10119, 13, 4372, 17125, 498, 62, 1891, 437, 3419, 198, 220, 220, 220, 1869, 361, 10119, 13, 4372, 17125, 498, 62, 1891, 437, 0, 7, 26145, 62, 261, 65, 62, 69, 9504, 62, 26069, 8, 198, 220, 220, 220, 2488, 9288, 1869, 361, 10119, 13, 4372, 17125, 498, 62, 1891, 437, 3419, 24844, 374, 65, 62, 261, 65, 62, 69, 9504, 62, 26069, 198, 220, 220, 220, 1869, 361, 10119, 13, 4372, 17125, 498, 62, 1891, 437, 0, 7, 22065, 62, 26069, 8, 628, 220, 220, 220, 45218, 62, 9744, 796, 1869, 361, 10119, 13, 81, 49607, 62, 1891, 437, 3419, 198, 220, 220, 220, 1869, 361, 10119, 13, 81, 49607, 62, 1891, 437, 0, 7, 26145, 62, 261, 65, 62, 69, 9504, 62, 26069, 8, 198, 220, 220, 220, 2488, 9288, 1869, 361, 10119, 13, 81, 49607, 62, 1891, 437, 3419, 24844, 374, 65, 62, 261, 65, 62, 69, 9504, 62, 26069, 198, 220, 220, 220, 1869, 361, 10119, 13, 81, 49607, 62, 1891, 437, 0, 7, 22065, 62, 9744, 8, 198, 437, 198, 198, 31, 9288, 2617, 366, 49, 26597, 1236, 666, 1180, 8231, 1, 2221, 198, 220, 220, 220, 264, 17, 796, 31798, 7, 17, 8, 198, 220, 220, 220, 279, 796, 685, 15, 13, 15, 11, 657, 13, 15, 11, 352, 13, 15, 60, 198, 220, 220, 220, 10662, 796, 685, 16, 13, 15, 11, 657, 13, 15, 11, 657, 13, 15, 60, 198, 220, 220, 220, 269, 16, 7, 83, 8, 796, 4903, 4147, 291, 7, 82, 17, 11, 10662, 11, 279, 11, 256, 8, 628, 220, 220, 220, 1395, 2100, 796, 25915, 31166, 17034, 7, 17, 8, 1220, 362, 11, 657, 13, 15, 11, 19862, 17034, 7, 17, 8, 1220, 362, 60, 198, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 269, 16, 7, 46582, 1220, 604, 828, 22577, 7, 82, 17, 11, 269, 16, 11, 18074, 222, 1220, 604, 828, 1395, 2100, 8, 198, 220, 220, 220, 1395, 796, 2092, 7, 79, 8, 198, 220, 220, 220, 22577, 0, 7, 82, 17, 11, 269, 16, 11, 1395, 11, 18074, 222, 1220, 604, 8, 198, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 269, 16, 7, 46582, 1220, 604, 828, 1395, 11, 1395, 2100, 8, 628, 220, 220, 220, 2488, 9288, 2617, 329, 30203, 287, 685, 26145, 62, 261, 65, 62, 16344, 4349, 11, 374, 65, 62, 261, 65, 62, 69, 16993, 62, 26069, 11, 374, 65, 62, 261, 65, 62, 69, 9504, 62, 26069, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 269, 16, 7, 46582, 1220, 604, 828, 22577, 7, 82, 17, 11, 269, 16, 11, 18074, 222, 1220, 604, 11, 30203, 828, 1395, 2100, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1395, 796, 2092, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 22577, 0, 7, 82, 17, 11, 269, 16, 11, 1395, 11, 18074, 222, 1220, 604, 11, 30203, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 269, 16, 7, 46582, 1220, 604, 828, 1395, 11, 1395, 2100, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 31, 9288, 2617, 366, 49, 26597, 1236, 666, 3915, 2334, 1, 2221, 198, 220, 220, 220, 264, 17, 796, 31798, 7, 17, 8, 198, 220, 220, 220, 277, 16, 7, 79, 8, 796, 279, 58, 16, 60, 628, 220, 220, 220, 10662, 796, 685, 31166, 17034, 7, 17, 8, 1220, 362, 11, 657, 11, 19862, 17034, 7, 17, 8, 1220, 362, 60, 198, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 10662, 11, 31312, 7, 82, 17, 11, 277, 16, 11, 10662, 828, 685, 15, 13, 20, 11, 657, 13, 15, 11, 532, 15, 13, 20, 12962, 198, 220, 220, 220, 329, 30203, 287, 685, 26145, 62, 261, 65, 62, 12286, 11, 374, 65, 62, 1676, 73, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 10662, 11, 31312, 7, 82, 17, 11, 277, 16, 11, 10662, 11, 30203, 828, 685, 15, 13, 20, 11, 657, 13, 15, 11, 532, 15, 13, 20, 12962, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1395, 796, 2092, 7, 80, 8, 198, 220, 220, 220, 31312, 0, 7, 82, 17, 11, 277, 16, 11, 1395, 11, 10662, 8, 198, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 10662, 11, 1395, 11, 685, 15, 13, 20, 11, 657, 13, 15, 11, 532, 15, 13, 20, 12962, 198, 220, 220, 220, 329, 30203, 287, 685, 26145, 62, 261, 65, 62, 12286, 11, 374, 65, 62, 1676, 73, 60, 198, 220, 220, 220, 220, 220, 220, 220, 31312, 0, 7, 82, 17, 11, 277, 16, 11, 1395, 11, 10662, 11, 30203, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 82, 17, 11, 10662, 11, 1395, 11, 685, 15, 13, 20, 11, 657, 13, 15, 11, 532, 15, 13, 20, 12962, 198, 220, 220, 220, 886, 198, 437, 198 ]
2.035512
3,182
import Celeste.ArgumentParse @testset "argument parse" begin @testset "positional argument" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "my_arg") @test_throws ArgumentParse.ArgumentParsingError ArgumentParse.parse_args(parser, String[]) parsed_args = ArgumentParse.parse_args(parser, ["hello"]) @test parsed_args["my_arg"] == "hello" @test_throws ArgumentParse.ArgumentParsingError ArgumentParse.parse_args(parser, ["foo", "bar"]) end @testset "positional argument type conversion" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "my_arg", arg_type=Int) parsed_args = ArgumentParse.parse_args(parser, ["123"]) @test parsed_args["my_arg"] == 123 end @testset "keyword argument" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "--my-arg") parsed_args = ArgumentParse.parse_args(parser, String[]) @test !haskey(parsed_args, "my-arg") parsed_args = ArgumentParse.parse_args(parser, ["--my-arg", "hello"]) @test parsed_args["my-arg"] == "hello" end @testset "keyword argument type conversion" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "--my-arg", arg_type=Int) parsed_args = ArgumentParse.parse_args(parser, ["--my-arg", "123"]) @test parsed_args["my-arg"] == 123 end @testset "required keyword argument fails when missing" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "--my-arg", required=true) @test_throws ArgumentParse.ArgumentParsingError ArgumentParse.parse_args(parser, String[]) end @testset "keyword argument default value when missing" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "--my-arg", default="hi there") parsed_args = ArgumentParse.parse_args(parser, String[]) @test parsed_args["my-arg"] == "hi there" end @testset "keyword argument :store_true" begin parser = ArgumentParse.ArgumentParser(propagate_errors=true) ArgumentParse.add_argument(parser, "--my-arg", action=:store_true) parsed_args = ArgumentParse.parse_args(parser, String[]) @test parsed_args["my-arg"] == false parsed_args = ArgumentParse.parse_args(parser, String["--my-arg"]) @test parsed_args["my-arg"] == true end @testset "help message" begin parser = ArgumentParse.ArgumentParser(program_name="test.jl", propagate_errors=true) ArgumentParse.add_argument(parser, "--my-keyword", default="hello") ArgumentParse.add_argument(parser, "my_arg") help_message = nothing try ArgumentParse.parse_args(parser, ["--help"]) @test false catch exc if !isa(exc, ArgumentParse.ShowHelp) rethrow() end help_message = exc.message end @test help_message == "Usage: test.jl [--my-keyword my-keyword] my_arg" end end
[ 11748, 15248, 29872, 13, 28100, 1713, 10044, 325, 198, 198, 31, 9288, 2617, 366, 49140, 21136, 1, 2221, 198, 198, 31, 9288, 2617, 366, 1930, 1859, 4578, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 1820, 62, 853, 4943, 628, 220, 220, 220, 2488, 9288, 62, 400, 8516, 45751, 10044, 325, 13, 28100, 1713, 47, 945, 278, 12331, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 10903, 58, 12962, 628, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 14631, 31373, 8973, 8, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 62, 853, 8973, 6624, 366, 31373, 1, 628, 220, 220, 220, 2488, 9288, 62, 400, 8516, 45751, 10044, 325, 13, 28100, 1713, 47, 945, 278, 12331, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 14631, 21943, 1600, 366, 5657, 8973, 8, 198, 437, 198, 198, 31, 9288, 2617, 366, 1930, 1859, 4578, 2099, 11315, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 1820, 62, 853, 1600, 1822, 62, 4906, 28, 5317, 8, 198, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 14631, 10163, 8973, 8, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 62, 853, 8973, 6624, 17031, 198, 437, 198, 198, 31, 9288, 2617, 366, 2539, 4775, 4578, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 438, 1820, 12, 853, 4943, 628, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 10903, 58, 12962, 198, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 945, 276, 62, 22046, 11, 366, 1820, 12, 853, 4943, 628, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 14631, 438, 1820, 12, 853, 1600, 366, 31373, 8973, 8, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 12, 853, 8973, 6624, 366, 31373, 1, 198, 437, 198, 198, 31, 9288, 2617, 366, 2539, 4775, 4578, 2099, 11315, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 438, 1820, 12, 853, 1600, 1822, 62, 4906, 28, 5317, 8, 628, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 14631, 438, 1820, 12, 853, 1600, 366, 10163, 8973, 8, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 12, 853, 8973, 6624, 17031, 198, 437, 198, 198, 31, 9288, 2617, 366, 35827, 21179, 4578, 10143, 618, 4814, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 438, 1820, 12, 853, 1600, 2672, 28, 7942, 8, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 45751, 10044, 325, 13, 28100, 1713, 47, 945, 278, 12331, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 10903, 58, 12962, 198, 437, 198, 198, 31, 9288, 2617, 366, 2539, 4775, 4578, 4277, 1988, 618, 4814, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 438, 1820, 12, 853, 1600, 4277, 2625, 5303, 612, 4943, 198, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 10903, 58, 12962, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 12, 853, 8973, 6624, 366, 5303, 612, 1, 198, 437, 198, 198, 31, 9288, 2617, 366, 2539, 4775, 4578, 1058, 8095, 62, 7942, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 22930, 37861, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 438, 1820, 12, 853, 1600, 2223, 28, 25, 8095, 62, 7942, 8, 628, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 10903, 58, 12962, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 12, 853, 8973, 6624, 3991, 628, 220, 220, 220, 44267, 62, 22046, 796, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 10903, 14692, 438, 1820, 12, 853, 8973, 8, 198, 220, 220, 220, 2488, 9288, 44267, 62, 22046, 14692, 1820, 12, 853, 8973, 6624, 2081, 198, 437, 198, 198, 31, 9288, 2617, 366, 16794, 3275, 1, 2221, 198, 220, 220, 220, 30751, 796, 45751, 10044, 325, 13, 28100, 1713, 46677, 7, 23065, 62, 3672, 2625, 9288, 13, 20362, 1600, 47933, 62, 48277, 28, 7942, 8, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 438, 1820, 12, 2539, 4775, 1600, 4277, 2625, 31373, 4943, 198, 220, 220, 220, 45751, 10044, 325, 13, 2860, 62, 49140, 7, 48610, 11, 366, 1820, 62, 853, 4943, 198, 220, 220, 220, 1037, 62, 20500, 796, 2147, 198, 220, 220, 220, 1949, 198, 220, 220, 220, 220, 220, 220, 220, 45751, 10044, 325, 13, 29572, 62, 22046, 7, 48610, 11, 14631, 438, 16794, 8973, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3991, 198, 220, 220, 220, 4929, 2859, 198, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 9160, 7, 41194, 11, 45751, 10044, 325, 13, 15307, 22087, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 302, 16939, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1037, 62, 20500, 796, 2859, 13, 20500, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2488, 9288, 1037, 62, 20500, 6624, 366, 28350, 25, 1332, 13, 20362, 685, 438, 1820, 12, 2539, 4775, 616, 12, 2539, 4775, 60, 616, 62, 853, 1, 198, 437, 198, 198, 437, 198 ]
2.766304
1,104
using DataDrivenDiffEq using OrdinaryDiffEq using Plots gr() # Define measurements from unstable system with known control input X = [4 2 1 0.5 0.25; 7 0.7 0.07 0.007 0.0007] U = [-4 -2 -1 -0.5] B = Float32[1; 0] # See fail with unknown input sys = DMDc(X, U) # But with a little more knowledge sys = DMDc(X, U, B = B) # Extract the DMD from inside DMDc get_dynamics(sys) # Acess all the other stuff eigen(sys) eigvals(sys) eigvecs(sys) isstable(sys) # Get unforced dynamics dudt_ = dynamics(sys) prob = DiscreteProblem(dudt_, X[:, 1], (0., 10.)) sol_unforced = solve(prob, FunctionMap()) plot(sol_unforced) sol_unforced[:,:] # Create a system with cos control input to stabilize dudt_ = dynamics(sys, control = (u, p, t) -> -0.5u[1]) prob = DiscreteProblem(dudt_, X[:, 1], (0., 10.)) sol = solve(prob, FunctionMap()) plot!(sol)
[ 3500, 6060, 20564, 574, 28813, 36, 80, 198, 3500, 14230, 3219, 28813, 36, 80, 198, 3500, 1345, 1747, 198, 2164, 3419, 198, 198, 2, 2896, 500, 13871, 422, 21354, 1080, 351, 1900, 1630, 5128, 198, 55, 796, 685, 19, 362, 352, 657, 13, 20, 657, 13, 1495, 26, 767, 657, 13, 22, 657, 13, 2998, 657, 13, 25816, 657, 13, 830, 22, 60, 198, 52, 796, 25915, 19, 532, 17, 532, 16, 532, 15, 13, 20, 60, 198, 33, 796, 48436, 2624, 58, 16, 26, 657, 60, 198, 198, 2, 4091, 2038, 351, 6439, 5128, 198, 17597, 796, 360, 12740, 66, 7, 55, 11, 471, 8, 198, 2, 887, 351, 257, 1310, 517, 3725, 198, 17597, 796, 360, 12740, 66, 7, 55, 11, 471, 11, 347, 796, 347, 8, 198, 198, 2, 29677, 262, 360, 12740, 422, 2641, 360, 12740, 66, 198, 1136, 62, 67, 4989, 873, 7, 17597, 8, 198, 2, 317, 919, 477, 262, 584, 3404, 198, 68, 9324, 7, 17597, 8, 198, 68, 328, 12786, 7, 17597, 8, 198, 68, 328, 303, 6359, 7, 17597, 8, 198, 271, 31284, 7, 17597, 8, 198, 2, 3497, 555, 12072, 17262, 198, 67, 463, 83, 62, 796, 17262, 7, 17597, 8, 198, 1676, 65, 796, 8444, 8374, 40781, 7, 67, 463, 83, 62, 11, 1395, 58, 45299, 352, 4357, 357, 15, 1539, 838, 2014, 8, 198, 34453, 62, 403, 12072, 796, 8494, 7, 1676, 65, 11, 220, 15553, 13912, 28955, 198, 29487, 7, 34453, 62, 403, 12072, 8, 198, 34453, 62, 403, 12072, 58, 45299, 47715, 198, 2, 13610, 257, 1080, 351, 8615, 1630, 5128, 284, 32411, 198, 67, 463, 83, 62, 796, 17262, 7, 17597, 11, 1630, 796, 357, 84, 11, 279, 11, 256, 8, 4613, 532, 15, 13, 20, 84, 58, 16, 12962, 198, 1676, 65, 796, 8444, 8374, 40781, 7, 67, 463, 83, 62, 11, 1395, 58, 45299, 352, 4357, 357, 15, 1539, 838, 2014, 8, 198, 34453, 796, 8494, 7, 1676, 65, 11, 15553, 13912, 28955, 198, 198, 29487, 0, 7, 34453, 8, 198 ]
2.467456
338
<gh_stars>1-10 println("CHEM 324 Tutorials")
[ 27, 456, 62, 30783, 29, 16, 12, 940, 198, 35235, 7203, 3398, 3620, 38595, 36361, 82, 4943 ]
2.588235
17
<reponame>hnlee77/ApproximateDPs.jl using ApproximateDPs const ADP = ApproximateDPs using FlightSims const FS = FlightSims using Transducers using Plots using Random, LinearAlgebra, ComponentArrays using DynamicPolynomials, UnPack using DifferentialEquations, DataFrames using NumericalIntegration: integrate function initialise() # setting A, B = [-10 1; -0.002 -2], [0; 2] Q, R = I, I env = LinearSystem(A, B) __t = 0.0 irl = CTLinearValueIterationIRL(Q, R) env, irl end function train!(env, irl; Δt=0.01, tf=3.0, w_tol=1e-3) @unpack A, B = env args_linearsystem = (A, B) linearsystem, integ = FSimZoo.LinearSystem_SingleIntegrator(args_linearsystem) # integrated system with scalar integrator ∫r x0 = State(linearsystem, integ)([0.4, 4.0]) irl.V̂.param = zeros(size(irl.V̂.param)) # zero initialisation û = ADP.ApproximateOptimalInput(irl, B) _û = (X, p, t) -> û(X.x, p, t) # for integrated system cb_train = ADP.update_params_callback(irl, w_tol) cb = CallbackSet(cb_train) running_cost = ADP.RunningCost(irl) prob, df = sim( x0, apply_inputs(Dynamics!(linearsystem, integ, running_cost); u=_û); tf=tf, callback=cb, savestep=Δt ) ts = df.time xs = df.sol |> Map(datum -> datum.linearsystem.state) |> collect plot(ts, hcat(xs...)') # ∫rs = df.sol |> Map(datum -> datum.integ.integral) |> collect # plot(hcat(∫rs...)') end function main(; seed=1) Random.seed!(seed) env, irl = initialise() train!(env, irl; w_tol = 1e-3) end
[ 27, 7856, 261, 480, 29, 21116, 7197, 3324, 14, 4677, 13907, 1920, 6322, 82, 13, 20362, 198, 3500, 2034, 13907, 1920, 6322, 82, 198, 9979, 5984, 47, 796, 2034, 13907, 1920, 6322, 82, 198, 3500, 13365, 8890, 82, 198, 9979, 23324, 796, 13365, 8890, 82, 198, 3500, 3602, 41213, 198, 3500, 1345, 1747, 198, 3500, 14534, 11, 44800, 2348, 29230, 11, 35100, 3163, 20477, 198, 3500, 26977, 34220, 26601, 8231, 11, 791, 11869, 198, 3500, 20615, 498, 23588, 602, 11, 6060, 35439, 198, 3500, 399, 6975, 605, 34500, 1358, 25, 19386, 628, 198, 8818, 4238, 786, 3419, 198, 220, 220, 220, 1303, 4634, 198, 220, 220, 220, 317, 11, 347, 796, 25915, 940, 352, 26, 532, 15, 13, 21601, 532, 17, 4357, 685, 15, 26, 362, 60, 198, 220, 220, 220, 1195, 11, 371, 796, 314, 11, 314, 198, 220, 220, 220, 17365, 796, 44800, 11964, 7, 32, 11, 347, 8, 198, 220, 220, 220, 11593, 83, 796, 657, 13, 15, 198, 220, 220, 220, 220, 1901, 796, 327, 14990, 259, 451, 11395, 29993, 341, 4663, 43, 7, 48, 11, 371, 8, 198, 220, 220, 220, 17365, 11, 220, 1901, 198, 437, 198, 198, 8818, 4512, 0, 7, 24330, 11, 220, 1901, 26, 37455, 83, 28, 15, 13, 486, 11, 48700, 28, 18, 13, 15, 11, 266, 62, 83, 349, 28, 16, 68, 12, 18, 8, 198, 220, 220, 220, 2488, 403, 8002, 317, 11, 347, 796, 17365, 198, 220, 220, 220, 26498, 62, 29127, 10057, 796, 357, 32, 11, 347, 8, 198, 220, 220, 220, 14174, 10057, 11, 4132, 796, 376, 8890, 57, 2238, 13, 14993, 451, 11964, 62, 28008, 34500, 12392, 7, 22046, 62, 29127, 10057, 8, 220, 1303, 11521, 1080, 351, 16578, 283, 4132, 12392, 18872, 104, 81, 198, 220, 220, 220, 2124, 15, 796, 1812, 7, 29127, 10057, 11, 4132, 5769, 58, 15, 13, 19, 11, 604, 13, 15, 12962, 198, 220, 220, 220, 220, 1901, 13, 53, 136, 224, 13, 17143, 796, 1976, 27498, 7, 7857, 7, 1901, 13, 53, 136, 224, 13, 17143, 4008, 220, 1303, 6632, 4238, 5612, 198, 220, 220, 220, 334, 136, 224, 796, 5984, 47, 13, 4677, 13907, 1920, 27871, 4402, 20560, 7, 1901, 11, 347, 8, 198, 220, 220, 220, 4808, 84, 136, 224, 796, 357, 55, 11, 279, 11, 256, 8, 4613, 334, 136, 224, 7, 55, 13, 87, 11, 279, 11, 256, 8, 220, 1303, 329, 11521, 1080, 628, 220, 220, 220, 269, 65, 62, 27432, 796, 5984, 47, 13, 19119, 62, 37266, 62, 47423, 7, 1901, 11, 266, 62, 83, 349, 8, 198, 220, 220, 220, 269, 65, 796, 4889, 1891, 7248, 7, 21101, 62, 27432, 8, 198, 220, 220, 220, 2491, 62, 15805, 796, 5984, 47, 13, 28768, 13729, 7, 1901, 8, 198, 220, 220, 220, 1861, 11, 47764, 796, 985, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2124, 15, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4174, 62, 15414, 82, 7, 35, 4989, 873, 0, 7, 29127, 10057, 11, 4132, 11, 2491, 62, 15805, 1776, 334, 28, 62, 84, 136, 224, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 48700, 28, 27110, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23838, 28, 21101, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 473, 4223, 538, 28, 138, 242, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 40379, 796, 47764, 13, 2435, 198, 220, 220, 220, 2124, 82, 796, 47764, 13, 34453, 930, 29, 9347, 7, 19608, 388, 4613, 4818, 388, 13, 29127, 10057, 13, 5219, 8, 930, 29, 2824, 198, 220, 220, 220, 7110, 7, 912, 11, 289, 9246, 7, 34223, 23029, 11537, 198, 220, 220, 220, 1303, 18872, 104, 3808, 796, 47764, 13, 34453, 930, 29, 9347, 7, 19608, 388, 4613, 4818, 388, 13, 18908, 13, 18908, 1373, 8, 930, 29, 2824, 198, 220, 220, 220, 1303, 7110, 7, 71, 9246, 7, 24861, 104, 3808, 23029, 11537, 198, 437, 198, 198, 8818, 1388, 7, 26, 9403, 28, 16, 8, 198, 220, 220, 220, 14534, 13, 28826, 0, 7, 28826, 8, 198, 220, 220, 220, 17365, 11, 220, 1901, 796, 4238, 786, 3419, 198, 220, 220, 220, 4512, 0, 7, 24330, 11, 220, 1901, 26, 266, 62, 83, 349, 796, 352, 68, 12, 18, 8, 198, 437, 198 ]
2.120359
781
""" rna(R::AbstractRecurrenceMatrix) rna(args...; kwargs...) Calculate a set of Recurrence Network parameters. The input `R` can be a symmetric recurrence matrix that is interpreted as the adjacency matrix of an undirected complex network, such that linked vertices are neighboring points in the phase space. Alternatively, the inputs can be a graph object or any valid inputs to the `SimpleGraph` constructor of the [LightGraphs](https://github.com/JuliaGraphs/LightGraphs.jl) package. ## Return The returned value is a dictionary that contains the following entries, with the corresponding global network properties[1, 2]: * `:density`: edge density, approximately equivalent to the global recurrence rate in the phase space. * `:transitivity`: network transitivity, which describes the global clustering of points following Barrat's and Weigt's formulation [3]. * `:averagepath`: mean value of the shortest path lengths taken over all pairs of connected vertices, related to the average separation between points in the phase. * `:diameter`: maximum value of the shortest path lengths between pairs of connected vertices, related to the phase space diameter. ## References [1]: <NAME> *et al.* "Recurrence networks — a novel paradigm for nonlinear time series analysis", *New Journal of Physics* 12, 033025 (2010) [DOI:10.1088/1367-2630/12/3/033025](https://doi.org/10.1088/1367-2630/12/3/033025) [2]: <NAME> *et al.*, The geometry of chaotic dynamics — a complex network perspective, *Eur. Phys. J.* B 84, 653–672 (2011) [DOI:10.1140/epjb/e2011-10899-1](https://doi.org/10.1140/epjb/e2011-10899-1) [3]: <NAME> & <NAME>, "On the properties of small-world network models", *The European Physical Journal B* 13, 547–560 (2000) [DOI:10.1007/s100510050067](https://doi.org/10.1007/s100510050067) """ function rna(args...; kwargs...) graph = SimpleGraph(args...; kwargs...) return Dict{Symbol, Float64}( :density => density(graph), :transitivity => global_clustering_coefficient(graph), :averagepath => averagepath(graph), :diameter => diameter(graph) ) end """ averagepath(graph) Calculates average minimum path length for a SimpleGraph. Uses Donner, 2010, Eq. 26 on pg. 18. """ function averagepath(graph::SimpleGraph) num_verts = nv(graph) dist_mat = floyd_warshall_shortest_paths(graph).dists @. dist_mat[dist_mat == typemax(dist_mat)] = 0. return sum(dist_mat) / (num_verts * (num_verts - 1)) end
[ 37811, 198, 220, 220, 220, 374, 2616, 7, 49, 3712, 23839, 6690, 33928, 46912, 8, 198, 220, 220, 220, 374, 2616, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 198, 9771, 3129, 378, 257, 900, 286, 3311, 33928, 7311, 10007, 13, 198, 464, 5128, 4600, 49, 63, 460, 307, 257, 23606, 19482, 664, 33928, 17593, 326, 318, 198, 27381, 276, 355, 262, 9224, 330, 1387, 17593, 286, 281, 3318, 1060, 276, 3716, 3127, 11, 198, 10508, 326, 6692, 9421, 1063, 389, 19651, 2173, 287, 262, 7108, 2272, 13, 198, 198, 44163, 11, 262, 17311, 460, 307, 257, 4823, 2134, 393, 597, 220, 198, 12102, 17311, 284, 262, 4600, 26437, 37065, 63, 23772, 286, 262, 198, 58, 15047, 37065, 82, 16151, 5450, 1378, 12567, 13, 785, 14, 16980, 544, 37065, 82, 14, 15047, 37065, 82, 13, 20362, 8, 5301, 13, 198, 198, 2235, 8229, 198, 198, 464, 4504, 1988, 318, 257, 22155, 326, 4909, 262, 1708, 12784, 11, 198, 4480, 262, 11188, 3298, 3127, 6608, 58, 16, 11, 362, 5974, 198, 9, 4600, 25, 43337, 63, 25, 5743, 12109, 11, 6702, 7548, 284, 262, 3298, 664, 33928, 2494, 287, 262, 7108, 2272, 13, 198, 9, 4600, 25, 7645, 11365, 63, 25, 3127, 11168, 3458, 11, 543, 8477, 262, 198, 20541, 32966, 1586, 286, 2173, 1708, 2409, 10366, 338, 290, 775, 328, 83, 338, 31760, 685, 18, 4083, 198, 9, 4600, 25, 23913, 6978, 63, 25, 1612, 1988, 286, 262, 35581, 3108, 20428, 2077, 625, 198, 439, 14729, 286, 5884, 9421, 1063, 11, 3519, 284, 262, 2811, 14139, 198, 23395, 2173, 287, 262, 7108, 13, 198, 9, 4600, 25, 67, 13173, 63, 25, 5415, 1988, 286, 262, 35581, 3108, 20428, 1022, 198, 79, 3468, 286, 5884, 9421, 1063, 11, 3519, 284, 262, 7108, 2272, 14753, 13, 198, 198, 2235, 31458, 198, 198, 58, 16, 5974, 1279, 20608, 29, 1635, 316, 435, 15885, 366, 6690, 33928, 7686, 851, 257, 5337, 23457, 329, 1729, 29127, 640, 2168, 3781, 1600, 198, 9, 3791, 4913, 286, 23123, 9, 1105, 11, 7643, 1270, 1495, 357, 10333, 8, 198, 58, 18227, 40, 25, 940, 13, 940, 3459, 14, 1485, 3134, 12, 2075, 1270, 14, 1065, 14, 18, 14, 3070, 1270, 1495, 16151, 5450, 1378, 34023, 13, 2398, 14, 940, 13, 940, 3459, 14, 1485, 3134, 12, 2075, 1270, 14, 1065, 14, 18, 14, 3070, 1270, 1495, 8, 198, 198, 58, 17, 5974, 1279, 20608, 29, 1635, 316, 435, 15885, 11, 383, 22939, 286, 23458, 17262, 851, 257, 3716, 3127, 6650, 11, 198, 9, 36, 333, 13, 8687, 13, 449, 15885, 347, 9508, 11, 718, 4310, 1906, 43864, 357, 9804, 8, 198, 58, 18227, 40, 25, 940, 13, 1157, 1821, 14, 538, 73, 65, 14, 68, 9804, 12, 15711, 2079, 12, 16, 16151, 5450, 1378, 34023, 13, 2398, 14, 940, 13, 1157, 1821, 14, 538, 73, 65, 14, 68, 9804, 12, 15711, 2079, 12, 16, 8, 198, 198, 58, 18, 5974, 1279, 20608, 29, 1222, 1279, 20608, 22330, 366, 2202, 262, 6608, 286, 1402, 12, 6894, 3127, 4981, 1600, 198, 9, 464, 3427, 16331, 4913, 347, 9, 1511, 11, 642, 2857, 1906, 34135, 357, 11024, 8, 198, 58, 18227, 40, 25, 940, 13, 44318, 14, 82, 3064, 20, 3064, 4059, 3134, 16151, 5450, 1378, 34023, 13, 2398, 14, 940, 13, 44318, 14, 82, 3064, 20, 3064, 4059, 3134, 8, 198, 37811, 198, 8818, 374, 2616, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 220, 220, 220, 4823, 796, 17427, 37065, 7, 22046, 986, 26, 479, 86, 22046, 23029, 198, 220, 220, 220, 1441, 360, 713, 90, 13940, 23650, 11, 48436, 2414, 92, 7, 198, 220, 220, 220, 220, 220, 220, 220, 1058, 43337, 5218, 12109, 7, 34960, 828, 198, 220, 220, 220, 220, 220, 220, 220, 1058, 7645, 11365, 5218, 3298, 62, 565, 436, 1586, 62, 1073, 16814, 7, 34960, 828, 198, 220, 220, 220, 220, 220, 220, 220, 1058, 23913, 6978, 5218, 2811, 6978, 7, 34960, 828, 198, 220, 220, 220, 220, 220, 220, 220, 1058, 67, 13173, 5218, 14753, 7, 34960, 8, 198, 220, 220, 220, 1267, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 2811, 6978, 7, 34960, 8, 198, 198, 9771, 3129, 689, 2811, 5288, 3108, 4129, 329, 257, 17427, 37065, 13, 198, 5842, 274, 2094, 1008, 11, 3050, 11, 412, 80, 13, 2608, 319, 23241, 13, 1248, 13, 198, 37811, 198, 8818, 2811, 6978, 7, 34960, 3712, 26437, 37065, 8, 198, 220, 220, 220, 997, 62, 24040, 796, 299, 85, 7, 34960, 8, 628, 220, 220, 220, 1233, 62, 6759, 796, 781, 12192, 62, 86, 5406, 439, 62, 19509, 395, 62, 6978, 82, 7, 34960, 737, 67, 1023, 198, 220, 220, 220, 2488, 13, 1233, 62, 6759, 58, 17080, 62, 6759, 6624, 2170, 368, 897, 7, 17080, 62, 6759, 15437, 796, 657, 13, 628, 220, 220, 220, 1441, 2160, 7, 17080, 62, 6759, 8, 1220, 357, 22510, 62, 24040, 1635, 357, 22510, 62, 24040, 532, 352, 4008, 198, 437, 198 ]
3.034188
819
# This file is auto-generated by AWSMetadata.jl using AWS using AWS.AWSServices: workmailmessageflow using AWS.Compat using AWS.UUIDs """ GetRawMessageContent() Retrieves the raw content of an in-transit email message, in MIME format. # Required Parameters - `messageId`: The identifier of the email message to retrieve. """ get_raw_message_content(messageId; aws_config::AWSConfig=global_aws_config()) = workmailmessageflow("GET", "/messages/$(messageId)"; aws_config=aws_config) get_raw_message_content(messageId, args::AbstractDict{String, <:Any}; aws_config::AWSConfig=global_aws_config()) = workmailmessageflow("GET", "/messages/$(messageId)", args; aws_config=aws_config)
[ 2, 770, 2393, 318, 8295, 12, 27568, 416, 30865, 9171, 14706, 13, 20362, 198, 3500, 30865, 198, 3500, 30865, 13, 12298, 5432, 712, 1063, 25, 670, 4529, 20500, 11125, 198, 198, 3500, 30865, 13, 40073, 198, 3500, 30865, 13, 52, 27586, 82, 198, 37811, 198, 220, 220, 220, 3497, 27369, 12837, 19746, 3419, 198, 198, 9781, 5034, 1158, 262, 8246, 2695, 286, 281, 287, 12, 7645, 270, 3053, 3275, 11, 287, 337, 12789, 5794, 13, 220, 198, 198, 2, 20906, 40117, 198, 12, 4600, 20500, 7390, 63, 25, 383, 27421, 286, 262, 3053, 3275, 284, 19818, 13, 198, 198, 37811, 198, 198, 1136, 62, 1831, 62, 20500, 62, 11299, 7, 20500, 7390, 26, 3253, 82, 62, 11250, 3712, 12298, 50, 16934, 28, 20541, 62, 8356, 62, 11250, 28955, 796, 670, 4529, 20500, 11125, 7203, 18851, 1600, 12813, 37348, 1095, 32624, 7, 20500, 7390, 8, 8172, 3253, 82, 62, 11250, 28, 8356, 62, 11250, 8, 198, 1136, 62, 1831, 62, 20500, 62, 11299, 7, 20500, 7390, 11, 26498, 3712, 23839, 35, 713, 90, 10100, 11, 1279, 25, 7149, 19629, 3253, 82, 62, 11250, 3712, 12298, 50, 16934, 28, 20541, 62, 8356, 62, 11250, 28955, 796, 670, 4529, 20500, 11125, 7203, 18851, 1600, 12813, 37348, 1095, 32624, 7, 20500, 7390, 42501, 26498, 26, 3253, 82, 62, 11250, 28, 8356, 62, 11250, 8, 198 ]
3.113122
221
using InformationInequalities using Test @testset "InformationInequalities.jl" begin # Write your tests here. end
[ 3500, 6188, 40, 710, 13255, 871, 198, 3500, 6208, 198, 198, 31, 9288, 2617, 366, 21918, 40, 710, 13255, 871, 13, 20362, 1, 2221, 198, 220, 220, 220, 1303, 19430, 534, 5254, 994, 13, 198, 437, 198 ]
3.216216
37
<reponame>IngiOrn/AQFED.jl using AQFED, Test import AQFED.PLN: EtoreGobetPLNPricer, LeFlochLehmanPLNPricer, priceEuropean import AQFED.TermStructure: CapitalizedDividend, Dividend, futureValue import AQFED.Basket: DeelstraBasketPricer, DeelstraLBBasketPricer @testset "EtoreGobetSingle" begin spot = 100.0 vol = 0.3 discountRate = 0.0 divAmount = 7.0 tte = 1.0 ttd = 0.9 * tte ttp = tte isCall = true discountFactor = exp(-discountRate * ttp) dividends = Vector{CapitalizedDividend}(undef, 1) #amount::T exDate::Float64 payDate::Float64 isProportional::bool isKnown::bool dividends[1] = CapitalizedDividend(Dividend(divAmount, ttd, ttd, false, false), exp((tte - ttd) * discountRate)) println("S Model Price Error") eg2 = EtoreGobetPLNPricer(2) eg3 = EtoreGobetPLNPricer(3) ll2 = LeFlochLehmanPLNPricer(2) ll3 = LeFlochLehmanPLNPricer(3) d = DeelstraBasketPricer(1, 3) dlb = DeelstraLBBasketPricer(1, 3) refHHL = [43.24845580, 9.07480013, 1.06252880, 0.10473887] refEg2 = [43.24846889, 9.07479039, 1.06253441, 0.10474035] refEg3 = [43.24845582, 9.07480026, 1.06252875, 0.10473885] for (i, strike) in enumerate(LinRange(50.0, 200.0, 4)) price = priceEuropean( eg2, isCall, strike, spot * exp(tte * discountRate), vol * vol * tte, tte, discountFactor, dividends, ) println(strike, " EG-2 ", price, " ", price - refHHL[i]) @test isapprox(refEg2[i], price, atol = 1e-8) price = priceEuropean( eg3, isCall, strike, spot * exp(tte * discountRate), vol * vol * tte, tte, discountFactor, dividends, ) println(strike, " EG-3 ", price, " ", price - refHHL[i]) @test isapprox(refEg3[i], price, atol = 1e-8) price = priceEuropean( ll2, isCall, strike, spot * exp(tte * discountRate), vol * vol * tte, tte, discountFactor, dividends, ) println(strike, " LL-2 ", price, " ", price - refHHL[i]) price = priceEuropean( ll3, isCall, strike, spot * exp(tte * discountRate), vol * vol * tte, tte, discountFactor, dividends, ) println(strike, " LL-3 ", price, " ", price - refHHL[i]) price = AQFED.Basket.priceEuropean( d, isCall, strike, spot * exp(tte * discountRate), vol * vol * tte, tte, discountFactor, dividends, ) println(strike, " Deelstra ", price, " ", price - refHHL[i]) price = AQFED.Basket.priceEuropean( dlb, isCall, strike, spot * exp(tte * discountRate), vol * vol * tte, tte, discountFactor, dividends, ) println(strike, " Deelstra-LB ", price, " ", price - refHHL[i]) end end @testset "MultipleVellekoop" begin spot = 100.0 σ = 0.25 discountRate = 0.06 tte = 7.0 isCall = true ttd = 0.9 dividends = [CapitalizedDividend(Dividend(6.0, ttd, ttd, false, false), exp((tte - ttd) * discountRate)), CapitalizedDividend(Dividend(6.5, ttd + 1, ttd + 1, false, false), exp((tte - ttd - 1) * discountRate)), CapitalizedDividend(Dividend(7.0, ttd + 2, ttd + 2, false, false), exp((tte - ttd - 2) * discountRate)), CapitalizedDividend(Dividend(7.5, ttd + 3, ttd + 3, false, false), exp((tte - ttd - 3) * discountRate)), CapitalizedDividend(Dividend(8.0, ttd + 4, ttd + 4, false, false), exp((tte - ttd - 4) * discountRate)), CapitalizedDividend(Dividend(8.0, ttd + 5, ttd + 5, false, false), exp((tte - ttd - 5) * discountRate)), CapitalizedDividend(Dividend(8.0, ttd + 6, ttd + 6, false, false), exp((tte - ttd - 6) * discountRate))] rawForward = spot * exp(discountRate * tte) df = exp(-discountRate * tte) ll3 = LeFlochLehmanPLNPricer(3) d = DeelstraBasketPricer(3, 3) dlb = DeelstraLBBasketPricer(3, 3) refPrices = [ 34.19664044, 30.49396147, 27.21393776, 24.31297892, 21.74885502, 19.48228598, 17.47762235, 15.70300783, 14.13025908, 12.73460326, 11.49435473, ] f = spot * exp(discountRate * tte) - sum(futureValue(cd) for cd in dividends) for (i, strike) in enumerate(LinRange(50.0, 150.0, 11)) refVol = Black.impliedVolatility(isCall, refPrices[i], f, strike, tte, df) price = priceEuropean(ll3, isCall, strike, rawForward, σ^2 * tte, tte, df, dividends) vol = Black.impliedVolatility(isCall, price, f, strike, tte, df) println(strike, " LL-3 ", price, " ", price / refPrices[i] - 1, " ", vol - refVol) price = AQFED.Basket.priceEuropean(d, isCall, strike, rawForward, σ^2 * tte, tte, df, dividends) vol = Black.impliedVolatility(isCall, price, f, strike, tte, df) println(strike, " Deelstra ", price, " ", price / refPrices[i] - 1, " ", vol - refVol) price = AQFED.Basket.priceEuropean(dlb, isCall, strike, rawForward, σ^2 * tte, tte, df, dividends) vol = Black.impliedVolatility(isCall, price, f, strike, tte, df) println(strike, " Deelstra-LB ", price, " ", price / refPrices[i] - 1, " ", vol - refVol) end end @testset "MultipleGocsei" begin spot = 100.0 σ = 0.25 discountRate = 0.03 divAmount = 2.0 tte = 10.0 isCall = true ttd0 = 1.0 / 365 dividends = Vector{CapitalizedDividend}(undef, 20) for i = 1:20 ttd = ttd0 + (i - 1) / 2 dividends[i] = CapitalizedDividend(Dividend(divAmount, ttd, ttd, false, false), exp((tte - ttd) * discountRate)) end rawForward = spot * exp(discountRate * tte) df = exp(-discountRate * tte) ll3 = LeFlochLehmanPLNPricer(3) d = DeelstraBasketPricer(1, 3) #1,3 minimizes relative error in price, 3,3 minimizes volatility error dlb = DeelstraLBBasketPricer(1, 3) refPrices = [37.25772649, 28.59516740, 22.28192756, 17.61042951, 14.09731856, 11.41453970, 9.33695198] f = spot * exp(discountRate * tte) - sum(futureValue(cd) for cd in dividends) for (i, strike) in enumerate(LinRange(50.0, 200.0, 7)) refVol = Black.impliedVolatility(isCall, refPrices[i], f, strike, tte, df) price = priceEuropean(ll3, isCall, strike, rawForward, σ^2 * tte, tte, df, dividends) vol = Black.impliedVolatility(isCall, price, f, strike, tte, df) println(strike, " LL-3 ", price, " ", price / refPrices[i] - 1, " ", vol - refVol) price = AQFED.Basket.priceEuropean(d, isCall, strike, rawForward, σ^2 * tte, tte, df, dividends) vol = Black.impliedVolatility(isCall, price, f, strike, tte, df) println(strike, " Deelstra ", price, " ", price / refPrices[i] - 1, " ", vol - refVol) price = AQFED.Basket.priceEuropean(dlb, isCall, strike, rawForward, σ^2 * tte, tte, df, dividends) vol = Black.impliedVolatility(isCall, price, f, strike, tte, df) println(strike, " Deelstra-LB ", price, " ", price / refPrices[i] - 1, " ", vol - refVol) end end
[ 27, 7856, 261, 480, 29, 27682, 72, 5574, 77, 14, 32, 48, 37, 1961, 13, 20362, 198, 3500, 39514, 37, 1961, 11, 6208, 198, 11748, 39514, 37, 1961, 13, 6489, 45, 25, 17906, 382, 38, 672, 316, 6489, 22182, 1173, 263, 11, 1004, 7414, 5374, 3123, 71, 805, 6489, 22182, 1173, 263, 11, 2756, 22030, 198, 11748, 39514, 37, 1961, 13, 40596, 1273, 5620, 25, 9747, 1143, 35, 1699, 437, 11, 360, 1699, 437, 11, 2003, 11395, 198, 11748, 39514, 37, 1961, 13, 33, 11715, 25, 1024, 417, 12044, 33, 11715, 47, 1173, 263, 11, 1024, 417, 12044, 43, 15199, 11715, 47, 1173, 263, 198, 198, 31, 9288, 2617, 366, 36, 83, 382, 38, 672, 316, 28008, 1, 2221, 198, 220, 220, 220, 4136, 796, 1802, 13, 15, 198, 220, 220, 220, 2322, 796, 657, 13, 18, 198, 220, 220, 220, 9780, 32184, 796, 657, 13, 15, 198, 220, 220, 220, 2659, 31264, 796, 767, 13, 15, 198, 220, 220, 220, 256, 660, 796, 352, 13, 15, 198, 220, 220, 220, 256, 8671, 796, 657, 13, 24, 1635, 256, 660, 198, 220, 220, 220, 256, 34788, 796, 256, 660, 198, 220, 220, 220, 318, 14134, 796, 2081, 198, 220, 220, 220, 9780, 41384, 796, 1033, 32590, 15410, 608, 32184, 1635, 256, 34788, 8, 198, 220, 220, 220, 26360, 796, 20650, 90, 39315, 1143, 35, 1699, 437, 92, 7, 917, 891, 11, 352, 8, 198, 220, 220, 220, 1303, 17287, 3712, 51, 220, 220, 220, 220, 220, 220, 220, 409, 10430, 3712, 43879, 2414, 220, 220, 220, 220, 220, 220, 220, 1414, 10430, 3712, 43879, 2414, 220, 220, 220, 220, 220, 220, 220, 318, 2964, 634, 1538, 3712, 30388, 220, 220, 220, 220, 220, 220, 220, 318, 29870, 3712, 30388, 198, 220, 220, 220, 26360, 58, 16, 60, 796, 198, 220, 220, 220, 220, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 7146, 31264, 11, 256, 8671, 11, 256, 8671, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 8, 1635, 9780, 32184, 4008, 198, 220, 220, 220, 44872, 7203, 50, 9104, 7886, 13047, 4943, 198, 220, 220, 220, 29206, 17, 796, 17906, 382, 38, 672, 316, 6489, 22182, 1173, 263, 7, 17, 8, 198, 220, 220, 220, 29206, 18, 796, 17906, 382, 38, 672, 316, 6489, 22182, 1173, 263, 7, 18, 8, 628, 220, 220, 220, 32660, 17, 796, 1004, 7414, 5374, 3123, 71, 805, 6489, 22182, 1173, 263, 7, 17, 8, 198, 220, 220, 220, 32660, 18, 796, 1004, 7414, 5374, 3123, 71, 805, 6489, 22182, 1173, 263, 7, 18, 8, 198, 220, 220, 220, 288, 796, 1024, 417, 12044, 33, 11715, 47, 1173, 263, 7, 16, 11, 513, 8, 198, 220, 220, 220, 288, 23160, 796, 1024, 417, 12044, 43, 15199, 11715, 47, 1173, 263, 7, 16, 11, 513, 8, 198, 220, 220, 220, 1006, 39, 6581, 796, 685, 3559, 13, 23045, 30505, 1795, 11, 860, 13, 2998, 2780, 405, 1485, 11, 352, 13, 3312, 1495, 2078, 1795, 11, 657, 13, 940, 2857, 2548, 5774, 60, 198, 220, 220, 220, 1006, 36, 70, 17, 796, 685, 3559, 13, 1731, 5705, 3104, 4531, 11, 860, 13, 2998, 2857, 3829, 2670, 11, 352, 13, 3312, 28592, 39710, 11, 657, 13, 940, 2857, 1821, 2327, 60, 198, 220, 220, 220, 1006, 36, 70, 18, 796, 685, 3559, 13, 23045, 2231, 46044, 11, 860, 13, 2998, 2780, 405, 2075, 11, 352, 13, 3312, 1495, 2078, 2425, 11, 657, 13, 940, 2857, 2548, 5332, 60, 198, 220, 220, 220, 329, 357, 72, 11, 5587, 8, 287, 27056, 378, 7, 14993, 17257, 7, 1120, 13, 15, 11, 939, 13, 15, 11, 604, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2756, 22030, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29206, 17, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 14134, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5587, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4136, 1635, 1033, 7, 83, 660, 1635, 9780, 32184, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2322, 1635, 2322, 1635, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9780, 41384, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26360, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 41513, 12, 17, 33172, 2756, 11, 366, 33172, 2756, 532, 1006, 39, 6581, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 5420, 36, 70, 17, 58, 72, 4357, 2756, 11, 379, 349, 796, 352, 68, 12, 23, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2756, 22030, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29206, 18, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 14134, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5587, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4136, 1635, 1033, 7, 83, 660, 1635, 9780, 32184, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2322, 1635, 2322, 1635, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9780, 41384, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26360, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 41513, 12, 18, 33172, 2756, 11, 366, 33172, 2756, 532, 1006, 39, 6581, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 1324, 13907, 7, 5420, 36, 70, 18, 58, 72, 4357, 2756, 11, 379, 349, 796, 352, 68, 12, 23, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2756, 22030, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 32660, 17, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 14134, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5587, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4136, 1635, 1033, 7, 83, 660, 1635, 9780, 32184, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2322, 1635, 2322, 1635, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9780, 41384, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26360, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 27140, 12, 17, 33172, 2756, 11, 366, 33172, 2756, 532, 1006, 39, 6581, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2756, 22030, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 32660, 18, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 14134, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5587, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4136, 1635, 1033, 7, 83, 660, 1635, 9780, 32184, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2322, 1635, 2322, 1635, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9780, 41384, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26360, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 27140, 12, 18, 33172, 2756, 11, 366, 33172, 2756, 532, 1006, 39, 6581, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 39514, 37, 1961, 13, 33, 11715, 13, 20888, 22030, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 14134, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5587, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4136, 1635, 1033, 7, 83, 660, 1635, 9780, 32184, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2322, 1635, 2322, 1635, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9780, 41384, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26360, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 1024, 417, 12044, 33172, 2756, 11, 366, 33172, 2756, 532, 1006, 39, 6581, 58, 72, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 39514, 37, 1961, 13, 33, 11715, 13, 20888, 22030, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 23160, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 14134, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5587, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4136, 1635, 1033, 7, 83, 660, 1635, 9780, 32184, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2322, 1635, 2322, 1635, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 660, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9780, 41384, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26360, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 1024, 417, 12044, 12, 30501, 33172, 2756, 11, 366, 33172, 2756, 532, 1006, 39, 6581, 58, 72, 12962, 628, 220, 220, 220, 886, 198, 198, 437, 628, 198, 198, 31, 9288, 2617, 366, 31217, 53, 13485, 7204, 404, 1, 2221, 198, 220, 220, 220, 4136, 796, 1802, 13, 15, 198, 220, 220, 220, 18074, 225, 796, 657, 13, 1495, 198, 220, 220, 220, 9780, 32184, 796, 657, 13, 3312, 198, 220, 220, 220, 256, 660, 796, 767, 13, 15, 198, 220, 220, 220, 318, 14134, 796, 2081, 198, 220, 220, 220, 256, 8671, 796, 657, 13, 24, 198, 220, 220, 220, 26360, 796, 685, 39315, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 21, 13, 15, 11, 256, 8671, 11, 256, 8671, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 8, 1635, 9780, 32184, 36911, 198, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 21, 13, 20, 11, 256, 8671, 1343, 352, 11, 256, 8671, 1343, 352, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 532, 352, 8, 1635, 9780, 32184, 36911, 198, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 22, 13, 15, 11, 256, 8671, 1343, 362, 11, 256, 8671, 1343, 362, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 532, 362, 8, 1635, 9780, 32184, 36911, 198, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 22, 13, 20, 11, 256, 8671, 1343, 513, 11, 256, 8671, 1343, 513, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 532, 513, 8, 1635, 9780, 32184, 36911, 198, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 23, 13, 15, 11, 256, 8671, 1343, 604, 11, 256, 8671, 1343, 604, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 532, 604, 8, 1635, 9780, 32184, 36911, 198, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 23, 13, 15, 11, 256, 8671, 1343, 642, 11, 256, 8671, 1343, 642, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 532, 642, 8, 1635, 9780, 32184, 36911, 198, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 23, 13, 15, 11, 256, 8671, 1343, 718, 11, 256, 8671, 1343, 718, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 532, 718, 8, 1635, 9780, 32184, 4008, 60, 198, 220, 220, 220, 8246, 39746, 796, 4136, 1635, 1033, 7, 15410, 608, 32184, 1635, 256, 660, 8, 198, 220, 220, 220, 47764, 796, 1033, 32590, 15410, 608, 32184, 1635, 256, 660, 8, 198, 220, 220, 220, 32660, 18, 796, 1004, 7414, 5374, 3123, 71, 805, 6489, 22182, 1173, 263, 7, 18, 8, 198, 220, 220, 220, 288, 796, 1024, 417, 12044, 33, 11715, 47, 1173, 263, 7, 18, 11, 513, 8, 198, 220, 220, 220, 288, 23160, 796, 1024, 417, 12044, 43, 15199, 11715, 47, 1173, 263, 7, 18, 11, 513, 8, 198, 220, 220, 220, 1006, 6836, 1063, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 4974, 13, 44227, 1821, 2598, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1542, 13, 2920, 34107, 20198, 11, 198, 220, 220, 220, 220, 220, 220, 220, 2681, 13, 17, 20219, 2718, 4304, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1987, 13, 18, 18741, 3695, 5892, 11, 198, 220, 220, 220, 220, 220, 220, 220, 2310, 13, 48246, 5332, 35126, 11, 198, 220, 220, 220, 220, 220, 220, 220, 678, 13, 2780, 23815, 41292, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1596, 13, 2857, 4304, 1828, 2327, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1315, 13, 2154, 6200, 50165, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1478, 13, 12952, 25191, 2919, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1105, 13, 22, 2682, 35642, 2075, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1367, 13, 39449, 2327, 37804, 11, 198, 220, 220, 220, 2361, 198, 220, 220, 220, 277, 796, 4136, 1635, 1033, 7, 15410, 608, 32184, 1635, 256, 660, 8, 532, 2160, 7, 37443, 11395, 7, 10210, 8, 329, 22927, 287, 26360, 8, 628, 220, 220, 220, 329, 357, 72, 11, 5587, 8, 287, 27056, 378, 7, 14993, 17257, 7, 1120, 13, 15, 11, 6640, 13, 15, 11, 1367, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 1006, 16598, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 1006, 6836, 1063, 58, 72, 4357, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2756, 22030, 7, 297, 18, 11, 318, 14134, 11, 5587, 11, 8246, 39746, 11, 18074, 225, 61, 17, 1635, 256, 660, 11, 256, 660, 11, 47764, 11, 26360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2322, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 2756, 11, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 27140, 12, 18, 33172, 2756, 11, 366, 33172, 2756, 1220, 1006, 6836, 1063, 58, 72, 60, 532, 352, 11, 366, 33172, 2322, 532, 1006, 16598, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 39514, 37, 1961, 13, 33, 11715, 13, 20888, 22030, 7, 67, 11, 318, 14134, 11, 5587, 11, 8246, 39746, 11, 18074, 225, 61, 17, 1635, 256, 660, 11, 256, 660, 11, 47764, 11, 26360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2322, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 2756, 11, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 1024, 417, 12044, 33172, 2756, 11, 366, 33172, 2756, 1220, 1006, 6836, 1063, 58, 72, 60, 532, 352, 11, 366, 33172, 2322, 532, 1006, 16598, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 39514, 37, 1961, 13, 33, 11715, 13, 20888, 22030, 7, 67, 23160, 11, 318, 14134, 11, 5587, 11, 8246, 39746, 11, 18074, 225, 61, 17, 1635, 256, 660, 11, 256, 660, 11, 47764, 11, 26360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2322, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 2756, 11, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 1024, 417, 12044, 12, 30501, 33172, 2756, 11, 366, 33172, 2756, 1220, 1006, 6836, 1063, 58, 72, 60, 532, 352, 11, 366, 33172, 2322, 532, 1006, 16598, 8, 628, 220, 220, 220, 886, 198, 437, 628, 628, 198, 31, 9288, 2617, 366, 31217, 38, 420, 36455, 1, 2221, 198, 220, 220, 220, 4136, 796, 1802, 13, 15, 198, 220, 220, 220, 18074, 225, 796, 657, 13, 1495, 198, 220, 220, 220, 9780, 32184, 796, 657, 13, 3070, 198, 220, 220, 220, 2659, 31264, 796, 362, 13, 15, 198, 220, 220, 220, 256, 660, 796, 838, 13, 15, 198, 220, 220, 220, 318, 14134, 796, 2081, 198, 220, 220, 220, 256, 8671, 15, 796, 352, 13, 15, 1220, 21268, 198, 220, 220, 220, 26360, 796, 20650, 90, 39315, 1143, 35, 1699, 437, 92, 7, 917, 891, 11, 1160, 8, 198, 220, 220, 220, 329, 1312, 796, 352, 25, 1238, 198, 220, 220, 220, 220, 220, 220, 220, 256, 8671, 796, 256, 8671, 15, 1343, 357, 72, 532, 352, 8, 1220, 362, 198, 220, 220, 220, 220, 220, 220, 220, 26360, 58, 72, 60, 796, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9747, 1143, 35, 1699, 437, 7, 35, 1699, 437, 7, 7146, 31264, 11, 256, 8671, 11, 256, 8671, 11, 3991, 11, 3991, 828, 1033, 19510, 83, 660, 532, 256, 8671, 8, 1635, 9780, 32184, 4008, 198, 220, 220, 220, 886, 198, 220, 220, 220, 8246, 39746, 796, 4136, 1635, 1033, 7, 15410, 608, 32184, 1635, 256, 660, 8, 198, 220, 220, 220, 47764, 796, 1033, 32590, 15410, 608, 32184, 1635, 256, 660, 8, 198, 220, 220, 220, 32660, 18, 796, 1004, 7414, 5374, 3123, 71, 805, 6489, 22182, 1173, 263, 7, 18, 8, 198, 220, 220, 220, 288, 796, 1024, 417, 12044, 33, 11715, 47, 1173, 263, 7, 16, 11, 513, 8, 1303, 16, 11, 18, 10356, 4340, 3585, 4049, 287, 2756, 11, 513, 11, 18, 10356, 4340, 30772, 4049, 198, 220, 220, 220, 288, 23160, 796, 1024, 417, 12044, 43, 15199, 11715, 47, 1173, 263, 7, 16, 11, 513, 8, 198, 220, 220, 220, 1006, 6836, 1063, 796, 685, 2718, 13, 1495, 3324, 2075, 2920, 11, 2579, 13, 35124, 21940, 1821, 11, 2534, 13, 2078, 1129, 1983, 3980, 11, 1596, 13, 39132, 11785, 4349, 11, 1478, 13, 2931, 4790, 1507, 3980, 11, 1367, 13, 19, 18781, 2670, 2154, 11, 860, 13, 2091, 37381, 22337, 60, 198, 220, 220, 220, 277, 796, 4136, 1635, 1033, 7, 15410, 608, 32184, 1635, 256, 660, 8, 532, 2160, 7, 37443, 11395, 7, 10210, 8, 329, 22927, 287, 26360, 8, 628, 220, 220, 220, 329, 357, 72, 11, 5587, 8, 287, 27056, 378, 7, 14993, 17257, 7, 1120, 13, 15, 11, 939, 13, 15, 11, 767, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 1006, 16598, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 1006, 6836, 1063, 58, 72, 4357, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 2756, 22030, 7, 297, 18, 11, 318, 14134, 11, 5587, 11, 8246, 39746, 11, 18074, 225, 61, 17, 1635, 256, 660, 11, 256, 660, 11, 47764, 11, 26360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2322, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 2756, 11, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 27140, 12, 18, 33172, 2756, 11, 366, 33172, 2756, 1220, 1006, 6836, 1063, 58, 72, 60, 532, 352, 11, 366, 33172, 2322, 532, 1006, 16598, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 39514, 37, 1961, 13, 33, 11715, 13, 20888, 22030, 7, 67, 11, 318, 14134, 11, 5587, 11, 8246, 39746, 11, 18074, 225, 61, 17, 1635, 256, 660, 11, 256, 660, 11, 47764, 11, 26360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2322, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 2756, 11, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 1024, 417, 12044, 33172, 2756, 11, 366, 33172, 2756, 1220, 1006, 6836, 1063, 58, 72, 60, 532, 352, 11, 366, 33172, 2322, 532, 1006, 16598, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2756, 796, 39514, 37, 1961, 13, 33, 11715, 13, 20888, 22030, 7, 67, 23160, 11, 318, 14134, 11, 5587, 11, 8246, 39746, 11, 18074, 225, 61, 17, 1635, 256, 660, 11, 256, 660, 11, 47764, 11, 26360, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2322, 796, 2619, 13, 23928, 798, 16598, 18486, 7, 271, 14134, 11, 2756, 11, 277, 11, 5587, 11, 256, 660, 11, 47764, 8, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7, 33069, 11, 366, 1024, 417, 12044, 12, 30501, 33172, 2756, 11, 366, 33172, 2756, 1220, 1006, 6836, 1063, 58, 72, 60, 532, 352, 11, 366, 33172, 2322, 532, 1006, 16598, 8, 628, 220, 220, 220, 886, 198, 437, 198 ]
2.030715
3,679
<reponame>andreaskoher/CovidSurvey using DrWatson quickactivate(@__DIR__) @show projectdir() ## ============================================================================ @info "load packages" using CovidSurvey using Random, Dates, Turing using Base.Threads using StatsPlots using PrettyTables using DataFrames using BSON using Memoization using ReverseDiff setadbackend(:reversediff) Turing.setrdcache(true) plotlyjs() @info "number of threads available: $(nthreads())" ## ============================================================================ ps = ( warmup = 100, model = "intdeaths", steps = 100, seed = nothing, observ = nothing, chains = 1, preds = nothing,#"CF,CC,CR,CS",#"CS,MG,MA" semipara=true, rwstep = 7, include= true, std = false, ) ## ============================================================================ # load data @info "load data" data_params = ( observationsend = ps.observ , predictors = ps.preds|> CovidSurvey.parse_predictors # , cases_start = ps.cases # , hospitmodel = Regional.HospitInit1(obs_stop="2020-07-01") , rwstep = ps.rwstep , epidemicstart = Date("2020-08-01") , numimpute = 20 , include_early_dynamic = ps.include , link = KLogistic(4.5) , invlink = KLogit(4.5) , predictive = false , covariates_kwargs = Dict( :semiparametric => ps.semipara, :fname => [projectdir("data/contacts/int/smoothed_contact_rates_region=$(r).csv" ) for r in International.regions],#[projectdir("data", "mean_contact_rates_region=$r.csv" ) for r in 1:Regional.nregions], :shift => -1, :conditions => :date => x->x>Date("2020-11-10"), # >= 1000 cases / day # :datecol => "date", :aggregation => ps.rwstep, :standardize => ps.std, :normalize => true, :mobility => [projectdir("data/mobility/mobility_country=$(r).csv") for r in International.regions] ) ) data = International.load_data(; data_params... ) d = turing_data = data.turing_data; ## ============================================================================ @info "prepare model" model = Regional.model_deaths model = Regional.model_international_deaths #!isnothing(ps.seed) && Random.seed!(ps.seed); @info ps m = model(turing_data; vectorize=true) m(); ## ============================================================================ @info "start sampling" @time chain = let #460s; 366s thinning = 1 if ps.chains > 1 sample(m, NUTS(ps.warmup, 0.9; max_depth=6), MCMCThreads(), ps.steps + ps.warmup, ps.chains; progress=true, thinning) else sample(m, NUTS(ps.warmup, 0.9; max_depth=6), ps.steps + ps.warmup; progress=true, thinning) #; max_depth=15 end end divervences = sum( chain[ps.warmup+1:end, :numerical_error, :] ) @show divervences ## ========================================================================== @info "save" fdir = projectdir("reports/tmp", "$(today())") fname = Regional.save_results(fdir, ps, data, chain) ## ========================================================================== @info "post processing" Regional.postprocessing(fname; plot_results=false) ## ========================================================================== ## ========================================================================== @info "post processing" fdir, ps, ignores = Regional.parse_fname(fname) p = Regional.PostProcessing2(fdir, ps, ignores, [], fname) ## ========================================================================== @info "plot chain" plot_results = true Regional.plot_chains(p; plot_results) ## ========================================================================== @info "meanplot" Regional.plot_means(p; plot_results) ## ========================================================================== # perform diagnostics p = Regional.skip_warmup(p) Regional.diagnostics(p) data.cases ## ========================================================================== @info "make predictions" gp = Regional.generate_posterior(p); ## ========================================================================== @info "plot regions" Regional.plot_regions(p, gp; plot_results=true) ## ========================================================================== @info "plot predictors" # pgfplotsx() # default(titlefontsize = 20, legendfontsize = 18, labelfontsize = 18, guidefontsize = 18, tickfontsize = 12, framestyle = :zerolines, yminorgrid = true) Regional.plot_effects(p, gp; plot_results , grouped = false, effect_on_Rt = 0.) Regional.plot_effects(p, gp; plot_results, grouped = false, effect_on_Rt = 2.) Regional.plot_effects(p, gp; plot_results, grouped = false, effect_on_Rt = -0.5) Regional.plot_effects(p, gp; plot_results, grouped = true, effect_on_Rt = 0.) Regional.plot_effects(p, gp; plot_results, grouped = true, effect_on_Rt = 2.) Regional.plot_effects(p, gp; plot_results, grouped = true, effect_on_Rt = -0.5) ## =================================================================== TV = Vector{Float64} V = Float64 vectorize = true θ = turing_data @unpack num_observations, num_total_days, num_regions, num_rt_steps, deathmodel, num_covariates, rwscale, include_early_dynamic,init_infected = θ # If we don't want to predict the future, we only need to compute up-to time-step `num_obs_countries[m]` num_time_steps = num_observations ############# 2.) time varying reproduction number R0_std = truncated(Normal(.5, .2), 0.01, Inf) |> rand R0s = filldist(truncated(Normal(0.8, R0_std), 0., 4.5), num_regions) |> rand σ_rt = truncated(Normal(0.3*rwscale, .02*rwscale), 0, .5*rwscale) |> rand n = first( num_rt_steps ) latent_Rts_z = filldist( CovidSurvey.RandomWalk( n ), num_regions) |> rand latent_Rts = CovidSurvey.rescale( latent_Rts_z, σ_rt, d.invlink.(R0s) ) Rts = TV[TV(undef, num_time_steps[m]) for m in 1:num_regions] if num_covariates > 0 grouped_effect = filldist( Laplace(0,0.2), num_covariates) |> rand effect_std = filldist( GammaMeanCv(0.1, 0.5), num_covariates) |> rand effects_z = filldist( MvNormal( num_covariates, 1.), num_regions) |> rand effects = [ effects_z[:,m] .* effect_std .+ grouped_effect for m in 1:num_regions] # grouped_effect = filldist( Exponential(0.2), num_covariates) # effect_std = filldist( GammaMeanCv(0.1, 0.5), num_covariates) # pooled_effects_distr_raw = Normal.( grouped_effect, effect_std ) # pooled_effects_distr = arraydist( truncated.( pooled_effects_distr_raw, zero(V), V(Inf) ) ) # effects = filldist( pooled_effects_distr, num_regions ) if θ.semiparametric CovidSurvey.semiparametric!(Rts, θ, false, latent_Rts, R0s, σ_rt, effects) else CovidSurvey.mixed!(Rts, θ, false, latent_Rts, R0s, σ_rt, effects) end else CovidSurvey.random_walks!(Rts, θ, false, latent_Rts, R0s, σ_rt) end plot(latent_Rts_z[:,3], ticks=:native) plot(θ.link.(latent_Rts[:,1]), ticks=:native) plot(d.dates[1], Rts[1], ticks=:native) ############ 3.) infection dynamics ys = arraydist(Exponential.(init_infected)) |> rand newly_infecteds = TV[TV(undef, num_time_steps[m]) for m in 1:num_regions] CovidSurvey.infections!(newly_infecteds, θ, ys, Rts) plot(d.dates[1], newly_infecteds[1], ticks=:native) # infections!(newly_infecteds, cumulative_infecteds, effective_Rts, θ, τ, ys, Rts) ########### 4.) derive observables μ_i2d = truncated(Normal(21.82, 1.01), 18, 24) |> rand σ_i2d = truncated(Normal(4.26, 5.18), 1, 14) |> rand idr = truncated(Normal(8/1000, 1/1000), 1/1000, 15/1000) |> rand ϕ_d = truncated(Normal(50, 10), 20, Inf) |> rand weekdayeffect_simplex = filldist(Dirichlet([7,7,7,7,7,3,1]), num_regions) |> rand weekdayeffect = TV[TV(undef, 7) for m in 1:num_regions] CovidSurvey.weekdayeffect!(weekdayeffect, weekdayeffect_simplex) ### holiday effect holidayeffect = filldist(Beta(1,1), num_regions) |> rand expected_daily_deaths = TV[TV(undef, num_time_steps[m]) for m in 1:num_regions] deaths_observation_model = CovidSurvey.WeekdayHolidayObsModel2( deathmodel, μ_i2d, σ_i2d, idr, ϕ_d, expected_daily_deaths, weekdayeffect, holidayeffect, vectorize ) # deaths_observation_model = CovidSurvey.SimpleObsModel2(deathmodel, μ_i2d, σ_i2d, idr, ϕ_d, expected_daily_deaths, vectorize) CovidSurvey.expected!(deaths_observation_model, newly_infecteds) plot(d.dates[1], expected_daily_deaths[1], ticks=:native) ########### 4.) compare model to observations ## 4.1) observe hospitalizations ℓ = zero(V) ℓ += CovidSurvey.logpdf(deaths_observation_model, θ.deaths)
[ 27, 7856, 261, 480, 29, 49078, 2093, 78, 372, 14, 34, 709, 312, 14214, 3304, 198, 3500, 1583, 54, 13506, 198, 24209, 39022, 7, 31, 834, 34720, 834, 8, 198, 31, 12860, 1628, 15908, 3419, 198, 198, 2235, 38093, 2559, 18604, 198, 31, 10951, 366, 2220, 10392, 1, 198, 3500, 39751, 312, 14214, 3304, 198, 3500, 14534, 11, 44712, 11, 39141, 198, 3500, 7308, 13, 16818, 82, 198, 3500, 20595, 3646, 1747, 198, 3500, 20090, 51, 2977, 198, 3500, 6060, 35439, 198, 3500, 347, 11782, 198, 198, 3500, 4942, 78, 1634, 198, 3500, 31849, 28813, 198, 2617, 324, 1891, 437, 7, 25, 260, 690, 276, 733, 8, 198, 51, 870, 13, 2617, 4372, 23870, 7, 7942, 8, 198, 198, 29487, 306, 8457, 3419, 198, 31, 10951, 366, 17618, 286, 14390, 1695, 25, 29568, 77, 16663, 82, 3419, 16725, 198, 2235, 38093, 2559, 18604, 198, 198, 862, 796, 357, 5814, 929, 796, 1802, 11, 198, 220, 220, 220, 2746, 220, 796, 366, 600, 22595, 82, 1600, 198, 220, 220, 220, 4831, 220, 796, 1802, 11, 198, 220, 220, 220, 9403, 220, 220, 796, 2147, 11, 198, 220, 220, 220, 3799, 796, 2147, 11, 198, 220, 220, 220, 14659, 796, 352, 11, 198, 220, 220, 220, 2747, 82, 796, 2147, 11, 2, 1, 22495, 11, 4093, 11, 9419, 11, 7902, 1600, 2, 1, 7902, 11, 20474, 11, 5673, 1, 198, 220, 220, 220, 5026, 541, 3301, 28, 7942, 11, 198, 220, 220, 220, 374, 86, 9662, 796, 767, 11, 198, 220, 220, 220, 2291, 28, 2081, 11, 198, 220, 220, 220, 14367, 796, 3991, 11, 198, 8, 198, 2235, 38093, 2559, 18604, 198, 2, 3440, 1366, 198, 31, 10951, 366, 2220, 1366, 1, 198, 198, 7890, 62, 37266, 796, 357, 198, 220, 220, 220, 220, 220, 13050, 437, 220, 796, 26692, 13, 672, 3168, 198, 220, 220, 220, 837, 4331, 669, 220, 220, 220, 220, 220, 220, 220, 796, 26692, 13, 28764, 82, 91, 29, 39751, 312, 14214, 3304, 13, 29572, 62, 79, 17407, 669, 198, 220, 220, 220, 1303, 837, 2663, 62, 9688, 220, 220, 220, 220, 220, 220, 796, 26692, 13, 33964, 198, 220, 220, 220, 1303, 837, 10496, 270, 19849, 220, 220, 220, 220, 220, 220, 796, 15994, 13, 39, 2117, 270, 31768, 16, 7, 8158, 62, 11338, 2625, 42334, 12, 2998, 12, 486, 4943, 198, 220, 220, 220, 837, 374, 86, 9662, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 796, 26692, 13, 31653, 9662, 198, 220, 220, 220, 837, 18195, 9688, 220, 220, 220, 220, 796, 7536, 7203, 42334, 12, 2919, 12, 486, 4943, 198, 220, 220, 220, 837, 997, 11011, 1133, 220, 220, 220, 220, 220, 220, 220, 220, 796, 1160, 198, 220, 220, 220, 837, 2291, 62, 11458, 62, 67, 28995, 796, 26692, 13, 17256, 198, 220, 220, 220, 837, 2792, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 796, 509, 11187, 2569, 7, 19, 13, 20, 8, 198, 220, 220, 220, 837, 800, 8726, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 796, 509, 11187, 270, 7, 19, 13, 20, 8, 198, 220, 220, 220, 837, 33344, 220, 220, 220, 220, 220, 220, 220, 796, 3991, 198, 220, 220, 220, 837, 44829, 689, 62, 46265, 22046, 796, 360, 713, 7, 198, 220, 220, 220, 220, 220, 1058, 43616, 541, 41158, 19482, 5218, 26692, 13, 43616, 541, 3301, 11, 198, 220, 220, 220, 220, 220, 1058, 69, 3672, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5218, 685, 16302, 15908, 7203, 7890, 14, 3642, 8656, 14, 600, 14, 5796, 1025, 704, 62, 32057, 62, 9700, 62, 36996, 43641, 7, 81, 737, 40664, 1, 1267, 329, 374, 287, 4037, 13, 2301, 507, 4357, 2, 58, 16302, 15908, 7203, 7890, 1600, 366, 32604, 62, 32057, 62, 9700, 62, 36996, 43641, 81, 13, 40664, 1, 1267, 329, 374, 287, 352, 25, 8081, 1538, 13, 77, 2301, 507, 4357, 198, 220, 220, 220, 220, 220, 1058, 30846, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5218, 532, 16, 11, 198, 220, 220, 220, 220, 220, 1058, 17561, 1756, 220, 220, 220, 220, 5218, 1058, 4475, 5218, 2124, 3784, 87, 29, 10430, 7203, 42334, 12, 1157, 12, 940, 12340, 1303, 18189, 8576, 2663, 1220, 1110, 198, 220, 220, 220, 220, 220, 1303, 1058, 4475, 4033, 220, 220, 220, 220, 220, 220, 220, 5218, 366, 4475, 1600, 198, 220, 220, 220, 220, 220, 1058, 9460, 43068, 220, 220, 220, 5218, 26692, 13, 31653, 9662, 11, 198, 220, 220, 220, 220, 220, 1058, 20307, 1096, 220, 220, 220, 5218, 26692, 13, 19282, 11, 198, 220, 220, 220, 220, 220, 1058, 11265, 1096, 220, 220, 220, 220, 220, 5218, 2081, 11, 198, 220, 220, 220, 220, 220, 1058, 39949, 879, 220, 220, 220, 220, 220, 220, 5218, 685, 16302, 15908, 7203, 7890, 14, 39949, 879, 14, 39949, 879, 62, 19315, 43641, 7, 81, 737, 40664, 4943, 329, 374, 287, 4037, 13, 2301, 507, 60, 198, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 1267, 198, 198, 7890, 796, 4037, 13, 2220, 62, 7890, 7, 26, 1366, 62, 37266, 986, 1267, 198, 67, 796, 256, 870, 62, 7890, 796, 1366, 13, 83, 870, 62, 7890, 26, 198, 2235, 38093, 2559, 18604, 198, 31, 10951, 366, 46012, 533, 2746, 1, 198, 198, 19849, 796, 15994, 13, 19849, 62, 22595, 82, 198, 19849, 796, 15994, 13, 19849, 62, 45609, 62, 22595, 82, 198, 2, 0, 271, 22366, 7, 862, 13, 28826, 8, 11405, 14534, 13, 28826, 0, 7, 862, 13, 28826, 1776, 198, 31, 10951, 26692, 198, 76, 796, 2746, 7, 83, 870, 62, 7890, 26, 15879, 1096, 28, 7942, 8, 198, 76, 9783, 198, 2235, 38093, 2559, 18604, 198, 31, 10951, 366, 9688, 19232, 1, 198, 198, 31, 2435, 6333, 796, 1309, 1303, 34716, 82, 26, 44856, 82, 198, 220, 220, 220, 7888, 768, 796, 352, 198, 220, 220, 220, 611, 26692, 13, 38861, 1875, 352, 198, 220, 220, 220, 220, 220, 220, 220, 6291, 7, 76, 11, 399, 3843, 50, 7, 862, 13, 31975, 929, 11, 657, 13, 24, 26, 3509, 62, 18053, 28, 21, 828, 13122, 9655, 16818, 82, 22784, 26692, 13, 20214, 1343, 26692, 13, 31975, 929, 11, 26692, 13, 38861, 26, 4371, 28, 7942, 11, 7888, 768, 8, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 6291, 7, 76, 11, 399, 3843, 50, 7, 862, 13, 31975, 929, 11, 657, 13, 24, 26, 3509, 62, 18053, 28, 21, 828, 26692, 13, 20214, 1343, 26692, 13, 31975, 929, 26, 4371, 28, 7942, 11, 7888, 768, 8, 1303, 26, 3509, 62, 18053, 28, 1314, 198, 220, 220, 220, 886, 198, 437, 198, 198, 67, 1428, 574, 728, 796, 2160, 7, 6333, 58, 862, 13, 31975, 929, 10, 16, 25, 437, 11, 1058, 77, 6975, 605, 62, 18224, 11, 1058, 60, 1267, 198, 31, 12860, 12312, 574, 728, 198, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 21928, 1, 198, 69, 15908, 796, 1628, 15908, 7203, 48922, 14, 22065, 1600, 17971, 7, 40838, 28955, 4943, 198, 69, 3672, 796, 15994, 13, 21928, 62, 43420, 7, 69, 15908, 11, 26692, 11, 1366, 11, 6333, 8, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 7353, 7587, 1, 198, 8081, 1538, 13, 7353, 36948, 7, 69, 3672, 26, 7110, 62, 43420, 28, 9562, 8, 198, 2235, 38093, 2559, 28, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 7353, 7587, 1, 198, 69, 15908, 11, 26692, 11, 24245, 796, 15994, 13, 29572, 62, 69, 3672, 7, 69, 3672, 8, 198, 79, 796, 15994, 13, 6307, 18709, 278, 17, 7, 69, 15908, 11, 26692, 11, 24245, 11, 685, 4357, 277, 3672, 8, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 29487, 6333, 1, 198, 29487, 62, 43420, 796, 2081, 198, 8081, 1538, 13, 29487, 62, 38861, 7, 79, 26, 7110, 62, 43420, 8, 198, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 32604, 29487, 1, 198, 8081, 1538, 13, 29487, 62, 1326, 504, 7, 79, 26, 7110, 62, 43420, 8, 198, 2235, 38093, 2559, 28, 198, 2, 1620, 6689, 34558, 198, 79, 796, 15994, 13, 48267, 62, 31975, 929, 7, 79, 8, 198, 8081, 1538, 13, 47356, 34558, 7, 79, 8, 198, 7890, 13, 33964, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 15883, 16277, 1, 198, 31197, 796, 15994, 13, 8612, 378, 62, 79, 6197, 1504, 7, 79, 1776, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 29487, 7652, 1, 198, 8081, 1538, 13, 29487, 62, 2301, 507, 7, 79, 11, 27809, 26, 7110, 62, 43420, 28, 7942, 8, 198, 2235, 38093, 2559, 28, 198, 31, 10951, 366, 29487, 4331, 669, 1, 198, 2, 23241, 69, 489, 1747, 87, 3419, 198, 2, 4277, 7, 7839, 10331, 7857, 796, 1160, 11, 8177, 10331, 7857, 796, 1248, 11, 6167, 10331, 7857, 796, 1248, 11, 5698, 10331, 7857, 796, 1248, 11, 4378, 10331, 7857, 796, 1105, 11, 5346, 10992, 796, 1058, 9107, 349, 1127, 11, 331, 1084, 273, 25928, 796, 2081, 8, 198, 8081, 1538, 13, 29487, 62, 34435, 7, 79, 11, 27809, 26, 7110, 62, 43420, 837, 32824, 796, 3991, 11, 1245, 62, 261, 62, 49, 83, 796, 657, 2014, 198, 8081, 1538, 13, 29487, 62, 34435, 7, 79, 11, 27809, 26, 7110, 62, 43420, 11, 32824, 796, 3991, 11, 1245, 62, 261, 62, 49, 83, 796, 362, 2014, 198, 8081, 1538, 13, 29487, 62, 34435, 7, 79, 11, 27809, 26, 7110, 62, 43420, 11, 32824, 796, 3991, 11, 1245, 62, 261, 62, 49, 83, 796, 532, 15, 13, 20, 8, 198, 198, 8081, 1538, 13, 29487, 62, 34435, 7, 79, 11, 27809, 26, 7110, 62, 43420, 11, 32824, 796, 2081, 11, 1245, 62, 261, 62, 49, 83, 796, 657, 2014, 198, 8081, 1538, 13, 29487, 62, 34435, 7, 79, 11, 27809, 26, 7110, 62, 43420, 11, 32824, 796, 2081, 11, 1245, 62, 261, 62, 49, 83, 796, 362, 2014, 198, 8081, 1538, 13, 29487, 62, 34435, 7, 79, 11, 27809, 26, 7110, 62, 43420, 11, 32824, 796, 2081, 11, 1245, 62, 261, 62, 49, 83, 796, 532, 15, 13, 20, 8, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 198, 198, 2235, 38093, 855, 198, 198, 6849, 796, 20650, 90, 43879, 2414, 92, 198, 53, 796, 48436, 2414, 198, 31364, 1096, 796, 2081, 198, 138, 116, 796, 256, 870, 62, 7890, 198, 31, 403, 8002, 997, 62, 672, 3168, 602, 11, 997, 62, 23350, 62, 12545, 11, 997, 62, 2301, 507, 11, 997, 62, 17034, 62, 20214, 11, 1918, 19849, 11, 997, 62, 66, 709, 2743, 689, 11, 374, 86, 9888, 11, 2291, 62, 11458, 62, 67, 28995, 11, 15003, 62, 27816, 276, 796, 7377, 116, 198, 220, 1303, 1002, 356, 836, 470, 765, 284, 4331, 262, 2003, 11, 356, 691, 761, 284, 24061, 510, 12, 1462, 640, 12, 9662, 4600, 22510, 62, 8158, 62, 9127, 1678, 58, 76, 60, 63, 198, 22510, 62, 2435, 62, 20214, 796, 997, 62, 672, 3168, 602, 198, 198, 7804, 4242, 2, 362, 2014, 640, 15874, 20728, 1271, 198, 198, 49, 15, 62, 19282, 220, 220, 220, 220, 796, 40122, 515, 7, 26447, 7, 13, 20, 11, 764, 17, 828, 657, 13, 486, 11, 4806, 8, 930, 29, 43720, 198, 49, 15, 82, 220, 220, 220, 220, 220, 220, 220, 796, 6070, 17080, 7, 2213, 19524, 515, 7, 26447, 7, 15, 13, 23, 11, 371, 15, 62, 19282, 828, 657, 1539, 604, 13, 20, 828, 997, 62, 2301, 507, 8, 930, 29, 43720, 198, 38392, 62, 17034, 220, 220, 220, 220, 220, 220, 796, 40122, 515, 7, 26447, 7, 15, 13, 18, 9, 31653, 9888, 11, 764, 2999, 9, 31653, 9888, 828, 657, 11, 764, 20, 9, 31653, 9888, 8, 930, 29, 43720, 198, 198, 77, 796, 717, 7, 997, 62, 17034, 62, 20214, 1267, 198, 15460, 298, 62, 49, 912, 62, 89, 796, 6070, 17080, 7, 39751, 312, 14214, 3304, 13, 29531, 35963, 7, 299, 10612, 997, 62, 2301, 507, 8, 930, 29, 43720, 198, 15460, 298, 62, 49, 912, 796, 39751, 312, 14214, 3304, 13, 411, 38765, 7, 41270, 62, 49, 912, 62, 89, 11, 18074, 225, 62, 17034, 11, 288, 13, 16340, 8726, 12195, 49, 15, 82, 8, 1267, 628, 198, 198, 49, 912, 796, 3195, 58, 6849, 7, 917, 891, 11, 997, 62, 2435, 62, 20214, 58, 76, 12962, 329, 285, 287, 352, 25, 22510, 62, 2301, 507, 60, 198, 361, 997, 62, 66, 709, 2743, 689, 1875, 657, 198, 220, 220, 220, 32824, 62, 10760, 796, 6070, 17080, 7, 4689, 5372, 7, 15, 11, 15, 13, 17, 828, 997, 62, 66, 709, 2743, 689, 8, 930, 29, 43720, 198, 220, 220, 220, 1245, 62, 19282, 796, 6070, 17080, 7, 43595, 5308, 272, 34, 85, 7, 15, 13, 16, 11, 657, 13, 20, 828, 997, 62, 66, 709, 2743, 689, 8, 930, 29, 43720, 198, 220, 220, 220, 3048, 62, 89, 796, 6070, 17080, 7, 337, 85, 26447, 7, 997, 62, 66, 709, 2743, 689, 11, 352, 12179, 997, 62, 2301, 507, 8, 930, 29, 43720, 198, 220, 220, 220, 3048, 796, 685, 3048, 62, 89, 58, 45299, 76, 60, 764, 9, 1245, 62, 19282, 764, 10, 32824, 62, 10760, 329, 285, 287, 352, 25, 22510, 62, 2301, 507, 60, 628, 220, 220, 220, 1303, 32824, 62, 10760, 796, 6070, 17080, 7, 5518, 35470, 7, 15, 13, 17, 828, 997, 62, 66, 709, 2743, 689, 8, 198, 220, 220, 220, 1303, 1245, 62, 19282, 796, 6070, 17080, 7, 43595, 5308, 272, 34, 85, 7, 15, 13, 16, 11, 657, 13, 20, 828, 997, 62, 66, 709, 2743, 689, 8, 198, 220, 220, 220, 1303, 44762, 62, 34435, 62, 17080, 81, 62, 1831, 796, 14435, 12195, 32824, 62, 10760, 11, 1245, 62, 19282, 1267, 198, 220, 220, 220, 1303, 44762, 62, 34435, 62, 17080, 81, 796, 7177, 17080, 7, 40122, 515, 12195, 44762, 62, 34435, 62, 17080, 81, 62, 1831, 11, 6632, 7, 53, 828, 569, 7, 18943, 8, 1267, 1267, 198, 220, 220, 220, 1303, 3048, 796, 6070, 17080, 7, 44762, 62, 34435, 62, 17080, 81, 11, 997, 62, 2301, 507, 1267, 628, 220, 220, 220, 611, 7377, 116, 13, 43616, 541, 41158, 19482, 198, 220, 220, 220, 220, 220, 220, 220, 39751, 312, 14214, 3304, 13, 43616, 541, 41158, 19482, 0, 7, 49, 912, 11, 7377, 116, 11, 3991, 11, 41270, 62, 49, 912, 11, 371, 15, 82, 11, 18074, 225, 62, 17034, 11, 3048, 8, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 39751, 312, 14214, 3304, 13, 76, 2966, 0, 7, 49, 912, 11, 7377, 116, 11, 3991, 11, 41270, 62, 49, 912, 11, 371, 15, 82, 11, 18074, 225, 62, 17034, 11, 3048, 8, 198, 220, 220, 220, 886, 198, 17772, 198, 220, 220, 220, 39751, 312, 14214, 3304, 13, 25120, 62, 16783, 591, 0, 7, 49, 912, 11, 7377, 116, 11, 3991, 11, 41270, 62, 49, 912, 11, 371, 15, 82, 11, 18074, 225, 62, 17034, 8, 198, 437, 198, 29487, 7, 15460, 298, 62, 49, 912, 62, 89, 58, 45299, 18, 4357, 36066, 28, 25, 30191, 8, 198, 29487, 7, 138, 116, 13, 8726, 12195, 15460, 298, 62, 49, 912, 58, 45299, 16, 46570, 36066, 28, 25, 30191, 8, 198, 29487, 7, 67, 13, 19581, 58, 16, 4357, 371, 912, 58, 16, 4357, 36066, 28, 25, 30191, 8, 198, 7804, 4242, 513, 2014, 10280, 17262, 198, 893, 796, 7177, 17080, 7, 16870, 35470, 12195, 15003, 62, 27816, 276, 4008, 930, 29, 43720, 628, 198, 3605, 306, 62, 27816, 5379, 220, 220, 220, 220, 220, 796, 3195, 58, 6849, 7, 917, 891, 11, 997, 62, 2435, 62, 20214, 58, 76, 12962, 329, 285, 287, 352, 25, 22510, 62, 2301, 507, 60, 198, 34, 709, 312, 14214, 3304, 13, 27816, 507, 0, 7, 3605, 306, 62, 27816, 5379, 11, 7377, 116, 11, 331, 82, 11, 371, 912, 8, 198, 29487, 7, 67, 13, 19581, 58, 16, 4357, 8308, 62, 27816, 5379, 58, 16, 4357, 36066, 28, 25, 30191, 8, 198, 198, 2, 16079, 0, 7, 3605, 306, 62, 27816, 5379, 11, 23818, 62, 27816, 5379, 11, 4050, 62, 49, 912, 11, 7377, 116, 11, 46651, 11, 331, 82, 11, 371, 912, 8, 198, 7804, 21017, 604, 2014, 27099, 3799, 2977, 198, 34703, 62, 72, 17, 67, 796, 40122, 515, 7, 26447, 7, 2481, 13, 6469, 11, 352, 13, 486, 828, 1248, 11, 1987, 8, 930, 29, 43720, 198, 38392, 62, 72, 17, 67, 796, 40122, 515, 7, 26447, 7, 19, 13, 2075, 11, 642, 13, 1507, 828, 352, 11, 1478, 8, 930, 29, 43720, 198, 312, 81, 220, 220, 796, 40122, 515, 7, 26447, 7, 23, 14, 12825, 11, 352, 14, 12825, 828, 352, 14, 12825, 11, 1315, 14, 12825, 8, 930, 29, 43720, 198, 139, 243, 62, 67, 220, 220, 796, 40122, 515, 7, 26447, 7, 1120, 11, 838, 828, 1160, 11, 4806, 8, 930, 29, 43720, 628, 198, 10464, 820, 10760, 62, 14323, 11141, 796, 6070, 17080, 7, 35277, 488, 1616, 26933, 22, 11, 22, 11, 22, 11, 22, 11, 22, 11, 18, 11, 16, 46570, 997, 62, 2301, 507, 8, 930, 29, 43720, 198, 10464, 820, 10760, 796, 3195, 58, 6849, 7, 917, 891, 11, 767, 8, 329, 285, 287, 352, 25, 22510, 62, 2301, 507, 60, 198, 34, 709, 312, 14214, 3304, 13, 10464, 820, 10760, 0, 7, 10464, 820, 10760, 11, 28269, 10760, 62, 14323, 11141, 8, 198, 198, 21017, 9912, 1245, 198, 37689, 10760, 796, 6070, 17080, 7, 43303, 7, 16, 11, 16, 828, 997, 62, 2301, 507, 8, 930, 29, 43720, 198, 198, 40319, 62, 29468, 62, 22595, 82, 220, 220, 220, 796, 3195, 58, 6849, 7, 917, 891, 11, 997, 62, 2435, 62, 20214, 58, 76, 12962, 329, 285, 287, 352, 25, 22510, 62, 2301, 507, 60, 198, 22595, 82, 62, 672, 3168, 341, 62, 19849, 796, 39751, 312, 14214, 3304, 13, 20916, 820, 28115, 2567, 31310, 17633, 17, 7, 198, 220, 220, 220, 1918, 19849, 11, 18919, 62, 72, 17, 67, 11, 18074, 225, 62, 72, 17, 67, 11, 4686, 81, 11, 18074, 243, 62, 67, 11, 2938, 62, 29468, 62, 22595, 82, 11, 28269, 10760, 11, 9912, 10760, 11, 15879, 1096, 198, 8, 198, 198, 2, 7040, 62, 672, 3168, 341, 62, 19849, 796, 39751, 312, 14214, 3304, 13, 26437, 31310, 17633, 17, 7, 22595, 19849, 11, 18919, 62, 72, 17, 67, 11, 18074, 225, 62, 72, 17, 67, 11, 4686, 81, 11, 18074, 243, 62, 67, 11, 2938, 62, 29468, 62, 22595, 82, 11, 15879, 1096, 8, 198, 198, 34, 709, 312, 14214, 3304, 13, 40319, 0, 7, 22595, 82, 62, 672, 3168, 341, 62, 19849, 11, 8308, 62, 27816, 5379, 8, 198, 29487, 7, 67, 13, 19581, 58, 16, 4357, 2938, 62, 29468, 62, 22595, 82, 58, 16, 4357, 36066, 28, 25, 30191, 8, 628, 198, 7804, 21017, 604, 2014, 8996, 2746, 284, 13050, 198, 2235, 604, 13, 16, 8, 12414, 4436, 4582, 198, 198, 158, 226, 241, 220, 796, 6632, 7, 53, 8, 198, 158, 226, 241, 15853, 39751, 312, 14214, 3304, 13, 6404, 12315, 7, 22595, 82, 62, 672, 3168, 341, 62, 19849, 11, 7377, 116, 13, 22595, 82, 8, 198 ]
2.72693
3,186
<filename>src/unresolved/1232.check-if-it-is-a-straight-line.jl # --- # title: 1232. Check If It Is a Straight Line # id: problem1232 # author: <NAME> # date: 2020-10-31 # difficulty: Easy # categories: Array, Math, Geometry # link: <https://leetcode.com/problems/check-if-it-is-a-straight-line/description/> # hidden: true # --- # # You are given an array `coordinates`, `coordinates[i] = [x, y]`, where `[x, # y]` represents the coordinate of a point. Check if these points make a # straight line in the XY plane. # # # # # # **Example 1:** # # ![](https://assets.leetcode.com/uploads/2019/10/15/untitled-diagram-2.jpg) # # # # Input: coordinates = [[1,2],[2,3],[3,4],[4,5],[5,6],[6,7]] # Output: true # # # **Example 2:** # # **![](https://assets.leetcode.com/uploads/2019/10/09/untitled-diagram-1.jpg)** # # # # Input: coordinates = [[1,1],[2,2],[3,4],[4,5],[5,6],[7,7]] # Output: false # # # # # **Constraints:** # # * `2 <= coordinates.length <= 1000` # * `coordinates[i].length == 2` # * `-10^4 <= coordinates[i][0], coordinates[i][1] <= 10^4` # * `coordinates` contains no duplicate point. # # ## @lc code=start using LeetCode ## add your code here: ## @lc code=end
[ 27, 34345, 29, 10677, 14, 403, 411, 5634, 14, 1065, 2624, 13, 9122, 12, 361, 12, 270, 12, 271, 12, 64, 12, 42729, 12, 1370, 13, 20362, 198, 2, 11420, 198, 2, 3670, 25, 1105, 2624, 13, 6822, 1002, 632, 1148, 257, 27680, 6910, 198, 2, 4686, 25, 1917, 1065, 2624, 198, 2, 1772, 25, 1279, 20608, 29, 198, 2, 3128, 25, 12131, 12, 940, 12, 3132, 198, 2, 8722, 25, 16789, 198, 2, 9376, 25, 15690, 11, 16320, 11, 2269, 15748, 198, 2, 2792, 25, 1279, 5450, 1378, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 9122, 12, 361, 12, 270, 12, 271, 12, 64, 12, 42729, 12, 1370, 14, 11213, 15913, 198, 2, 7104, 25, 2081, 198, 2, 11420, 198, 2, 220, 198, 2, 921, 389, 1813, 281, 7177, 4600, 37652, 17540, 47671, 4600, 37652, 17540, 58, 72, 60, 796, 685, 87, 11, 331, 60, 47671, 810, 4600, 58, 87, 11, 198, 2, 331, 60, 63, 6870, 262, 20435, 286, 257, 966, 13, 6822, 611, 777, 2173, 787, 257, 198, 2, 3892, 1627, 287, 262, 41420, 6614, 13, 198, 2, 220, 198, 2, 220, 198, 2, 220, 198, 2, 220, 198, 2, 220, 198, 2, 12429, 16281, 352, 25, 1174, 198, 2, 220, 198, 2, 5145, 58, 16151, 5450, 1378, 19668, 13, 293, 316, 8189, 13, 785, 14, 39920, 14, 23344, 14, 940, 14, 1314, 14, 2797, 7803, 12, 10989, 6713, 12, 17, 13, 9479, 8, 198, 2, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 23412, 25, 22715, 796, 16410, 16, 11, 17, 38430, 17, 11, 18, 38430, 18, 11, 19, 38430, 19, 11, 20, 38430, 20, 11, 21, 38430, 21, 11, 22, 11907, 198, 2, 220, 220, 220, 220, 25235, 25, 2081, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 198, 2, 12429, 16281, 362, 25, 1174, 198, 2, 220, 198, 2, 12429, 0, 58, 16151, 5450, 1378, 19668, 13, 293, 316, 8189, 13, 785, 14, 39920, 14, 23344, 14, 940, 14, 2931, 14, 2797, 7803, 12, 10989, 6713, 12, 16, 13, 9479, 8, 1174, 198, 2, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 23412, 25, 22715, 796, 16410, 16, 11, 16, 38430, 17, 11, 17, 38430, 18, 11, 19, 38430, 19, 11, 20, 38430, 20, 11, 21, 38430, 22, 11, 22, 11907, 198, 2, 220, 220, 220, 220, 25235, 25, 3991, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 198, 2, 220, 198, 2, 220, 198, 2, 12429, 3103, 2536, 6003, 25, 1174, 198, 2, 220, 198, 2, 220, 220, 1635, 4600, 17, 19841, 22715, 13, 13664, 19841, 8576, 63, 198, 2, 220, 220, 1635, 4600, 37652, 17540, 58, 72, 4083, 13664, 6624, 362, 63, 198, 2, 220, 220, 1635, 4600, 12, 940, 61, 19, 19841, 22715, 58, 72, 7131, 15, 4357, 22715, 58, 72, 7131, 16, 60, 19841, 838, 61, 19, 63, 198, 2, 220, 220, 1635, 4600, 37652, 17540, 63, 4909, 645, 23418, 966, 13, 198, 2, 220, 198, 2, 220, 198, 2235, 2488, 44601, 2438, 28, 9688, 198, 3500, 1004, 316, 10669, 198, 198, 2235, 751, 534, 2438, 994, 25, 198, 2235, 2488, 44601, 2438, 28, 437, 198 ]
2.273723
548
# Use baremodule to shave off a few KB from the serialized `.ji` file baremodule Ogg_jll using Base using Base: UUID import JLLWrappers JLLWrappers.@generate_main_file_header("Ogg") JLLWrappers.@generate_main_file("Ogg", UUID("e7412a2a-1a6e-54c0-be00-318e2571c051")) end # module Ogg_jll
[ 2, 5765, 6247, 21412, 284, 34494, 572, 257, 1178, 14204, 422, 262, 11389, 1143, 4600, 13, 7285, 63, 2393, 198, 49382, 21412, 440, 1130, 62, 73, 297, 198, 3500, 7308, 198, 3500, 7308, 25, 471, 27586, 198, 11748, 449, 3069, 36918, 11799, 198, 198, 41, 3069, 36918, 11799, 13, 31, 8612, 378, 62, 12417, 62, 7753, 62, 25677, 7203, 46, 1130, 4943, 198, 41, 3069, 36918, 11799, 13, 31, 8612, 378, 62, 12417, 62, 7753, 7203, 46, 1130, 1600, 471, 27586, 7203, 68, 4524, 1065, 64, 17, 64, 12, 16, 64, 21, 68, 12, 4051, 66, 15, 12, 1350, 405, 12, 36042, 68, 1495, 4869, 66, 2713, 16, 48774, 198, 437, 220, 1303, 8265, 440, 1130, 62, 73, 297, 198 ]
2.416667
120
<gh_stars>0 # This file manages the tests for the `Exceptions.jl` package # A flag to throw the first captured exception back fatalerrors = length(ARGS) > 0 && ARGS[1] == "-f" # A flag to hide additional LoadErrors quiet = length(ARGS) > 0 && ARGS[1] == "-q" # A flag to check if any error occurred anyerrors = false # Specify tests tests_dir = joinpath(@__DIR__, "tests") tests = ["exception.jl"] # Print info println("\e[1;32mRUNNING TESTS\e[0m for `Exceptions.jl`") # Run tests for test in joinpath.(tests_dir, tests) # Run a test try include(test) # If everything is fine, print about that println("\e[1;32mPASSED\e[0m: $(basename(test))") # If error occurred, note that catch e # Alter the global variable global anyerrors = true # Print about the fail println("\e[1;31mFAILED\e[0m: $(basename(test))") # Exit immediately is needed if fatalerrors rethrow(e) # Show the error if needed elseif !quiet showerror(stdout, e, backtrace()) println() end end end # If any errors, throw an exception anyerrors && throw("Some tests have failed.")
[ 27, 456, 62, 30783, 29, 15, 198, 2, 770, 2393, 15314, 262, 5254, 329, 262, 4600, 3109, 11755, 13, 20362, 63, 5301, 198, 198, 2, 317, 6056, 284, 3714, 262, 717, 7907, 6631, 736, 198, 69, 10254, 48277, 796, 4129, 7, 1503, 14313, 8, 1875, 657, 11405, 5923, 14313, 58, 16, 60, 6624, 27444, 69, 1, 198, 198, 2, 317, 6056, 284, 7808, 3224, 8778, 9139, 5965, 198, 39624, 796, 4129, 7, 1503, 14313, 8, 1875, 657, 11405, 5923, 14313, 58, 16, 60, 6624, 27444, 80, 1, 198, 198, 2, 317, 6056, 284, 2198, 611, 597, 4049, 5091, 198, 1092, 48277, 796, 3991, 198, 198, 2, 18291, 1958, 5254, 198, 41989, 62, 15908, 796, 4654, 6978, 7, 31, 834, 34720, 834, 11, 366, 41989, 4943, 198, 41989, 796, 14631, 1069, 4516, 13, 20362, 8973, 198, 198, 2, 12578, 7508, 198, 35235, 7203, 59, 68, 58, 16, 26, 2624, 76, 49, 4944, 15871, 309, 1546, 4694, 59, 68, 58, 15, 76, 329, 4600, 3109, 11755, 13, 20362, 63, 4943, 198, 198, 2, 5660, 5254, 198, 1640, 1332, 287, 4654, 6978, 12195, 41989, 62, 15908, 11, 5254, 8, 628, 220, 220, 220, 1303, 5660, 257, 1332, 198, 220, 220, 220, 1949, 628, 220, 220, 220, 220, 220, 220, 220, 2291, 7, 9288, 8, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 1002, 2279, 318, 3734, 11, 3601, 546, 326, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7203, 59, 68, 58, 16, 26, 2624, 76, 47924, 1961, 59, 68, 58, 15, 76, 25, 29568, 12093, 12453, 7, 9288, 4008, 4943, 628, 220, 220, 220, 1303, 1002, 4049, 5091, 11, 3465, 326, 198, 220, 220, 220, 4929, 304, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 32770, 262, 3298, 7885, 198, 220, 220, 220, 220, 220, 220, 220, 3298, 597, 48277, 796, 2081, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 12578, 546, 262, 2038, 198, 220, 220, 220, 220, 220, 220, 220, 44872, 7203, 59, 68, 58, 16, 26, 3132, 76, 7708, 4146, 1961, 59, 68, 58, 15, 76, 25, 29568, 12093, 12453, 7, 9288, 4008, 4943, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 29739, 3393, 318, 2622, 198, 220, 220, 220, 220, 220, 220, 220, 611, 10800, 48277, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 302, 16939, 7, 68, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 5438, 262, 4049, 611, 2622, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 361, 5145, 39624, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 14643, 1472, 7, 19282, 448, 11, 304, 11, 736, 40546, 28955, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 44872, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 886, 198, 437, 198, 198, 2, 1002, 597, 8563, 11, 3714, 281, 6631, 198, 1092, 48277, 11405, 3714, 7203, 4366, 5254, 423, 4054, 19570, 198 ]
2.462322
491
""" Base.rand(randomwalk::RandomWalk{<:AbstractArray{<:DataType}, <:AbstractArray{<:Real}, <:Sampleable}, ntimesteps::Integer) -> Matrix{Int} Simulate `randomwalk` for `ntimesteps` time-steps over an integer lattice, returning one sample path (i.e. trajectory) of length `ntimesteps`. The time steps represented in the sample path are `0, 1, ..., ntimesteps-1`, for we start with an initial state. ##### Complexity - Time complexity: `O(n)`. """ function Base.rand(randomwalk::RandomWalk{<:AbstractArray{<:DataType}, <:AbstractArray{<:Real}, <:Sampleable}, ntimesteps::Integer) # allocate memory realizationmatrix = Matrix{Int}(undef, ntimesteps, length(randomwalk.initialstate)) realizationmatrix[1,:] = randomwalk.initialstate # draw a random step change = rand(randomwalk.stepsampler) for step in 2:ntimesteps realizationmatrix[step,:] = realizationmatrix[step-1,:] + change change = rand(randomwalk.stepsampler) end return realizationmatrix end """ Base.rand(randomwalk::RandomWalk{<:DataType, <:Real, <:Sampleable, ntimesteps::Integer) -> Vector{Int} Simulate a one-dimensional `randomwalk` for `ntimesteps` time-steps, returning one sample path (i.e. trajectory) of length `ntimesteps`. The time steps represented in the sample path are `0, 1, ..., ntimesteps-1`, for we start with an initial state. ##### Complexity - Time complexity: `O(n)`. """ function Base.rand(randomwalk::RandomWalk{<:DataType, <:Real, <:Sampleable}, ntimesteps::Integer) # allocate memory realizationvec = Vector{eltype(randomwalk)}(undef, ntimesteps) realizationvec[1] = randomwalk.initialstate # draw a random step change = rand(randomwalk.stepsampler)[1] for step in 2:ntimesteps realizationvec[step] = realizationvec[step-1] + change change = rand(randomwalk.stepsampler)[1] end return realizationvec end """ Base.rand(randomwalk::RandomWalk{<:AbstractGraph, <:Integer, <:Sampleable}, ntimesteps::Integer) -> Vector{Int} Simulate `randomwalk` for `ntimesteps` time-steps over a graph, returning one sample path (i.e. trajectory) of length `ntimesteps`. The time steps represented in the sample path are `0, 1, ..., ntimesteps-1`, for we start with an initial state. ##### Complexity - Time complexity: `O(n)`. """ function Base.rand(randomwalk::RandomWalk{<:AbstractGraph, <:Integer, <:Sampleable}, ntimesteps::Integer) # allocate memory realizationvec = Vector{eltype(randomwalk)}(undef, ntimesteps) realizationvec[1] = randomwalk.initialstate for step in 2:ntimesteps # draw a neighbor at random realizationvec[step] = NeighborSampler(randomwalk.statespace, realizationvec[step-1]) |> rand end return realizationvec end
[ 37811, 198, 220, 220, 220, 7308, 13, 25192, 7, 25120, 11152, 3712, 29531, 35963, 90, 27, 25, 23839, 19182, 90, 27, 25, 6601, 6030, 5512, 1279, 25, 23839, 19182, 90, 27, 25, 15633, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1279, 25, 36674, 540, 5512, 299, 16514, 395, 25386, 3712, 46541, 8, 4613, 24936, 90, 5317, 92, 198, 198, 8890, 5039, 4600, 25120, 11152, 63, 329, 4600, 429, 320, 395, 25386, 63, 640, 12, 20214, 625, 281, 18253, 47240, 501, 11, 8024, 530, 198, 39873, 3108, 357, 72, 13, 68, 13, 22942, 8, 286, 4129, 4600, 429, 320, 395, 25386, 44646, 198, 198, 464, 640, 4831, 7997, 287, 262, 6291, 3108, 389, 4600, 15, 11, 352, 11, 2644, 11, 299, 16514, 395, 25386, 12, 16, 47671, 329, 356, 923, 198, 4480, 281, 4238, 1181, 13, 198, 198, 4242, 2, 19157, 414, 198, 12, 3862, 13357, 25, 4600, 46, 7, 77, 8, 44646, 198, 37811, 198, 8818, 7308, 13, 25192, 7, 25120, 11152, 3712, 29531, 35963, 90, 27, 25, 23839, 19182, 90, 27, 25, 6601, 6030, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1279, 25, 23839, 19182, 90, 27, 25, 15633, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1279, 25, 36674, 540, 5512, 299, 16514, 395, 25386, 3712, 46541, 8, 198, 220, 220, 220, 1303, 31935, 4088, 198, 220, 220, 220, 23258, 6759, 8609, 796, 24936, 90, 5317, 92, 7, 917, 891, 11, 299, 16514, 395, 25386, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4129, 7, 25120, 11152, 13, 36733, 5219, 4008, 198, 220, 220, 220, 23258, 6759, 8609, 58, 16, 11, 47715, 796, 4738, 11152, 13, 36733, 5219, 198, 220, 220, 220, 1303, 3197, 257, 4738, 2239, 198, 220, 220, 220, 1487, 796, 43720, 7, 25120, 11152, 13, 20214, 321, 20053, 8, 198, 220, 220, 220, 329, 2239, 287, 362, 25, 429, 320, 395, 25386, 198, 220, 220, 220, 220, 220, 220, 220, 23258, 6759, 8609, 58, 9662, 11, 47715, 796, 23258, 6759, 8609, 58, 9662, 12, 16, 11, 47715, 1343, 1487, 198, 220, 220, 220, 220, 220, 220, 220, 1487, 796, 43720, 7, 25120, 11152, 13, 20214, 321, 20053, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 23258, 6759, 8609, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 7308, 13, 25192, 7, 25120, 11152, 3712, 29531, 35963, 90, 27, 25, 6601, 6030, 11, 1279, 25, 15633, 11, 1279, 25, 36674, 540, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 16514, 395, 25386, 3712, 46541, 8, 4613, 20650, 90, 5317, 92, 198, 198, 8890, 5039, 257, 530, 12, 19577, 4600, 25120, 11152, 63, 329, 4600, 429, 320, 395, 25386, 63, 640, 12, 20214, 11, 8024, 530, 6291, 198, 6978, 357, 72, 13, 68, 13, 22942, 8, 286, 4129, 4600, 429, 320, 395, 25386, 44646, 198, 198, 464, 640, 4831, 7997, 287, 262, 6291, 3108, 389, 4600, 15, 11, 352, 11, 2644, 11, 299, 16514, 395, 25386, 12, 16, 47671, 329, 356, 923, 198, 4480, 281, 4238, 1181, 13, 198, 198, 4242, 2, 19157, 414, 198, 12, 3862, 13357, 25, 4600, 46, 7, 77, 8, 44646, 198, 37811, 198, 8818, 7308, 13, 25192, 7, 25120, 11152, 3712, 29531, 35963, 90, 27, 25, 6601, 6030, 11, 1279, 25, 15633, 11, 1279, 25, 36674, 540, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 16514, 395, 25386, 3712, 46541, 8, 198, 220, 220, 220, 1303, 31935, 4088, 198, 220, 220, 220, 23258, 35138, 796, 20650, 90, 417, 4906, 7, 25120, 11152, 38165, 7, 917, 891, 11, 299, 16514, 395, 25386, 8, 198, 220, 220, 220, 23258, 35138, 58, 16, 60, 796, 4738, 11152, 13, 36733, 5219, 198, 220, 220, 220, 1303, 3197, 257, 4738, 2239, 198, 220, 220, 220, 1487, 796, 43720, 7, 25120, 11152, 13, 20214, 321, 20053, 38381, 16, 60, 198, 220, 220, 220, 329, 2239, 287, 362, 25, 429, 320, 395, 25386, 198, 220, 220, 220, 220, 220, 220, 220, 23258, 35138, 58, 9662, 60, 796, 23258, 35138, 58, 9662, 12, 16, 60, 1343, 1487, 198, 220, 220, 220, 220, 220, 220, 220, 1487, 796, 43720, 7, 25120, 11152, 13, 20214, 321, 20053, 38381, 16, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 23258, 35138, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 7308, 13, 25192, 7, 25120, 11152, 3712, 29531, 35963, 90, 27, 25, 23839, 37065, 11, 1279, 25, 46541, 11, 1279, 25, 36674, 540, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 16514, 395, 25386, 3712, 46541, 8, 4613, 20650, 90, 5317, 92, 198, 198, 8890, 5039, 4600, 25120, 11152, 63, 329, 4600, 429, 320, 395, 25386, 63, 640, 12, 20214, 625, 257, 4823, 11, 8024, 530, 6291, 3108, 198, 7, 72, 13, 68, 13, 22942, 8, 286, 4129, 4600, 429, 320, 395, 25386, 44646, 198, 198, 464, 640, 4831, 7997, 287, 262, 6291, 3108, 389, 4600, 15, 11, 352, 11, 2644, 11, 299, 16514, 395, 25386, 12, 16, 47671, 329, 356, 923, 198, 4480, 281, 4238, 1181, 13, 198, 198, 4242, 2, 19157, 414, 198, 12, 3862, 13357, 25, 4600, 46, 7, 77, 8, 44646, 198, 37811, 198, 8818, 7308, 13, 25192, 7, 25120, 11152, 3712, 29531, 35963, 90, 27, 25, 23839, 37065, 11, 1279, 25, 46541, 11, 1279, 25, 36674, 540, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 16514, 395, 25386, 3712, 46541, 8, 198, 220, 220, 220, 1303, 31935, 4088, 198, 220, 220, 220, 23258, 35138, 796, 20650, 90, 417, 4906, 7, 25120, 11152, 38165, 7, 917, 891, 11, 299, 16514, 395, 25386, 8, 198, 220, 220, 220, 23258, 35138, 58, 16, 60, 796, 4738, 11152, 13, 36733, 5219, 198, 220, 220, 220, 329, 2239, 287, 362, 25, 429, 320, 395, 25386, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 3197, 257, 4780, 379, 4738, 198, 220, 220, 220, 220, 220, 220, 220, 23258, 35138, 58, 9662, 60, 796, 28708, 16305, 20053, 7, 25120, 11152, 13, 27219, 10223, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23258, 35138, 58, 9662, 12, 16, 12962, 930, 29, 43720, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 23258, 35138, 198, 437, 198 ]
2.470445
1,235
<filename>tutorials/Land/Soil/PhaseChange/freezing_front.jl # # Modeling a freezing front in unsaturated soil # Before reading this tutorial, # we recommend that you look over the coupled energy # and water [tutorial](../Coupled/equilibrium_test.md). # That tutorial showed how to solve the heat equation for soil volumetric # internal energy `ρe_int`, simultaneously # with Richards equation for volumetric liquid water fraction `ϑ_l`, assuming zero # volumetric ice fraction `θ_i` for all time, everywhere in the domain[^a]. # In this example, we add in a source term to the right hand side for both `θ_i` # and `ϑ_l` which models freezing and thawing and conserves water mass during the process. # The equations are # `` # \frac{∂ ρe_{int}}{∂ t} = ∇ ⋅ κ(θ_l, θ_i; ν, ...) ∇T + ∇ ⋅ ρe_{int_{liq}} K (T,θ_l, θ_i; ν, ...) \nabla h( ϑ_l, z; ν, ...) # `` # `` # \frac{ ∂ ϑ_l}{∂ t} = ∇ ⋅ K (T,θ_l, θ_i; ν, ...) ∇h( ϑ_l, z; ν, ...) -\frac{F_T}{ρ_l} # `` # `` # \frac{ ∂ θ_i}{∂ t} = \frac{F_T}{ρ_i} # `` # Here # ``t`` is the time (s), # ``z`` is the location in the vertical (m), # ``ρe_{int}`` is the volumetric internal energy of the soil (J/m^3), # ``T`` is the temperature of the soil (K), # ``κ`` is the thermal conductivity (W/m/K), # ``ρe_{int_{liq}}`` is the volumetric internal energy of liquid water (J/m^3), # ``K`` is the hydraulic conductivity (m/s), # ``h`` is the hydraulic head (m), # ``ϑ_l`` is the augmented volumetric liquid water fraction, # ``θ_i`` is the volumetric ice fraction, # ``ν, ...`` denotes parameters relating to soil type, such as porosity, and # ``F_T`` is the freeze-thaw term. # To begin, we will show how to implement adding in this source term. After the results are obtained, # we will [explain](#Discussion-and-Model-Explanation) how our model parameterizes this effect and # compare the results with some analytic expections. # We solve these equations in an effectively 1-d domain with ``z ∈ [-0.2,0]``, # and with the following boundary and initial conditions: # ``- κ ∇T(t, z = 0) = 28 W/m^2/K (T - 267.15K) ẑ`` # ``- κ ∇T(t, z= -0.2) = 0 ẑ `` # `` T(t = 0, z) = 279.85 K`` # ``- K ∇h(t, z = 0) = 0 ẑ `` # `` -K ∇h(t, z = -0.2) = 0 ẑ`` # `` ϑ_l(t = 0, z) = 0.33 ``. # The problem setup and soil properties are chosen to match the lab experiment of [Mizoguchi1990](@cite), as detailed in [Hansson2004](@cite) and [DallAmico2011](@cite)]. # # Import necessary modules # External (non - CliMA) modules using MPI using OrderedCollections using StaticArrays using Statistics using Test using DelimitedFiles using Plots # CliMA Parameters using CLIMAParameters struct EarthParameterSet <: AbstractEarthParameterSet end const param_set = EarthParameterSet() using CLIMAParameters.Planet: ρ_cloud_liq using CLIMAParameters.Planet: ρ_cloud_ice # ClimateMachine modules using ClimateMachine using ClimateMachine.Land using ClimateMachine.Land.SoilWaterParameterizations using ClimateMachine.Land.SoilHeatParameterizations using ClimateMachine.Mesh.Topologies using ClimateMachine.Mesh.Grids using ClimateMachine.DGMethods using ClimateMachine.DGMethods.NumericalFluxes using ClimateMachine.DGMethods: BalanceLaw, LocalGeometry using ClimateMachine.MPIStateArrays using ClimateMachine.GenericCallbacks using ClimateMachine.SystemSolvers using ClimateMachine.ODESolvers using ClimateMachine.VariableTemplates using ClimateMachine.SingleStackUtils using ClimateMachine.BalanceLaws: BalanceLaw, Prognostic, Auxiliary, Gradient, GradientFlux, vars_state using ClimateMachine.ArtifactWrappers # # Preliminary set-up # Get the parameter set, which holds constants used across CliMA models: struct EarthParameterSet <: AbstractEarthParameterSet end const param_set = EarthParameterSet(); # Initialize and pick a floating point precision: ClimateMachine.init() const FT = Float64; # Load plot helpers: const clima_dir = dirname(dirname(pathof(ClimateMachine))); include(joinpath(clima_dir, "docs", "plothelpers.jl")); # # Simulation specific parameters N_poly = 1 nelem_vert = 20 zmax = FT(0) zmin = FT(-0.2) t0 = FT(0) dt = FT(6) timeend = FT(3600 * 50) n_outputs = 50 every_x_simulation_time = ceil(Int, timeend / n_outputs) Δ = abs(zmin - zmax) / FT(nelem_vert); # # Soil properties. # All are given in mks units. ν = FT(0.535) θ_r = FT(0.05) S_s = FT(1e-3) Ksat = FT(3.2e-6) vg_α = 1.11 vg_n = 1.48; ν_ss_quartz = FT(0.7) ν_ss_minerals = FT(0.0) ν_ss_om = FT(0.3) ν_ss_gravel = FT(0.0); κ_quartz = FT(7.7) κ_minerals = FT(2.4) κ_om = FT(0.25) κ_liq = FT(0.57) κ_ice = FT(2.29); κ_solid = k_solid(ν_ss_om, ν_ss_quartz, κ_quartz, κ_minerals, κ_om) κ_sat_frozen = ksat_frozen(κ_solid, ν, κ_ice) κ_sat_unfrozen = ksat_unfrozen(κ_solid, ν, κ_liq); ρp = FT(3200) ρc_ds = FT((1 - ν) * 2.3e6); soil_param_functions = SoilParamFunctions{FT}( porosity = ν, Ksat = Ksat, S_s = S_s, θ_r = θ_r, ν_ss_gravel = ν_ss_gravel, ν_ss_om = ν_ss_om, ν_ss_quartz = ν_ss_quartz, ρc_ds = ρc_ds, ρp = ρp, κ_solid = κ_solid, κ_sat_unfrozen = κ_sat_unfrozen, κ_sat_frozen = κ_sat_frozen, ); # # Build the model # Initial and Boundary conditions. The default initial condition for # `θ_i` is zero everywhere, so we don't modify that. Furthermore, since # the equation for `θ_i` does not involve spatial derivatives, we don't need # to supply boundary conditions for it. zero_flux = (aux, t) -> eltype(aux)(0.0) surface_heat_flux = (aux, t) -> eltype(aux)(28) * (aux.soil.heat.T - eltype(aux)(273.15 - 6)) T_init = aux -> eltype(aux)(279.85) ϑ_l0 = (aux) -> eltype(aux)(0.33); bc = LandDomainBC( bottom_bc = LandComponentBC( soil_heat = Neumann(zero_flux), soil_water = Neumann(zero_flux), ), surface_bc = LandComponentBC( soil_heat = Neumann(surface_heat_flux), soil_water = Neumann(zero_flux), ), ); # Create the [`SoilWaterModel`](@ref ClimateMachine.Land.SoilWaterModel), # [`SoilHeatModel`](@ref ClimateMachine.Land.SoilHeatModel), # and the [`SoilModel`](@ref ClimateMachine.Land.SoilModel) instances. # Note that we are allowing for the hydraulic conductivity to be affected by # both temperature and ice fraction by choosing the following # [`viscosity_factor`](@ref ClimateMachine.Land.SoilWaterParameterizations.viscosity_factor) # and [`impedance_factor`](@ref ClimateMachine.Land.SoilWaterParameterizations.impedance_factor). # To turn these off - the default - just remove these lines. These factors are explained more # [here](../Water/hydraulic_functions.md). soil_water_model = SoilWaterModel( FT; viscosity_factor = TemperatureDependentViscosity{FT}(), moisture_factor = MoistureDependent{FT}(), impedance_factor = IceImpedance{FT}(Ω = 7.0), hydraulics = vanGenuchten{FT}(α = vg_α, n = vg_n), initialϑ_l = ϑ_l0, ) soil_heat_model = SoilHeatModel(FT; initialT = T_init); m_soil = SoilModel(soil_param_functions, soil_water_model, soil_heat_model); # Create the source term instance. Our phase change model requires # knowledge of the vertical spacing, so we pass # that information in via an attribute of the # [`PhaseChange`](@ref ClimateMachine.Land.PhaseChange) structure. freeze_thaw_source = PhaseChange{FT}(Δz = Δ); # Sources are added as elements of a list of sources. Here we just add freezing # and thawing. sources = (freeze_thaw_source,); # Next, we define the required `init_soil!` function, which takes the user # specified functions of space for `T_init` and `ϑ_l0` and initializes the state # variables of volumetric internal energy and augmented liquid fraction. This requires # a conversion from `T` to `ρe_int`. function init_soil!(land, state, aux, localgeo, time) myFT = eltype(state) ϑ_l = myFT(land.soil.water.initialϑ_l(aux)) θ_i = myFT(land.soil.water.initialθ_i(aux)) state.soil.water.ϑ_l = ϑ_l state.soil.water.θ_i = θ_i param_set = land.param_set θ_l = volumetric_liquid_fraction(ϑ_l, land.soil.param_functions.porosity) ρc_ds = land.soil.param_functions.ρc_ds ρc_s = volumetric_heat_capacity(θ_l, θ_i, ρc_ds, param_set) state.soil.heat.ρe_int = volumetric_internal_energy( θ_i, ρc_s, land.soil.heat.initialT(aux), param_set, ) end; # Lastly, package it all up in the `LandModel`: m = LandModel( param_set, m_soil; boundary_conditions = bc, source = sources, init_state_prognostic = init_soil!, ); # # Build the simulation domain, solver, and callbacks driver_config = ClimateMachine.SingleStackConfiguration( "LandModel", N_poly, nelem_vert, zmax, param_set, m; zmin = zmin, numerical_flux_first_order = CentralNumericalFluxFirstOrder(), ); solver_config = ClimateMachine.SolverConfiguration(t0, timeend, driver_config, ode_dt = dt); dg = solver_config.dg Q = solver_config.Q state_types = (Prognostic(), Auxiliary(), GradientFlux()) dons_arr = Dict[dict_of_nodal_states(solver_config, state_types; interp = true)] time_data = FT[0] callback = GenericCallbacks.EveryXSimulationTime(every_x_simulation_time) do dons = dict_of_nodal_states(solver_config, state_types; interp = true) push!(dons_arr, dons) push!(time_data, gettime(solver_config.solver)) nothing end; # # Run the simulation, and plot the output ClimateMachine.invoke!(solver_config; user_callbacks = (callback,)); z = get_z(solver_config.dg.grid; rm_dupes = true); output_dir = @__DIR__; mkpath(output_dir); export_plot( z, time_data[[1, 16, 31, 46]] ./ (60 * 60), dons_arr[[1, 16, 31, 46]], ("soil.water.ϑ_l",), joinpath(output_dir, "moisture_plot.png"); xlabel = "ϑ_l", ylabel = "z (m)", time_units = "hrs ", ) # ![](moisture_plot.png) export_plot( z, time_data[[1, 16, 31, 46]] ./ (60 * 60), dons_arr[[1, 16, 31, 46]], ("soil.water.θ_i",), joinpath(output_dir, "ice_plot.png"); xlabel = "θ_i", ylabel = "z (m)", time_units = "hrs ", legend = :bottomright, ) # ![](ice_plot.png) export_plot( z, time_data[[1, 16, 31, 46]] ./ (60 * 60), dons_arr[[1, 16, 31, 46]], ("soil.heat.T",), joinpath(output_dir, "T_plot.png"); xlabel = "T (K)", ylabel = "z (m)", time_units = "hrs ", ) # ![](T_plot.png) # # Comparison to data # This data was obtained by us from the figures of [Hansson2004](@cite), but was originally obtained # by [Mizoguchi1990](@cite). No error bars were reported, and we haven't quantified the error in our # estimation of the data from images. dataset = ArtifactWrapper( @__DIR__, isempty(get(ENV, "CI", "")), "mizoguchi", ArtifactFile[ArtifactFile( url = "https://caltech.box.com/shared/static/3xbo4rlam8u390vmucc498cao6wmqlnd.csv", filename = "mizoguchi_all_data.csv", ),], ); dataset_path = get_data_folder(dataset); data = joinpath(dataset_path, "mizoguchi_all_data.csv") ds = readdlm(data, ',') hours = ds[:, 1][2:end] vwc = ds[:, 2][2:end] ./ 100.0 depth = ds[:, 3][2:end] mask_12h = hours .== 12 mask_24h = hours .== 24 mask_50h = hours .== 50; plot_12h = scatter(vwc[mask_12h], -depth[mask_12h], label = "", color = "purple") plot!( dons_arr[13]["soil.water.θ_i"] .+ dons_arr[13]["soil.water.ϑ_l"], z, label = "", color = "green", ) plot!(title = "12h") plot!(xlim = [0.2, 0.55]) plot!(xticks = [0.2, 0.3, 0.4, 0.5]) plot!(ylabel = "Depth (m)"); plot_24h = scatter(vwc[mask_24h], -depth[mask_24h], label = "Data", color = "purple") plot!( dons_arr[25]["soil.water.θ_i"] .+ dons_arr[25]["soil.water.ϑ_l"], z, label = "Simulation", color = "green", ) plot!(title = "24h") plot!(legend = :bottomright) plot!(xlim = [0.2, 0.55]) plot!(xticks = [0.2, 0.3, 0.4, 0.5]); plot_50h = scatter(vwc[mask_50h], -depth[mask_50h], label = "", color = "purple") plot!( dons_arr[51]["soil.water.θ_i"] .+ dons_arr[51]["soil.water.ϑ_l"], z, label = "", color = "green", ) plot!(title = "50h") plot!(xlim = [0.2, 0.55]) plot!(xticks = [0.2, 0.3, 0.4, 0.5]); plot(plot_12h, plot_24h, plot_50h, layout = (1, 3)) plot!(xlabel = "θ_l+θ_i") savefig("mizoguchi_data_comparison.png") # ![](mizoguchi_data_comparison.png) # # Discussion and Model Explanation # To begin, let's observe that the freeze thaw source term alone conserves water mass, as # it satisfies # `` # ρ_l \partial_tϑ_l + ρ_i \partial_tθ_i = -F_T + F_T = 0 # `` # Next, we describe how we define `F_T`. # The Clausius-Clapeyron (CC) equation defines a pressure-temperature curve along which two # phases can co-exist. It assumes that the phases are at equal temperature and pressures. # For water in soil, however, the liquid water experiences pressure `ρ_l g ψ`, where # `ψ` is the matric potential. A more general form of the CC equation allows for different # pressures in the two phases. Usually the ice pressure is taken to be zero, which is reasonable # for unsaturated freezing soils. In saturated soils, freezing can lead to heaving of the soil which # we do not model. After that assumption is made, we obtain that, below freezing (``T < T_f``) # `` # \frac{dp_l}{ρ_l} = L_f \frac{dT}{T}, # `` # or # `` # p_l = p_{l,0} + L_f ρ_l \frac{T-T_f}{T_f} \mathcal{H}(T_f-T) # `` # where we have assumed that assumed `T` is near the freezing point, and then # performed a Taylor explansion of the logarithm, # and we are ignoring the freezing point depression, which is small (less than one degree) for # non-clay soils. What we have sketched is further explained in [DallAmico2011](@cite) and [KurylykWatanabe2013](@cite). # What this implies is that above the freezing point, the pressure is equal to ``p_{l,0}``, # which is independent of temperature. Once the temperature drops below the freezing point, # the pressure drops. Since prior to freezing, the pressure ``p_{l,0}`` is equal to # `ρ_l g ψ(θ_l)`, water undergoing freezing alone (without flowing) should satisfy ([DallAmico2011](@cite)): # `` # p_{l,0} = ρ_l g ψ(θ_l+ρ_iθ_i/ρ_l) # `` # where `ψ` is the matric potential function of van Genuchten. At each step, we know both # the water and ice contents, as well as the temperature, and can then solve for # `` # θ_{l}^* = (ν-θ_r) ψ^{-1}(p_l/(ρ_l g)) + θ_r. # `` # For freezing, the freeze thaw function `F_T` is equal to # `` # F_T = \frac{1}{τ} ρ_l (θ_l-θ_{l}^*) \mathcal{H}(T_f-T) \mathcal{H}(θ_l-θ_{l}^*) # `` # which brings the `θ_l` to a value which satisfies `p_l = ρ_l g ψ(θ_l)`. # This is why, in our simulation, we see the liquid # water fraction approaches a constant around 0.075 in the frozen region, rather than the residual fraction # of 0.019, or 0. This behavior is observed, for example, in the experiments of [Watanabe2011](@cite). # Although this approach may indicate that we should replace the pressure head appearing in the # diffusive water flux term in Richards equation ([DallAmico2011](@cite)), we do not do so at present. As such, we may not be modeling # the flow of water around the freezing front properly. However, we still observe cryosuction, which # is the flow of water towards the freezing front, from the unfrozen side. As the water freezes, the liquid # water content drops, # setting up a larger gradient in matric potential across the freezing front, which generates upward flow # against gravity. This is evident because the total water content at the top is larger at the end of the # simulation # than it was at `t=0` (when it was 0.33). # This model differs from others (e.g. [Painter2011](@cite), [Hansson2004](@cite), [DallAmico2011](@cite)) in that it requires us to set a timescale for the phase change, `τ`. # In a first-order # phase transition, the temperature is fixed while the necessary latent heat is either lost or gained by the # system. Ignoring # changes in internal energy due to flowing water, we would expect # `` # \partial_t ρe_{int} \approx (ρ_l c_l \partial_t θ_l + ρ_i c_i \partial_t θ_i) (T-T_0) -ρ_i L_f \partial_t θ_i # `` # `` # = [(c_i-c_l) (T-T_0) -L_f]F_T \approx -L_f F_T # `` # or # `` # F_T ∼ \frac{κ|∇²T|}{L_f} ∼\frac{κ}{c̃ Δz²}\frac{c̃ |∂zT| Δz}{L_f} # `` # suggesting # `` # τ ∼ τ_{LTE}\frac{ρ_lL_f (ν-θ_r)}{c̃ |∂zT| Δz} # `` # with # `` # τ_{LTE}= c̃ Δz²/κ # `` # This is the value we use. This seems to work adequately for modeling freezing front propagation and # cryosuction, via comparisons with [Mizoguchi1990](@cite), but we plan to revisit it in the future. For example, # we do not see a strong temperature plateau at the freezing point ([Watanabe2011](@cite)), # which we would expect while the phase change is occuring. Experimentally, this timescale also affects the abruptness of the freezing front, which our simulation softens. # # References # - [Mizoguchi1990](@cite) # - [Hansson2004](@cite) # - [DallAmico2011](@cite) # - [KurylykWatanabe2013](@cite) # - [Watanabe2011](@cite) # - [Painter2011](@cite) # [^a]: # Note that `θ_i` is always treated as a prognostic variable # in the `SoilWaterModel`, but with # zero terms on the RHS unless freezing and thawing is turn on, as demonstrated in this # tutorial. That means that the user could, in principle, set the initial condition to be nonzero # (`θ_i(x, y, z ,t=0) = 0` is the default), which in turn would allow a nonzero `θ_i` # profile to affect things like thermal conductivity, etc, # in a consistent way. However, it would not be enforced that ``θ_l+θ_i \leq ν``, because there would # be no physics linking the liquid and water content to each other, and they are independent # variables in our model. We don't envision this being a common use case.
[ 27, 34345, 29, 83, 44917, 82, 14, 22342, 14, 2396, 346, 14, 35645, 19400, 14, 5787, 9510, 62, 8534, 13, 20362, 198, 2, 1303, 9104, 278, 257, 20884, 2166, 287, 5576, 30192, 9260, 198, 198, 2, 7413, 3555, 428, 11808, 11, 220, 198, 2, 356, 4313, 326, 345, 804, 625, 262, 18064, 2568, 198, 2, 290, 1660, 685, 83, 44917, 16151, 40720, 34, 280, 10137, 14, 4853, 24741, 62, 9288, 13, 9132, 737, 198, 2, 1320, 11808, 3751, 703, 284, 8494, 262, 4894, 16022, 329, 9260, 2322, 388, 19482, 198, 2, 5387, 2568, 4600, 33643, 68, 62, 600, 47671, 11640, 198, 2, 351, 14743, 16022, 329, 2322, 388, 19482, 8122, 1660, 13390, 4600, 139, 239, 62, 75, 47671, 13148, 6632, 198, 2, 2322, 388, 19482, 4771, 13390, 4600, 138, 116, 62, 72, 63, 329, 477, 640, 11, 8347, 287, 262, 7386, 58, 61, 64, 4083, 198, 2, 554, 428, 1672, 11, 356, 751, 287, 257, 2723, 3381, 284, 262, 826, 1021, 1735, 329, 1111, 4600, 138, 116, 62, 72, 63, 198, 2, 290, 4600, 139, 239, 62, 75, 63, 543, 4981, 20884, 290, 294, 707, 278, 290, 4055, 274, 1660, 2347, 1141, 262, 1429, 13, 198, 2, 383, 27490, 389, 628, 198, 2, 7559, 198, 2, 3467, 31944, 90, 24861, 224, 18074, 223, 68, 23330, 600, 11709, 90, 24861, 224, 256, 92, 796, 220, 18872, 229, 2343, 233, 227, 7377, 118, 7, 138, 116, 62, 75, 11, 7377, 116, 62, 72, 26, 7377, 121, 11, 2644, 8, 18872, 229, 51, 1343, 18872, 229, 2343, 233, 227, 18074, 223, 68, 23330, 600, 23330, 4528, 80, 11709, 509, 357, 51, 11, 138, 116, 62, 75, 11, 7377, 116, 62, 72, 26, 7377, 121, 11, 2644, 8, 3467, 77, 397, 5031, 289, 7, 18074, 239, 62, 75, 11, 1976, 26, 7377, 121, 11, 2644, 8, 198, 2, 7559, 198, 198, 2, 7559, 198, 2, 3467, 31944, 90, 18872, 224, 18074, 239, 62, 75, 18477, 24861, 224, 256, 92, 796, 18872, 229, 2343, 233, 227, 509, 357, 51, 11, 138, 116, 62, 75, 11, 7377, 116, 62, 72, 26, 7377, 121, 11, 2644, 8, 18872, 229, 71, 7, 18074, 239, 62, 75, 11, 1976, 26, 7377, 121, 11, 2644, 8, 532, 59, 31944, 90, 37, 62, 51, 18477, 33643, 62, 75, 92, 198, 2, 7559, 198, 198, 2, 7559, 198, 2, 3467, 31944, 90, 18872, 224, 7377, 116, 62, 72, 18477, 24861, 224, 256, 92, 796, 3467, 31944, 90, 37, 62, 51, 18477, 33643, 62, 72, 92, 198, 2, 7559, 198, 198, 2, 3423, 198, 198, 2, 7559, 83, 15506, 318, 262, 640, 357, 82, 828, 198, 198, 2, 7559, 89, 15506, 318, 262, 4067, 287, 262, 11723, 357, 76, 828, 198, 198, 2, 7559, 33643, 68, 23330, 600, 92, 15506, 318, 262, 2322, 388, 19482, 5387, 2568, 286, 262, 9260, 357, 41, 14, 76, 61, 18, 828, 198, 198, 2, 7559, 51, 15506, 318, 262, 5951, 286, 262, 9260, 357, 42, 828, 198, 198, 2, 7559, 43000, 15506, 318, 262, 18411, 3189, 3458, 357, 54, 14, 76, 14, 42, 828, 198, 198, 2, 7559, 33643, 68, 23330, 600, 23330, 4528, 80, 11709, 15506, 318, 262, 2322, 388, 19482, 5387, 2568, 286, 8122, 1660, 357, 41, 14, 76, 61, 18, 828, 198, 198, 2, 7559, 42, 15506, 318, 262, 34797, 3189, 3458, 357, 76, 14, 82, 828, 198, 198, 2, 7559, 71, 15506, 318, 262, 34797, 1182, 357, 76, 828, 198, 198, 2, 7559, 139, 239, 62, 75, 15506, 318, 262, 30259, 2322, 388, 19482, 8122, 1660, 13390, 11, 198, 198, 2, 7559, 138, 116, 62, 72, 15506, 318, 262, 2322, 388, 19482, 4771, 13390, 11, 198, 198, 2, 7559, 26180, 11, 2644, 15506, 43397, 10007, 11270, 284, 9260, 2099, 11, 884, 355, 16964, 16579, 11, 290, 198, 198, 2, 7559, 37, 62, 51, 15506, 318, 262, 16611, 12, 400, 707, 3381, 13, 198, 198, 2, 1675, 2221, 11, 356, 481, 905, 703, 284, 3494, 4375, 287, 428, 2723, 3381, 13, 2293, 262, 2482, 389, 6492, 11, 198, 2, 356, 481, 685, 20676, 391, 16151, 2, 34255, 12, 392, 12, 17633, 12, 3109, 11578, 341, 8, 703, 674, 2746, 11507, 4340, 428, 1245, 290, 198, 2, 8996, 262, 2482, 351, 617, 49166, 1607, 507, 13, 198, 198, 2, 775, 8494, 777, 27490, 287, 281, 6840, 352, 12, 67, 7386, 351, 7559, 89, 18872, 230, 25915, 15, 13, 17, 11, 15, 60, 15506, 11, 198, 2, 290, 351, 262, 1708, 18645, 290, 4238, 3403, 25, 198, 198, 2, 7559, 12, 7377, 118, 18872, 229, 51, 7, 83, 11, 1976, 796, 657, 8, 796, 2579, 370, 14, 76, 61, 17, 14, 42, 357, 51, 532, 37364, 13, 1314, 42, 8, 1976, 136, 224, 15506, 198, 198, 2, 7559, 12, 7377, 118, 18872, 229, 51, 7, 83, 11, 1976, 28, 532, 15, 13, 17, 8, 796, 220, 657, 1976, 136, 224, 7559, 198, 198, 2, 7559, 309, 7, 83, 796, 657, 11, 1976, 8, 796, 39466, 13, 5332, 509, 15506, 198, 198, 2, 7559, 12, 509, 18872, 229, 71, 7, 83, 11, 1976, 796, 657, 8, 796, 657, 1976, 136, 224, 7559, 198, 198, 2, 7559, 532, 42, 18872, 229, 71, 7, 83, 11, 1976, 796, 532, 15, 13, 17, 8, 796, 657, 1976, 136, 224, 15506, 198, 198, 2, 7559, 18074, 239, 62, 75, 7, 83, 796, 657, 11, 1976, 8, 796, 657, 13, 2091, 7559, 13, 198, 198, 2, 383, 1917, 9058, 290, 9260, 6608, 389, 7147, 284, 2872, 262, 2248, 6306, 286, 685, 44, 528, 519, 22200, 19891, 16151, 31, 66, 578, 828, 355, 6496, 287, 685, 39, 44038, 15724, 16151, 31, 66, 578, 8, 290, 685, 35, 439, 5840, 3713, 9804, 16151, 31, 66, 578, 25295, 198, 198, 2, 1303, 17267, 3306, 13103, 198, 2, 34579, 357, 13159, 532, 1012, 72, 5673, 8, 13103, 198, 3500, 4904, 40, 198, 3500, 14230, 1068, 5216, 26448, 198, 3500, 36125, 3163, 20477, 198, 3500, 14370, 198, 3500, 6208, 198, 3500, 4216, 320, 863, 25876, 198, 3500, 1345, 1747, 198, 198, 2, 1012, 72, 5673, 40117, 198, 3500, 7852, 3955, 2969, 41158, 7307, 198, 7249, 3668, 36301, 7248, 1279, 25, 27741, 22840, 36301, 7248, 886, 198, 9979, 5772, 62, 2617, 796, 3668, 36301, 7248, 3419, 198, 3500, 7852, 3955, 2969, 41158, 7307, 13, 41801, 25, 18074, 223, 62, 17721, 62, 4528, 80, 198, 3500, 7852, 3955, 2969, 41158, 7307, 13, 41801, 25, 18074, 223, 62, 17721, 62, 501, 198, 198, 2, 13963, 37573, 13103, 198, 3500, 13963, 37573, 198, 3500, 13963, 37573, 13, 22342, 198, 3500, 13963, 37573, 13, 22342, 13, 2396, 346, 19184, 36301, 4582, 198, 3500, 13963, 37573, 13, 22342, 13, 2396, 346, 39596, 36301, 4582, 198, 3500, 13963, 37573, 13, 37031, 13, 9126, 5823, 198, 3500, 13963, 37573, 13, 37031, 13, 8642, 2340, 198, 3500, 13963, 37573, 13, 35, 38, 46202, 198, 3500, 13963, 37573, 13, 35, 38, 46202, 13, 45, 6975, 605, 37, 22564, 274, 198, 3500, 13963, 37573, 13, 35, 38, 46202, 25, 22924, 16966, 11, 10714, 10082, 15748, 198, 3500, 13963, 37573, 13, 7378, 40, 9012, 3163, 20477, 198, 3500, 13963, 37573, 13, 46189, 14134, 10146, 198, 3500, 13963, 37573, 13, 11964, 36949, 690, 198, 3500, 13963, 37573, 13, 3727, 1546, 349, 690, 198, 3500, 13963, 37573, 13, 43015, 12966, 17041, 198, 3500, 13963, 37573, 13, 28008, 25896, 18274, 4487, 198, 3500, 13963, 37573, 13, 45866, 43, 8356, 25, 198, 220, 220, 220, 22924, 16966, 11, 1041, 4593, 15132, 11, 47105, 28129, 11, 17701, 1153, 11, 17701, 1153, 37, 22564, 11, 410, 945, 62, 5219, 198, 3500, 13963, 37573, 13, 8001, 29660, 36918, 11799, 198, 198, 2, 1303, 28887, 38429, 900, 12, 929, 198, 198, 2, 3497, 262, 11507, 900, 11, 543, 6622, 38491, 973, 1973, 1012, 72, 5673, 4981, 25, 198, 7249, 3668, 36301, 7248, 1279, 25, 27741, 22840, 36301, 7248, 886, 198, 9979, 5772, 62, 2617, 796, 3668, 36301, 7248, 9783, 198, 2, 20768, 1096, 290, 2298, 257, 12462, 966, 15440, 25, 198, 37649, 37573, 13, 15003, 3419, 198, 9979, 19446, 796, 48436, 2414, 26, 198, 198, 2, 8778, 7110, 49385, 25, 198, 9979, 5424, 64, 62, 15908, 796, 26672, 3672, 7, 15908, 3672, 7, 6978, 1659, 7, 37649, 37573, 4008, 1776, 198, 17256, 7, 22179, 6978, 7, 565, 8083, 62, 15908, 11, 366, 31628, 1600, 366, 29487, 16794, 364, 13, 20362, 4943, 1776, 628, 198, 2, 1303, 41798, 2176, 10007, 198, 45, 62, 35428, 796, 352, 198, 710, 10671, 62, 1851, 796, 1160, 198, 89, 9806, 796, 19446, 7, 15, 8, 198, 89, 1084, 796, 19446, 32590, 15, 13, 17, 8, 198, 83, 15, 796, 19446, 7, 15, 8, 198, 28664, 796, 19446, 7, 21, 8, 198, 2435, 437, 796, 19446, 7, 2623, 405, 1635, 2026, 8, 198, 77, 62, 22915, 82, 796, 2026, 198, 16833, 62, 87, 62, 14323, 1741, 62, 2435, 796, 2906, 346, 7, 5317, 11, 640, 437, 1220, 299, 62, 22915, 82, 8, 198, 138, 242, 796, 2352, 7, 89, 1084, 532, 1976, 9806, 8, 1220, 19446, 7, 710, 10671, 62, 1851, 1776, 198, 198, 2, 1303, 1406, 346, 6608, 13, 198, 2, 1439, 389, 1813, 287, 285, 591, 4991, 13, 198, 26180, 796, 19446, 7, 15, 13, 44465, 8, 198, 138, 116, 62, 81, 796, 19446, 7, 15, 13, 2713, 8, 198, 50, 62, 82, 796, 19446, 7, 16, 68, 12, 18, 8, 198, 42, 49720, 796, 19446, 7, 18, 13, 17, 68, 12, 21, 8, 198, 45119, 62, 17394, 796, 352, 13, 1157, 198, 45119, 62, 77, 796, 352, 13, 2780, 26, 198, 198, 26180, 62, 824, 62, 421, 13636, 796, 19446, 7, 15, 13, 22, 8, 198, 26180, 62, 824, 62, 1084, 263, 874, 796, 19446, 7, 15, 13, 15, 8, 198, 26180, 62, 824, 62, 296, 796, 19446, 7, 15, 13, 18, 8, 198, 26180, 62, 824, 62, 70, 25843, 796, 19446, 7, 15, 13, 15, 1776, 198, 43000, 62, 421, 13636, 796, 19446, 7, 22, 13, 22, 8, 198, 43000, 62, 1084, 263, 874, 796, 19446, 7, 17, 13, 19, 8, 198, 43000, 62, 296, 796, 19446, 7, 15, 13, 1495, 8, 198, 43000, 62, 4528, 80, 796, 19446, 7, 15, 13, 3553, 8, 198, 43000, 62, 501, 796, 19446, 7, 17, 13, 1959, 1776, 198, 43000, 62, 39390, 796, 479, 62, 39390, 7, 26180, 62, 824, 62, 296, 11, 7377, 121, 62, 824, 62, 421, 13636, 11, 7377, 118, 62, 421, 13636, 11, 7377, 118, 62, 1084, 263, 874, 11, 7377, 118, 62, 296, 8, 198, 43000, 62, 49720, 62, 69, 42005, 796, 479, 49720, 62, 69, 42005, 7, 43000, 62, 39390, 11, 7377, 121, 11, 7377, 118, 62, 501, 8, 198, 43000, 62, 49720, 62, 403, 69, 42005, 796, 479, 49720, 62, 403, 69, 42005, 7, 43000, 62, 39390, 11, 7377, 121, 11, 7377, 118, 62, 4528, 80, 1776, 198, 33643, 79, 796, 19446, 7, 18, 2167, 8, 198, 33643, 66, 62, 9310, 796, 19446, 19510, 16, 532, 7377, 121, 8, 1635, 362, 13, 18, 68, 21, 1776, 628, 198, 568, 346, 62, 17143, 62, 12543, 2733, 796, 1406, 346, 22973, 24629, 2733, 90, 9792, 92, 7, 198, 220, 220, 220, 16964, 16579, 796, 7377, 121, 11, 198, 220, 220, 220, 509, 49720, 796, 509, 49720, 11, 198, 220, 220, 220, 311, 62, 82, 796, 311, 62, 82, 11, 198, 220, 220, 220, 7377, 116, 62, 81, 796, 7377, 116, 62, 81, 11, 198, 220, 220, 220, 7377, 121, 62, 824, 62, 70, 25843, 796, 7377, 121, 62, 824, 62, 70, 25843, 11, 198, 220, 220, 220, 7377, 121, 62, 824, 62, 296, 796, 7377, 121, 62, 824, 62, 296, 11, 198, 220, 220, 220, 7377, 121, 62, 824, 62, 421, 13636, 796, 7377, 121, 62, 824, 62, 421, 13636, 11, 198, 220, 220, 220, 18074, 223, 66, 62, 9310, 796, 18074, 223, 66, 62, 9310, 11, 198, 220, 220, 220, 18074, 223, 79, 796, 18074, 223, 79, 11, 198, 220, 220, 220, 7377, 118, 62, 39390, 796, 7377, 118, 62, 39390, 11, 198, 220, 220, 220, 7377, 118, 62, 49720, 62, 403, 69, 42005, 796, 7377, 118, 62, 49720, 62, 403, 69, 42005, 11, 198, 220, 220, 220, 7377, 118, 62, 49720, 62, 69, 42005, 796, 7377, 118, 62, 49720, 62, 69, 42005, 11, 198, 1776, 198, 198, 2, 1303, 10934, 262, 2746, 198, 2, 20768, 290, 30149, 560, 3403, 13, 383, 4277, 4238, 4006, 329, 198, 2, 4600, 138, 116, 62, 72, 63, 318, 6632, 8347, 11, 523, 356, 836, 470, 13096, 326, 13, 11399, 11, 1201, 198, 2, 262, 16022, 329, 4600, 138, 116, 62, 72, 63, 857, 407, 6211, 21739, 28486, 11, 356, 836, 470, 761, 198, 2, 284, 5127, 18645, 3403, 329, 340, 13, 198, 22570, 62, 69, 22564, 796, 357, 14644, 11, 256, 8, 4613, 1288, 4906, 7, 14644, 5769, 15, 13, 15, 8, 198, 42029, 62, 25080, 62, 69, 22564, 796, 198, 220, 220, 220, 357, 14644, 11, 256, 8, 4613, 1288, 4906, 7, 14644, 5769, 2078, 8, 1635, 357, 14644, 13, 568, 346, 13, 25080, 13, 51, 532, 1288, 4906, 7, 14644, 5769, 27367, 13, 1314, 532, 718, 4008, 198, 51, 62, 15003, 796, 27506, 4613, 1288, 4906, 7, 14644, 5769, 26050, 13, 5332, 8, 198, 139, 239, 62, 75, 15, 796, 357, 14644, 8, 4613, 1288, 4906, 7, 14644, 5769, 15, 13, 2091, 1776, 198, 198, 15630, 796, 6379, 43961, 2749, 7, 198, 220, 220, 220, 4220, 62, 15630, 796, 6379, 21950, 2749, 7, 198, 220, 220, 220, 220, 220, 220, 220, 9260, 62, 25080, 796, 3169, 40062, 7, 22570, 62, 69, 22564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 9260, 62, 7050, 796, 3169, 40062, 7, 22570, 62, 69, 22564, 828, 198, 220, 220, 220, 10612, 198, 220, 220, 220, 4417, 62, 15630, 796, 6379, 21950, 2749, 7, 198, 220, 220, 220, 220, 220, 220, 220, 9260, 62, 25080, 796, 3169, 40062, 7, 42029, 62, 25080, 62, 69, 22564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 9260, 62, 7050, 796, 3169, 40062, 7, 22570, 62, 69, 22564, 828, 198, 220, 220, 220, 10612, 198, 1776, 198, 198, 2, 13610, 262, 685, 63, 2396, 346, 19184, 17633, 63, 16151, 31, 5420, 13963, 37573, 13, 22342, 13, 2396, 346, 19184, 17633, 828, 198, 2, 685, 63, 2396, 346, 39596, 17633, 63, 16151, 31, 5420, 13963, 37573, 13, 22342, 13, 2396, 346, 39596, 17633, 828, 198, 2, 290, 262, 685, 63, 2396, 346, 17633, 63, 16151, 31, 5420, 13963, 37573, 13, 22342, 13, 2396, 346, 17633, 8, 10245, 13, 198, 2, 5740, 326, 356, 389, 5086, 329, 262, 34797, 3189, 3458, 284, 307, 5676, 416, 198, 2, 1111, 5951, 290, 4771, 13390, 416, 11236, 262, 1708, 198, 2, 685, 63, 85, 2304, 16579, 62, 31412, 63, 16151, 31, 5420, 13963, 37573, 13, 22342, 13, 2396, 346, 19184, 36301, 4582, 13, 85, 2304, 16579, 62, 31412, 8, 198, 2, 290, 685, 63, 320, 9124, 590, 62, 31412, 63, 16151, 31, 5420, 13963, 37573, 13, 22342, 13, 2396, 346, 19184, 36301, 4582, 13, 320, 9124, 590, 62, 31412, 737, 198, 2, 1675, 1210, 777, 572, 532, 262, 4277, 532, 655, 4781, 777, 3951, 13, 2312, 5087, 389, 4893, 517, 198, 2, 685, 1456, 16151, 40720, 19184, 14, 15511, 430, 28575, 62, 12543, 2733, 13, 9132, 737, 198, 568, 346, 62, 7050, 62, 19849, 796, 1406, 346, 19184, 17633, 7, 198, 220, 220, 220, 19446, 26, 198, 220, 220, 220, 1490, 6966, 414, 62, 31412, 796, 34467, 35, 8682, 53, 2304, 16579, 90, 9792, 92, 22784, 198, 220, 220, 220, 20160, 62, 31412, 796, 4270, 396, 495, 35, 8682, 90, 9792, 92, 22784, 198, 220, 220, 220, 47472, 62, 31412, 796, 6663, 26950, 276, 590, 90, 9792, 92, 7, 138, 102, 796, 767, 13, 15, 828, 198, 220, 220, 220, 25039, 377, 873, 796, 5719, 13746, 794, 1452, 90, 9792, 92, 7, 17394, 796, 410, 70, 62, 17394, 11, 299, 796, 410, 70, 62, 77, 828, 198, 220, 220, 220, 4238, 139, 239, 62, 75, 796, 18074, 239, 62, 75, 15, 11, 198, 8, 198, 198, 568, 346, 62, 25080, 62, 19849, 796, 1406, 346, 39596, 17633, 7, 9792, 26, 4238, 51, 796, 309, 62, 15003, 1776, 198, 198, 76, 62, 568, 346, 796, 1406, 346, 17633, 7, 568, 346, 62, 17143, 62, 12543, 2733, 11, 9260, 62, 7050, 62, 19849, 11, 9260, 62, 25080, 62, 19849, 1776, 198, 198, 2, 13610, 262, 2723, 3381, 4554, 13, 3954, 7108, 1487, 2746, 4433, 198, 2, 3725, 286, 262, 11723, 31050, 11, 523, 356, 1208, 198, 2, 326, 1321, 287, 2884, 281, 11688, 286, 262, 198, 2, 685, 63, 35645, 19400, 63, 16151, 31, 5420, 13963, 37573, 13, 22342, 13, 35645, 19400, 8, 4645, 13, 198, 5787, 2736, 62, 400, 707, 62, 10459, 796, 18983, 19400, 90, 9792, 92, 7, 138, 242, 89, 796, 37455, 1776, 198, 198, 2, 26406, 389, 2087, 355, 4847, 286, 257, 1351, 286, 4237, 13, 3423, 356, 655, 751, 20884, 198, 2, 290, 294, 707, 278, 13, 198, 82, 2203, 796, 357, 5787, 2736, 62, 400, 707, 62, 10459, 11, 1776, 198, 198, 2, 7406, 11, 356, 8160, 262, 2672, 4600, 15003, 62, 568, 346, 0, 63, 2163, 11, 543, 2753, 262, 2836, 198, 2, 7368, 5499, 286, 2272, 329, 4600, 51, 62, 15003, 63, 290, 4600, 139, 239, 62, 75, 15, 63, 290, 4238, 4340, 262, 1181, 198, 2, 9633, 286, 2322, 388, 19482, 5387, 2568, 290, 30259, 8122, 13390, 13, 770, 4433, 198, 2, 257, 11315, 422, 4600, 51, 63, 284, 4600, 33643, 68, 62, 600, 44646, 198, 8818, 2315, 62, 568, 346, 0, 7, 1044, 11, 1181, 11, 27506, 11, 1957, 469, 78, 11, 640, 8, 198, 220, 220, 220, 616, 9792, 796, 1288, 4906, 7, 5219, 8, 198, 220, 220, 220, 18074, 239, 62, 75, 796, 616, 9792, 7, 1044, 13, 568, 346, 13, 7050, 13, 36733, 139, 239, 62, 75, 7, 14644, 4008, 198, 220, 220, 220, 7377, 116, 62, 72, 796, 616, 9792, 7, 1044, 13, 568, 346, 13, 7050, 13, 36733, 138, 116, 62, 72, 7, 14644, 4008, 198, 220, 220, 220, 1181, 13, 568, 346, 13, 7050, 13, 139, 239, 62, 75, 796, 18074, 239, 62, 75, 198, 220, 220, 220, 1181, 13, 568, 346, 13, 7050, 13, 138, 116, 62, 72, 796, 7377, 116, 62, 72, 198, 220, 220, 220, 5772, 62, 2617, 796, 1956, 13, 17143, 62, 2617, 628, 220, 220, 220, 7377, 116, 62, 75, 796, 2322, 388, 19482, 62, 39250, 62, 69, 7861, 7, 139, 239, 62, 75, 11, 1956, 13, 568, 346, 13, 17143, 62, 12543, 2733, 13, 1819, 16579, 8, 198, 220, 220, 220, 18074, 223, 66, 62, 9310, 796, 1956, 13, 568, 346, 13, 17143, 62, 12543, 2733, 13, 33643, 66, 62, 9310, 198, 220, 220, 220, 18074, 223, 66, 62, 82, 796, 2322, 388, 19482, 62, 25080, 62, 42404, 7, 138, 116, 62, 75, 11, 7377, 116, 62, 72, 11, 18074, 223, 66, 62, 9310, 11, 5772, 62, 2617, 8, 628, 220, 220, 220, 1181, 13, 568, 346, 13, 25080, 13, 33643, 68, 62, 600, 796, 2322, 388, 19482, 62, 32538, 62, 22554, 7, 198, 220, 220, 220, 220, 220, 220, 220, 7377, 116, 62, 72, 11, 198, 220, 220, 220, 220, 220, 220, 220, 18074, 223, 66, 62, 82, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1956, 13, 568, 346, 13, 25080, 13, 36733, 51, 7, 14644, 828, 198, 220, 220, 220, 220, 220, 220, 220, 5772, 62, 2617, 11, 198, 220, 220, 220, 1267, 198, 437, 26, 198, 198, 2, 36778, 11, 5301, 340, 477, 510, 287, 262, 4600, 22342, 17633, 63, 25, 198, 76, 796, 6379, 17633, 7, 198, 220, 220, 220, 5772, 62, 2617, 11, 198, 220, 220, 220, 285, 62, 568, 346, 26, 198, 220, 220, 220, 18645, 62, 17561, 1756, 796, 47125, 11, 198, 220, 220, 220, 2723, 796, 4237, 11, 198, 220, 220, 220, 2315, 62, 5219, 62, 1676, 4593, 15132, 796, 2315, 62, 568, 346, 28265, 198, 1776, 198, 198, 2, 1303, 10934, 262, 18640, 7386, 11, 1540, 332, 11, 290, 869, 10146, 198, 198, 26230, 62, 11250, 796, 13963, 37573, 13, 28008, 25896, 38149, 7, 198, 220, 220, 220, 366, 22342, 17633, 1600, 198, 220, 220, 220, 399, 62, 35428, 11, 198, 220, 220, 220, 497, 10671, 62, 1851, 11, 198, 220, 220, 220, 1976, 9806, 11, 198, 220, 220, 220, 5772, 62, 2617, 11, 198, 220, 220, 220, 285, 26, 198, 220, 220, 220, 1976, 1084, 796, 1976, 1084, 11, 198, 220, 220, 220, 29052, 62, 69, 22564, 62, 11085, 62, 2875, 796, 5694, 45, 6975, 605, 37, 22564, 5962, 18743, 22784, 198, 1776, 628, 198, 82, 14375, 62, 11250, 796, 198, 220, 220, 220, 13963, 37573, 13, 50, 14375, 38149, 7, 83, 15, 11, 640, 437, 11, 4639, 62, 11250, 11, 267, 2934, 62, 28664, 796, 288, 83, 1776, 198, 198, 67, 70, 796, 1540, 332, 62, 11250, 13, 67, 70, 198, 48, 796, 1540, 332, 62, 11250, 13, 48, 198, 5219, 62, 19199, 796, 357, 2964, 4593, 15132, 22784, 47105, 28129, 22784, 17701, 1153, 37, 22564, 28955, 198, 67, 684, 62, 3258, 796, 360, 713, 58, 11600, 62, 1659, 62, 77, 375, 282, 62, 27219, 7, 82, 14375, 62, 11250, 11, 1181, 62, 19199, 26, 987, 79, 796, 2081, 15437, 198, 2435, 62, 7890, 796, 19446, 58, 15, 60, 198, 47423, 796, 42044, 14134, 10146, 13, 6109, 55, 8890, 1741, 7575, 7, 16833, 62, 87, 62, 14323, 1741, 62, 2435, 8, 466, 198, 220, 220, 220, 288, 684, 796, 8633, 62, 1659, 62, 77, 375, 282, 62, 27219, 7, 82, 14375, 62, 11250, 11, 1181, 62, 19199, 26, 987, 79, 796, 2081, 8, 198, 220, 220, 220, 4574, 0, 7, 67, 684, 62, 3258, 11, 288, 684, 8, 198, 220, 220, 220, 4574, 0, 7, 2435, 62, 7890, 11, 651, 2435, 7, 82, 14375, 62, 11250, 13, 82, 14375, 4008, 198, 220, 220, 220, 2147, 198, 437, 26, 198, 198, 2, 1303, 5660, 262, 18640, 11, 290, 7110, 262, 5072, 198, 37649, 37573, 13, 37669, 0, 7, 82, 14375, 62, 11250, 26, 2836, 62, 13345, 10146, 796, 357, 47423, 11, 18125, 198, 198, 89, 796, 651, 62, 89, 7, 82, 14375, 62, 11250, 13, 67, 70, 13, 25928, 26, 42721, 62, 646, 12272, 796, 2081, 1776, 198, 198, 22915, 62, 15908, 796, 2488, 834, 34720, 834, 26, 198, 198, 28015, 6978, 7, 22915, 62, 15908, 1776, 198, 198, 39344, 62, 29487, 7, 198, 220, 220, 220, 1976, 11, 198, 220, 220, 220, 640, 62, 7890, 30109, 16, 11, 1467, 11, 3261, 11, 6337, 11907, 24457, 357, 1899, 1635, 3126, 828, 198, 220, 220, 220, 288, 684, 62, 3258, 30109, 16, 11, 1467, 11, 3261, 11, 6337, 60, 4357, 198, 220, 220, 220, 5855, 568, 346, 13, 7050, 13, 139, 239, 62, 75, 1600, 828, 198, 220, 220, 220, 4654, 6978, 7, 22915, 62, 15908, 11, 366, 5908, 396, 495, 62, 29487, 13, 11134, 15341, 198, 220, 220, 220, 2124, 18242, 796, 366, 139, 239, 62, 75, 1600, 198, 220, 220, 220, 331, 18242, 796, 366, 89, 357, 76, 42501, 198, 220, 220, 220, 640, 62, 41667, 796, 366, 71, 3808, 33172, 198, 8, 198, 2, 5145, 58, 16151, 5908, 396, 495, 62, 29487, 13, 11134, 8, 198, 198, 39344, 62, 29487, 7, 198, 220, 220, 220, 1976, 11, 198, 220, 220, 220, 640, 62, 7890, 30109, 16, 11, 1467, 11, 3261, 11, 6337, 11907, 24457, 357, 1899, 1635, 3126, 828, 198, 220, 220, 220, 288, 684, 62, 3258, 30109, 16, 11, 1467, 11, 3261, 11, 6337, 60, 4357, 198, 220, 220, 220, 5855, 568, 346, 13, 7050, 13, 138, 116, 62, 72, 1600, 828, 198, 220, 220, 220, 4654, 6978, 7, 22915, 62, 15908, 11, 366, 501, 62, 29487, 13, 11134, 15341, 198, 220, 220, 220, 2124, 18242, 796, 366, 138, 116, 62, 72, 1600, 198, 220, 220, 220, 331, 18242, 796, 366, 89, 357, 76, 42501, 198, 220, 220, 220, 640, 62, 41667, 796, 366, 71, 3808, 33172, 198, 220, 220, 220, 8177, 796, 1058, 22487, 3506, 11, 198, 8, 198, 2, 5145, 58, 16151, 501, 62, 29487, 13, 11134, 8, 198, 39344, 62, 29487, 7, 198, 220, 220, 220, 1976, 11, 198, 220, 220, 220, 640, 62, 7890, 30109, 16, 11, 1467, 11, 3261, 11, 6337, 11907, 24457, 357, 1899, 1635, 3126, 828, 198, 220, 220, 220, 288, 684, 62, 3258, 30109, 16, 11, 1467, 11, 3261, 11, 6337, 60, 4357, 198, 220, 220, 220, 5855, 568, 346, 13, 25080, 13, 51, 1600, 828, 198, 220, 220, 220, 4654, 6978, 7, 22915, 62, 15908, 11, 366, 51, 62, 29487, 13, 11134, 15341, 198, 220, 220, 220, 2124, 18242, 796, 366, 51, 357, 42, 42501, 198, 220, 220, 220, 331, 18242, 796, 366, 89, 357, 76, 42501, 198, 220, 220, 220, 640, 62, 41667, 796, 366, 71, 3808, 33172, 198, 8, 198, 2, 5145, 58, 16151, 51, 62, 29487, 13, 11134, 8, 198, 198, 2, 1303, 34420, 284, 1366, 198, 2, 770, 1366, 373, 6492, 416, 514, 422, 262, 5538, 286, 685, 39, 44038, 15724, 16151, 31, 66, 578, 828, 475, 373, 6198, 6492, 198, 2, 416, 685, 44, 528, 519, 22200, 19891, 16151, 31, 66, 578, 737, 1400, 4049, 9210, 547, 2098, 11, 290, 356, 4398, 470, 5554, 1431, 262, 4049, 287, 674, 198, 2, 31850, 286, 262, 1366, 422, 4263, 13, 198, 19608, 292, 316, 796, 45908, 36918, 2848, 7, 198, 220, 220, 220, 2488, 834, 34720, 834, 11, 198, 220, 220, 220, 318, 28920, 7, 1136, 7, 1677, 53, 11, 366, 25690, 1600, 366, 4943, 828, 198, 220, 220, 220, 366, 76, 528, 519, 22200, 1600, 198, 220, 220, 220, 45908, 8979, 58, 8001, 29660, 8979, 7, 198, 220, 220, 220, 220, 220, 220, 220, 19016, 796, 366, 5450, 1378, 9948, 13670, 13, 3524, 13, 785, 14, 28710, 14, 12708, 14, 18, 87, 2127, 19, 81, 2543, 23, 84, 25964, 14761, 18863, 36260, 66, 5488, 21, 26377, 13976, 358, 13, 40664, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 29472, 796, 366, 76, 528, 519, 22200, 62, 439, 62, 7890, 13, 40664, 1600, 198, 220, 220, 220, 10612, 4357, 198, 1776, 198, 19608, 292, 316, 62, 6978, 796, 651, 62, 7890, 62, 43551, 7, 19608, 292, 316, 1776, 198, 7890, 796, 4654, 6978, 7, 19608, 292, 316, 62, 6978, 11, 366, 76, 528, 519, 22200, 62, 439, 62, 7890, 13, 40664, 4943, 198, 9310, 796, 1100, 25404, 76, 7, 7890, 11, 705, 4032, 8, 198, 24425, 796, 288, 82, 58, 45299, 352, 7131, 17, 25, 437, 60, 198, 85, 86, 66, 796, 288, 82, 58, 45299, 362, 7131, 17, 25, 437, 60, 24457, 1802, 13, 15, 198, 18053, 796, 288, 82, 58, 45299, 513, 7131, 17, 25, 437, 60, 198, 27932, 62, 1065, 71, 796, 2250, 764, 855, 1105, 198, 27932, 62, 1731, 71, 796, 2250, 764, 855, 1987, 198, 27932, 62, 1120, 71, 796, 2250, 764, 855, 2026, 26, 198, 198, 29487, 62, 1065, 71, 796, 198, 220, 220, 220, 41058, 7, 85, 86, 66, 58, 27932, 62, 1065, 71, 4357, 532, 18053, 58, 27932, 62, 1065, 71, 4357, 6167, 796, 366, 1600, 3124, 796, 366, 14225, 1154, 4943, 198, 29487, 0, 7, 198, 220, 220, 220, 288, 684, 62, 3258, 58, 1485, 7131, 1, 568, 346, 13, 7050, 13, 138, 116, 62, 72, 8973, 764, 10, 288, 684, 62, 3258, 58, 1485, 7131, 1, 568, 346, 13, 7050, 13, 139, 239, 62, 75, 33116, 198, 220, 220, 220, 1976, 11, 198, 220, 220, 220, 6167, 796, 366, 1600, 198, 220, 220, 220, 3124, 796, 366, 14809, 1600, 198, 8, 198, 29487, 0, 7, 7839, 796, 366, 1065, 71, 4943, 198, 29487, 0, 7, 87, 2475, 796, 685, 15, 13, 17, 11, 657, 13, 2816, 12962, 198, 29487, 0, 7, 742, 3378, 796, 685, 15, 13, 17, 11, 657, 13, 18, 11, 657, 13, 19, 11, 657, 13, 20, 12962, 198, 29487, 0, 7, 2645, 9608, 796, 366, 48791, 357, 76, 8, 15341, 198, 198, 29487, 62, 1731, 71, 796, 198, 220, 220, 220, 41058, 7, 85, 86, 66, 58, 27932, 62, 1731, 71, 4357, 532, 18053, 58, 27932, 62, 1731, 71, 4357, 6167, 796, 366, 6601, 1600, 3124, 796, 366, 14225, 1154, 4943, 198, 29487, 0, 7, 198, 220, 220, 220, 288, 684, 62, 3258, 58, 1495, 7131, 1, 568, 346, 13, 7050, 13, 138, 116, 62, 72, 8973, 764, 10, 288, 684, 62, 3258, 58, 1495, 7131, 1, 568, 346, 13, 7050, 13, 139, 239, 62, 75, 33116, 198, 220, 220, 220, 1976, 11, 198, 220, 220, 220, 6167, 796, 366, 8890, 1741, 1600, 198, 220, 220, 220, 3124, 796, 366, 14809, 1600, 198, 8, 198, 29487, 0, 7, 7839, 796, 366, 1731, 71, 4943, 198, 29487, 0, 7, 1455, 437, 796, 1058, 22487, 3506, 8, 198, 29487, 0, 7, 87, 2475, 796, 685, 15, 13, 17, 11, 657, 13, 2816, 12962, 198, 29487, 0, 7, 742, 3378, 796, 685, 15, 13, 17, 11, 657, 13, 18, 11, 657, 13, 19, 11, 657, 13, 20, 36563, 198, 198, 29487, 62, 1120, 71, 796, 198, 220, 220, 220, 41058, 7, 85, 86, 66, 58, 27932, 62, 1120, 71, 4357, 532, 18053, 58, 27932, 62, 1120, 71, 4357, 6167, 796, 366, 1600, 3124, 796, 366, 14225, 1154, 4943, 198, 29487, 0, 7, 198, 220, 220, 220, 288, 684, 62, 3258, 58, 4349, 7131, 1, 568, 346, 13, 7050, 13, 138, 116, 62, 72, 8973, 764, 10, 288, 684, 62, 3258, 58, 4349, 7131, 1, 568, 346, 13, 7050, 13, 139, 239, 62, 75, 33116, 198, 220, 220, 220, 1976, 11, 198, 220, 220, 220, 6167, 796, 366, 1600, 198, 220, 220, 220, 3124, 796, 366, 14809, 1600, 198, 8, 198, 29487, 0, 7, 7839, 796, 366, 1120, 71, 4943, 198, 29487, 0, 7, 87, 2475, 796, 685, 15, 13, 17, 11, 657, 13, 2816, 12962, 198, 29487, 0, 7, 742, 3378, 796, 685, 15, 13, 17, 11, 657, 13, 18, 11, 657, 13, 19, 11, 657, 13, 20, 36563, 198, 198, 29487, 7, 29487, 62, 1065, 71, 11, 7110, 62, 1731, 71, 11, 7110, 62, 1120, 71, 11, 12461, 796, 357, 16, 11, 513, 4008, 198, 29487, 0, 7, 87, 18242, 796, 366, 138, 116, 62, 75, 10, 138, 116, 62, 72, 4943, 198, 21928, 5647, 7203, 76, 528, 519, 22200, 62, 7890, 62, 785, 1845, 1653, 13, 11134, 4943, 198, 2, 5145, 58, 16151, 76, 528, 519, 22200, 62, 7890, 62, 785, 1845, 1653, 13, 11134, 8, 198, 198, 2, 1303, 27766, 290, 9104, 50125, 341, 198, 198, 2, 1675, 2221, 11, 1309, 338, 12414, 326, 262, 16611, 294, 707, 2723, 3381, 3436, 4055, 274, 1660, 2347, 11, 355, 198, 2, 340, 45104, 198, 198, 2, 7559, 198, 2, 18074, 223, 62, 75, 3467, 47172, 62, 83, 139, 239, 62, 75, 1343, 18074, 223, 62, 72, 3467, 47172, 62, 83, 138, 116, 62, 72, 796, 532, 37, 62, 51, 1343, 376, 62, 51, 796, 657, 198, 2, 7559, 198, 198, 2, 7406, 11, 356, 6901, 703, 356, 8160, 4600, 37, 62, 51, 44646, 198, 2, 383, 33989, 3754, 12, 2601, 1758, 88, 1313, 357, 4093, 8, 16022, 15738, 257, 3833, 12, 11498, 21069, 12133, 1863, 543, 734, 198, 2, 21164, 460, 763, 12, 38476, 13, 632, 18533, 326, 262, 21164, 389, 379, 4961, 5951, 290, 18895, 13, 198, 2, 1114, 1660, 287, 9260, 11, 2158, 11, 262, 8122, 1660, 6461, 3833, 4600, 33643, 62, 75, 308, 18074, 230, 47671, 810, 198, 2, 4600, 139, 230, 63, 318, 262, 2603, 1173, 2785, 13, 317, 517, 2276, 1296, 286, 262, 12624, 16022, 3578, 329, 1180, 198, 2, 18895, 287, 262, 734, 21164, 13, 19672, 262, 4771, 3833, 318, 2077, 284, 307, 6632, 11, 543, 318, 6397, 198, 2, 329, 5576, 30192, 20884, 38750, 13, 554, 24725, 38750, 11, 20884, 460, 1085, 284, 339, 2703, 286, 262, 9260, 543, 198, 2, 356, 466, 407, 2746, 13, 2293, 326, 13196, 318, 925, 11, 356, 7330, 326, 11, 2174, 20884, 357, 15506, 51, 1279, 309, 62, 69, 15506, 8, 198, 198, 2, 7559, 198, 2, 3467, 31944, 90, 26059, 62, 75, 18477, 33643, 62, 75, 92, 796, 406, 62, 69, 3467, 31944, 90, 67, 51, 18477, 51, 5512, 198, 2, 7559, 198, 198, 2, 393, 198, 198, 2, 7559, 198, 2, 279, 62, 75, 796, 279, 23330, 75, 11, 15, 92, 1343, 406, 62, 69, 18074, 223, 62, 75, 3467, 31944, 90, 51, 12, 51, 62, 69, 18477, 51, 62, 69, 92, 3467, 11018, 9948, 90, 39, 92, 7, 51, 62, 69, 12, 51, 8, 198, 2, 7559, 198, 198, 2, 810, 356, 423, 9672, 326, 9672, 4600, 51, 63, 318, 1474, 262, 20884, 966, 11, 290, 788, 198, 2, 6157, 257, 8121, 1193, 5487, 286, 262, 2604, 283, 342, 76, 11, 198, 2, 290, 356, 389, 15482, 262, 20884, 966, 8862, 11, 543, 318, 1402, 357, 1203, 621, 530, 4922, 8, 329, 198, 2, 1729, 12, 565, 323, 38750, 13, 1867, 356, 423, 28427, 1740, 318, 2252, 4893, 287, 685, 35, 439, 5840, 3713, 9804, 16151, 31, 66, 578, 8, 290, 685, 42, 1601, 306, 74, 54, 39036, 11231, 6390, 16151, 31, 66, 578, 737, 198, 198, 2, 1867, 428, 15565, 318, 326, 2029, 262, 20884, 966, 11, 262, 3833, 318, 4961, 284, 7559, 79, 23330, 75, 11, 15, 92, 15506, 11, 198, 2, 543, 318, 4795, 286, 5951, 13, 4874, 262, 5951, 10532, 2174, 262, 20884, 966, 11, 198, 2, 262, 3833, 10532, 13, 4619, 3161, 284, 20884, 11, 262, 3833, 7559, 79, 23330, 75, 11, 15, 92, 15506, 318, 4961, 284, 198, 2, 4600, 33643, 62, 75, 308, 18074, 230, 7, 138, 116, 62, 75, 8, 47671, 1660, 23247, 20884, 3436, 357, 19419, 17609, 8, 815, 15959, 29565, 35, 439, 5840, 3713, 9804, 16151, 31, 66, 578, 8, 2599, 198, 198, 2, 7559, 198, 2, 279, 23330, 75, 11, 15, 92, 796, 18074, 223, 62, 75, 308, 18074, 230, 7, 138, 116, 62, 75, 10, 33643, 62, 72, 138, 116, 62, 72, 14, 33643, 62, 75, 8, 198, 2, 7559, 198, 198, 2, 810, 4600, 139, 230, 63, 318, 262, 2603, 1173, 2785, 2163, 286, 5719, 5215, 794, 1452, 13, 1629, 1123, 2239, 11, 356, 760, 1111, 198, 2, 262, 1660, 290, 4771, 10154, 11, 355, 880, 355, 262, 5951, 11, 290, 460, 788, 8494, 329, 198, 198, 2, 7559, 198, 2, 7377, 116, 23330, 75, 92, 61, 9, 796, 357, 26180, 12, 138, 116, 62, 81, 8, 18074, 230, 36796, 12, 16, 92, 7, 79, 62, 75, 29006, 33643, 62, 75, 308, 4008, 1343, 7377, 116, 62, 81, 13, 198, 2, 7559, 198, 198, 2, 1114, 20884, 11, 262, 16611, 294, 707, 2163, 4600, 37, 62, 51, 63, 318, 4961, 284, 198, 198, 2, 7559, 198, 2, 376, 62, 51, 796, 3467, 31944, 90, 16, 18477, 32830, 92, 18074, 223, 62, 75, 357, 138, 116, 62, 75, 12, 138, 116, 23330, 75, 92, 61, 28104, 3467, 11018, 9948, 90, 39, 92, 7, 51, 62, 69, 12, 51, 8, 3467, 11018, 9948, 90, 39, 92, 7, 138, 116, 62, 75, 12, 138, 116, 23330, 75, 92, 61, 28104, 198, 2, 7559, 198, 198, 2, 543, 6774, 262, 4600, 138, 116, 62, 75, 63, 284, 257, 1988, 543, 45104, 4600, 79, 62, 75, 796, 18074, 223, 62, 75, 308, 18074, 230, 7, 138, 116, 62, 75, 8, 44646, 198, 2, 770, 318, 1521, 11, 287, 674, 18640, 11, 356, 766, 262, 8122, 198, 2, 1660, 13390, 10581, 257, 6937, 1088, 657, 13, 46396, 287, 262, 12912, 3814, 11, 2138, 621, 262, 29598, 13390, 198, 2, 286, 657, 13, 30484, 11, 393, 657, 13, 770, 4069, 318, 6515, 11, 329, 1672, 11, 287, 262, 10256, 286, 685, 54, 39036, 11231, 9804, 16151, 31, 66, 578, 737, 198, 198, 2, 4900, 428, 3164, 743, 7603, 326, 356, 815, 6330, 262, 3833, 1182, 12655, 287, 262, 198, 2, 814, 11350, 1660, 28462, 3381, 287, 14743, 16022, 29565, 35, 439, 5840, 3713, 9804, 16151, 31, 66, 578, 36911, 356, 466, 407, 466, 523, 379, 1944, 13, 1081, 884, 11, 356, 743, 407, 307, 21128, 198, 2, 262, 5202, 286, 1660, 1088, 262, 20884, 2166, 6105, 13, 2102, 11, 356, 991, 12414, 3960, 418, 8110, 11, 543, 198, 2, 318, 262, 5202, 286, 1660, 3371, 262, 20884, 2166, 11, 422, 262, 3684, 42005, 1735, 13, 1081, 262, 1660, 44389, 11, 262, 8122, 198, 2, 1660, 2695, 10532, 11, 198, 2, 4634, 510, 257, 4025, 31312, 287, 2603, 1173, 2785, 1973, 262, 20884, 2166, 11, 543, 18616, 18644, 5202, 198, 2, 1028, 13522, 13, 770, 318, 10678, 780, 262, 2472, 1660, 2695, 379, 262, 1353, 318, 4025, 379, 262, 886, 286, 262, 198, 2, 18640, 198, 2, 621, 340, 373, 379, 4600, 83, 28, 15, 63, 357, 12518, 340, 373, 657, 13, 2091, 737, 198, 198, 2, 770, 2746, 24242, 422, 1854, 357, 68, 13, 70, 13, 685, 38490, 353, 9804, 16151, 31, 66, 578, 828, 685, 39, 44038, 15724, 16151, 31, 66, 578, 828, 685, 35, 439, 5840, 3713, 9804, 16151, 31, 66, 578, 4008, 220, 287, 326, 340, 4433, 514, 284, 900, 257, 1661, 38765, 329, 262, 7108, 1487, 11, 4600, 32830, 44646, 198, 2, 554, 257, 717, 12, 2875, 198, 2, 7108, 6801, 11, 262, 5951, 318, 5969, 981, 262, 3306, 41270, 4894, 318, 2035, 2626, 393, 8618, 416, 262, 198, 2, 1080, 13, 220, 16583, 3255, 198, 2, 2458, 287, 5387, 2568, 2233, 284, 17609, 1660, 11, 356, 561, 1607, 628, 198, 2, 7559, 198, 2, 3467, 47172, 62, 83, 18074, 223, 68, 23330, 600, 92, 3467, 1324, 13907, 357, 33643, 62, 75, 269, 62, 75, 3467, 47172, 62, 83, 7377, 116, 62, 75, 1343, 18074, 223, 62, 72, 269, 62, 72, 3467, 47172, 62, 83, 7377, 116, 62, 72, 8, 357, 51, 12, 51, 62, 15, 8, 532, 33643, 62, 72, 406, 62, 69, 3467, 47172, 62, 83, 7377, 116, 62, 72, 198, 2, 7559, 198, 198, 2, 7559, 198, 2, 796, 47527, 66, 62, 72, 12, 66, 62, 75, 8, 357, 51, 12, 51, 62, 15, 8, 532, 43, 62, 69, 60, 37, 62, 51, 3467, 1324, 13907, 532, 43, 62, 69, 376, 62, 51, 198, 2, 7559, 198, 198, 2, 393, 198, 198, 2, 7559, 198, 2, 376, 62, 51, 42783, 3467, 31944, 90, 43000, 91, 24861, 229, 31185, 51, 91, 18477, 43, 62, 69, 92, 42783, 59, 31944, 90, 43000, 18477, 66, 136, 225, 37455, 89, 31185, 32239, 31944, 90, 66, 136, 225, 930, 24861, 224, 89, 51, 91, 37455, 89, 18477, 43, 62, 69, 92, 198, 2, 7559, 198, 198, 2, 9524, 198, 198, 2, 7559, 198, 2, 46651, 42783, 46651, 23330, 43, 9328, 32239, 31944, 90, 33643, 62, 75, 43, 62, 69, 357, 26180, 12, 138, 116, 62, 81, 8, 18477, 66, 136, 225, 930, 24861, 224, 89, 51, 91, 37455, 89, 92, 198, 2, 7559, 198, 198, 2, 351, 198, 198, 2, 7559, 198, 2, 46651, 23330, 43, 9328, 92, 28, 269, 136, 225, 37455, 89, 31185, 14, 43000, 198, 2, 7559, 198, 198, 2, 770, 318, 262, 1988, 356, 779, 13, 770, 2331, 284, 670, 22668, 329, 21128, 20884, 2166, 43594, 290, 198, 2, 3960, 418, 8110, 11, 2884, 17909, 351, 685, 44, 528, 519, 22200, 19891, 16151, 31, 66, 578, 828, 475, 356, 1410, 284, 32302, 340, 287, 262, 2003, 13, 1114, 1672, 11, 198, 2, 356, 466, 407, 766, 257, 1913, 5951, 38008, 379, 262, 20884, 966, 29565, 54, 39036, 11231, 9804, 16151, 31, 66, 578, 36911, 198, 2, 543, 356, 561, 1607, 981, 262, 7108, 1487, 318, 1609, 870, 13, 29544, 453, 11, 428, 1661, 38765, 635, 10975, 262, 19363, 1108, 286, 262, 20884, 2166, 11, 543, 674, 18640, 2705, 641, 13, 198, 198, 2, 1303, 31458, 198, 2, 532, 685, 44, 528, 519, 22200, 19891, 16151, 31, 66, 578, 8, 198, 2, 532, 685, 39, 44038, 15724, 16151, 31, 66, 578, 8, 198, 2, 532, 685, 35, 439, 5840, 3713, 9804, 16151, 31, 66, 578, 8, 198, 2, 532, 685, 42, 1601, 306, 74, 54, 39036, 11231, 6390, 16151, 31, 66, 578, 8, 198, 2, 532, 685, 54, 39036, 11231, 9804, 16151, 31, 66, 578, 8, 198, 2, 532, 685, 38490, 353, 9804, 16151, 31, 66, 578, 8, 198, 198, 2, 685, 61, 64, 5974, 198, 2, 220, 220, 220, 220, 220, 220, 5740, 326, 4600, 138, 116, 62, 72, 63, 318, 1464, 5716, 355, 257, 1172, 43758, 7885, 198, 2, 220, 220, 220, 220, 220, 220, 287, 262, 4600, 2396, 346, 19184, 17633, 47671, 475, 351, 198, 2, 220, 220, 220, 220, 220, 220, 6632, 2846, 319, 262, 371, 7998, 4556, 20884, 290, 294, 707, 278, 318, 1210, 319, 11, 355, 9555, 287, 428, 198, 2, 220, 220, 220, 220, 220, 220, 11808, 13, 1320, 1724, 326, 262, 2836, 714, 11, 287, 7989, 11, 900, 262, 4238, 4006, 284, 307, 1729, 22570, 198, 2, 220, 220, 220, 220, 220, 220, 357, 63, 138, 116, 62, 72, 7, 87, 11, 331, 11, 1976, 837, 83, 28, 15, 8, 796, 657, 63, 318, 262, 4277, 828, 543, 287, 1210, 561, 1249, 257, 1729, 22570, 4600, 138, 116, 62, 72, 63, 198, 2, 220, 220, 220, 220, 220, 220, 7034, 284, 2689, 1243, 588, 18411, 3189, 3458, 11, 3503, 11, 198, 2, 220, 220, 220, 220, 220, 220, 287, 257, 6414, 835, 13, 2102, 11, 340, 561, 407, 307, 20326, 326, 7559, 138, 116, 62, 75, 10, 138, 116, 62, 72, 3467, 293, 80, 7377, 121, 15506, 11, 780, 612, 561, 198, 2, 220, 220, 220, 220, 220, 220, 307, 645, 11887, 17795, 262, 8122, 290, 1660, 2695, 284, 1123, 584, 11, 290, 484, 389, 4795, 198, 2, 220, 220, 220, 220, 220, 220, 9633, 287, 674, 2746, 13, 775, 836, 470, 21786, 428, 852, 257, 2219, 779, 1339, 13, 198 ]
2.546769
6,917
module FractionalTransforms using LinearAlgebra, DSP, ToeplitzMatrices, FFTW include("frft.jl") include("frst.jl") include("frct.jl") export frft export freq_shear, time_shear, sinc_interp export frst export frct end
[ 21412, 376, 7861, 282, 8291, 23914, 198, 198, 3500, 44800, 2348, 29230, 11, 360, 4303, 11, 1675, 68, 489, 4224, 19044, 45977, 11, 376, 9792, 54, 198, 198, 17256, 7203, 8310, 701, 13, 20362, 4943, 198, 17256, 7203, 8310, 301, 13, 20362, 4943, 198, 17256, 7203, 8310, 310, 13, 20362, 4943, 198, 198, 39344, 1216, 701, 198, 39344, 2030, 80, 62, 7091, 283, 11, 640, 62, 7091, 283, 11, 264, 1939, 62, 3849, 79, 198, 198, 39344, 1216, 301, 198, 39344, 1216, 310, 198, 198, 437 ]
2.569767
86
<filename>src/operations.jl # Submodule for basic wavelets operations ################################################### # Function that remove empty trailing dimensions function trim_dim(x) if size(x,3)==1 x = x[:,:,1]; if size(x,2)==1 x = x[:,1]; end end return x; end # trim_dim ################################################### # Function that make a subsampling of an array # along dimension d """ ... subsampling(x,d=1,p=2) subsampling of an array x, along dimension d, by a factor of p, for d≤3 ... """ function subsampling(x,d=1,p=2) if d==1 y = x[1:p:end,:,:]; elseif d==2 y = x[:,1:p:end,:]; elseif d==3 y = x[:,:,1:p:end]; else error("Not implemented"); end y = trim_dim(y); return y; end # subsampling ################################################### # Function that make a upsampling of an array # along dimension d """ ... upsampling(x,d=1,p=2) upsampling of an array x, along dimension d, by a factor of p, for d≤3 ... """ function upsampling(x,d=1,p=2) if d==1 y = zeros(p*size(x,1),size(x,2),size(x,3)); y[1:p:end,:,:] = x; elseif d==2 y = zeros(size(x,1),p*size(x,2),size(x,3)); y[:,1:p:end,:] = x; elseif d==3 y = zeros(size(x,1),size(x,2),p*size(x,3)); y[:,:,1:p:end] = x; else error("Not implemented"); end y = trim_dim(y); return y; end # upsampling ################################################### # Function to compute the spatial domain circular # convolution of two signals """ ... cconv(x,h,d=1) circular convolution along dimension d, of signals x and h ... """ function cconvol(x,h,d=1) # If p=length(h) is odd then h((p+1)/2) corresponds to the zero position. # If p is even, h(p/2) corresponds to the zero position. if d==2 return ( cconvol( x',h, 1 )' ); elseif d==3 # permute do not exists in python return permute( cconvol( permute(x,[3, 2, 1]),h), [3 2 1]); end p = length(h); if mod(p,2)==0 pc = p/2; else pc = (p+1)/2; end y = zeros(size(x)); for i=1:length(h) y = y + h[i]*circshift(x,i-pc); end return y; end # cconvol ##################################### # Function that flips a vector """ ... reverse(x::Array) flips a vector ... """ function reverse(x) return x[length(x):-1:1]; end # function x = reverse(x) ##################################### # Function that computes the mirror # filter """ ... mirror(h::Array) computes the mirror filter of h[n], namely g[n] = (-1)^(1-n) h[1-n] ... """ function mirror(h) cat(1, 0, h[length(h):-1:2]) .* ( (-1).^(1:length(h)) ) end #mirror ##################################### # Function that clamps a value """ ... clamp(x::Array, a=0,b=1) clamps a value in [a,b](=[0,1] by default) ... """ function clamp(x,a=0,b=1) y = max(x,a); y = min(y,b); return y; end # clamp ######################################### # Function to subselect dimensions in an # array function subselectdim(f,sel,d) g = []; if d==1 g = f[sel,:,:]; elseif d==2 g = f[:,sel,:]; elseif d==3 g = f[:,:,sel]; end return trim_dim(g); end ######################################### # Function to assign value to elements # of an array function subassign(f,sel,g) d = ndims(f); if d==1 f[sel] = g; elseif d==2 f[sel,sel] = g; elseif d==3 f[sel,sel,sel] = g; end return f; end # subassign ######################################### # Function to select elements of an array function subselect(f,sel) d = ndims(f) if d==1 return f[sel]; elseif d==2 return f[sel,sel]; elseif d==3 return f[sel,sel,sel]; end return []; end ############################################################## # Function to perform wavelet orthognal transform of a signal # f0, with Jmin minimum scale, dir dirección, and h a filter """ ... perform_wavortho_transform(f0:::Array, Jmin:::int,dir,h) computes the wavelet transform of a signal f0, with Jmin as the minimum scale in the direction dir∈{-1,1} ... """ function perform_wavortho_transf(f0,Jmin,dir,h) n = size(f0,1); Jmax = round(Int64,log2(n))-1; g = [0; h[length(h):-1:2]] .* (-1).^(1:length(h)); f = copy(f0) if dir==1 ### FORWARD ### for j=Jmax:-1:Jmin sel = 1:2^(j+1); a = subselect(f,sel); for d=1:ndims(f) a = cat(d, subsampling(cconvol(a,h,d),d), subsampling(cconvol(a,g,d),d) ); end f = subassign(f,sel,a); end else ### FORWARD ### for j=Jmin:Jmax sel = 1:2^(j+1); a = subselect(f,sel); for d=1:ndims(f) w = subselectdim(a,2^j+1:2^(j+1),d); a = subselectdim(a,1:2^j,d); a = cconvol(upsampling(a,d),reverse(h),d) + cconvol(upsampling(w,d),reverse(g),d); end f = subassign(f,sel,a); end end return f; end # perform_wavortho_transf ##################################################### # Function that computes the signal to noise radio """ ... snr(x::Array,y:::Array) computes the siganl to noise radio of a original clean signal x and a denoised signal y ... """ function snr(x,y) return 20*log10(norm(x[:])/norm(x[:]-y[:])); end # snr
[ 27, 34345, 29, 10677, 14, 3575, 602, 13, 20362, 198, 2, 3834, 21412, 329, 4096, 6769, 5289, 4560, 628, 198, 29113, 14468, 21017, 198, 2, 15553, 326, 4781, 6565, 25462, 15225, 198, 8818, 15797, 62, 27740, 7, 87, 8, 198, 197, 361, 2546, 7, 87, 11, 18, 8, 855, 16, 198, 197, 197, 87, 796, 2124, 58, 45299, 45299, 16, 11208, 198, 197, 197, 361, 2546, 7, 87, 11, 17, 8, 855, 16, 198, 197, 197, 197, 87, 796, 2124, 58, 45299, 16, 11208, 198, 197, 197, 437, 198, 197, 437, 198, 197, 7783, 2124, 26, 198, 437, 1303, 15797, 62, 27740, 220, 198, 198, 29113, 14468, 21017, 198, 2, 15553, 326, 787, 257, 6352, 321, 11347, 286, 281, 7177, 198, 2, 1863, 15793, 288, 198, 37811, 198, 986, 198, 7266, 37687, 11347, 7, 87, 11, 67, 28, 16, 11, 79, 28, 17, 8, 6352, 321, 11347, 286, 281, 7177, 2124, 11, 1863, 15793, 288, 11, 416, 257, 198, 31412, 286, 279, 11, 329, 288, 35705, 97, 18, 198, 986, 198, 37811, 198, 8818, 6352, 321, 11347, 7, 87, 11, 67, 28, 16, 11, 79, 28, 17, 8, 198, 197, 361, 288, 855, 16, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 796, 2124, 58, 16, 25, 79, 25, 437, 11, 45299, 25, 11208, 198, 197, 17772, 361, 288, 855, 17, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 796, 2124, 58, 45299, 16, 25, 79, 25, 437, 11, 25, 11208, 198, 197, 17772, 361, 288, 855, 18, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 796, 2124, 58, 45299, 45299, 16, 25, 79, 25, 437, 11208, 198, 197, 17772, 198, 197, 220, 220, 220, 220, 220, 220, 220, 4049, 7203, 3673, 9177, 15341, 198, 197, 437, 198, 197, 88, 796, 15797, 62, 27740, 7, 88, 1776, 198, 197, 7783, 331, 26, 198, 437, 1303, 6352, 321, 11347, 198, 198, 29113, 14468, 21017, 198, 2, 15553, 326, 787, 257, 19649, 321, 11347, 286, 281, 7177, 198, 2, 1863, 15793, 288, 198, 37811, 198, 986, 198, 4739, 321, 11347, 7, 87, 11, 67, 28, 16, 11, 79, 28, 17, 8, 19649, 321, 11347, 286, 281, 7177, 2124, 11, 1863, 15793, 288, 11, 416, 257, 198, 31412, 286, 279, 11, 329, 288, 35705, 97, 18, 198, 986, 198, 37811, 198, 8818, 19649, 321, 11347, 7, 87, 11, 67, 28, 16, 11, 79, 28, 17, 8, 198, 197, 361, 288, 855, 16, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 796, 1976, 27498, 7, 79, 9, 7857, 7, 87, 11, 16, 828, 7857, 7, 87, 11, 17, 828, 7857, 7, 87, 11, 18, 18125, 220, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 58, 16, 25, 79, 25, 437, 11, 45299, 47715, 796, 2124, 26, 198, 197, 17772, 361, 288, 855, 17, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 796, 1976, 27498, 7, 7857, 7, 87, 11, 16, 828, 79, 9, 7857, 7, 87, 11, 17, 828, 7857, 7, 87, 11, 18, 18125, 220, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 58, 45299, 16, 25, 79, 25, 437, 11, 47715, 796, 2124, 26, 198, 197, 17772, 361, 288, 855, 18, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 796, 1976, 27498, 7, 7857, 7, 87, 11, 16, 828, 7857, 7, 87, 11, 17, 828, 79, 9, 7857, 7, 87, 11, 18, 18125, 220, 198, 197, 220, 220, 220, 220, 220, 220, 220, 331, 58, 45299, 45299, 16, 25, 79, 25, 437, 60, 796, 2124, 26, 198, 197, 17772, 198, 197, 220, 220, 220, 220, 220, 220, 220, 4049, 7203, 3673, 9177, 15341, 198, 197, 437, 198, 197, 88, 796, 15797, 62, 27740, 7, 88, 1776, 198, 197, 198, 197, 7783, 331, 26, 198, 437, 1303, 19649, 321, 11347, 628, 198, 29113, 14468, 21017, 198, 2, 15553, 284, 24061, 262, 21739, 7386, 18620, 198, 2, 3063, 2122, 286, 734, 10425, 220, 198, 37811, 198, 986, 198, 535, 261, 85, 7, 87, 11, 71, 11, 67, 28, 16, 8, 18620, 3063, 2122, 1863, 15793, 288, 11, 286, 220, 198, 12683, 874, 2124, 290, 289, 220, 198, 986, 198, 37811, 198, 8818, 269, 1102, 10396, 7, 87, 11, 71, 11, 67, 28, 16, 8, 198, 197, 2, 220, 220, 1002, 279, 28, 13664, 7, 71, 8, 318, 5629, 788, 289, 19510, 79, 10, 16, 20679, 17, 8, 24866, 284, 262, 6632, 2292, 13, 198, 197, 2, 220, 220, 1002, 279, 318, 772, 11, 289, 7, 79, 14, 17, 8, 24866, 284, 262, 6632, 2292, 13, 198, 197, 361, 288, 855, 17, 198, 197, 220, 220, 220, 1441, 357, 269, 1102, 10396, 7, 2124, 3256, 71, 11, 352, 1267, 6, 5619, 198, 197, 17772, 361, 288, 855, 18, 198, 197, 197, 2, 9943, 1133, 466, 407, 7160, 287, 21015, 198, 197, 220, 220, 220, 1441, 9943, 1133, 7, 269, 1102, 10396, 7, 9943, 1133, 7, 87, 17414, 18, 11, 362, 11, 352, 46570, 71, 828, 685, 18, 362, 352, 36563, 220, 220, 198, 197, 437, 198, 197, 79, 796, 4129, 7, 71, 1776, 198, 197, 361, 953, 7, 79, 11, 17, 8, 855, 15, 198, 197, 220, 220, 220, 40653, 796, 279, 14, 17, 26, 198, 197, 17772, 198, 197, 220, 220, 220, 40653, 796, 357, 79, 10, 16, 20679, 17, 26, 198, 197, 437, 198, 197, 88, 796, 1976, 27498, 7, 7857, 7, 87, 18125, 198, 197, 1640, 1312, 28, 16, 25, 13664, 7, 71, 8, 198, 197, 220, 220, 220, 331, 796, 331, 1343, 289, 58, 72, 60, 9, 21170, 30846, 7, 87, 11, 72, 12, 14751, 1776, 220, 220, 198, 197, 437, 198, 197, 7783, 331, 26, 198, 437, 1303, 269, 1102, 10396, 198, 198, 29113, 4242, 2, 198, 2, 15553, 326, 45971, 257, 15879, 198, 37811, 198, 986, 198, 50188, 7, 87, 3712, 19182, 8, 45971, 257, 15879, 198, 986, 198, 37811, 198, 8818, 9575, 7, 87, 8, 198, 197, 7783, 2124, 58, 13664, 7, 87, 2599, 12, 16, 25, 16, 11208, 198, 437, 220, 1303, 2163, 2124, 796, 9575, 7, 87, 8, 198, 198, 29113, 4242, 2, 198, 2, 15553, 326, 552, 1769, 262, 10162, 220, 198, 2, 8106, 198, 37811, 198, 986, 198, 10793, 1472, 7, 71, 3712, 19182, 8, 552, 1769, 262, 10162, 8106, 286, 289, 58, 77, 4357, 14811, 198, 70, 58, 77, 60, 796, 13841, 16, 8, 61, 7, 16, 12, 77, 8, 289, 58, 16, 12, 77, 60, 198, 986, 198, 37811, 198, 8818, 10162, 7, 71, 8, 198, 197, 9246, 7, 16, 11, 657, 11, 289, 58, 13664, 7, 71, 2599, 12, 16, 25, 17, 12962, 764, 9, 357, 13841, 16, 737, 61, 7, 16, 25, 13664, 7, 71, 4008, 1267, 198, 437, 1303, 10793, 1472, 198, 198, 29113, 4242, 2, 198, 2, 15553, 326, 537, 9430, 257, 1988, 198, 37811, 198, 986, 198, 565, 696, 7, 87, 3712, 19182, 11, 257, 28, 15, 11, 65, 28, 16, 8, 537, 9430, 257, 1988, 287, 685, 64, 11, 65, 16151, 41888, 15, 11, 16, 60, 416, 4277, 8, 198, 986, 198, 37811, 198, 8818, 29405, 7, 87, 11, 64, 28, 15, 11, 65, 28, 16, 8, 198, 197, 88, 796, 3509, 7, 87, 11, 64, 1776, 198, 197, 88, 796, 949, 7, 88, 11, 65, 1776, 198, 197, 7783, 331, 26, 198, 198, 437, 1303, 29405, 198, 198, 29113, 7804, 2, 198, 2, 15553, 284, 850, 19738, 15225, 287, 281, 220, 198, 2, 7177, 198, 8818, 850, 19738, 27740, 7, 69, 11, 741, 11, 67, 8, 198, 197, 70, 796, 25787, 198, 197, 361, 288, 855, 16, 198, 197, 220, 220, 220, 308, 796, 277, 58, 741, 11, 45299, 25, 11208, 198, 197, 17772, 361, 288, 855, 17, 198, 197, 220, 220, 220, 308, 796, 277, 58, 45299, 741, 11, 25, 11208, 198, 197, 17772, 361, 288, 855, 18, 198, 197, 220, 220, 220, 308, 796, 277, 58, 45299, 45299, 741, 11208, 198, 197, 437, 198, 197, 7783, 15797, 62, 27740, 7, 70, 1776, 198, 437, 628, 198, 29113, 7804, 2, 198, 2, 15553, 284, 8333, 1988, 284, 4847, 198, 2, 286, 281, 7177, 198, 8818, 850, 562, 570, 7, 69, 11, 741, 11, 70, 8, 198, 197, 67, 796, 299, 67, 12078, 7, 69, 1776, 198, 197, 361, 288, 855, 16, 198, 197, 220, 220, 220, 277, 58, 741, 60, 796, 308, 26, 198, 197, 17772, 361, 288, 855, 17, 198, 197, 220, 220, 220, 277, 58, 741, 11, 741, 60, 796, 308, 26, 198, 197, 17772, 361, 288, 855, 18, 198, 197, 220, 220, 220, 277, 58, 741, 11, 741, 11, 741, 60, 796, 308, 26, 198, 197, 437, 198, 197, 7783, 277, 26, 198, 437, 1303, 850, 562, 570, 628, 198, 29113, 7804, 2, 198, 2, 15553, 284, 2922, 4847, 286, 281, 7177, 198, 8818, 850, 19738, 7, 69, 11, 741, 8, 198, 197, 67, 796, 299, 67, 12078, 7, 69, 8, 198, 220, 220, 220, 611, 288, 855, 16, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 277, 58, 741, 11208, 198, 220, 220, 220, 2073, 361, 288, 855, 17, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 277, 58, 741, 11, 741, 11208, 198, 220, 220, 220, 2073, 361, 288, 855, 18, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 277, 58, 741, 11, 741, 11, 741, 11208, 198, 197, 437, 198, 197, 7783, 25787, 198, 437, 628, 198, 29113, 14468, 7804, 4242, 2235, 198, 2, 15553, 284, 1620, 6769, 1616, 29617, 2360, 282, 6121, 286, 257, 6737, 198, 2, 277, 15, 11, 351, 449, 1084, 5288, 5046, 11, 26672, 19958, 35764, 18840, 11, 290, 289, 257, 8106, 198, 37811, 198, 986, 198, 525, 687, 62, 45137, 1506, 78, 62, 35636, 7, 69, 15, 3712, 25, 19182, 11, 449, 1084, 3712, 25, 600, 11, 15908, 11, 71, 8, 552, 1769, 198, 1169, 6769, 1616, 6121, 286, 257, 6737, 277, 15, 11, 351, 449, 1084, 355, 262, 5288, 220, 198, 9888, 287, 262, 4571, 26672, 24861, 230, 90, 12, 16, 11, 16, 92, 220, 198, 986, 198, 37811, 198, 8818, 1620, 62, 45137, 1506, 78, 62, 7645, 69, 7, 69, 15, 11, 41, 1084, 11, 15908, 11, 71, 8, 628, 197, 77, 796, 2546, 7, 69, 15, 11, 16, 1776, 220, 198, 197, 41, 9806, 796, 2835, 7, 5317, 2414, 11, 6404, 17, 7, 77, 4008, 12, 16, 26, 220, 628, 197, 70, 796, 685, 15, 26, 289, 58, 13664, 7, 71, 2599, 12, 16, 25, 17, 11907, 764, 9, 13841, 16, 737, 61, 7, 16, 25, 13664, 7, 71, 18125, 628, 197, 69, 796, 4866, 7, 69, 15, 8, 198, 197, 361, 26672, 855, 16, 198, 197, 220, 220, 220, 44386, 7473, 39743, 44386, 198, 197, 220, 220, 220, 329, 474, 28, 41, 9806, 21912, 16, 25, 41, 1084, 198, 197, 220, 220, 220, 220, 220, 220, 220, 384, 75, 796, 352, 25, 17, 61, 7, 73, 10, 16, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 257, 796, 850, 19738, 7, 69, 11, 741, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 329, 288, 28, 16, 25, 358, 12078, 7, 69, 8, 198, 197, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 3797, 7, 67, 11, 6352, 321, 11347, 7, 535, 261, 10396, 7, 64, 11, 71, 11, 67, 828, 67, 828, 6352, 321, 11347, 7, 535, 261, 10396, 7, 64, 11, 70, 11, 67, 828, 67, 8, 5619, 198, 197, 220, 220, 220, 220, 220, 220, 220, 886, 198, 197, 220, 220, 220, 220, 220, 220, 220, 277, 796, 850, 562, 570, 7, 69, 11, 741, 11, 64, 1776, 198, 197, 220, 220, 220, 886, 198, 197, 17772, 198, 197, 220, 220, 220, 44386, 7473, 39743, 44386, 198, 197, 220, 220, 220, 329, 474, 28, 41, 1084, 25, 41, 9806, 198, 197, 220, 220, 220, 220, 220, 220, 220, 384, 75, 796, 352, 25, 17, 61, 7, 73, 10, 16, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 257, 796, 850, 19738, 7, 69, 11, 741, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 329, 288, 28, 16, 25, 358, 12078, 7, 69, 8, 198, 197, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 266, 796, 850, 19738, 27740, 7, 64, 11, 17, 61, 73, 10, 16, 25, 17, 61, 7, 73, 10, 16, 828, 67, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 850, 19738, 27740, 7, 64, 11, 16, 25, 17, 61, 73, 11, 67, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 269, 1102, 10396, 7, 4739, 321, 11347, 7, 64, 11, 67, 828, 50188, 7, 71, 828, 67, 8, 1343, 269, 1102, 10396, 7, 4739, 321, 11347, 7, 86, 11, 67, 828, 50188, 7, 70, 828, 67, 1776, 198, 197, 220, 220, 220, 220, 220, 220, 220, 886, 198, 197, 220, 220, 220, 220, 220, 220, 220, 277, 796, 850, 562, 570, 7, 69, 11, 741, 11, 64, 1776, 198, 197, 220, 220, 220, 886, 220, 220, 220, 220, 198, 197, 437, 198, 197, 7783, 277, 26, 198, 437, 1303, 1620, 62, 45137, 1506, 78, 62, 7645, 69, 198, 198, 29113, 14468, 4242, 2, 198, 2, 15553, 326, 552, 1769, 262, 6737, 284, 7838, 5243, 198, 37811, 198, 986, 198, 16184, 81, 7, 87, 3712, 19182, 11, 88, 3712, 25, 19182, 8, 552, 1769, 262, 264, 5516, 75, 284, 7838, 5243, 198, 1659, 257, 2656, 3424, 6737, 2124, 290, 257, 2853, 78, 1417, 6737, 331, 198, 986, 198, 37811, 198, 8818, 3013, 81, 7, 87, 11, 88, 8, 198, 197, 7783, 1160, 9, 6404, 940, 7, 27237, 7, 87, 58, 25, 12962, 14, 27237, 7, 87, 58, 25, 45297, 88, 58, 25, 12962, 1776, 198, 437, 1303, 3013, 81, 198 ]
2.269917
2,297
using ArcadeLearningEnvironment using CGP using Logging using Images function play_qbert() game = Game("qbert", 0) reward = 0 frames = 0 while ~game_over(game.ale) inputs = get_inputs(game) action = 0 if inputs[13076] > 0 action = 2 end reward += act(game.ale, Cint(action)) frames += 1 screen = draw(game) for pixel_i in -1:1:1 for pixel_j in -1:1:1 if ~(pixel_i == 0 && pixel_j == 0) screen[56+pixel_i, 63+pixel_j] = RGB{Float64}(1.0, 1.0, 1.0) end end end save(@sprintf("qbert/frame_%06d.png", frames), screen) end close!(game) reward end function random_breakout_expert(nin::Int64, nout::Int64) # TODO: debug / rewrite without segmentation c = HPCGPChromo(nin, nout) pos = sort!(rand(15)) c.genes[1] = pos[1] for out in nin+(1:nout) c.genes[out] = pos[15] end c.genes[nin+4] = pos[13] c.genes[nin+5] = pos[14] CGP.set_genes!(c, nin+1, [ pos[2], rand(), rand(), CGP.Config.func2f(CGP.Config.f_const), 0.6]) CGP.set_genes!(c, nin+2, [ pos[3], rand(), rand(), CGP.Config.func2f(CGP.Config.f_const), 0.8]) CGP.set_genes!(c, nin+3, [ pos[4], pos[1], rand(), CGP.Config.func2f(CGP.Config.f_felzenszwalb), 0.8]) CGP.set_genes!(c, nin+4, [ pos[5], pos[4], pos[2], CGP.Config.func2f(CGP.Config.f_gt), rand()]) CGP.set_genes!(c, nin+5, [ pos[6], pos[4], pos[3], CGP.Config.func2f(CGP.Config.f_lt), rand()]) CGP.set_genes!(c, nin+6, [ pos[7], pos[4], pos[3], CGP.Config.func2f(CGP.Config.f_gt), rand()]) CGP.set_genes!(c, nin+7, [ pos[8], pos[5], pos[6], CGP.Config.func2f(CGP.Config.f_and), rand()]) CGP.set_genes!(c, nin+8, [ pos[9], pos[7], rand(), CGP.Config.func2f(CGP.Config.f_com), rand()]) CGP.set_genes!(c, nin+9, [ pos[10], pos[8], rand(), CGP.Config.func2f(CGP.Config.f_com), rand()]) CGP.set_genes!(c, nin+10, [ pos[11], pos[9], rand(), CGP.Config.func2f(CGP.Config.f_last), rand()]) CGP.set_genes!(c, nin+11, [ pos[12], pos[10], rand(), CGP.Config.func2f(CGP.Config.f_last), rand()]) CGP.set_genes!(c, nin+12, [ pos[13], pos[11], pos[12], CGP.Config.func2f(CGP.Config.f_gt), rand()]) CGP.set_genes!(c, nin+13, [ pos[14], pos[11], pos[12], CGP.Config.func2f(CGP.Config.f_lt), rand()]) CGP.set_genes!(c, nin+14, [ pos[15], rand(), rand(), CGP.Config.func2f(CGP.Config.f_zeros), rand()]) HPCGPChromo(c.genes, nin, nout) end function get_breakout_action(inputs::Array{Float64}) action = 2 bullet_box = inputs[94:189, 9:152]; slider_box = inputs[190:192, 9:152]; bullet_poses = find(bullet_box) slider_poses = find(slider_box) if length(bullet_poses) > 0 && length(slider_poses) > 0 bullet_pos = mean(map(x->ind2sub(bullet_box, x)[2], bullet_poses)) slider_pos = mean(map(x->ind2sub(slider_box, x)[2], slider_poses)) if bullet_pos < slider_pos action = 5 else action = 4 end end action end function play_breakout() game = Game("breakout") reward = 0 frames = 0 act(game.ale, game.actions[2]) life = lives(game.ale) while ~game_over(game.ale) action = game.actions[2] if lives(game.ale) < life life = lives(game.ale) else inputs = get_inputs(game) action = game.actions[get_breakout_action(inputs)] end reward += act(game.ale, action) frames += 1 screen = draw(game) save(@sprintf("breakout/frame_%06d.png", frames), screen) end close!(game) reward end # ACTION_MEANING = { # 0 : "NOOP", # 1 : "FIRE", # 2 : "UP", # 3 : "RIGHT", # 4 : "LEFT", # 5 : "DOWN", # 6 : "UPRIGHT", # 7 : "UPLEFT", # 8 : "DOWNRIGHT", # 9 : "DOWNLEFT", # 10 : "UPFIRE", # 11 : "RIGHTFIRE", # 12 : "LEFTFIRE", # 13 : "DOWNFIRE", # 14 : "UPRIGHTFIRE", # 15 : "UPLEFTFIRE", # 16 : "DOWNRIGHTFIRE", # 17 : "DOWNLEFTFIRE", # }
[ 3500, 23190, 41730, 31441, 198, 3500, 327, 16960, 198, 3500, 5972, 2667, 198, 3500, 5382, 628, 198, 8818, 711, 62, 80, 4835, 3419, 198, 220, 220, 220, 983, 796, 3776, 7203, 80, 4835, 1600, 657, 8, 198, 220, 220, 220, 6721, 796, 657, 198, 220, 220, 220, 13431, 796, 657, 198, 220, 220, 220, 981, 5299, 6057, 62, 2502, 7, 6057, 13, 1000, 8, 198, 220, 220, 220, 220, 220, 220, 220, 17311, 796, 651, 62, 15414, 82, 7, 6057, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2223, 796, 657, 198, 220, 220, 220, 220, 220, 220, 220, 611, 17311, 58, 12952, 4304, 60, 1875, 657, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2223, 796, 362, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 6721, 15853, 719, 7, 6057, 13, 1000, 11, 327, 600, 7, 2673, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 13431, 15853, 352, 198, 220, 220, 220, 220, 220, 220, 220, 3159, 796, 3197, 7, 6057, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 17465, 62, 72, 287, 532, 16, 25, 16, 25, 16, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 17465, 62, 73, 287, 532, 16, 25, 16, 25, 16, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 5299, 7, 32515, 62, 72, 6624, 657, 11405, 17465, 62, 73, 6624, 657, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3159, 58, 3980, 10, 32515, 62, 72, 11, 8093, 10, 32515, 62, 73, 60, 796, 25228, 90, 43879, 2414, 92, 7, 16, 13, 15, 11, 352, 13, 15, 11, 352, 13, 15, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 3613, 7, 31, 82, 37435, 7203, 80, 4835, 14, 14535, 62, 4, 3312, 67, 13, 11134, 1600, 13431, 828, 3159, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1969, 0, 7, 6057, 8, 198, 220, 220, 220, 6721, 198, 437, 198, 198, 8818, 4738, 62, 9032, 448, 62, 1069, 11766, 7, 35073, 3712, 5317, 2414, 11, 299, 448, 3712, 5317, 2414, 8, 198, 220, 220, 220, 1303, 16926, 46, 25, 14257, 1220, 28183, 1231, 10618, 341, 198, 220, 220, 220, 269, 796, 367, 5662, 16960, 1925, 398, 78, 7, 35073, 11, 299, 448, 8, 198, 220, 220, 220, 1426, 796, 3297, 0, 7, 25192, 7, 1314, 4008, 198, 220, 220, 220, 269, 13, 5235, 274, 58, 16, 60, 796, 1426, 58, 16, 60, 198, 220, 220, 220, 329, 503, 287, 13462, 33747, 16, 25, 77, 448, 8, 198, 220, 220, 220, 220, 220, 220, 220, 269, 13, 5235, 274, 58, 448, 60, 796, 1426, 58, 1314, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 269, 13, 5235, 274, 58, 35073, 10, 19, 60, 796, 1426, 58, 1485, 60, 198, 220, 220, 220, 269, 13, 5235, 274, 58, 35073, 10, 20, 60, 796, 1426, 58, 1415, 60, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 16, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 17, 4357, 43720, 22784, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 9979, 828, 657, 13, 21, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 17, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 18, 4357, 43720, 22784, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 9979, 828, 657, 13, 23, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 18, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 19, 4357, 1426, 58, 16, 4357, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 69, 417, 8247, 89, 16783, 65, 828, 657, 13, 23, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 19, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 20, 4357, 1426, 58, 19, 4357, 1426, 58, 17, 4357, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 13655, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 20, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 21, 4357, 1426, 58, 19, 4357, 1426, 58, 18, 4357, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 2528, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 21, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 22, 4357, 1426, 58, 19, 4357, 1426, 58, 18, 4357, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 13655, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 22, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 23, 4357, 1426, 58, 20, 4357, 1426, 58, 21, 4357, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 392, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 23, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 24, 4357, 1426, 58, 22, 4357, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 785, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 24, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 940, 4357, 1426, 58, 23, 4357, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 785, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 940, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 1157, 4357, 1426, 58, 24, 4357, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 12957, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 1157, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 1065, 4357, 1426, 58, 940, 4357, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 12957, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 1065, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 1485, 4357, 1426, 58, 1157, 4357, 1426, 58, 1065, 4357, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 13655, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 1485, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 1415, 4357, 1426, 58, 1157, 4357, 1426, 58, 1065, 4357, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 2528, 828, 43720, 3419, 12962, 198, 220, 220, 220, 327, 16960, 13, 2617, 62, 5235, 274, 0, 7, 66, 11, 13462, 10, 1415, 11, 685, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 58, 1314, 4357, 43720, 22784, 43720, 22784, 327, 16960, 13, 16934, 13, 20786, 17, 69, 7, 34, 16960, 13, 16934, 13, 69, 62, 9107, 418, 828, 43720, 3419, 12962, 198, 220, 220, 220, 367, 5662, 16960, 1925, 398, 78, 7, 66, 13, 5235, 274, 11, 13462, 11, 299, 448, 8, 198, 437, 198, 198, 8818, 651, 62, 9032, 448, 62, 2673, 7, 15414, 82, 3712, 19182, 90, 43879, 2414, 30072, 198, 220, 220, 220, 2223, 796, 362, 198, 220, 220, 220, 10492, 62, 3524, 796, 17311, 58, 5824, 25, 23362, 11, 860, 25, 17827, 11208, 198, 220, 220, 220, 28982, 62, 3524, 796, 17311, 58, 19782, 25, 17477, 11, 860, 25, 17827, 11208, 198, 220, 220, 220, 10492, 62, 4832, 796, 1064, 7, 15065, 1616, 62, 3524, 8, 198, 220, 220, 220, 28982, 62, 4832, 796, 1064, 7, 6649, 1304, 62, 3524, 8, 198, 220, 220, 220, 611, 4129, 7, 15065, 1616, 62, 4832, 8, 1875, 657, 11405, 4129, 7, 6649, 1304, 62, 4832, 8, 1875, 657, 198, 220, 220, 220, 220, 220, 220, 220, 10492, 62, 1930, 796, 1612, 7, 8899, 7, 87, 3784, 521, 17, 7266, 7, 15065, 1616, 62, 3524, 11, 2124, 38381, 17, 4357, 10492, 62, 4832, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 28982, 62, 1930, 796, 1612, 7, 8899, 7, 87, 3784, 521, 17, 7266, 7, 6649, 1304, 62, 3524, 11, 2124, 38381, 17, 4357, 28982, 62, 4832, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 611, 10492, 62, 1930, 1279, 28982, 62, 1930, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2223, 796, 642, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2223, 796, 604, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2223, 198, 437, 198, 198, 8818, 711, 62, 9032, 448, 3419, 198, 220, 220, 220, 983, 796, 3776, 7203, 9032, 448, 4943, 198, 220, 220, 220, 6721, 796, 657, 198, 220, 220, 220, 13431, 796, 657, 198, 220, 220, 220, 719, 7, 6057, 13, 1000, 11, 983, 13, 4658, 58, 17, 12962, 198, 220, 220, 220, 1204, 796, 3160, 7, 6057, 13, 1000, 8, 198, 220, 220, 220, 981, 5299, 6057, 62, 2502, 7, 6057, 13, 1000, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2223, 796, 983, 13, 4658, 58, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 611, 3160, 7, 6057, 13, 1000, 8, 1279, 1204, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1204, 796, 3160, 7, 6057, 13, 1000, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 17311, 796, 651, 62, 15414, 82, 7, 6057, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2223, 796, 983, 13, 4658, 58, 1136, 62, 9032, 448, 62, 2673, 7, 15414, 82, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 6721, 15853, 719, 7, 6057, 13, 1000, 11, 2223, 8, 198, 220, 220, 220, 220, 220, 220, 220, 13431, 15853, 352, 198, 220, 220, 220, 220, 220, 220, 220, 3159, 796, 3197, 7, 6057, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3613, 7, 31, 82, 37435, 7203, 9032, 448, 14, 14535, 62, 4, 3312, 67, 13, 11134, 1600, 13431, 828, 3159, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1969, 0, 7, 6057, 8, 198, 220, 220, 220, 6721, 198, 437, 198, 198, 2, 40282, 62, 11682, 1565, 2751, 796, 1391, 198, 2, 220, 220, 220, 220, 657, 1058, 366, 15285, 3185, 1600, 198, 2, 220, 220, 220, 220, 352, 1058, 366, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 362, 1058, 366, 8577, 1600, 198, 2, 220, 220, 220, 220, 513, 1058, 366, 49, 9947, 1600, 198, 2, 220, 220, 220, 220, 604, 1058, 366, 2538, 9792, 1600, 198, 2, 220, 220, 220, 220, 642, 1058, 366, 41925, 1600, 198, 2, 220, 220, 220, 220, 718, 1058, 366, 52, 4805, 9947, 1600, 198, 2, 220, 220, 220, 220, 767, 1058, 366, 8577, 2538, 9792, 1600, 198, 2, 220, 220, 220, 220, 807, 1058, 366, 41925, 49, 9947, 1600, 198, 2, 220, 220, 220, 220, 860, 1058, 366, 41925, 2538, 9792, 1600, 198, 2, 220, 220, 220, 220, 838, 1058, 366, 8577, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1367, 1058, 366, 49, 9947, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1105, 1058, 366, 2538, 9792, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1511, 1058, 366, 41925, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1478, 1058, 366, 52, 4805, 9947, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1315, 1058, 366, 8577, 2538, 9792, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1467, 1058, 366, 41925, 49, 9947, 11674, 2200, 1600, 198, 2, 220, 220, 220, 220, 1596, 1058, 366, 41925, 2538, 9792, 11674, 2200, 1600, 198, 2, 1782, 198 ]
1.904159
2,212
# Mld.jl ###### mld ##### """ mld(v) Compute the Mean log deviation of a vector `v`. # Examples ```julia julia> using Inequality julia> mld([8, 5, 1, 3, 5, 6, 7, 6, 3]) 0.1397460530936332 ``` """ mld(v::AbstractVector{<:Real})::Float64 = log(Statistics.mean(v[v .!= 0])) - Statistics.mean(log.(v[v .!= 0])) ###### weighted mld ##### """ mld(v, w) Compute the weighted Mean log deviation of a vector `v` using weights given by a weight vector `w`. Weights must not be negative, missing or NaN. The weights and data vectors must have the same length. # Examples ```julia julia> using Inequality julia> mld([8, 5, 1, 3, 5, 6, 7, 6, 3], collect(0.1:0.1:0.9)) 0.10375545537468206 ``` """ function mld(v::AbstractVector{<:Real}, w::AbstractVector{<:Real})::Float64 checks_weights(v, w) w = w[v .!= 0] v = v[v .!= 0] return -sum(w .* log.(v/mean(v, weights(w))) ) / sum(w) end function mld(v::AbstractVector{<:Real}, w::AbstractWeights)::Float64 checks_weights(v, w) w = w[v .!= 0] v = v[v .!= 0] return -sum(w .* log.(v/mean(v, weights(w))))/ sum(w) end """ wmld(v, w) Compute the Mean log deviationof `v` with weights `w`. See also [`mld`](@mld) """ wmld(v::AbstractVector{<:Real}, w::AbstractVector{<:Real}) = mld(v, w) wmld(v::AbstractVector{<:Real}, w::AbstractWeights) = mld(v, w)
[ 2, 337, 335, 13, 20362, 628, 198, 4242, 2235, 285, 335, 46424, 198, 37811, 198, 220, 220, 220, 285, 335, 7, 85, 8, 198, 198, 7293, 1133, 262, 22728, 2604, 28833, 286, 257, 15879, 4600, 85, 44646, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 198, 73, 43640, 29, 1262, 554, 48203, 198, 73, 43640, 29, 285, 335, 26933, 23, 11, 642, 11, 352, 11, 513, 11, 642, 11, 718, 11, 767, 11, 718, 11, 513, 12962, 198, 15, 13, 20219, 4524, 32417, 26895, 2623, 32148, 198, 15506, 63, 198, 37811, 198, 76, 335, 7, 85, 3712, 23839, 38469, 90, 27, 25, 15633, 92, 2599, 25, 43879, 2414, 796, 2604, 7, 48346, 13, 32604, 7, 85, 58, 85, 764, 0, 28, 657, 60, 4008, 532, 14370, 13, 32604, 7, 6404, 12195, 85, 58, 85, 764, 0, 28, 657, 60, 4008, 628, 198, 4242, 2235, 26356, 285, 335, 46424, 198, 37811, 198, 220, 220, 220, 285, 335, 7, 85, 11, 266, 8, 198, 198, 7293, 1133, 262, 26356, 22728, 2604, 28833, 286, 257, 15879, 4600, 85, 63, 1262, 19590, 1813, 416, 257, 3463, 15879, 4600, 86, 44646, 198, 198, 1135, 2337, 1276, 407, 307, 4633, 11, 4814, 393, 11013, 45, 13, 383, 19590, 290, 1366, 30104, 1276, 423, 262, 976, 4129, 13, 198, 198, 2, 21066, 198, 15506, 63, 73, 43640, 198, 73, 43640, 29, 1262, 554, 48203, 198, 73, 43640, 29, 285, 335, 26933, 23, 11, 642, 11, 352, 11, 513, 11, 642, 11, 718, 11, 767, 11, 718, 11, 513, 4357, 2824, 7, 15, 13, 16, 25, 15, 13, 16, 25, 15, 13, 24, 4008, 198, 15, 13, 15197, 38172, 30505, 31020, 3104, 22136, 198, 15506, 63, 198, 37811, 198, 8818, 285, 335, 7, 85, 3712, 23839, 38469, 90, 27, 25, 15633, 5512, 266, 3712, 23839, 38469, 90, 27, 25, 15633, 92, 2599, 25, 43879, 2414, 198, 220, 220, 220, 8794, 62, 43775, 7, 85, 11, 266, 8, 198, 220, 220, 220, 266, 796, 266, 58, 85, 764, 0, 28, 657, 60, 198, 220, 220, 220, 410, 796, 410, 58, 85, 764, 0, 28, 657, 60, 628, 220, 220, 220, 1441, 532, 16345, 7, 86, 764, 9, 2604, 12195, 85, 14, 32604, 7, 85, 11, 19590, 7, 86, 22305, 1267, 1220, 2160, 7, 86, 8, 198, 437, 628, 198, 8818, 285, 335, 7, 85, 3712, 23839, 38469, 90, 27, 25, 15633, 5512, 266, 3712, 23839, 1135, 2337, 2599, 25, 43879, 2414, 198, 220, 220, 220, 8794, 62, 43775, 7, 85, 11, 266, 8, 198, 220, 220, 220, 266, 796, 266, 58, 85, 764, 0, 28, 657, 60, 198, 220, 220, 220, 410, 796, 410, 58, 85, 764, 0, 28, 657, 60, 628, 220, 220, 220, 1441, 532, 16345, 7, 86, 764, 9, 2604, 12195, 85, 14, 32604, 7, 85, 11, 19590, 7, 86, 35514, 14, 2160, 7, 86, 8, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 266, 76, 335, 7, 85, 11, 266, 8, 198, 198, 7293, 1133, 262, 22728, 2604, 28833, 1659, 4600, 85, 63, 351, 19590, 4600, 86, 44646, 4091, 635, 685, 63, 76, 335, 63, 16151, 31, 76, 335, 8, 198, 37811, 198, 26377, 335, 7, 85, 3712, 23839, 38469, 90, 27, 25, 15633, 5512, 266, 3712, 23839, 38469, 90, 27, 25, 15633, 30072, 796, 285, 335, 7, 85, 11, 266, 8, 198, 198, 26377, 335, 7, 85, 3712, 23839, 38469, 90, 27, 25, 15633, 5512, 266, 3712, 23839, 1135, 2337, 8, 796, 285, 335, 7, 85, 11, 266, 8 ]
2.322357
577
<reponame>darsnack/TensorBoardLogger.jl """ tags_match_re_im(old_tag, new_tag) If `old_tag` and `new_tag` tag the real part and imaginary part of the same quantity, such as `old_tag = "test/struct/re"` and `new_tag = "test/struct/im"` then returns true. False otherwise """ function tags_match_re_im(old_tag, new_tag) if old_tag[end-2:end] == "/re" old_tag_parts = split(old_tag, "/") new_tag_parts = split(new_tag, "/") if ( all(old_tag_parts[1:end-1] .== new_tag_parts[1:end-1]) && new_tag_parts[end] == "im" ) return true end end return false end """ lookahead_deserialize(old_tag, old_val, summaries, state, type) Looks ahead at state, and checks that the tag of `state` matches `old_tag`, and if so, attempts to combine the value of `state` with that of `old_val`. For example, if `old_tag = "someval/re"` then if `state` contains "someval/im" the two values will be combined as real and immaginary part. Returns a possibly modified tag, a possibily modified value, and the number of states that it has looked ahead. If the lookahead fails to find matching states, he returns (old_tag, old_val, 0) """ function lookahead_deserialize(old_tag, old_val, evs::Summary, state, typ) res = old_tag, old_val, state if typ == :histo res = lookahead_deserialize_histogram_summary(old_tag, old_val, evs, state) elseif typ === :image res = lookahead_deserialize_image_summary(old_tag, old_val, evs, state) elseif typ == :simple_value res = lookahead_deserialize_simple_value_summary(old_tag, old_val, evs, state) end return res end # Lookahead for simple values. # Checks the next entry if it is /re and /im, and combines them function lookahead_deserialize_simple_value_summary(old_tag, old_val, evs::Summary, state) # prepare the default output (when no action is taken) result = old_tag, old_val, state # iterate to the next element res = iterate(evs, state + 1) res == nothing && return result # if the next event is identified, check its type (new_tag, summary), i_state = res typ = summary_type(summary) # if types match, check tags. If they match, return modified structure if typ === :simple_value && tags_match_re_im(old_tag, new_tag) val_im = summary.simple_value result = new_tag[1:end-3], old_val + im*val_im, i_state - 1 else return result end end
[ 27, 7856, 261, 480, 29, 67, 945, 77, 441, 14, 51, 22854, 29828, 11187, 1362, 13, 20362, 198, 37811, 198, 220, 220, 220, 15940, 62, 15699, 62, 260, 62, 320, 7, 727, 62, 12985, 11, 649, 62, 12985, 8, 198, 198, 1532, 4600, 727, 62, 12985, 63, 290, 4600, 3605, 62, 12985, 63, 7621, 262, 1103, 636, 290, 26726, 636, 286, 262, 976, 198, 40972, 414, 11, 884, 355, 4600, 727, 62, 12985, 796, 366, 9288, 14, 7249, 14, 260, 1, 63, 290, 4600, 3605, 62, 12985, 796, 366, 9288, 14, 7249, 14, 320, 1, 63, 198, 8524, 5860, 2081, 13, 10352, 4306, 198, 37811, 198, 8818, 15940, 62, 15699, 62, 260, 62, 320, 7, 727, 62, 12985, 11, 649, 62, 12985, 8, 198, 220, 220, 220, 611, 1468, 62, 12985, 58, 437, 12, 17, 25, 437, 60, 6624, 12813, 260, 1, 198, 220, 220, 220, 220, 220, 220, 220, 1468, 62, 12985, 62, 42632, 796, 6626, 7, 727, 62, 12985, 11, 12813, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 12985, 62, 42632, 796, 6626, 7, 3605, 62, 12985, 11, 12813, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 611, 357, 477, 7, 727, 62, 12985, 62, 42632, 58, 16, 25, 437, 12, 16, 60, 764, 855, 649, 62, 12985, 62, 42632, 58, 16, 25, 437, 12, 16, 12962, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 649, 62, 12985, 62, 42632, 58, 437, 60, 1849, 855, 366, 320, 1, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 3991, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 804, 38204, 62, 8906, 48499, 1096, 7, 727, 62, 12985, 11, 1468, 62, 2100, 11, 30114, 3166, 11, 1181, 11, 2099, 8, 198, 198, 41102, 4058, 379, 1181, 11, 290, 8794, 326, 262, 7621, 286, 4600, 5219, 63, 7466, 4600, 727, 62, 12985, 47671, 290, 198, 361, 523, 11, 6370, 284, 12082, 262, 1988, 286, 4600, 5219, 63, 351, 326, 286, 4600, 727, 62, 2100, 44646, 198, 198, 1890, 1672, 11, 611, 4600, 727, 62, 12985, 796, 366, 11246, 2100, 14, 260, 1, 63, 788, 611, 4600, 5219, 63, 4909, 366, 11246, 2100, 14, 320, 1, 262, 198, 11545, 3815, 481, 307, 5929, 355, 1103, 290, 2296, 363, 3219, 636, 13, 198, 198, 35561, 257, 5457, 9518, 7621, 11, 257, 1184, 571, 813, 9518, 1988, 11, 290, 262, 1271, 198, 1659, 2585, 326, 340, 468, 3114, 4058, 13, 198, 1532, 262, 804, 38204, 10143, 284, 1064, 12336, 2585, 11, 339, 5860, 357, 727, 62, 12985, 11, 1468, 62, 2100, 11, 657, 8, 198, 37811, 198, 8818, 804, 38204, 62, 8906, 48499, 1096, 7, 727, 62, 12985, 11, 1468, 62, 2100, 11, 819, 82, 3712, 22093, 11, 1181, 11, 2170, 8, 198, 220, 220, 220, 581, 796, 1468, 62, 12985, 11, 1468, 62, 2100, 11, 1181, 628, 220, 220, 220, 611, 2170, 6624, 1058, 10034, 78, 198, 220, 220, 220, 220, 220, 220, 220, 581, 796, 804, 38204, 62, 8906, 48499, 1096, 62, 10034, 21857, 62, 49736, 7, 727, 62, 12985, 11, 1468, 62, 2100, 11, 819, 82, 11, 1181, 8, 198, 220, 220, 220, 2073, 361, 2170, 24844, 1058, 9060, 198, 220, 220, 220, 220, 220, 220, 220, 581, 796, 804, 38204, 62, 8906, 48499, 1096, 62, 9060, 62, 49736, 7, 727, 62, 12985, 11, 1468, 62, 2100, 11, 819, 82, 11, 1181, 8, 198, 220, 220, 220, 2073, 361, 2170, 6624, 1058, 36439, 62, 8367, 198, 220, 220, 220, 220, 220, 220, 220, 581, 796, 804, 38204, 62, 8906, 48499, 1096, 62, 36439, 62, 8367, 62, 49736, 7, 727, 62, 12985, 11, 1468, 62, 2100, 11, 819, 82, 11, 1181, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1441, 581, 198, 437, 198, 198, 2, 6803, 38204, 329, 2829, 3815, 13, 198, 2, 1849, 7376, 4657, 262, 1306, 5726, 611, 340, 318, 1220, 260, 290, 1220, 320, 11, 290, 21001, 606, 198, 8818, 804, 38204, 62, 8906, 48499, 1096, 62, 36439, 62, 8367, 62, 49736, 7, 727, 62, 12985, 11, 1468, 62, 2100, 11, 819, 82, 3712, 22093, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1181, 8, 198, 220, 220, 220, 1303, 8335, 262, 4277, 5072, 357, 12518, 645, 2223, 318, 2077, 8, 198, 220, 220, 220, 1255, 796, 1468, 62, 12985, 11, 1468, 62, 2100, 11, 1181, 198, 220, 220, 220, 1303, 11629, 378, 284, 262, 1306, 5002, 198, 220, 220, 220, 581, 796, 11629, 378, 7, 1990, 82, 11, 1181, 1343, 352, 8, 198, 220, 220, 220, 581, 6624, 2147, 11405, 1441, 1255, 628, 220, 220, 220, 1303, 611, 262, 1306, 1785, 318, 5174, 11, 2198, 663, 2099, 198, 220, 220, 220, 357, 3605, 62, 12985, 11, 10638, 828, 1312, 62, 5219, 796, 581, 198, 220, 220, 220, 2170, 796, 10638, 62, 4906, 7, 49736, 8, 628, 220, 220, 220, 1303, 611, 3858, 2872, 11, 2198, 15940, 13, 1002, 484, 2872, 11, 1441, 9518, 4645, 198, 220, 220, 220, 611, 2170, 24844, 1058, 36439, 62, 8367, 11405, 15940, 62, 15699, 62, 260, 62, 320, 7, 727, 62, 12985, 11, 649, 62, 12985, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1188, 62, 320, 796, 10638, 13, 36439, 62, 8367, 198, 220, 220, 220, 220, 220, 220, 220, 1255, 796, 649, 62, 12985, 58, 16, 25, 437, 12, 18, 4357, 1468, 62, 2100, 1343, 545, 9, 2100, 62, 320, 11, 1312, 62, 5219, 532, 352, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 1255, 198, 220, 220, 220, 886, 198, 437, 198 ]
2.534343
990
############################################################################### # Reset and Clear ############################################################################### export @clearsnaps, @clearallsnaps, @resetallsnaps brandnewsnaps!() = begin global _num_trace_locations = 0 empty!(happysnaps) empty!(location_counts) empty!(watched_exprs) end macro resetallsnaps() :(RickTracy.brandnewsnaps!()) |> esc end macro clearallsnaps() :(empty!(RickTracy.happysnaps)) |> esc end clearsnaps(exprstr) = begin #find snaps that match key, and remove them from the happysnaps vector filter!((st)->st.exprstr == exprstr, happysnaps) #slow end macro clearsnaps(exprs...) res = :() for expr in exprs exprstr = "$expr" #expr as a string res = :($res; RickTracy.clearsnaps(exprstr)) end res |> esc end macro clearunwatch(exprs...) :(@unwatch exprs; @clearsnaps(exprs)) |> esc end
[ 29113, 29113, 7804, 4242, 21017, 198, 2, 30027, 290, 11459, 198, 29113, 29113, 7804, 4242, 21017, 198, 39344, 2488, 2375, 945, 77, 1686, 11, 2488, 20063, 5691, 77, 1686, 11, 2488, 42503, 5691, 77, 1686, 198, 198, 17938, 10827, 77, 1686, 0, 3419, 796, 2221, 198, 220, 220, 220, 3298, 4808, 22510, 62, 40546, 62, 17946, 602, 796, 657, 198, 220, 220, 220, 6565, 0, 7, 71, 1324, 893, 77, 1686, 8, 198, 220, 220, 220, 6565, 0, 7, 24886, 62, 9127, 82, 8, 198, 220, 220, 220, 6565, 0, 7, 86, 14265, 62, 31937, 82, 8, 198, 437, 198, 198, 20285, 305, 13259, 5691, 77, 1686, 3419, 198, 220, 220, 220, 36147, 33048, 2898, 1590, 13, 17938, 10827, 77, 1686, 0, 28955, 930, 29, 3671, 198, 437, 198, 198, 20285, 305, 1598, 5691, 77, 1686, 3419, 198, 220, 220, 220, 36147, 28920, 0, 7, 33048, 2898, 1590, 13, 71, 1324, 893, 77, 1686, 4008, 930, 29, 3671, 198, 437, 198, 198, 2375, 945, 77, 1686, 7, 31937, 2536, 8, 796, 2221, 198, 220, 220, 220, 1303, 19796, 23429, 326, 2872, 1994, 11, 290, 4781, 606, 422, 262, 1147, 893, 77, 1686, 15879, 198, 220, 220, 220, 8106, 0, 19510, 301, 8, 3784, 301, 13, 31937, 2536, 6624, 44052, 2536, 11, 1147, 893, 77, 1686, 8, 1303, 38246, 198, 437, 198, 198, 20285, 305, 37526, 77, 1686, 7, 31937, 82, 23029, 198, 220, 220, 220, 581, 796, 1058, 3419, 198, 220, 220, 220, 329, 44052, 287, 1033, 3808, 198, 220, 220, 220, 220, 220, 220, 220, 44052, 2536, 796, 17971, 31937, 1, 1303, 31937, 355, 257, 4731, 198, 220, 220, 220, 220, 220, 220, 220, 581, 796, 1058, 16763, 411, 26, 8759, 2898, 1590, 13, 2375, 945, 77, 1686, 7, 31937, 2536, 4008, 198, 220, 220, 220, 886, 198, 220, 220, 220, 581, 930, 29, 3671, 198, 437, 198, 198, 20285, 305, 1598, 403, 8340, 7, 31937, 82, 23029, 198, 220, 220, 220, 36147, 31, 403, 8340, 1033, 3808, 26, 2488, 2375, 945, 77, 1686, 7, 31937, 82, 4008, 930, 29, 3671, 198, 437, 198 ]
2.747826
345
<gh_stars>1-10 # Script const SIGHASH_ALL = UInt32(1) const SIGHASH_NONE = UInt32(2) const SIGHASH_SINGLE = UInt32(3) const SCRIPT_TYPES = Dict([ ("P2PKH", [0x6f, 0x00]), ("P2SH", [0xc4, 0x05]) ]) # Block GENESIS_BLOCK_HASH = Dict([ (false, hex2bytes("000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f")), (true, hex2bytes("000000000933ea01ad0ee984209779baaec3ced90fa3f408719526f8d77f4943")) ]) # Network USER_AGENT = "/bitcoin.jl:0.1/" const DEFAULT = Dict([ ("version", 70015), ("services", zero(UInt64)), ("ip", ip"0.0.0.0"), ("port", Dict([(false, 8333), (true, 18333)])), ("rpcport", Dict([(false, 8332), (true, 18332)])), ("start_height", zero(UInt32)), ("relay", true) ]) const IPV4_PREFIX = append!(fill(0x00, 10), [0xff, 0xff]) const NODE_URL = "btc.brane.cc" const TX_DATA_TYPE = 1 const BLOCK_DATA_TYPE = 2 const FILTERED_BLOCK_DATA_TYPE = 3 const COMPACT_BLOCK_DATA_TYPE = 4 const DATA_MESSAGE_NAME = Dict([ (1, "MSG_TX"), (2, "MSG_BLOCK"), (3, "MSG_FILTERED_BLOCK"), (4, "MSG_CMPCT_BLOCK"), (5, "MSG_WITNESS_BLOCK"), (6, "MSG_WITNESS_TX"), (7, "MSG_FILTERED_WITNESS_BLOCK")]) const DATA_MESSAGE_TYPE = Dict([ ("MSG_TX", 1), ("MSG_BLOCK", 2), ("MSG_FILTERED_BLOCK", 3), ("MSG_CMPCT_BLOCK", 4), ("MSG_WITNESS_BLOCK", 5), ("MSG_WITNESS_TX", 6), ("MSG_FILTERED_WITNESS_BLOCK", 7)]) """ NETWORK_MAGIC is testnet if `true` """ const NETWORK_MAGIC = Dict([ (false, 0xd9b4bef9) (true, 0x0709110b) ]) SERVICES_NAME = Dict([ (0x0000000000000001, "NODE_NETWORK"), (0x0000000000000002, "NODE_GETUTXO"), (0x0000000000000004, "NODE_BLOOM"), (0x0000000000000008, "NODE_WITNESS"), (0x0000000000000400, "NODE_NETWORK_LIMITED") ])
[ 27, 456, 62, 30783, 29, 16, 12, 940, 198, 2, 12327, 198, 198, 9979, 311, 18060, 11211, 62, 7036, 796, 471, 5317, 2624, 7, 16, 8, 198, 9979, 311, 18060, 11211, 62, 45, 11651, 796, 471, 5317, 2624, 7, 17, 8, 198, 9979, 311, 18060, 11211, 62, 50, 2751, 2538, 796, 471, 5317, 2624, 7, 18, 8, 198, 198, 9979, 6374, 46023, 62, 9936, 47, 1546, 796, 360, 713, 26933, 198, 220, 220, 220, 5855, 47, 17, 40492, 39, 1600, 685, 15, 87, 21, 69, 11, 657, 87, 405, 46570, 198, 220, 220, 220, 5855, 47, 17, 9693, 1600, 685, 15, 25306, 19, 11, 657, 87, 2713, 12962, 198, 12962, 198, 198, 2, 9726, 198, 198, 35353, 1546, 1797, 62, 9148, 11290, 62, 39, 11211, 796, 360, 713, 26933, 198, 220, 220, 220, 357, 9562, 11, 17910, 17, 33661, 7203, 8269, 405, 1129, 67, 2791, 4531, 66, 2919, 20, 3609, 1433, 3365, 3132, 68, 24, 2682, 487, 49641, 3609, 3510, 64, 17, 64, 21, 66, 23628, 65, 18, 69, 16, 65, 1899, 64, 23, 344, 2075, 69, 4943, 828, 198, 220, 220, 220, 357, 7942, 11, 17910, 17, 33661, 7203, 10535, 830, 24, 2091, 18213, 486, 324, 15, 1453, 4089, 19, 22567, 40393, 7012, 64, 721, 18, 771, 3829, 13331, 18, 69, 1821, 5774, 22186, 2075, 69, 23, 67, 3324, 69, 2920, 3559, 48774, 198, 12962, 198, 198, 2, 7311, 198, 198, 29904, 62, 4760, 3525, 796, 12813, 35395, 13, 20362, 25, 15, 13, 16, 30487, 198, 198, 9979, 5550, 38865, 796, 360, 713, 26933, 198, 220, 220, 220, 5855, 9641, 1600, 13037, 1314, 828, 198, 220, 220, 220, 5855, 30416, 1600, 6632, 7, 52, 5317, 2414, 36911, 198, 220, 220, 220, 5855, 541, 1600, 20966, 1, 15, 13, 15, 13, 15, 13, 15, 12340, 198, 220, 220, 220, 5855, 634, 1600, 360, 713, 26933, 7, 9562, 11, 807, 20370, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 7942, 11, 1248, 20370, 8, 12962, 828, 198, 220, 220, 220, 5855, 81, 14751, 634, 1600, 360, 713, 26933, 7, 9562, 11, 807, 32148, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 7942, 11, 1248, 32148, 8, 12962, 828, 198, 220, 220, 220, 5855, 9688, 62, 17015, 1600, 6632, 7, 52, 5317, 2624, 36911, 198, 220, 220, 220, 5855, 2411, 323, 1600, 2081, 8, 198, 12962, 198, 198, 9979, 6101, 53, 19, 62, 47, 31688, 10426, 796, 24443, 0, 7, 20797, 7, 15, 87, 405, 11, 838, 828, 685, 15, 47596, 11, 657, 47596, 12962, 198, 198, 9979, 399, 16820, 62, 21886, 796, 366, 18347, 66, 13, 1671, 1531, 13, 535, 1, 198, 198, 9979, 15326, 62, 26947, 62, 25216, 796, 352, 198, 9979, 9878, 11290, 62, 26947, 62, 25216, 796, 362, 198, 9979, 34020, 5781, 1961, 62, 9148, 11290, 62, 26947, 62, 25216, 796, 513, 198, 9979, 24301, 10659, 62, 9148, 11290, 62, 26947, 62, 25216, 796, 604, 198, 198, 9979, 42865, 62, 44, 1546, 4090, 8264, 62, 20608, 796, 360, 713, 26933, 198, 220, 220, 220, 357, 16, 11, 366, 5653, 38, 62, 29551, 12340, 198, 220, 220, 220, 357, 17, 11, 366, 5653, 38, 62, 9148, 11290, 12340, 198, 220, 220, 220, 357, 18, 11, 366, 5653, 38, 62, 46700, 5781, 1961, 62, 9148, 11290, 12340, 198, 220, 220, 220, 357, 19, 11, 366, 5653, 38, 62, 34, 7378, 4177, 62, 9148, 11290, 12340, 198, 220, 220, 220, 357, 20, 11, 366, 5653, 38, 62, 54, 46144, 62, 9148, 11290, 12340, 198, 220, 220, 220, 357, 21, 11, 366, 5653, 38, 62, 54, 46144, 62, 29551, 12340, 198, 220, 220, 220, 357, 22, 11, 366, 5653, 38, 62, 46700, 5781, 1961, 62, 54, 46144, 62, 9148, 11290, 4943, 12962, 198, 198, 9979, 42865, 62, 44, 1546, 4090, 8264, 62, 25216, 796, 360, 713, 26933, 198, 220, 220, 220, 5855, 5653, 38, 62, 29551, 1600, 352, 828, 198, 220, 220, 220, 5855, 5653, 38, 62, 9148, 11290, 1600, 362, 828, 198, 220, 220, 220, 5855, 5653, 38, 62, 46700, 5781, 1961, 62, 9148, 11290, 1600, 513, 828, 198, 220, 220, 220, 5855, 5653, 38, 62, 34, 7378, 4177, 62, 9148, 11290, 1600, 604, 828, 198, 220, 220, 220, 5855, 5653, 38, 62, 54, 46144, 62, 9148, 11290, 1600, 642, 828, 198, 220, 220, 220, 5855, 5653, 38, 62, 54, 46144, 62, 29551, 1600, 718, 828, 198, 220, 220, 220, 5855, 5653, 38, 62, 46700, 5781, 1961, 62, 54, 46144, 62, 9148, 11290, 1600, 767, 8, 12962, 198, 198, 37811, 198, 12884, 33249, 62, 45820, 2149, 318, 1332, 3262, 611, 4600, 7942, 63, 198, 37811, 198, 9979, 49791, 62, 45820, 2149, 796, 360, 713, 26933, 198, 220, 220, 220, 357, 9562, 11, 657, 24954, 24, 65, 19, 65, 891, 24, 8, 198, 220, 220, 220, 357, 7942, 11, 657, 87, 43509, 6420, 940, 65, 8, 198, 12962, 198, 198, 35009, 53, 34444, 62, 20608, 796, 360, 713, 26933, 198, 220, 220, 220, 357, 15, 87, 8269, 10535, 486, 11, 366, 45, 16820, 62, 12884, 33249, 12340, 198, 220, 220, 220, 357, 15, 87, 8269, 24598, 17, 11, 366, 45, 16820, 62, 18851, 3843, 55, 46, 12340, 198, 220, 220, 220, 357, 15, 87, 8269, 24598, 19, 11, 366, 45, 16820, 62, 9148, 46, 2662, 12340, 198, 220, 220, 220, 357, 15, 87, 8269, 24598, 23, 11, 366, 45, 16820, 62, 54, 46144, 12340, 198, 220, 220, 220, 357, 15, 87, 8269, 20483, 7029, 11, 366, 45, 16820, 62, 12884, 33249, 62, 43, 3955, 22061, 4943, 198, 12962, 198 ]
1.951768
933
module Datasource using ...SimpleTasks.Types import Base export get, put """ get(datasource::DatasourceService, key::AbstractString; force::Bool=false) Returns an IO reading the value in the datasource for the given key. Optionally allow skipping any cached values. """ function get(datasource::DatasourceService, key::AbstractString; override_cache::Bool=false) error("get is not implemented for $datasource") end function Base.getindex(datasource::DatasourceService, key::AbstractString) get(datasource, key) end """ get{String <: AbstractString}(datasource::DatasourceService, key::Array{AbstractString, 1}; Returns multiple IO's reading the value in the datasource for the given keys. Optionally allow skipping any cached values. """ # Using parametrics because as of 0.4.6 can not promote Array{ASCIIString, 1} # to Array{AbstractString, 1} function get{String <: AbstractString}(datasource::DatasourceService, keys::Array{String, 1}; override_cache::Bool=false) return pmap((key) -> Datasource.get(datasource, key; override_cache=override_cache), keys) end function Base.getindex{String <: AbstractString}(datasource::DatasourceService, keys::Array{String, 1}) get(datasource, keys) end """ put!(datasource::DatasourceService, key::AbstractString, new_value::Union{IO, Void}=nothing; only_cache::Bool=false) Put in a new value into the datasource for the given key. The new value can be specified by the input IO or if no IO is specified, it will be pulled from the cache. Optionally allow putting the new value into the cache only. NOTE: The operation is undefined if only_cache = true and input new_value IO is not specified. """ function put!(datasource::DatasourceService, key::AbstractString, new_value::Union{IO, Void}=nothing; only_cache::Bool=false) error("put! is not implemented for $datasource") end function Base.setindex!(datasource::DatasourceService, key::AbstractString, new_value::Union{IO, Void}=nothing; only_cache::Bool=false) put!(datasource, key, new_value) end """ put!{String <: AbstractString, I <: IO}( datasource::DatasourceService, keys::Array{String, 1}, new_values::Array{I, 1}; only_cache::Bool=false) Put in new values into the datasource for the given keys. The new value can be specified by the input IO or if no IO is specified, it will be pulled from the cache. Optionally allow putting the new value into the cache only. NOTE: The operation is undefined if only_cache = false and input new_value IO is not specified. """ # Using parametrics because as of 0.4.6 can not promote Array{ASCIIString, 1} # to Array{AbstractString, 1} function put!{String <: AbstractString, I <: Union{IO, Void}}( datasource::DatasourceService, keys::Array{String, 1}, new_values::Array{I, 1}; only_cache::Bool=false) return pmap((index) -> Datasource.put!(datasource, keys[index], new_values[index]; only_cache=only_cache), 1:length(keys)) end function Base.setindex!{String <: AbstractString, I <: Union{IO, Void}}( datasource::DatasourceService, keys::Array{String, 1}, new_values::Array{I, 1}; only_cache::Bool=false) put!(datasource, keys, new_values) end function put!{String <: AbstractString}( datasource::DatasourceService, keys::Array{String, 1}; only_cache::Bool=false) return pmap((index) -> Datasource.put!(datasource, keys[index], nothing; only_cache=only_cache), 1:length(keys)) end """ clear!(datasource::DatasourceService, key::AbstractString}; only_cache::Bool=false) Delete the value from the datasource. Optionally only delete from cache. Returns datasource and does nothing if key is not found (this is what Julia `Dict` does) """ function Base.delete!(datasource::DatasourceService, key::AbstractString; only_cache::Bool=false) error("delete! is not implemented for $datasource") end """ delete!{String <: AbstractString}(datasource::DatasourceService, keys::Array{String, 1}; only_cache::Bool=false) Delete multiple keys from the datasource. Optionally only delete from cache Returns datasource and does nothing if key is not found (this is what Julia `Dict` does) """ function Base.delete!{String <: AbstractString}(datasource::DatasourceService, keys::Array{String, 1}; only_cache::Bool=false) return pmap((key) -> Datasource.delete!(datasource, key; only_cache=only_cache), keys) end """ clear!() Clear the datasource! """ function clear_cache(datasource::DatasourceService) error("clear_cache! is not implemented for $datasource") end end # module Datasource
[ 21412, 16092, 292, 1668, 198, 198, 3500, 2644, 26437, 51, 6791, 13, 31431, 198, 198, 11748, 7308, 198, 198, 39344, 651, 11, 1234, 198, 198, 37811, 198, 220, 220, 220, 651, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 26, 2700, 3712, 33, 970, 28, 9562, 8, 198, 198, 35561, 281, 24418, 3555, 262, 1988, 287, 262, 19395, 1668, 329, 262, 1813, 1994, 13, 16018, 453, 198, 12154, 31017, 597, 39986, 3815, 13, 198, 37811, 198, 8818, 651, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 26, 198, 220, 220, 220, 220, 220, 220, 220, 20957, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 4049, 7203, 1136, 318, 407, 9177, 329, 720, 19608, 292, 1668, 4943, 198, 437, 198, 8818, 7308, 13, 1136, 9630, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 8, 198, 220, 220, 220, 651, 7, 19608, 292, 1668, 11, 1994, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 651, 90, 10100, 1279, 25, 27741, 10100, 92, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1994, 3712, 19182, 90, 23839, 10100, 11, 352, 19629, 198, 198, 35561, 3294, 24418, 338, 3555, 262, 1988, 287, 262, 19395, 1668, 329, 262, 1813, 8251, 13, 198, 19722, 453, 1249, 31017, 597, 39986, 3815, 13, 198, 37811, 198, 2, 8554, 5772, 316, 10466, 780, 355, 286, 657, 13, 19, 13, 21, 460, 407, 7719, 15690, 90, 42643, 3978, 10100, 11, 352, 92, 198, 2, 284, 15690, 90, 23839, 10100, 11, 352, 92, 198, 8818, 651, 90, 10100, 1279, 25, 27741, 10100, 92, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 198, 220, 220, 220, 220, 220, 220, 220, 8251, 3712, 19182, 90, 10100, 11, 352, 19629, 20957, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 1441, 279, 8899, 19510, 2539, 8, 4613, 16092, 292, 1668, 13, 1136, 7, 19608, 292, 1668, 11, 1994, 26, 198, 220, 220, 220, 220, 220, 220, 220, 20957, 62, 23870, 28, 2502, 13154, 62, 23870, 828, 8251, 8, 198, 437, 198, 8818, 7308, 13, 1136, 9630, 90, 10100, 1279, 25, 27741, 10100, 92, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 198, 220, 220, 220, 220, 220, 220, 220, 8251, 3712, 19182, 90, 10100, 11, 352, 30072, 198, 220, 220, 220, 651, 7, 19608, 292, 1668, 11, 8251, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 1234, 0, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 11, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 8367, 3712, 38176, 90, 9399, 11, 18331, 92, 28, 22366, 26, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 198, 11588, 287, 257, 649, 1988, 656, 262, 19395, 1668, 329, 262, 1813, 1994, 13, 383, 649, 1988, 460, 307, 198, 23599, 416, 262, 5128, 24418, 393, 611, 645, 24418, 318, 7368, 11, 340, 481, 307, 5954, 422, 262, 198, 23870, 13, 16018, 453, 1249, 5137, 262, 649, 1988, 656, 262, 12940, 691, 13, 198, 198, 16580, 25, 383, 4905, 318, 28721, 611, 691, 62, 23870, 796, 2081, 290, 5128, 649, 62, 8367, 24418, 318, 198, 1662, 7368, 13, 198, 37811, 198, 8818, 1234, 0, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 11, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 8367, 3712, 38176, 90, 9399, 11, 18331, 92, 28, 22366, 26, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 4049, 7203, 1996, 0, 318, 407, 9177, 329, 720, 19608, 292, 1668, 4943, 198, 437, 198, 8818, 7308, 13, 2617, 9630, 0, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 11, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 8367, 3712, 38176, 90, 9399, 11, 18331, 92, 28, 22366, 26, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 1234, 0, 7, 19608, 292, 1668, 11, 1994, 11, 649, 62, 8367, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 1234, 0, 90, 10100, 1279, 25, 27741, 10100, 11, 314, 1279, 25, 24418, 92, 7, 198, 220, 220, 220, 220, 220, 220, 220, 19395, 1668, 3712, 27354, 292, 1668, 16177, 11, 8251, 3712, 19182, 90, 10100, 11, 352, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 27160, 3712, 19182, 90, 40, 11, 352, 19629, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 198, 11588, 287, 649, 3815, 656, 262, 19395, 1668, 329, 262, 1813, 8251, 13, 383, 649, 1988, 460, 307, 198, 23599, 416, 262, 5128, 24418, 393, 611, 645, 24418, 318, 7368, 11, 340, 481, 307, 5954, 422, 262, 198, 23870, 13, 16018, 453, 1249, 5137, 262, 649, 1988, 656, 262, 12940, 691, 13, 198, 198, 16580, 25, 383, 4905, 318, 28721, 611, 691, 62, 23870, 796, 3991, 290, 5128, 649, 62, 8367, 24418, 318, 198, 1662, 7368, 13, 198, 37811, 198, 2, 8554, 5772, 316, 10466, 780, 355, 286, 657, 13, 19, 13, 21, 460, 407, 7719, 15690, 90, 42643, 3978, 10100, 11, 352, 92, 198, 2, 284, 15690, 90, 23839, 10100, 11, 352, 92, 198, 8818, 1234, 0, 90, 10100, 1279, 25, 27741, 10100, 11, 314, 1279, 25, 4479, 90, 9399, 11, 18331, 11709, 7, 198, 220, 220, 220, 220, 220, 220, 220, 19395, 1668, 3712, 27354, 292, 1668, 16177, 11, 8251, 3712, 19182, 90, 10100, 11, 352, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 27160, 3712, 19182, 90, 40, 11, 352, 19629, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 1441, 279, 8899, 19510, 9630, 8, 4613, 16092, 292, 1668, 13, 1996, 0, 7, 19608, 292, 1668, 11, 8251, 58, 9630, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 27160, 58, 9630, 11208, 691, 62, 23870, 28, 8807, 62, 23870, 828, 352, 25, 13664, 7, 13083, 4008, 198, 437, 198, 8818, 7308, 13, 2617, 9630, 0, 90, 10100, 1279, 25, 27741, 10100, 11, 314, 1279, 25, 4479, 90, 9399, 11, 18331, 11709, 7, 198, 220, 220, 220, 220, 220, 220, 220, 19395, 1668, 3712, 27354, 292, 1668, 16177, 11, 8251, 3712, 19182, 90, 10100, 11, 352, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 649, 62, 27160, 3712, 19182, 90, 40, 11, 352, 19629, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 1234, 0, 7, 19608, 292, 1668, 11, 8251, 11, 649, 62, 27160, 8, 198, 437, 198, 198, 8818, 1234, 0, 90, 10100, 1279, 25, 27741, 10100, 92, 7, 198, 220, 220, 220, 220, 220, 220, 220, 19395, 1668, 3712, 27354, 292, 1668, 16177, 11, 8251, 3712, 19182, 90, 10100, 11, 352, 19629, 198, 220, 220, 220, 220, 220, 220, 220, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 1441, 279, 8899, 19510, 9630, 8, 4613, 16092, 292, 1668, 13, 1996, 0, 7, 19608, 292, 1668, 11, 8251, 58, 9630, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 2147, 26, 691, 62, 23870, 28, 8807, 62, 23870, 828, 352, 25, 13664, 7, 13083, 4008, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 1598, 0, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 19629, 198, 220, 220, 220, 220, 220, 220, 220, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 198, 38727, 262, 1988, 422, 262, 19395, 1668, 13, 16018, 453, 691, 12233, 422, 12940, 13, 198, 35561, 19395, 1668, 290, 857, 2147, 611, 1994, 318, 407, 1043, 357, 5661, 318, 644, 22300, 198, 63, 35, 713, 63, 857, 8, 198, 37811, 198, 8818, 7308, 13, 33678, 0, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 1994, 3712, 23839, 10100, 26, 198, 220, 220, 220, 220, 220, 220, 220, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 4049, 7203, 33678, 0, 318, 407, 9177, 329, 720, 19608, 292, 1668, 4943, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 12233, 0, 90, 10100, 1279, 25, 27741, 10100, 92, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 198, 220, 220, 220, 220, 220, 220, 220, 8251, 3712, 19182, 90, 10100, 11, 352, 19629, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 198, 38727, 3294, 8251, 422, 262, 19395, 1668, 13, 16018, 453, 691, 12233, 422, 12940, 198, 35561, 19395, 1668, 290, 857, 2147, 611, 1994, 318, 407, 1043, 357, 5661, 318, 644, 22300, 198, 63, 35, 713, 63, 857, 8, 198, 37811, 198, 8818, 7308, 13, 33678, 0, 90, 10100, 1279, 25, 27741, 10100, 92, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 11, 198, 220, 220, 220, 220, 220, 220, 220, 8251, 3712, 19182, 90, 10100, 11, 352, 19629, 691, 62, 23870, 3712, 33, 970, 28, 9562, 8, 198, 220, 220, 220, 1441, 279, 8899, 19510, 2539, 8, 4613, 16092, 292, 1668, 13, 33678, 0, 7, 19608, 292, 1668, 11, 1994, 26, 198, 220, 220, 220, 220, 220, 220, 220, 691, 62, 23870, 28, 8807, 62, 23870, 828, 8251, 8, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 1598, 0, 3419, 198, 198, 19856, 262, 19395, 1668, 0, 198, 37811, 198, 8818, 1598, 62, 23870, 7, 19608, 292, 1668, 3712, 27354, 292, 1668, 16177, 8, 198, 220, 220, 220, 4049, 7203, 20063, 62, 23870, 0, 318, 407, 9177, 329, 720, 19608, 292, 1668, 4943, 198, 437, 198, 198, 437, 1303, 8265, 16092, 292, 1668, 198 ]
2.931832
1,599
@reexport module EmptyReservoirs # Standard library using Statistics using Printf using Dates using RecipesBase using Distributions using Parameters using StochasticPrograms using Flux using HydroModels using HydroModels: AbstractHydroModel, River, Plant, Area, Scenario, Forecaster, forecast import HydroModels: modelindices using Plots: font, text, Shape export EmptyReservoirsData, EmptyReservoirsScenario, EmptyReservoirsSampler, EmptyReservoirsModel include("data.jl") include("scenarios.jl") include("indices.jl") include("model.jl") end
[ 31, 631, 87, 634, 8265, 33523, 4965, 712, 10840, 82, 198, 198, 2, 8997, 5888, 198, 3500, 14370, 198, 3500, 12578, 69, 198, 3500, 44712, 198, 198, 3500, 44229, 14881, 198, 3500, 46567, 507, 198, 3500, 40117, 198, 3500, 520, 5374, 3477, 15167, 82, 198, 3500, 1610, 2821, 198, 3500, 32116, 5841, 1424, 198, 3500, 32116, 5841, 1424, 25, 27741, 40436, 305, 17633, 11, 5866, 11, 16561, 11, 9498, 11, 1446, 39055, 11, 4558, 17970, 11, 11092, 198, 198, 11748, 32116, 5841, 1424, 25, 2746, 521, 1063, 198, 198, 3500, 1345, 1747, 25, 10369, 11, 2420, 11, 25959, 198, 198, 39344, 198, 220, 220, 220, 33523, 4965, 712, 10840, 82, 6601, 11, 198, 220, 220, 220, 33523, 4965, 712, 10840, 82, 3351, 39055, 11, 198, 220, 220, 220, 33523, 4965, 712, 10840, 82, 16305, 20053, 11, 198, 220, 220, 220, 33523, 4965, 712, 10840, 82, 17633, 198, 198, 17256, 7203, 7890, 13, 20362, 4943, 198, 17256, 7203, 1416, 268, 13010, 13, 20362, 4943, 198, 17256, 7203, 521, 1063, 13, 20362, 4943, 198, 17256, 7203, 19849, 13, 20362, 4943, 198, 198, 437, 198 ]
3.115385
182
<gh_stars>10-100 # This file is a part of ElasticArrays.jl, licensed under the MIT License (MIT). function _split_dims(dims::NTuple{N,Integer}) where {N} int_dims = Int.(dims) Base.front(int_dims), int_dims[end] end
[ 27, 456, 62, 30783, 29, 940, 12, 3064, 198, 2, 770, 2393, 318, 257, 636, 286, 48567, 3163, 20477, 13, 20362, 11, 11971, 739, 262, 17168, 13789, 357, 36393, 737, 628, 198, 8818, 4808, 35312, 62, 67, 12078, 7, 67, 12078, 3712, 11251, 29291, 90, 45, 11, 46541, 30072, 810, 1391, 45, 92, 198, 220, 220, 220, 493, 62, 67, 12078, 796, 2558, 12195, 67, 12078, 8, 198, 220, 220, 220, 7308, 13, 8534, 7, 600, 62, 67, 12078, 828, 493, 62, 67, 12078, 58, 437, 60, 198, 437, 198 ]
2.511111
90
@inline function calcpoint(blockIdx, blockDim, threadIdx, size) i = (blockIdx - 1) * blockDim + threadIdx return i, Float32(i) end function kernel_texture_warp_native(dst::CuDeviceArray{<:Any,1}, texture::CuDeviceTexture{<:Any,1}) i, u = calcpoint(blockIdx().x, blockDim().x, threadIdx().x, size(dst)[1]) @inbounds dst[i] = texture[u] return nothing end function kernel_texture_warp_native(dst::CuDeviceArray{<:Any,2}, texture::CuDeviceTexture{<:Any,2}) i, u = calcpoint(blockIdx().x, blockDim().x, threadIdx().x, size(dst)[1]) j, v = calcpoint(blockIdx().y, blockDim().y, threadIdx().y, size(dst)[2]) @inbounds dst[i,j] = texture[u,v] return nothing end function kernel_texture_warp_native(dst::CuDeviceArray{<:Any,3}, texture::CuDeviceTexture{<:Any,3}) i, u = calcpoint(blockIdx().x, blockDim().x, threadIdx().x, size(dst)[1]) j, v = calcpoint(blockIdx().y, blockDim().y, threadIdx().y, size(dst)[2]) k, w = calcpoint(blockIdx().z, blockDim().z, threadIdx().z, size(dst)[3]) @inbounds dst[i,j,k] = texture[u,v,w] return nothing end function fetch_all(texture) dims = size(texture) d_out = CuArray{eltype(texture)}(undef, dims...) @cuda threads = dims kernel_texture_warp_native(d_out, texture) d_out end @testset "CuTextureArray(::CuArray)" begin testheight, testwidth, testdepth = 16, 16, 4 a1D = convert(Array{Float32}, 1:testheight) a2D = convert(Array{Float32}, repeat(1:testheight, 1, testwidth) + repeat(0.01 * (1:testwidth)', testheight, 1)) a3D = convert(Array{Float32}, repeat(a2D, 1, 1, testdepth)) for k = 1:testdepth; a3D[:,:,k] .+= 0.0001 * k; end d_a1D = CuArray(a1D) d_a2D = CuArray(a2D) d_a3D = CuArray(a3D) texarr1D = CuTextureArray(d_a1D) tex1D = CuTexture(texarr1D) @test fetch_all(tex1D) == d_a1D texarr2D = CuTextureArray(d_a2D) tex2D = CuTexture(texarr2D) @test fetch_all(tex2D) == d_a2D texarr3D = CuTextureArray(d_a3D) tex3D = CuTexture(texarr3D) @test fetch_all(tex3D) == d_a3D end @testset "CuTextureArray(::Array)" begin testheight, testwidth, testdepth = 16, 16, 4 a1D = convert(Array{Float32}, 1:testheight) a2D = convert(Array{Float32}, repeat(1:testheight, 1, testwidth) + repeat(0.01 * (1:testwidth)', testheight, 1)) a3D = convert(Array{Float32}, repeat(a2D, 1, 1, testdepth)) for k = 1:testdepth; a3D[:,:,k] .+= 0.0001 * k; end texarr1D = CuTextureArray(a1D) copyto!(texarr1D, a1D) tex1D = CuTexture(texarr1D) @test Array(fetch_all(tex1D)) == a1D texarr2D = CuTextureArray(a2D) tex2D = CuTexture(texarr2D) @test Array(fetch_all(tex2D)) == a2D tex2D_dir = CuTexture(CuTextureArray(a2D)) @test Array(fetch_all(tex2D_dir)) == a2D texarr3D = CuTextureArray(a3D) tex3D = CuTexture(texarr3D) @test Array(fetch_all(tex3D)) == a3D end @testset "CuTexture(::CuArray)" begin testheight, testwidth, testdepth = 16, 16, 4 a1D = convert(Array{Float32}, 1:testheight) a2D = convert(Array{Float32}, repeat(1:testheight, 1, testwidth) + repeat(0.01 * (1:testwidth)', testheight, 1)) d_a1D = CuArray(a1D) d_a2D = CuArray(a2D) # Strangely, this is not working texwrap1D = CuTexture(d_a1D) @test_broken fetch_all(texwrap1D) == d_a1D # This works as long as d_a2D is well pitched texwrap2D = CuTexture(d_a2D) @test fetch_all(texwrap2D) == d_a2D end @testset "type support" begin for T in (Int32, UInt32, Int16, UInt16, Int8, UInt8, Float32, Float16) testheight, testwidth, testdepth = 32, 32, 4 a2D = rand(T, testheight, testwidth) d_a2D = CuArray(a2D) # Using CuTextureArray tex_2D = CuTexture(d_a2D) @test fetch_all(tex_2D) == d_a2D # Wrapping CuArray # This works as long as d_a2D is well pitched texwrap_2D = CuTexture(d_a2D) @test fetch_all(texwrap_2D) == d_a2D end end @testset "multiple channels" begin testheight, testwidth, testdepth = 16, 16, 4 a2D = [(Int32(i), Int32(j)) for i = 1:testheight, j = 1:testwidth] d_a2D = CuArray(a2D) texarr2D = CuTextureArray(d_a2D) tex2D = CuTexture(texarr2D) @test fetch_all(tex2D) == d_a2D testheight, testwidth, testdepth = 16, 16, 4 a2D = [(Int16(i), Int16(j), Int16(i + j), Int16(i - j)) for i = 1:testheight, j = 1:testwidth] d_a2D = CuArray(a2D) texarr2D = CuTextureArray(d_a2D) tex2D = CuTexture(texarr2D) @test fetch_all(tex2D) == d_a2D end
[ 31, 45145, 2163, 42302, 4122, 7, 9967, 7390, 87, 11, 2512, 29271, 11, 4704, 7390, 87, 11, 2546, 8, 198, 220, 220, 220, 1312, 796, 357, 9967, 7390, 87, 532, 352, 8, 1635, 2512, 29271, 1343, 4704, 7390, 87, 198, 220, 220, 220, 1441, 1312, 11, 48436, 2624, 7, 72, 8, 198, 437, 198, 8818, 9720, 62, 41293, 62, 86, 5117, 62, 30191, 7, 67, 301, 3712, 46141, 24728, 19182, 90, 27, 25, 7149, 11, 16, 5512, 11743, 3712, 46141, 24728, 32742, 90, 27, 25, 7149, 11, 16, 30072, 198, 220, 220, 220, 1312, 11, 334, 796, 42302, 4122, 7, 9967, 7390, 87, 22446, 87, 11, 2512, 29271, 22446, 87, 11, 4704, 7390, 87, 22446, 87, 11, 2546, 7, 67, 301, 38381, 16, 12962, 198, 220, 220, 220, 2488, 259, 65, 3733, 29636, 58, 72, 60, 796, 11743, 58, 84, 60, 198, 220, 220, 220, 1441, 2147, 198, 437, 198, 8818, 9720, 62, 41293, 62, 86, 5117, 62, 30191, 7, 67, 301, 3712, 46141, 24728, 19182, 90, 27, 25, 7149, 11, 17, 5512, 11743, 3712, 46141, 24728, 32742, 90, 27, 25, 7149, 11, 17, 30072, 198, 220, 220, 220, 1312, 11, 334, 796, 42302, 4122, 7, 9967, 7390, 87, 22446, 87, 11, 2512, 29271, 22446, 87, 11, 4704, 7390, 87, 22446, 87, 11, 2546, 7, 67, 301, 38381, 16, 12962, 198, 220, 220, 220, 474, 11, 410, 796, 42302, 4122, 7, 9967, 7390, 87, 22446, 88, 11, 2512, 29271, 22446, 88, 11, 4704, 7390, 87, 22446, 88, 11, 2546, 7, 67, 301, 38381, 17, 12962, 198, 220, 220, 220, 2488, 259, 65, 3733, 29636, 58, 72, 11, 73, 60, 796, 11743, 58, 84, 11, 85, 60, 198, 220, 220, 220, 1441, 2147, 198, 437, 198, 8818, 9720, 62, 41293, 62, 86, 5117, 62, 30191, 7, 67, 301, 3712, 46141, 24728, 19182, 90, 27, 25, 7149, 11, 18, 5512, 11743, 3712, 46141, 24728, 32742, 90, 27, 25, 7149, 11, 18, 30072, 198, 220, 220, 220, 1312, 11, 334, 796, 42302, 4122, 7, 9967, 7390, 87, 22446, 87, 11, 2512, 29271, 22446, 87, 11, 4704, 7390, 87, 22446, 87, 11, 2546, 7, 67, 301, 38381, 16, 12962, 198, 220, 220, 220, 474, 11, 410, 796, 42302, 4122, 7, 9967, 7390, 87, 22446, 88, 11, 2512, 29271, 22446, 88, 11, 4704, 7390, 87, 22446, 88, 11, 2546, 7, 67, 301, 38381, 17, 12962, 198, 220, 220, 220, 479, 11, 266, 796, 42302, 4122, 7, 9967, 7390, 87, 22446, 89, 11, 2512, 29271, 22446, 89, 11, 4704, 7390, 87, 22446, 89, 11, 2546, 7, 67, 301, 38381, 18, 12962, 198, 220, 220, 220, 2488, 259, 65, 3733, 29636, 58, 72, 11, 73, 11, 74, 60, 796, 11743, 58, 84, 11, 85, 11, 86, 60, 198, 220, 220, 220, 1441, 2147, 198, 437, 198, 198, 8818, 21207, 62, 439, 7, 41293, 8, 198, 220, 220, 220, 5391, 82, 796, 2546, 7, 41293, 8, 198, 220, 220, 220, 288, 62, 448, 796, 14496, 19182, 90, 417, 4906, 7, 41293, 38165, 7, 917, 891, 11, 5391, 82, 23029, 198, 220, 220, 220, 2488, 66, 15339, 14390, 796, 5391, 82, 9720, 62, 41293, 62, 86, 5117, 62, 30191, 7, 67, 62, 448, 11, 11743, 8, 198, 220, 220, 220, 288, 62, 448, 198, 437, 198, 198, 31, 9288, 2617, 366, 46141, 32742, 19182, 7, 3712, 46141, 19182, 16725, 2221, 198, 220, 220, 220, 1332, 17015, 11, 1332, 10394, 11, 1332, 18053, 796, 1467, 11, 1467, 11, 604, 198, 220, 220, 220, 257, 16, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 352, 25, 9288, 17015, 8, 198, 220, 220, 220, 257, 17, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 9585, 7, 16, 25, 9288, 17015, 11, 352, 11, 1332, 10394, 8, 1343, 9585, 7, 15, 13, 486, 1635, 357, 16, 25, 9288, 10394, 8, 3256, 1332, 17015, 11, 352, 4008, 198, 220, 220, 220, 257, 18, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 9585, 7, 64, 17, 35, 11, 352, 11, 352, 11, 1332, 18053, 4008, 198, 220, 220, 220, 329, 479, 796, 352, 25, 9288, 18053, 26, 257, 18, 35, 58, 45299, 45299, 74, 60, 764, 47932, 657, 13, 18005, 1635, 479, 26, 886, 198, 220, 220, 220, 288, 62, 64, 16, 35, 796, 14496, 19182, 7, 64, 16, 35, 8, 198, 220, 220, 220, 288, 62, 64, 17, 35, 796, 14496, 19182, 7, 64, 17, 35, 8, 198, 220, 220, 220, 288, 62, 64, 18, 35, 796, 14496, 19182, 7, 64, 18, 35, 8, 628, 220, 220, 220, 48659, 3258, 16, 35, 796, 14496, 32742, 19182, 7, 67, 62, 64, 16, 35, 8, 198, 220, 220, 220, 48659, 16, 35, 796, 14496, 32742, 7, 16886, 3258, 16, 35, 8, 198, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 16, 35, 8, 6624, 288, 62, 64, 16, 35, 628, 220, 220, 220, 48659, 3258, 17, 35, 796, 14496, 32742, 19182, 7, 67, 62, 64, 17, 35, 8, 198, 220, 220, 220, 48659, 17, 35, 796, 14496, 32742, 7, 16886, 3258, 17, 35, 8, 198, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 17, 35, 8, 6624, 288, 62, 64, 17, 35, 628, 220, 220, 220, 48659, 3258, 18, 35, 796, 14496, 32742, 19182, 7, 67, 62, 64, 18, 35, 8, 198, 220, 220, 220, 48659, 18, 35, 796, 14496, 32742, 7, 16886, 3258, 18, 35, 8, 198, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 18, 35, 8, 6624, 288, 62, 64, 18, 35, 198, 437, 198, 198, 31, 9288, 2617, 366, 46141, 32742, 19182, 7, 3712, 19182, 16725, 2221, 198, 220, 220, 220, 1332, 17015, 11, 1332, 10394, 11, 1332, 18053, 796, 1467, 11, 1467, 11, 604, 198, 220, 220, 220, 257, 16, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 352, 25, 9288, 17015, 8, 198, 220, 220, 220, 257, 17, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 9585, 7, 16, 25, 9288, 17015, 11, 352, 11, 1332, 10394, 8, 1343, 9585, 7, 15, 13, 486, 1635, 357, 16, 25, 9288, 10394, 8, 3256, 1332, 17015, 11, 352, 4008, 198, 220, 220, 220, 257, 18, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 9585, 7, 64, 17, 35, 11, 352, 11, 352, 11, 1332, 18053, 4008, 198, 220, 220, 220, 329, 479, 796, 352, 25, 9288, 18053, 26, 257, 18, 35, 58, 45299, 45299, 74, 60, 764, 47932, 657, 13, 18005, 1635, 479, 26, 886, 628, 220, 220, 220, 48659, 3258, 16, 35, 796, 14496, 32742, 19182, 7, 64, 16, 35, 8, 198, 220, 220, 220, 4866, 1462, 0, 7, 16886, 3258, 16, 35, 11, 257, 16, 35, 8, 198, 220, 220, 220, 48659, 16, 35, 796, 14496, 32742, 7, 16886, 3258, 16, 35, 8, 198, 220, 220, 220, 2488, 9288, 15690, 7, 69, 7569, 62, 439, 7, 16886, 16, 35, 4008, 6624, 257, 16, 35, 628, 220, 220, 220, 48659, 3258, 17, 35, 796, 14496, 32742, 19182, 7, 64, 17, 35, 8, 198, 220, 220, 220, 48659, 17, 35, 796, 14496, 32742, 7, 16886, 3258, 17, 35, 8, 198, 220, 220, 220, 2488, 9288, 15690, 7, 69, 7569, 62, 439, 7, 16886, 17, 35, 4008, 6624, 257, 17, 35, 628, 220, 220, 220, 48659, 17, 35, 62, 15908, 796, 14496, 32742, 7, 46141, 32742, 19182, 7, 64, 17, 35, 4008, 198, 220, 220, 220, 2488, 9288, 15690, 7, 69, 7569, 62, 439, 7, 16886, 17, 35, 62, 15908, 4008, 6624, 257, 17, 35, 628, 220, 220, 220, 48659, 3258, 18, 35, 796, 14496, 32742, 19182, 7, 64, 18, 35, 8, 198, 220, 220, 220, 48659, 18, 35, 796, 14496, 32742, 7, 16886, 3258, 18, 35, 8, 198, 220, 220, 220, 2488, 9288, 15690, 7, 69, 7569, 62, 439, 7, 16886, 18, 35, 4008, 6624, 257, 18, 35, 198, 437, 198, 198, 31, 9288, 2617, 366, 46141, 32742, 7, 3712, 46141, 19182, 16725, 2221, 198, 220, 220, 220, 1332, 17015, 11, 1332, 10394, 11, 1332, 18053, 796, 1467, 11, 1467, 11, 604, 198, 220, 220, 220, 257, 16, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 352, 25, 9288, 17015, 8, 198, 220, 220, 220, 257, 17, 35, 796, 10385, 7, 19182, 90, 43879, 2624, 5512, 9585, 7, 16, 25, 9288, 17015, 11, 352, 11, 1332, 10394, 8, 1343, 9585, 7, 15, 13, 486, 1635, 357, 16, 25, 9288, 10394, 8, 3256, 1332, 17015, 11, 352, 4008, 198, 220, 220, 220, 288, 62, 64, 16, 35, 796, 14496, 19182, 7, 64, 16, 35, 8, 198, 220, 220, 220, 288, 62, 64, 17, 35, 796, 14496, 19182, 7, 64, 17, 35, 8, 628, 220, 220, 220, 1303, 16810, 306, 11, 428, 318, 407, 1762, 198, 220, 220, 220, 48659, 37150, 16, 35, 796, 14496, 32742, 7, 67, 62, 64, 16, 35, 8, 198, 220, 220, 220, 2488, 9288, 62, 25826, 21207, 62, 439, 7, 16886, 37150, 16, 35, 8, 6624, 288, 62, 64, 16, 35, 628, 220, 220, 220, 1303, 770, 2499, 355, 890, 355, 288, 62, 64, 17, 35, 318, 880, 21730, 198, 220, 220, 220, 48659, 37150, 17, 35, 796, 14496, 32742, 7, 67, 62, 64, 17, 35, 8, 198, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 37150, 17, 35, 8, 6624, 288, 62, 64, 17, 35, 198, 437, 198, 198, 31, 9288, 2617, 366, 4906, 1104, 1, 2221, 198, 220, 220, 220, 329, 309, 287, 357, 5317, 2624, 11, 471, 5317, 2624, 11, 2558, 1433, 11, 471, 5317, 1433, 11, 2558, 23, 11, 471, 5317, 23, 11, 48436, 2624, 11, 48436, 1433, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1332, 17015, 11, 1332, 10394, 11, 1332, 18053, 796, 3933, 11, 3933, 11, 604, 198, 220, 220, 220, 220, 220, 220, 220, 257, 17, 35, 796, 43720, 7, 51, 11, 1332, 17015, 11, 1332, 10394, 8, 198, 220, 220, 220, 220, 220, 220, 220, 288, 62, 64, 17, 35, 796, 14496, 19182, 7, 64, 17, 35, 8, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 8554, 14496, 32742, 19182, 198, 220, 220, 220, 220, 220, 220, 220, 48659, 62, 17, 35, 796, 14496, 32742, 7, 67, 62, 64, 17, 35, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 62, 17, 35, 8, 6624, 288, 62, 64, 17, 35, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 27323, 2105, 14496, 19182, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 770, 2499, 355, 890, 355, 288, 62, 64, 17, 35, 318, 880, 21730, 198, 220, 220, 220, 220, 220, 220, 220, 48659, 37150, 62, 17, 35, 796, 14496, 32742, 7, 67, 62, 64, 17, 35, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 37150, 62, 17, 35, 8, 6624, 288, 62, 64, 17, 35, 198, 220, 220, 220, 886, 198, 437, 198, 198, 31, 9288, 2617, 366, 48101, 9619, 1, 2221, 198, 220, 220, 220, 1332, 17015, 11, 1332, 10394, 11, 1332, 18053, 796, 1467, 11, 1467, 11, 604, 198, 220, 220, 220, 257, 17, 35, 796, 47527, 5317, 2624, 7, 72, 828, 2558, 2624, 7, 73, 4008, 329, 1312, 796, 352, 25, 9288, 17015, 11, 474, 796, 352, 25, 9288, 10394, 60, 198, 220, 220, 220, 288, 62, 64, 17, 35, 796, 14496, 19182, 7, 64, 17, 35, 8, 198, 220, 220, 220, 48659, 3258, 17, 35, 796, 14496, 32742, 19182, 7, 67, 62, 64, 17, 35, 8, 198, 220, 220, 220, 48659, 17, 35, 796, 14496, 32742, 7, 16886, 3258, 17, 35, 8, 198, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 17, 35, 8, 6624, 288, 62, 64, 17, 35, 628, 220, 220, 220, 1332, 17015, 11, 1332, 10394, 11, 1332, 18053, 796, 1467, 11, 1467, 11, 604, 198, 220, 220, 220, 257, 17, 35, 796, 47527, 5317, 1433, 7, 72, 828, 2558, 1433, 7, 73, 828, 2558, 1433, 7, 72, 1343, 474, 828, 2558, 1433, 7, 72, 532, 474, 4008, 329, 1312, 796, 352, 25, 9288, 17015, 11, 474, 796, 352, 25, 9288, 10394, 60, 198, 220, 220, 220, 288, 62, 64, 17, 35, 796, 14496, 19182, 7, 64, 17, 35, 8, 198, 220, 220, 220, 48659, 3258, 17, 35, 796, 14496, 32742, 19182, 7, 67, 62, 64, 17, 35, 8, 198, 220, 220, 220, 48659, 17, 35, 796, 14496, 32742, 7, 16886, 3258, 17, 35, 8, 198, 220, 220, 220, 2488, 9288, 21207, 62, 439, 7, 16886, 17, 35, 8, 6624, 288, 62, 64, 17, 35, 198, 437, 198 ]
2.181643
2,070
#__precompile__() module SparseUtils import SparseArrays import SparseArrays: SparseMatrixCSC, nnz import LinearAlgebra #import DataUtils import StatsBase import Printf const Callable = Union{Function, Type} export c_to_julia_index, c_to_julia_index!, density, nnzcounts, summarystats, nrows, ncols, prunecols!, prunecols, prunerows, renumbercols, renumberrows, renumberrowscols, hasemptycols, hasemptyrows include("findrepeated.jl") include("nzval.jl") include("ijv.jl") include("csc.jl") include("coo.jl") include("coorenumber.jl") include("abstract.jl") include("countmap.jl") import .NZVal, .IJV end # module SparseUtils # LocalWords: nnzcounts countmap sp
[ 2, 834, 3866, 5589, 576, 834, 3419, 198, 21412, 1338, 17208, 18274, 4487, 198, 198, 11748, 1338, 17208, 3163, 20477, 198, 11748, 1338, 17208, 3163, 20477, 25, 1338, 17208, 46912, 34, 6173, 11, 299, 27305, 198, 11748, 44800, 2348, 29230, 198, 2, 11748, 6060, 18274, 4487, 198, 11748, 20595, 14881, 198, 11748, 12578, 69, 198, 198, 9979, 4889, 540, 796, 4479, 90, 22203, 11, 5994, 92, 198, 198, 39344, 198, 220, 220, 220, 269, 62, 1462, 62, 73, 43640, 62, 9630, 11, 198, 220, 220, 220, 269, 62, 1462, 62, 73, 43640, 62, 9630, 28265, 198, 220, 220, 220, 12109, 11, 198, 220, 220, 220, 299, 27305, 9127, 82, 11, 198, 220, 220, 220, 10638, 34242, 11, 198, 220, 220, 220, 299, 8516, 11, 198, 220, 220, 220, 299, 4033, 82, 11, 198, 220, 220, 220, 778, 403, 721, 10220, 28265, 198, 220, 220, 220, 778, 403, 721, 10220, 11, 198, 220, 220, 220, 778, 38886, 1666, 11, 198, 220, 220, 220, 8851, 4494, 4033, 82, 11, 198, 220, 220, 220, 8851, 4494, 8516, 11, 198, 220, 220, 220, 8851, 4494, 808, 1416, 10220, 11, 198, 220, 220, 220, 468, 28920, 4033, 82, 11, 198, 220, 220, 220, 468, 28920, 8516, 198, 198, 17256, 7203, 19796, 45956, 515, 13, 20362, 4943, 198, 17256, 7203, 27305, 2100, 13, 20362, 4943, 198, 17256, 7203, 2926, 85, 13, 20362, 4943, 198, 17256, 7203, 66, 1416, 13, 20362, 4943, 198, 17256, 7203, 1073, 78, 13, 20362, 4943, 198, 17256, 7203, 1073, 382, 17618, 13, 20362, 4943, 198, 17256, 7203, 397, 8709, 13, 20362, 4943, 198, 17256, 7203, 9127, 8899, 13, 20362, 4943, 628, 198, 11748, 764, 37371, 7762, 11, 764, 23852, 53, 198, 198, 437, 1303, 8265, 1338, 17208, 18274, 4487, 198, 198, 2, 220, 10714, 37117, 25, 220, 299, 27305, 9127, 82, 954, 8899, 599, 198 ]
2.412541
303
using Turing, Test import Random dir = splitdir(splitdir(pathof(Turing))[1])[1] include(dir*"/test/test_utils/AllUtils.jl") @stage_testset "dynamichmc" "dynamichmc.jl" begin import DynamicHMC Random.seed!(100) chn = sample(gdemo_default, DynamicNUTS(), 5000); check_numerical(chn, [:s, :m], [49/24, 7/6], atol=0.2) end
[ 3500, 39141, 11, 6208, 198, 11748, 14534, 198, 198, 15908, 796, 6626, 15908, 7, 35312, 15908, 7, 6978, 1659, 7, 51, 870, 4008, 58, 16, 12962, 58, 16, 60, 198, 17256, 7, 15908, 9, 1, 14, 9288, 14, 9288, 62, 26791, 14, 3237, 18274, 4487, 13, 20362, 4943, 198, 198, 31, 14247, 62, 9288, 2617, 366, 67, 4989, 488, 23209, 1, 366, 67, 4989, 488, 23209, 13, 20362, 1, 2221, 198, 220, 220, 220, 1330, 26977, 39, 9655, 198, 220, 220, 220, 14534, 13, 28826, 0, 7, 3064, 8, 198, 220, 220, 220, 442, 77, 796, 6291, 7, 70, 9536, 78, 62, 12286, 11, 26977, 45, 3843, 50, 22784, 23336, 1776, 198, 220, 220, 220, 2198, 62, 77, 6975, 605, 7, 1349, 11, 685, 25, 82, 11, 1058, 76, 4357, 685, 2920, 14, 1731, 11, 767, 14, 21, 4357, 379, 349, 28, 15, 13, 17, 8, 198, 437, 198 ]
2.261745
149
module InteractiveErrors # TODO: de-vendor once changes are upstreamed. include("vendor/FoldingTrees/src/FoldingTrees.jl") using .FoldingTrees using REPL, REPL.TerminalMenus, InteractiveUtils, IterTools, Requires export toggle, current_theme, set_theme!, reset_theme!, adjust_theme! # # Themes. # const DEFAULT_THEME = ( function_name = (bold = true,), directory = (color = :light_black,), filename = (color = :magenta, bold = true,), line_number = (color = :green, bold = true), user_stack = (color = :green, bold = true), system_stack = (color = :red, bold = true), stdlib_module = (color = :yellow,), base_module = (color = :blue,), core_module = (color = :light_black,), package_module = (color = :cyan, bold = true,), unknown_module = (color = :red,), inlined_frames = (color = :light_black,), toplevel_frames = (color = :light_black,), repeated_frames = (color = :red,), file_contents = (color = :light_black,), signature = (color = :light_black, format = true, highlight = true), source = (color = :normal, bold = true, highlight = true), line_range = (before = 0, after = 5,), charset = :unicode, ) const THEME = Ref{Any}(DEFAULT_THEME) current_theme() = THEME[] set_theme!(nt::NamedTuple) = THEME[] = nt set_theme!(; kws...) = set_theme!(_nt(kws)) _nt(kws) = NamedTuple{Tuple(keys(kws))}(values(kws)) reset_theme!() = set_theme!(DEFAULT_THEME) adjust_theme!(nt::NamedTuple) = set_theme!(merge(current_theme(), nt)) adjust_theme!(; kws...) = adjust_theme!(_nt(kws)) get_theme(key) = get(NamedTuple, current_theme(), key) get_theme(key, default) = get(current_theme(), key, default) function style(str; kws...) sprint(; context = :color => true) do io printstyled( io, str; bold = get(kws, :bold, false), color = get(kws, :color, :normal), ) end end style(str, key::Symbol) = style(str; get_theme(key)...) # # Stackframe Wrapping. # struct StackFrameWrapper sf::StackTraces.StackFrame n::Int StackFrameWrapper(tuple) = new(tuple...) end function Base.show(io::IO, s::StackFrameWrapper) func = style(s.sf.func, :function_name) file = rewrite_path(s.sf.file) dir, file = dirname(file), basename(file) file = style(file, :filename) dir = style(joinpath(dir, ""), :directory) line = style(s.sf.line, :line_number) repeated = s.n > 1 ? style("x $(s.n)", :repeated_frames) : "" print(io, strip("$func $dir$file:$line $repeated")) end function rewrite_path(path) fn(path, replacer) = replace(String(path), replacer; count = 1) path = fn(path, normpath(Sys.BUILD_STDLIB_PATH) => "@stdlib") path = fn(path, normpath(Sys.STDLIB) => "@stdlib") path = fn(path, homedir() => "~") return path end function find_source(file) # Binary versions of Julia have the wrong stdlib path, fix it. file = replace(string(file), normpath(Sys.BUILD_STDLIB_PATH) => Sys.STDLIB; count = 1) return Base.find_source_file(file) end # # Explorer. # struct CapturedError err bt end Base.show(io::IO, ce::CapturedError) = showerror(io, ce.err, ce.bt) explore(err::CapturedError) = explore(stdout, err) function explore(io::IO, err::CapturedError; interactive = true) # Give a printout of the actual error message prior to launching tree # explorer since it's probably useful to have. println(io, sprint(showerror, err.err, context = :color => true)) # Use the default cleaning functionality from Base. No need to reinvent. clean = Base.process_backtrace(err.bt) wrapped = StackFrameWrapper.(clean) toplevel = findfirst(s -> StackTraces.is_top_level_frame(s.sf), wrapped) toplevel = toplevel === nothing ? length(wrapped) : toplevel user_frames = wrapped[1:toplevel] system_frames = wrapped[toplevel+1:end] root = Node{Any}("(stacktrace)") function make_nodes(root_node, frames; fold = false) for (nth, frame_group) in enumerate(aggregate_modules(frames)) m = module_of(first(frame_group)) if m === :unknown for frame in frame_group fold!(Node{Any}(frame, root_node)) end else name = m === :inlined ? style("[inlined]", :inlined_frames) : m === :toplevel ? style("[top-level]", :toplevel_frames) : is_from_stdlib(m) ? style("$(m)", :stdlib_module) : is_from_base(m) ? style("$(m)", :base_module) : is_from_core(m) ? style("$(m)", :core_module) : is_from_package(m) ? style("$(m)", :package_module) : style("$(m)", :unknown_module) node = Node{Any}(name, root_node) for frame in frame_group current = Node{Any}(frame, node) fold!(current) # Formatted signature for the frame: if !StackTraces.is_top_level_frame(frame.sf) let lines = _formatted_signature(frame) if !isempty(lines) sig = Node{Any}(style("signature", :signature), current) fold!(sig) for line in lines Node{Any}(line, sig) end end end end # Source code for the frame: let lines = _lines_around(frame) if !isempty(lines) src = Node{Any}(style("source", :source), current) for line in lines Node{Any}(line, src) end end end end # Hide any of the following by default: if m in (:inlined, :toplevel) || is_from_stdlib(m) || is_from_base(m) || is_from_core(m) || fold fold!(node) end # Always open up the very first node, unless it's a toplevel. if nth === 1 && m !== :toplevel unfold!(node) end end end end user_nodes = Node{Any}(style("(user)", :user_stack), root) make_nodes(user_nodes, user_frames) system_nodes = Node{Any}(style("(system)", :system_stack), root) make_nodes(system_nodes, system_frames; fold = true) fold!(system_nodes) menu = TreeMenu(root; dynamic = true, maxsize = 30) result = interactive ? TerminalMenus.request(menu; cursor = 3) : user_nodes result === nothing && return actions = [ "clipboard" => () -> (maybe_clipboard(sprint(showerror, err.err, err.bt[1:toplevel])); nothing), "print" => () -> (showerror(io, err.err, err.bt[1:toplevel]); nothing), "stacktrace" => () -> clean, "exception" => () -> err.err, "backtrace" => () -> err.bt, ] data = result.data extras = [] if isa(data, StackFrameWrapper) file, line = data.sf.file, data.sf.line file = find_source(file) if file !== nothing && isfile(file) file, line extras = [ "edit" => () -> (edit(file, line); nothing), "retry" => () -> true, ] has_debugger() && push!(extras, "breakpoint" => () -> breakpoint(file, line)) push!(extras, "less" => () -> (less(file, line); nothing)) actions = vcat(extras, actions) end if isdefined(data.sf, :linfo) mi = data.sf.linfo if isa(mi, Core.MethodInstance) extras = [] if has_cthulhu() push!(extras, "ascend" => () -> ascend(mi)) push!(extras, "descend" => () -> descend(mi)) end if has_jet() push!(extras, "JET" => () -> report_call(mi)) end actions = vcat(extras, actions) end end end result = interactive ? request(MultiSelectMenu(first.(actions); charset = get_theme(:charset, :unicode))) : collect(1:length(actions)) choice = sort(collect(result)) if !isempty(choice) output = [] for (name, func) in actions[choice] out = func() out === nothing || push!(output, Symbol(name) => out) end isempty(output) || return NamedTuple{Tuple(first.(output))}(last.(output)) end return nothing end function _lines_around(s::StackFrameWrapper) file, line = s.sf.file, s.sf.line file = find_source(file) if file !== nothing && isfile(file) lines = readlines(file) range = get_theme(:line_range) above = max(1, line - get(range, :before, 0)) below = min(line + get(range, :after, 5), length(lines)) highlighter = get(get_theme(:source), :highlight, true) === true ? highlight : s -> style(s, :file_contents) return highlighter.(lines[above:below]) else return String[] end end function _formatted_signature(s::StackFrameWrapper) str = String(rsplit(string(s.sf), " at "; limit = 2)[1]) str = replace(str, "#unused#" => "") formatter = get(get_theme(:signature), :format, true) === true ? format_julia_source : identity highlighter = get(get_theme(:signature), :highlight, true) === true ? highlight : s -> style(s, :file_contents) fmt = highlighter(formatter(str)) return collect(eachline(IOBuffer(fmt))) end # Just give up when there is no clipboard available. function maybe_clipboard(str) try clipboard(str) catch err @warn "Could not find a clipboard." end end rootmodule(m::Module) = m === Base ? m : m === parentmodule(m) ? m : rootmodule(parentmodule(m)) rootmodule(::Any) = nothing modulepath(m::Module) = string(pkgdir(m)) modulepath(other) = "" is_from_stdlib(m) = startswith(modulepath(rootmodule(m)), Sys.STDLIB) is_from_base(m) = rootmodule(m) === Base is_from_core(m) = rootmodule(m) === Core is_from_package(m) = (r = rootmodule(m); !is_from_core(r) && !is_from_base(r) && !is_from_stdlib(r)) module_of(sf) = sf.sf.inlined ? :inlined : sf.sf.func === Symbol("top-level scope") ? :toplevel : isa(sf.sf.linfo, Core.MethodInstance) ? sf.sf.linfo.def.module : :unknown aggregate_modules(stacktrace) = IterTools.groupby(module_of, stacktrace) # # REPL hook. # const ENABLED = Ref(true) """ Turn interactive errors on or off. """ toggle() = ENABLED[] = !ENABLED[] is_toggle_expr(expr) = Meta.isexpr(expr, :call, 1) && expr.args[1] === :toggle is_retry(::Nothing) = false is_retry(nt::NamedTuple) = haskey(nt, :retry) && nt.retry === true maybe_retry(out, expr) = is_retry(out) ? Core.eval(Main, _ast_transforms(expr)) : out function _ast_transforms(ast) if isdefined(Base, :active_repl_backend) for xf in Base.active_repl_backend.ast_transforms ast = Base.invokelatest(xf, ast) end end return ast end function wrap_errors(expr) if ENABLED[] && !is_toggle_expr(expr) quote try $(Expr(:toplevel, expr)) catch e $(maybe_retry)($(explore)(($CapturedError)(e, catch_backtrace())), $(Expr(:quote, expr))) end end else expr end end function setup_repl() @async begin done = false for _ in 1:10 if isdefined(Base, :active_repl_backend) backend = Base.active_repl_backend if isdefined(backend, :ast_transforms) pushfirst!(backend.ast_transforms, wrap_errors) done = true break end end sleep(0.5) end done || @warn "Could not start `InteractiveErrors` REPL hook." end end # # Requires. # has_cthulhu(args...) = false ascend(args...) = @warn "`import Cthulhu` to enable `ascend` action." descend(args...) = @warn "`import Cthulhu` to enable `descend` action." has_debugger(args...) = false breakpoint(args...) = @warn "`import Debugger` to enable `breakpoint` action." has_jet(args...) = false report_call(args...) = @warn "`import JET` to enable `report_call` action." has_juliaformatter(args...) = false format_julia_source(source) = source has_ohmyrepl(args...) = false highlight(source) = style(source, :file_contents) function requires() @require Cthulhu = "f68482b8-f384-11e8-15f7-abe071a5a75f" begin has_cthulhu() = true ascend(mi::Core.MethodInstance) = Cthulhu.ascend(mi) descend(mi::Core.MethodInstance) = Cthulhu.descend(mi) end @require Debugger = "31a5f54b-26ea-5ae9-a837-f05ce5417438" begin has_debugger() = true breakpoint(file::AbstractString, line::Integer) = Debugger.breakpoint(file, line) end @require JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b" begin has_jet() = true function report_call(mi::Core.MethodInstance) func = Base.tuple_type_head(mi.specTypes).instance sig = Base.tuple_type_tail(mi.specTypes) result = JET.report_call(func, sig) @info "Press return to continue." readline() return result end end @require JuliaFormatter = "98e50ef6-434e-11e9-1051-2b60c6c9e899" begin has_juliaformatter() = true format_julia_source(source::String) = try JuliaFormatter.format_text(source); catch err; source; end end @require OhMyREPL = "5fb14364-9ced-5910-84b2-373655c76a03" begin has_ohmyrepl() = true function highlight(source::String) O = OhMyREPL tokens = collect(O.tokenize(source)) crayons = fill(O.Crayon(), length(tokens)) O.Passes.SyntaxHighlighter.SYNTAX_HIGHLIGHTER_SETTINGS(crayons, tokens, 0) io = IOBuffer() for (token, crayon) in zip(tokens, crayons) print(io, crayon) print(io, O.untokenize(token)) print(io, O.Crayon(reset = true)) end return String(take!(io)) end end end # # Module Initialisation. # function __init__() setup_repl() requires() end end # module
[ 21412, 21365, 9139, 5965, 198, 198, 2, 16926, 46, 25, 390, 12, 85, 18738, 1752, 2458, 389, 28717, 276, 13, 198, 17256, 7203, 85, 18738, 14, 37, 33266, 51, 6037, 14, 10677, 14, 37, 33266, 51, 6037, 13, 20362, 4943, 198, 3500, 764, 37, 33266, 51, 6037, 198, 198, 3500, 45285, 11, 45285, 13, 44798, 282, 10418, 385, 11, 21365, 18274, 4487, 11, 40806, 33637, 11, 26848, 198, 198, 39344, 19846, 11, 1459, 62, 43810, 11, 900, 62, 43810, 28265, 13259, 62, 43810, 28265, 4532, 62, 43810, 0, 628, 198, 2, 198, 2, 383, 6880, 13, 198, 2, 198, 198, 9979, 5550, 38865, 62, 4221, 3620, 36, 796, 357, 198, 220, 220, 220, 2163, 62, 3672, 220, 220, 796, 357, 36575, 796, 2081, 11, 828, 198, 220, 220, 220, 8619, 220, 220, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 2971, 62, 13424, 11, 828, 198, 220, 220, 220, 29472, 220, 220, 220, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 19726, 29188, 11, 10758, 796, 2081, 11, 828, 198, 220, 220, 220, 1627, 62, 17618, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 14809, 11, 10758, 796, 2081, 828, 198, 220, 220, 220, 2836, 62, 25558, 220, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 14809, 11, 10758, 796, 2081, 828, 198, 220, 220, 220, 1080, 62, 25558, 220, 220, 220, 796, 357, 8043, 796, 1058, 445, 11, 10758, 796, 2081, 828, 198, 220, 220, 220, 14367, 8019, 62, 21412, 220, 220, 796, 357, 8043, 796, 1058, 36022, 11, 828, 198, 220, 220, 220, 2779, 62, 21412, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 17585, 11, 828, 198, 220, 220, 220, 4755, 62, 21412, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 2971, 62, 13424, 11, 828, 198, 220, 220, 220, 5301, 62, 21412, 220, 796, 357, 8043, 796, 1058, 948, 272, 11, 10758, 796, 2081, 11, 828, 198, 220, 220, 220, 6439, 62, 21412, 220, 796, 357, 8043, 796, 1058, 445, 11, 828, 198, 220, 220, 220, 287, 10837, 62, 37805, 220, 796, 357, 8043, 796, 1058, 2971, 62, 13424, 11, 828, 198, 220, 220, 220, 284, 1154, 626, 62, 37805, 796, 357, 8043, 796, 1058, 2971, 62, 13424, 11, 828, 198, 220, 220, 220, 5100, 62, 37805, 796, 357, 8043, 796, 1058, 445, 11, 828, 198, 220, 220, 220, 2393, 62, 3642, 658, 220, 220, 796, 357, 8043, 796, 1058, 2971, 62, 13424, 11, 828, 198, 220, 220, 220, 9877, 220, 220, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 2971, 62, 13424, 11, 5794, 796, 2081, 11, 7238, 796, 2081, 828, 198, 220, 220, 220, 2723, 220, 220, 220, 220, 220, 220, 220, 220, 220, 796, 357, 8043, 796, 1058, 11265, 11, 10758, 796, 2081, 11, 7238, 796, 2081, 828, 198, 220, 220, 220, 1627, 62, 9521, 220, 220, 220, 220, 220, 796, 357, 19052, 796, 657, 11, 706, 796, 642, 11, 828, 198, 220, 220, 220, 34534, 316, 220, 220, 220, 220, 220, 220, 220, 220, 796, 1058, 46903, 1098, 11, 198, 8, 198, 9979, 3336, 11682, 796, 6524, 90, 7149, 92, 7, 7206, 38865, 62, 4221, 3620, 36, 8, 198, 198, 14421, 62, 43810, 3419, 796, 3336, 11682, 21737, 198, 2617, 62, 43810, 0, 7, 429, 3712, 45, 2434, 51, 29291, 8, 796, 3336, 11682, 21737, 796, 299, 83, 198, 2617, 62, 43810, 0, 7, 26, 479, 18504, 23029, 796, 900, 62, 43810, 0, 28264, 429, 7, 74, 18504, 4008, 198, 198, 62, 429, 7, 74, 18504, 8, 796, 34441, 51, 29291, 90, 51, 29291, 7, 13083, 7, 74, 18504, 4008, 92, 7, 27160, 7, 74, 18504, 4008, 198, 42503, 62, 43810, 0, 3419, 796, 900, 62, 43810, 0, 7, 7206, 38865, 62, 4221, 3620, 36, 8, 198, 198, 23032, 62, 43810, 0, 7, 429, 3712, 45, 2434, 51, 29291, 8, 796, 900, 62, 43810, 0, 7, 647, 469, 7, 14421, 62, 43810, 22784, 299, 83, 4008, 198, 23032, 62, 43810, 0, 7, 26, 479, 18504, 23029, 796, 4532, 62, 43810, 0, 28264, 429, 7, 74, 18504, 4008, 198, 198, 1136, 62, 43810, 7, 2539, 8, 796, 651, 7, 45, 2434, 51, 29291, 11, 1459, 62, 43810, 22784, 1994, 8, 198, 1136, 62, 43810, 7, 2539, 11, 4277, 8, 796, 651, 7, 14421, 62, 43810, 22784, 1994, 11, 4277, 8, 198, 198, 8818, 3918, 7, 2536, 26, 479, 18504, 23029, 198, 220, 220, 220, 18553, 7, 26, 4732, 796, 1058, 8043, 5218, 2081, 8, 466, 33245, 198, 220, 220, 220, 220, 220, 220, 220, 3601, 34365, 992, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33245, 11, 965, 26, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10758, 796, 651, 7, 74, 18504, 11, 1058, 36575, 11, 3991, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3124, 796, 651, 7, 74, 18504, 11, 1058, 8043, 11, 1058, 11265, 828, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 886, 198, 437, 198, 7635, 7, 2536, 11, 1994, 3712, 13940, 23650, 8, 796, 3918, 7, 2536, 26, 651, 62, 43810, 7, 2539, 8, 23029, 628, 198, 2, 198, 2, 23881, 14535, 27323, 2105, 13, 198, 2, 198, 198, 7249, 23881, 19778, 36918, 2848, 198, 220, 220, 220, 264, 69, 3712, 25896, 2898, 2114, 13, 25896, 19778, 198, 220, 220, 220, 299, 3712, 5317, 198, 220, 220, 220, 23881, 19778, 36918, 2848, 7, 83, 29291, 8, 796, 649, 7, 83, 29291, 23029, 198, 437, 198, 198, 8818, 7308, 13, 12860, 7, 952, 3712, 9399, 11, 264, 3712, 25896, 19778, 36918, 2848, 8, 198, 220, 220, 220, 25439, 796, 3918, 7, 82, 13, 28202, 13, 20786, 11, 1058, 8818, 62, 3672, 8, 198, 220, 220, 220, 2393, 796, 28183, 62, 6978, 7, 82, 13, 28202, 13, 7753, 8, 198, 220, 220, 220, 26672, 11, 2393, 796, 26672, 3672, 7, 7753, 828, 1615, 12453, 7, 7753, 8, 198, 220, 220, 220, 2393, 796, 3918, 7, 7753, 11, 1058, 34345, 8, 198, 220, 220, 220, 26672, 796, 3918, 7, 22179, 6978, 7, 15908, 11, 366, 12340, 1058, 34945, 8, 198, 220, 220, 220, 1627, 796, 3918, 7, 82, 13, 28202, 13, 1370, 11, 1058, 1370, 62, 17618, 8, 198, 220, 220, 220, 5100, 796, 264, 13, 77, 1875, 352, 5633, 3918, 7203, 87, 29568, 82, 13, 77, 42501, 1058, 45956, 515, 62, 37805, 8, 1058, 13538, 198, 220, 220, 220, 3601, 7, 952, 11, 10283, 7203, 3, 20786, 720, 15908, 3, 7753, 25, 3, 1370, 720, 45956, 515, 48774, 198, 437, 198, 198, 8818, 28183, 62, 6978, 7, 6978, 8, 198, 220, 220, 220, 24714, 7, 6978, 11, 2186, 11736, 8, 796, 6330, 7, 10100, 7, 6978, 828, 2186, 11736, 26, 954, 796, 352, 8, 198, 220, 220, 220, 3108, 796, 24714, 7, 6978, 11, 2593, 6978, 7, 44387, 13, 19499, 26761, 62, 2257, 19260, 9865, 62, 34219, 8, 5218, 44212, 19282, 8019, 4943, 198, 220, 220, 220, 3108, 796, 24714, 7, 6978, 11, 2593, 6978, 7, 44387, 13, 2257, 19260, 9865, 8, 5218, 44212, 19282, 8019, 4943, 198, 220, 220, 220, 3108, 796, 24714, 7, 6978, 11, 3488, 276, 343, 3419, 5218, 366, 93, 4943, 198, 220, 220, 220, 1441, 3108, 198, 437, 198, 198, 8818, 1064, 62, 10459, 7, 7753, 8, 198, 220, 220, 220, 1303, 45755, 6300, 286, 22300, 423, 262, 2642, 14367, 8019, 3108, 11, 4259, 340, 13, 198, 220, 220, 220, 2393, 796, 6330, 7, 8841, 7, 7753, 828, 2593, 6978, 7, 44387, 13, 19499, 26761, 62, 2257, 19260, 9865, 62, 34219, 8, 5218, 311, 893, 13, 2257, 19260, 9865, 26, 954, 796, 352, 8, 198, 220, 220, 220, 1441, 7308, 13, 19796, 62, 10459, 62, 7753, 7, 7753, 8, 198, 437, 198, 198, 2, 198, 2, 19142, 13, 198, 2, 198, 198, 7249, 6790, 1522, 12331, 198, 220, 220, 220, 11454, 198, 220, 220, 220, 275, 83, 198, 437, 198, 198, 14881, 13, 12860, 7, 952, 3712, 9399, 11, 2906, 3712, 19209, 1522, 12331, 8, 796, 14643, 1472, 7, 952, 11, 2906, 13, 8056, 11, 2906, 13, 18347, 8, 198, 198, 20676, 382, 7, 8056, 3712, 19209, 1522, 12331, 8, 796, 7301, 7, 19282, 448, 11, 11454, 8, 198, 198, 8818, 7301, 7, 952, 3712, 9399, 11, 11454, 3712, 19209, 1522, 12331, 26, 14333, 796, 2081, 8, 198, 220, 220, 220, 1303, 13786, 257, 3601, 448, 286, 262, 4036, 4049, 3275, 3161, 284, 13925, 5509, 198, 220, 220, 220, 1303, 39349, 1201, 340, 338, 2192, 4465, 284, 423, 13, 198, 220, 220, 220, 44872, 7, 952, 11, 18553, 7, 1477, 789, 1472, 11, 11454, 13, 8056, 11, 4732, 796, 1058, 8043, 5218, 2081, 4008, 628, 220, 220, 220, 1303, 5765, 262, 4277, 12724, 11244, 422, 7308, 13, 1400, 761, 284, 36608, 13, 198, 220, 220, 220, 3424, 796, 7308, 13, 14681, 62, 1891, 40546, 7, 8056, 13, 18347, 8, 198, 220, 220, 220, 12908, 796, 23881, 19778, 36918, 2848, 12195, 27773, 8, 628, 220, 220, 220, 284, 1154, 626, 796, 1064, 11085, 7, 82, 4613, 23881, 2898, 2114, 13, 271, 62, 4852, 62, 5715, 62, 14535, 7, 82, 13, 28202, 828, 12908, 8, 198, 220, 220, 220, 284, 1154, 626, 796, 284, 1154, 626, 24844, 2147, 5633, 4129, 7, 29988, 1496, 8, 1058, 284, 1154, 626, 198, 220, 220, 220, 2836, 62, 37805, 796, 12908, 58, 16, 25, 83, 643, 626, 60, 198, 220, 220, 220, 1080, 62, 37805, 796, 12908, 58, 83, 643, 626, 10, 16, 25, 437, 60, 628, 220, 220, 220, 6808, 796, 19081, 90, 7149, 92, 7203, 7, 25558, 40546, 8, 4943, 628, 220, 220, 220, 2163, 787, 62, 77, 4147, 7, 15763, 62, 17440, 11, 13431, 26, 5591, 796, 3991, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 357, 77, 400, 11, 5739, 62, 8094, 8, 287, 27056, 378, 7, 9460, 49373, 62, 18170, 7, 37805, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 285, 796, 8265, 62, 1659, 7, 11085, 7, 14535, 62, 8094, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 285, 24844, 1058, 34680, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 5739, 287, 5739, 62, 8094, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5591, 0, 7, 19667, 90, 7149, 92, 7, 14535, 11, 6808, 62, 17440, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1438, 796, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 285, 24844, 1058, 259, 10837, 220, 220, 220, 5633, 3918, 7203, 58, 259, 10837, 60, 1600, 1058, 259, 10837, 62, 37805, 8, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 285, 24844, 1058, 83, 643, 626, 220, 220, 5633, 3918, 7203, 58, 4852, 12, 5715, 60, 1600, 1058, 83, 643, 626, 62, 37805, 8, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 62, 6738, 62, 19282, 8019, 7, 76, 8, 5633, 3918, 7203, 3, 7, 76, 42501, 1058, 19282, 8019, 62, 21412, 8, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 62, 6738, 62, 8692, 7, 76, 8, 220, 220, 5633, 3918, 7203, 3, 7, 76, 42501, 1058, 8692, 62, 21412, 8, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 62, 6738, 62, 7295, 7, 76, 8, 220, 220, 5633, 3918, 7203, 3, 7, 76, 42501, 1058, 7295, 62, 21412, 8, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 62, 6738, 62, 26495, 7, 76, 8, 5633, 3918, 7203, 3, 7, 76, 42501, 1058, 26495, 62, 21412, 8, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3918, 7203, 3, 7, 76, 42501, 1058, 34680, 62, 21412, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10139, 796, 19081, 90, 7149, 92, 7, 3672, 11, 6808, 62, 17440, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 5739, 287, 5739, 62, 8094, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1459, 796, 19081, 90, 7149, 92, 7, 14535, 11, 10139, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5591, 0, 7, 14421, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 5178, 16898, 9877, 329, 262, 5739, 25, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 25896, 2898, 2114, 13, 271, 62, 4852, 62, 5715, 62, 14535, 7, 14535, 13, 28202, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1309, 3951, 796, 4808, 687, 16898, 62, 12683, 1300, 7, 14535, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 271, 28920, 7, 6615, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 43237, 796, 19081, 90, 7149, 92, 7, 7635, 7203, 12683, 1300, 1600, 1058, 12683, 1300, 828, 1459, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5591, 0, 7, 82, 328, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 1627, 287, 3951, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 19081, 90, 7149, 92, 7, 1370, 11, 43237, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 8090, 2438, 329, 262, 5739, 25, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1309, 3951, 796, 4808, 6615, 62, 14145, 7, 14535, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 271, 28920, 7, 6615, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 12351, 796, 19081, 90, 7149, 92, 7, 7635, 7203, 10459, 1600, 1058, 10459, 828, 1459, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 1627, 287, 3951, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 19081, 90, 7149, 92, 7, 1370, 11, 12351, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 10415, 597, 286, 262, 1708, 416, 4277, 25, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 285, 287, 357, 25, 259, 10837, 11, 1058, 83, 643, 626, 8, 8614, 318, 62, 6738, 62, 19282, 8019, 7, 76, 8, 8614, 318, 62, 6738, 62, 8692, 7, 76, 8, 8614, 318, 62, 6738, 62, 7295, 7, 76, 8, 8614, 5591, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5591, 0, 7, 17440, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 16622, 1280, 510, 262, 845, 717, 10139, 11, 4556, 340, 338, 257, 284, 1154, 626, 13, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 299, 400, 24844, 352, 11405, 285, 5145, 855, 1058, 83, 643, 626, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16631, 0, 7, 17440, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2836, 62, 77, 4147, 796, 19081, 90, 7149, 92, 7, 7635, 7203, 7, 7220, 42501, 1058, 7220, 62, 25558, 828, 6808, 8, 198, 220, 220, 220, 787, 62, 77, 4147, 7, 7220, 62, 77, 4147, 11, 2836, 62, 37805, 8, 628, 220, 220, 220, 1080, 62, 77, 4147, 796, 19081, 90, 7149, 92, 7, 7635, 7203, 7, 10057, 42501, 1058, 10057, 62, 25558, 828, 6808, 8, 198, 220, 220, 220, 787, 62, 77, 4147, 7, 10057, 62, 77, 4147, 11, 1080, 62, 37805, 26, 5591, 796, 2081, 8, 198, 220, 220, 220, 5591, 0, 7, 10057, 62, 77, 4147, 8, 628, 220, 220, 220, 6859, 796, 12200, 23381, 7, 15763, 26, 8925, 796, 2081, 11, 3509, 7857, 796, 1542, 8, 198, 220, 220, 220, 1255, 796, 14333, 5633, 24523, 10418, 385, 13, 25927, 7, 26272, 26, 23493, 796, 513, 8, 1058, 2836, 62, 77, 4147, 198, 220, 220, 220, 1255, 24844, 2147, 11405, 1441, 628, 220, 220, 220, 4028, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 366, 15036, 3526, 1, 220, 5218, 7499, 4613, 357, 25991, 62, 15036, 3526, 7, 82, 4798, 7, 1477, 789, 1472, 11, 11454, 13, 8056, 11, 11454, 13, 18347, 58, 16, 25, 83, 643, 626, 12962, 1776, 2147, 828, 198, 220, 220, 220, 220, 220, 220, 220, 366, 4798, 1, 220, 220, 220, 220, 220, 5218, 7499, 4613, 357, 1477, 789, 1472, 7, 952, 11, 11454, 13, 8056, 11, 11454, 13, 18347, 58, 16, 25, 83, 643, 626, 36563, 2147, 828, 198, 220, 220, 220, 220, 220, 220, 220, 366, 25558, 40546, 1, 5218, 7499, 4613, 3424, 11, 198, 220, 220, 220, 220, 220, 220, 220, 366, 1069, 4516, 1, 220, 5218, 7499, 4613, 11454, 13, 8056, 11, 198, 220, 220, 220, 220, 220, 220, 220, 366, 1891, 40546, 1, 220, 5218, 7499, 4613, 11454, 13, 18347, 11, 198, 220, 220, 220, 2361, 628, 220, 220, 220, 1366, 796, 1255, 13, 7890, 198, 220, 220, 220, 33849, 796, 17635, 198, 220, 220, 220, 611, 318, 64, 7, 7890, 11, 23881, 19778, 36918, 2848, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2393, 11, 1627, 796, 1366, 13, 28202, 13, 7753, 11, 1366, 13, 28202, 13, 1370, 198, 220, 220, 220, 220, 220, 220, 220, 2393, 796, 1064, 62, 10459, 7, 7753, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 2393, 5145, 855, 2147, 11405, 318, 7753, 7, 7753, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2393, 11, 1627, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33849, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 19312, 1, 5218, 7499, 4613, 357, 19312, 7, 7753, 11, 1627, 1776, 2147, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 1186, 563, 1, 5218, 7499, 4613, 2081, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2361, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 468, 62, 24442, 1362, 3419, 11405, 4574, 0, 7, 2302, 8847, 11, 366, 9032, 4122, 1, 5218, 7499, 4613, 2270, 4122, 7, 7753, 11, 1627, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 2302, 8847, 11, 366, 1203, 1, 5218, 7499, 4613, 357, 1203, 7, 7753, 11, 1627, 1776, 2147, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4028, 796, 410, 9246, 7, 2302, 8847, 11, 4028, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 611, 318, 23211, 7, 7890, 13, 28202, 11, 1058, 2815, 6513, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 21504, 796, 1366, 13, 28202, 13, 2815, 6513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 318, 64, 7, 11632, 11, 7231, 13, 17410, 33384, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33849, 796, 17635, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 468, 62, 310, 71, 36828, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 2302, 8847, 11, 366, 3372, 437, 1, 5218, 7499, 4613, 34800, 7, 11632, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 2302, 8847, 11, 366, 20147, 437, 1, 5218, 7499, 4613, 15350, 7, 11632, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 468, 62, 31173, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 2302, 8847, 11, 366, 41, 2767, 1, 5218, 7499, 4613, 989, 62, 13345, 7, 11632, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4028, 796, 410, 9246, 7, 2302, 8847, 11, 4028, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1255, 796, 14333, 5633, 2581, 7, 29800, 17563, 23381, 7, 11085, 12195, 4658, 1776, 34534, 316, 796, 651, 62, 43810, 7, 25, 354, 945, 316, 11, 1058, 46903, 1098, 22305, 1058, 2824, 7, 16, 25, 13664, 7, 4658, 4008, 198, 220, 220, 220, 3572, 796, 3297, 7, 33327, 7, 20274, 4008, 198, 220, 220, 220, 611, 5145, 271, 28920, 7, 25541, 8, 198, 220, 220, 220, 220, 220, 220, 220, 5072, 796, 17635, 198, 220, 220, 220, 220, 220, 220, 220, 329, 357, 3672, 11, 25439, 8, 287, 4028, 58, 25541, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 503, 796, 25439, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 503, 24844, 2147, 8614, 4574, 0, 7, 22915, 11, 38357, 7, 3672, 8, 5218, 503, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 318, 28920, 7, 22915, 8, 8614, 1441, 34441, 51, 29291, 90, 51, 29291, 7, 11085, 12195, 22915, 4008, 92, 7, 12957, 12195, 22915, 4008, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 2147, 198, 437, 198, 198, 8818, 4808, 6615, 62, 14145, 7, 82, 3712, 25896, 19778, 36918, 2848, 8, 198, 220, 220, 220, 2393, 11, 1627, 796, 264, 13, 28202, 13, 7753, 11, 264, 13, 28202, 13, 1370, 198, 220, 220, 220, 2393, 796, 1064, 62, 10459, 7, 7753, 8, 198, 220, 220, 220, 611, 2393, 5145, 855, 2147, 11405, 318, 7753, 7, 7753, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3951, 796, 1100, 6615, 7, 7753, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2837, 796, 651, 62, 43810, 7, 25, 1370, 62, 9521, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2029, 796, 3509, 7, 16, 11, 1627, 532, 651, 7, 9521, 11, 1058, 19052, 11, 657, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2174, 796, 949, 7, 1370, 1343, 651, 7, 9521, 11, 1058, 8499, 11, 642, 828, 4129, 7, 6615, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 1029, 75, 4799, 796, 651, 7, 1136, 62, 43810, 7, 25, 10459, 828, 1058, 8929, 2971, 11, 2081, 8, 24844, 2081, 5633, 7238, 1058, 264, 4613, 3918, 7, 82, 11, 1058, 7753, 62, 3642, 658, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 1029, 75, 4799, 12195, 6615, 58, 29370, 25, 35993, 12962, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 10903, 21737, 198, 220, 220, 220, 886, 198, 437, 198, 198, 8818, 4808, 687, 16898, 62, 12683, 1300, 7, 82, 3712, 25896, 19778, 36918, 2848, 8, 198, 220, 220, 220, 965, 796, 10903, 7, 3808, 489, 270, 7, 8841, 7, 82, 13, 28202, 828, 366, 379, 366, 26, 4179, 796, 362, 38381, 16, 12962, 198, 220, 220, 220, 965, 796, 6330, 7, 2536, 11, 25113, 403, 1484, 2, 1, 5218, 366, 4943, 198, 220, 220, 220, 1296, 1436, 796, 651, 7, 1136, 62, 43810, 7, 25, 12683, 1300, 828, 1058, 18982, 11, 2081, 8, 24844, 2081, 5633, 5794, 62, 73, 43640, 62, 10459, 1058, 5369, 198, 220, 220, 220, 1029, 75, 4799, 796, 651, 7, 1136, 62, 43810, 7, 25, 12683, 1300, 828, 1058, 8929, 2971, 11, 2081, 8, 24844, 2081, 5633, 7238, 1058, 264, 4613, 3918, 7, 82, 11, 1058, 7753, 62, 3642, 658, 8, 198, 220, 220, 220, 46996, 796, 1029, 75, 4799, 7, 687, 1436, 7, 2536, 4008, 198, 220, 220, 220, 1441, 2824, 7, 27379, 1370, 7, 9399, 28632, 7, 69, 16762, 22305, 198, 437, 198, 198, 2, 2329, 1577, 510, 618, 612, 318, 645, 47999, 1695, 13, 198, 8818, 3863, 62, 15036, 3526, 7, 2536, 8, 198, 220, 220, 220, 1949, 198, 220, 220, 220, 220, 220, 220, 220, 47999, 7, 2536, 8, 198, 220, 220, 220, 4929, 11454, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 40539, 366, 23722, 407, 1064, 257, 47999, 526, 198, 220, 220, 220, 886, 198, 437, 198, 198, 15763, 21412, 7, 76, 3712, 26796, 8, 796, 285, 24844, 7308, 5633, 285, 1058, 285, 24844, 2560, 21412, 7, 76, 8, 5633, 285, 1058, 6808, 21412, 7, 8000, 21412, 7, 76, 4008, 198, 15763, 21412, 7, 3712, 7149, 8, 796, 2147, 198, 21412, 6978, 7, 76, 3712, 26796, 8, 796, 4731, 7, 35339, 15908, 7, 76, 4008, 198, 21412, 6978, 7, 847, 8, 796, 13538, 198, 198, 271, 62, 6738, 62, 19282, 8019, 7, 76, 8, 796, 923, 2032, 342, 7, 21412, 6978, 7, 15763, 21412, 7, 76, 36911, 311, 893, 13, 2257, 19260, 9865, 8, 198, 271, 62, 6738, 62, 8692, 7, 76, 8, 796, 6808, 21412, 7, 76, 8, 24844, 7308, 198, 271, 62, 6738, 62, 7295, 7, 76, 8, 796, 6808, 21412, 7, 76, 8, 24844, 7231, 198, 271, 62, 6738, 62, 26495, 7, 76, 8, 796, 357, 81, 796, 6808, 21412, 7, 76, 1776, 5145, 271, 62, 6738, 62, 7295, 7, 81, 8, 11405, 5145, 271, 62, 6738, 62, 8692, 7, 81, 8, 11405, 5145, 271, 62, 6738, 62, 19282, 8019, 7, 81, 4008, 198, 198, 21412, 62, 1659, 7, 28202, 8, 796, 198, 220, 220, 220, 264, 69, 13, 28202, 13, 259, 10837, 5633, 1058, 259, 10837, 1058, 198, 220, 220, 220, 264, 69, 13, 28202, 13, 20786, 24844, 38357, 7203, 4852, 12, 5715, 8354, 4943, 5633, 1058, 83, 643, 626, 1058, 198, 220, 220, 220, 318, 64, 7, 28202, 13, 28202, 13, 2815, 6513, 11, 7231, 13, 17410, 33384, 8, 5633, 264, 69, 13, 28202, 13, 2815, 6513, 13, 4299, 13, 21412, 1058, 198, 220, 220, 220, 220, 220, 220, 220, 1058, 34680, 198, 198, 9460, 49373, 62, 18170, 7, 25558, 40546, 8, 796, 40806, 33637, 13, 8094, 1525, 7, 21412, 62, 1659, 11, 8931, 40546, 8, 628, 198, 2, 198, 2, 45285, 8011, 13, 198, 2, 198, 198, 9979, 412, 4535, 9148, 1961, 796, 6524, 7, 7942, 8, 198, 198, 37811, 198, 17278, 14333, 8563, 319, 393, 572, 13, 198, 37811, 198, 44256, 3419, 796, 412, 4535, 9148, 1961, 21737, 796, 5145, 1677, 6242, 30465, 21737, 198, 198, 271, 62, 44256, 62, 31937, 7, 31937, 8, 796, 30277, 13, 786, 87, 1050, 7, 31937, 11, 1058, 13345, 11, 352, 8, 11405, 44052, 13, 22046, 58, 16, 60, 24844, 1058, 44256, 198, 198, 271, 62, 1186, 563, 7, 3712, 18465, 8, 796, 3991, 198, 271, 62, 1186, 563, 7, 429, 3712, 45, 2434, 51, 29291, 8, 796, 468, 2539, 7, 429, 11, 1058, 1186, 563, 8, 11405, 299, 83, 13, 1186, 563, 24844, 2081, 198, 198, 25991, 62, 1186, 563, 7, 448, 11, 44052, 8, 796, 318, 62, 1186, 563, 7, 448, 8, 5633, 7231, 13, 18206, 7, 13383, 11, 4808, 459, 62, 7645, 23914, 7, 31937, 4008, 1058, 503, 198, 198, 8818, 4808, 459, 62, 7645, 23914, 7, 459, 8, 198, 220, 220, 220, 611, 318, 23211, 7, 14881, 11, 1058, 5275, 62, 35666, 62, 1891, 437, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 2124, 69, 287, 7308, 13, 5275, 62, 35666, 62, 1891, 437, 13, 459, 62, 7645, 23914, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6468, 796, 7308, 13, 37669, 42861, 7, 26152, 11, 6468, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 6468, 198, 437, 198, 198, 8818, 14441, 62, 48277, 7, 31937, 8, 198, 220, 220, 220, 611, 412, 4535, 9148, 1961, 21737, 11405, 5145, 271, 62, 44256, 62, 31937, 7, 31937, 8, 198, 220, 220, 220, 220, 220, 220, 220, 9577, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1949, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29568, 3109, 1050, 7, 25, 83, 643, 626, 11, 44052, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4929, 304, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29568, 25991, 62, 1186, 563, 5769, 3, 7, 20676, 382, 5769, 16763, 19209, 1522, 12331, 5769, 68, 11, 4929, 62, 1891, 40546, 28955, 828, 29568, 3109, 1050, 7, 25, 22708, 11, 44052, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 44052, 198, 220, 220, 220, 886, 198, 437, 198, 198, 8818, 9058, 62, 35666, 3419, 198, 220, 220, 220, 2488, 292, 13361, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 1760, 796, 3991, 198, 220, 220, 220, 220, 220, 220, 220, 329, 4808, 287, 352, 25, 940, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 318, 23211, 7, 14881, 11, 1058, 5275, 62, 35666, 62, 1891, 437, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 30203, 796, 7308, 13, 5275, 62, 35666, 62, 1891, 437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 318, 23211, 7, 1891, 437, 11, 1058, 459, 62, 7645, 23914, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4574, 11085, 0, 7, 1891, 437, 13, 459, 62, 7645, 23914, 11, 14441, 62, 48277, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1760, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2270, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3993, 7, 15, 13, 20, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1760, 8614, 2488, 40539, 366, 23722, 407, 923, 4600, 9492, 5275, 9139, 5965, 63, 45285, 8011, 526, 198, 220, 220, 220, 886, 198, 437, 628, 198, 2, 198, 2, 26848, 13, 198, 2, 198, 198, 10134, 62, 310, 71, 36828, 7, 22046, 23029, 796, 3991, 198, 3372, 437, 7, 22046, 23029, 796, 2488, 40539, 366, 63, 11748, 39316, 63, 284, 7139, 4600, 3372, 437, 63, 2223, 526, 198, 20147, 437, 7, 22046, 23029, 796, 2488, 40539, 366, 63, 11748, 39316, 63, 284, 7139, 4600, 20147, 437, 63, 2223, 526, 198, 198, 10134, 62, 24442, 1362, 7, 22046, 23029, 796, 3991, 198, 9032, 4122, 7, 22046, 23029, 796, 2488, 40539, 366, 63, 11748, 31687, 1362, 63, 284, 7139, 4600, 9032, 4122, 63, 2223, 526, 198, 198, 10134, 62, 31173, 7, 22046, 23029, 796, 3991, 198, 13116, 62, 13345, 7, 22046, 23029, 796, 2488, 40539, 366, 63, 11748, 449, 2767, 63, 284, 7139, 4600, 13116, 62, 13345, 63, 2223, 526, 198, 198, 10134, 62, 73, 43640, 687, 1436, 7, 22046, 23029, 796, 3991, 198, 18982, 62, 73, 43640, 62, 10459, 7, 10459, 8, 796, 2723, 198, 198, 10134, 62, 1219, 1820, 35666, 7, 22046, 23029, 796, 3991, 198, 8929, 2971, 7, 10459, 8, 796, 3918, 7, 10459, 11, 1058, 7753, 62, 3642, 658, 8, 198, 198, 8818, 4433, 3419, 198, 220, 220, 220, 2488, 46115, 39316, 796, 366, 69, 3104, 40149, 65, 23, 12, 69, 22842, 12, 1157, 68, 23, 12, 1314, 69, 22, 12, 11231, 2998, 16, 64, 20, 64, 2425, 69, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 468, 62, 310, 71, 36828, 3419, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 34800, 7, 11632, 3712, 14055, 13, 17410, 33384, 8, 796, 39316, 13, 3372, 437, 7, 11632, 8, 198, 220, 220, 220, 220, 220, 220, 220, 15350, 7, 11632, 3712, 14055, 13, 17410, 33384, 8, 796, 39316, 13, 20147, 437, 7, 11632, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2488, 46115, 31687, 1362, 796, 366, 3132, 64, 20, 69, 4051, 65, 12, 2075, 18213, 12, 20, 3609, 24, 12, 64, 23, 2718, 12, 69, 2713, 344, 4051, 22985, 2548, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 468, 62, 24442, 1362, 3419, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 2270, 4122, 7, 7753, 3712, 23839, 10100, 11, 1627, 3712, 46541, 8, 796, 31687, 1362, 13, 9032, 4122, 7, 7753, 11, 1627, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2488, 46115, 449, 2767, 796, 366, 66, 18, 64, 49489, 1495, 12, 10210, 3134, 12, 35890, 68, 12, 64, 23, 68, 22, 12, 15, 64, 20, 64, 15, 487, 19, 68, 3132, 65, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 468, 62, 31173, 3419, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 2163, 989, 62, 13345, 7, 11632, 3712, 14055, 13, 17410, 33384, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 25439, 796, 7308, 13, 83, 29291, 62, 4906, 62, 2256, 7, 11632, 13, 16684, 31431, 737, 39098, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 43237, 796, 7308, 13, 83, 29291, 62, 4906, 62, 13199, 7, 11632, 13, 16684, 31431, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1255, 796, 449, 2767, 13, 13116, 62, 13345, 7, 20786, 11, 43237, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 10951, 366, 13800, 1441, 284, 2555, 526, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1100, 1370, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 1255, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2488, 46115, 22300, 8479, 1436, 796, 366, 4089, 68, 1120, 891, 21, 12, 47101, 68, 12, 1157, 68, 24, 12, 940, 4349, 12, 17, 65, 1899, 66, 21, 66, 24, 68, 44093, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 468, 62, 73, 43640, 687, 1436, 3419, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 5794, 62, 73, 43640, 62, 10459, 7, 10459, 3712, 10100, 8, 796, 1949, 22300, 8479, 1436, 13, 18982, 62, 5239, 7, 10459, 1776, 4929, 11454, 26, 2723, 26, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2488, 46115, 3966, 3666, 2200, 6489, 796, 366, 20, 21855, 21139, 2414, 12, 24, 771, 12, 3270, 940, 12, 5705, 65, 17, 12, 2718, 2623, 2816, 66, 4304, 64, 3070, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 468, 62, 1219, 1820, 35666, 3419, 796, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 2163, 7238, 7, 10459, 3712, 10100, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 440, 796, 3966, 3666, 2200, 6489, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16326, 796, 2824, 7, 46, 13, 30001, 1096, 7, 10459, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1067, 323, 684, 796, 6070, 7, 46, 13, 34, 2433, 261, 22784, 4129, 7, 83, 482, 641, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 440, 13, 47, 13978, 13, 13940, 41641, 11922, 75, 4799, 13, 23060, 45, 5603, 55, 62, 39, 3528, 6581, 18060, 5781, 62, 28480, 51, 20754, 7, 66, 2433, 684, 11, 16326, 11, 657, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 357, 30001, 11, 1067, 323, 261, 8, 287, 19974, 7, 83, 482, 641, 11, 1067, 323, 684, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 952, 11, 1067, 323, 261, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 952, 11, 440, 13, 2797, 4233, 1096, 7, 30001, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 952, 11, 440, 13, 34, 2433, 261, 7, 42503, 796, 2081, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 10903, 7, 20657, 0, 7, 952, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 437, 628, 198, 2, 198, 2, 19937, 20768, 5612, 13, 198, 2, 198, 198, 8818, 11593, 15003, 834, 3419, 198, 220, 220, 220, 9058, 62, 35666, 3419, 198, 220, 220, 220, 4433, 3419, 198, 437, 198, 198, 437, 1303, 8265, 198 ]
2.116357
6,884
""" transpose_to_axes(coord, b, n) Convert from Hilbert index to a coordinatefor `b` bits in `n` dimensions. """ function transpose_to_axes!(X::Vector{T}, b, n) where {T <: Integer} N = T(2) << (b - 1) # Gray decode by H^(H/2) t = X[n] >> 1 for io = n:-1:2 X[io] ⊻= X[io - 1] end X[1] ⊻= t # Undo excess work Q = T(2) while Q != N P = Q - one(T) for jo = n:-1:1 if (X[jo] & Q) != zero(T) X[1] ⊻= P # invert else # exchange t = (X[1] ⊻ X[jo]) & P X[1] ⊻= t X[jo] ⊻= t end end Q <<= 1 end end function axes_to_transpose!(X::Vector{T}, b, n) where {T <: Integer} M = one(T) << (b - 1) # Inverse undo Q = M while Q > one(T) P = Q - one(T) for io = 1:n if (X[io] & Q) != zero(T) X[1] ⊻= P else t = (X[1] ⊻ X[io]) & P X[1] ⊻= t X[io] ⊻= t end end Q >>= 1 end # Gray encode for jo = 2:n X[jo] ⊻= X[jo - 1] end t2 = zero(T) Q = M while Q > one(T) if (X[n] & Q) != 0 t2 ⊻= (Q - one(T)) end Q >>= one(T) end for ko = 1:n X[ko] ⊻= t2 end end """ Takes a vector of length `n` and places the bits of all `n` integers into a single integer. The vector's 1st component is the most significant bit. """ function interleave_transpose(::Type{T}, X::Vector, b, n) where {T} h = zero(T) for i in 0:(b - 1) for d in 1:n ith_bit = (X[d] & (1<<i)) >> i h |= ith_bit << (i * n + n - d) end end h end """ Takes a single integer and places its values into components of a vector, bit-by-bit. """ function outerleave_transpose!(X::Vector{T}, h, b, n) where {T <: Integer} X .= zero(T) for i in 0:(b-1) for d in 1:n ith_bit = (h & (one(h) << (i * n + n - d))) >> (i * n + n - d) X[d] |= ith_bit << i end end end """ Takes a vector of length `n` and places the bits of all `n` integers into a single integer. The vector's 1st component is the least significant bit. """ function interleave_transpose_low(::Type{T}, X::Vector{T}, b, n) where {T} h = zero(T) for i in 0:(b - 1) for d in 1:n h |= ((X[d] & (one(T)<<i))) << (i*(n - 1) + d - 1) end end h end function outerleave_transpose_low!(X::Vector{T}, h, b, n) where {T <: Integer} X .= zero(T) for i in 0:(b-1) for d in 1:n X[d] |= (h & (one(T) << (i * n + d - 1))) >> (i * (n - 1) + d - 1) end end end """ GlobalGray(b, n) GlobalGray(T, b, n) `T` is a data type for the Hilbert index. It can be signed or unsigned, as long as it has at least `n * b` bits. `n` is the number of dimensions, and `b` is the bits per dimension, so each axis value should be between 0 and ``2^b - 1``, inclusive, for the zero-based interface. They should be between 1 and ``2^b``, inclusive, for the one-based interface. The GlobalGray algorithm is an n-dimensional Hilbert curve with a simplified implementation. It follows an article, "Programming the Hilbert Curve," by <NAME>, 707 (2004), http://dx.doi.org/10.1063/1.1751381. I call it "Global Gray" because the insight of the article is that a single, global Gray code can be applied to all np bits of a Hilbert length. """ struct GlobalGray{T} <: HilbertAlgorithm{T} b::Int n::Int end axis_type(gg::GlobalGray) = large_enough_unsigned(gg.b) function GlobalGray(b, n) ttype = large_enough_unsigned(b * n) GlobalGray{ttype}(b, n) end function GlobalGray(::Type{T}, b, n) where {T} GlobalGray{T}(b, n) end function encode_hilbert_zero!(g::GlobalGray{T}, X::Vector)::T where {T} axes_to_transpose!(X, g.b, g.n) interleave_transpose(T, X, g.b, g.n) end """ encode_hilbert_zero(ha::HilbertAlgorithm{T}, X::Vector{A}) Takes an n-dimensional vector `X` and returns a single integer of type `T` which orders `X` to improve spatial locality. The input `X` has multiple axes and the output is called a Hilbert index. This version is zero-based, so each axis counts from 0, and the smallest Hilbert index is 0. """ function encode_hilbert_zero(g::GlobalGray{T}, X::Vector)::T where {T} Y = copy(X) encode_hilbert_zero!(g, Y) end """ decode_hilbert_zero!(ha::HilbertAlgorithm{T}}, X::Vector{A}, h::T) Given a Hilbert index, `h`, computes an n-dimensional coordinate `X`. The type of the Hilbert index is large enought to contain the bits of all dimensions of the axis vector, `X`. """ function decode_hilbert_zero!(g::GlobalGray{T}, X::Vector, h::T) where {T} outerleave_transpose!(X, h, g.b, g.n) transpose_to_axes!(X, g.b, g.n) end
[ 37811, 198, 220, 220, 220, 1007, 3455, 62, 1462, 62, 897, 274, 7, 37652, 11, 275, 11, 299, 8, 198, 198, 3103, 1851, 422, 47718, 6376, 284, 257, 20435, 1640, 4600, 65, 63, 10340, 198, 259, 4600, 77, 63, 15225, 13, 198, 37811, 198, 8818, 1007, 3455, 62, 1462, 62, 897, 274, 0, 7, 55, 3712, 38469, 90, 51, 5512, 275, 11, 299, 8, 810, 1391, 51, 1279, 25, 34142, 92, 198, 220, 220, 220, 399, 796, 309, 7, 17, 8, 9959, 357, 65, 532, 352, 8, 198, 220, 220, 220, 1303, 12723, 36899, 416, 367, 61, 7, 39, 14, 17, 8, 198, 220, 220, 220, 256, 796, 1395, 58, 77, 60, 9609, 352, 198, 220, 220, 220, 329, 33245, 796, 299, 21912, 16, 25, 17, 198, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 952, 60, 2343, 232, 119, 28, 1395, 58, 952, 532, 352, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1395, 58, 16, 60, 2343, 232, 119, 28, 256, 198, 220, 220, 220, 1303, 13794, 78, 6992, 670, 198, 220, 220, 220, 1195, 796, 309, 7, 17, 8, 198, 220, 220, 220, 981, 1195, 14512, 399, 198, 220, 220, 220, 220, 220, 220, 220, 350, 796, 1195, 532, 530, 7, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 2525, 796, 299, 21912, 16, 25, 16, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 357, 55, 58, 7639, 60, 1222, 1195, 8, 14512, 6632, 7, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 16, 60, 2343, 232, 119, 28, 350, 220, 1303, 287, 1851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2073, 220, 1303, 5163, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 796, 357, 55, 58, 16, 60, 2343, 232, 119, 1395, 58, 7639, 12962, 1222, 350, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 16, 60, 2343, 232, 119, 28, 256, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 7639, 60, 2343, 232, 119, 28, 256, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1195, 9959, 28, 352, 198, 220, 220, 220, 886, 198, 437, 628, 198, 8818, 34197, 62, 1462, 62, 7645, 3455, 0, 7, 55, 3712, 38469, 90, 51, 5512, 275, 11, 299, 8, 810, 1391, 51, 1279, 25, 34142, 92, 198, 220, 220, 220, 337, 796, 530, 7, 51, 8, 9959, 357, 65, 532, 352, 8, 198, 220, 220, 220, 1303, 554, 4399, 23981, 198, 220, 220, 220, 1195, 796, 337, 198, 220, 220, 220, 981, 1195, 1875, 530, 7, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 350, 796, 1195, 532, 530, 7, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 33245, 796, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 357, 55, 58, 952, 60, 1222, 1195, 8, 14512, 6632, 7, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 16, 60, 2343, 232, 119, 28, 350, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 796, 357, 55, 58, 16, 60, 2343, 232, 119, 1395, 58, 952, 12962, 1222, 350, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 16, 60, 2343, 232, 119, 28, 256, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 952, 60, 2343, 232, 119, 28, 256, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1195, 9609, 28, 352, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1303, 12723, 37773, 198, 220, 220, 220, 329, 2525, 796, 362, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 7639, 60, 2343, 232, 119, 28, 1395, 58, 7639, 532, 352, 60, 198, 220, 220, 220, 886, 198, 220, 220, 220, 256, 17, 796, 6632, 7, 51, 8, 198, 220, 220, 220, 1195, 796, 337, 198, 220, 220, 220, 981, 1195, 1875, 530, 7, 51, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 357, 55, 58, 77, 60, 1222, 1195, 8, 14512, 657, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 17, 2343, 232, 119, 28, 357, 48, 532, 530, 7, 51, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1195, 9609, 28, 530, 7, 51, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 329, 41727, 796, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 7204, 60, 2343, 232, 119, 28, 256, 17, 198, 220, 220, 220, 886, 198, 437, 198, 198, 37811, 198, 51, 1124, 257, 15879, 286, 4129, 4600, 77, 63, 290, 4113, 262, 10340, 286, 477, 4600, 77, 63, 37014, 198, 20424, 257, 2060, 18253, 13, 383, 15879, 338, 352, 301, 7515, 318, 262, 749, 2383, 1643, 13, 198, 37811, 198, 8818, 987, 47408, 62, 7645, 3455, 7, 3712, 6030, 90, 51, 5512, 1395, 3712, 38469, 11, 275, 11, 299, 8, 810, 1391, 51, 92, 198, 220, 220, 220, 289, 796, 6632, 7, 51, 8, 198, 220, 220, 220, 329, 1312, 287, 657, 37498, 65, 532, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 288, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 340, 71, 62, 2545, 796, 357, 55, 58, 67, 60, 1222, 357, 16, 16791, 72, 4008, 9609, 1312, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 930, 28, 340, 71, 62, 2545, 9959, 357, 72, 1635, 299, 1343, 299, 532, 288, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 289, 198, 437, 628, 198, 37811, 198, 51, 1124, 257, 2060, 18253, 290, 4113, 663, 3815, 656, 6805, 286, 257, 15879, 11, 198, 2545, 12, 1525, 12, 2545, 13, 198, 37811, 198, 8818, 12076, 47408, 62, 7645, 3455, 0, 7, 55, 3712, 38469, 90, 51, 5512, 289, 11, 275, 11, 299, 8, 810, 1391, 51, 1279, 25, 34142, 92, 198, 220, 220, 220, 1395, 764, 28, 6632, 7, 51, 8, 198, 220, 220, 220, 329, 1312, 287, 657, 37498, 65, 12, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 288, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 340, 71, 62, 2545, 796, 357, 71, 1222, 357, 505, 7, 71, 8, 9959, 357, 72, 1635, 299, 1343, 299, 532, 288, 22305, 9609, 357, 72, 1635, 299, 1343, 299, 532, 288, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 67, 60, 930, 28, 340, 71, 62, 2545, 9959, 1312, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 437, 628, 198, 37811, 198, 51, 1124, 257, 15879, 286, 4129, 4600, 77, 63, 290, 4113, 262, 10340, 286, 477, 4600, 77, 63, 37014, 198, 20424, 257, 2060, 18253, 13, 383, 15879, 338, 352, 301, 7515, 318, 262, 1551, 2383, 1643, 13, 198, 37811, 198, 8818, 987, 47408, 62, 7645, 3455, 62, 9319, 7, 3712, 6030, 90, 51, 5512, 1395, 3712, 38469, 90, 51, 5512, 275, 11, 299, 8, 810, 1391, 51, 92, 198, 220, 220, 220, 289, 796, 6632, 7, 51, 8, 198, 220, 220, 220, 329, 1312, 287, 657, 37498, 65, 532, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 288, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 930, 28, 14808, 55, 58, 67, 60, 1222, 357, 505, 7, 51, 8, 16791, 72, 22305, 9959, 357, 72, 9, 7, 77, 532, 352, 8, 1343, 288, 532, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 289, 198, 437, 628, 198, 8818, 12076, 47408, 62, 7645, 3455, 62, 9319, 0, 7, 55, 3712, 38469, 90, 51, 5512, 289, 11, 275, 11, 299, 8, 810, 1391, 51, 1279, 25, 34142, 92, 198, 220, 220, 220, 1395, 764, 28, 6632, 7, 51, 8, 198, 220, 220, 220, 329, 1312, 287, 657, 37498, 65, 12, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 329, 288, 287, 352, 25, 77, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1395, 58, 67, 60, 930, 28, 357, 71, 1222, 357, 505, 7, 51, 8, 9959, 357, 72, 1635, 299, 1343, 288, 532, 352, 22305, 9609, 357, 72, 1635, 357, 77, 532, 352, 8, 1343, 288, 532, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 8060, 46130, 7, 65, 11, 299, 8, 198, 220, 220, 220, 8060, 46130, 7, 51, 11, 275, 11, 299, 8, 198, 198, 63, 51, 63, 318, 257, 1366, 2099, 329, 262, 47718, 6376, 13, 632, 460, 307, 4488, 393, 22165, 11, 198, 292, 890, 355, 340, 468, 379, 1551, 4600, 77, 1635, 275, 63, 10340, 13, 4600, 77, 63, 318, 262, 1271, 286, 15225, 11, 198, 392, 4600, 65, 63, 318, 262, 10340, 583, 15793, 11, 523, 1123, 16488, 1988, 815, 307, 1022, 198, 15, 290, 7559, 17, 61, 65, 532, 352, 15506, 11, 19889, 11, 329, 262, 6632, 12, 3106, 7071, 13, 1119, 815, 307, 198, 23395, 352, 290, 7559, 17, 61, 65, 15506, 11, 19889, 11, 329, 262, 530, 12, 3106, 7071, 13, 198, 198, 464, 8060, 46130, 11862, 318, 281, 299, 12, 19577, 47718, 12133, 351, 257, 27009, 198, 320, 32851, 13, 632, 5679, 281, 2708, 11, 366, 15167, 2229, 262, 47718, 46300, 553, 416, 198, 27, 20608, 22330, 767, 2998, 357, 15724, 828, 2638, 1378, 34350, 13, 34023, 13, 2398, 14, 940, 13, 940, 5066, 14, 16, 13, 17430, 1485, 6659, 13, 198, 40, 869, 340, 366, 22289, 12723, 1, 780, 262, 11281, 286, 262, 2708, 198, 271, 326, 257, 2060, 11, 3298, 12723, 2438, 460, 307, 5625, 284, 477, 198, 37659, 10340, 286, 257, 47718, 4129, 13, 198, 37811, 198, 7249, 8060, 46130, 90, 51, 92, 1279, 25, 47718, 2348, 42289, 90, 51, 92, 198, 220, 220, 220, 275, 3712, 5317, 198, 220, 220, 220, 299, 3712, 5317, 198, 437, 628, 198, 22704, 62, 4906, 7, 1130, 3712, 22289, 46130, 8, 796, 1588, 62, 48229, 62, 43375, 7, 1130, 13, 65, 8, 628, 198, 8818, 8060, 46130, 7, 65, 11, 299, 8, 198, 220, 220, 220, 256, 4906, 796, 1588, 62, 48229, 62, 43375, 7, 65, 1635, 299, 8, 198, 220, 220, 220, 8060, 46130, 90, 83, 4906, 92, 7, 65, 11, 299, 8, 198, 437, 628, 198, 8818, 8060, 46130, 7, 3712, 6030, 90, 51, 5512, 275, 11, 299, 8, 810, 1391, 51, 92, 198, 220, 220, 220, 8060, 46130, 90, 51, 92, 7, 65, 11, 299, 8, 198, 437, 628, 198, 8818, 37773, 62, 71, 346, 4835, 62, 22570, 0, 7, 70, 3712, 22289, 46130, 90, 51, 5512, 1395, 3712, 38469, 2599, 25, 51, 810, 1391, 51, 92, 198, 220, 220, 220, 34197, 62, 1462, 62, 7645, 3455, 0, 7, 55, 11, 308, 13, 65, 11, 308, 13, 77, 8, 198, 220, 220, 220, 987, 47408, 62, 7645, 3455, 7, 51, 11, 1395, 11, 308, 13, 65, 11, 308, 13, 77, 8, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 37773, 62, 71, 346, 4835, 62, 22570, 7, 3099, 3712, 39, 346, 4835, 2348, 42289, 90, 51, 5512, 1395, 3712, 38469, 90, 32, 30072, 198, 198, 51, 1124, 281, 299, 12, 19577, 15879, 4600, 55, 63, 290, 5860, 257, 2060, 18253, 286, 2099, 198, 63, 51, 63, 543, 6266, 4600, 55, 63, 284, 2987, 21739, 48036, 13, 383, 5128, 4600, 55, 63, 468, 3294, 198, 897, 274, 290, 262, 5072, 318, 1444, 257, 47718, 6376, 13, 770, 2196, 318, 6632, 12, 3106, 11, 198, 568, 1123, 16488, 9853, 422, 657, 11, 290, 262, 18197, 47718, 6376, 318, 657, 13, 198, 37811, 198, 8818, 37773, 62, 71, 346, 4835, 62, 22570, 7, 70, 3712, 22289, 46130, 90, 51, 5512, 1395, 3712, 38469, 2599, 25, 51, 810, 1391, 51, 92, 198, 220, 220, 220, 575, 796, 4866, 7, 55, 8, 198, 220, 220, 220, 37773, 62, 71, 346, 4835, 62, 22570, 0, 7, 70, 11, 575, 8, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 36899, 62, 71, 346, 4835, 62, 22570, 0, 7, 3099, 3712, 39, 346, 4835, 2348, 42289, 90, 51, 92, 5512, 1395, 3712, 38469, 90, 32, 5512, 289, 3712, 51, 8, 198, 198, 15056, 257, 47718, 6376, 11, 4600, 71, 47671, 552, 1769, 281, 299, 12, 19577, 20435, 4600, 55, 44646, 383, 2099, 286, 198, 1169, 47718, 6376, 318, 1588, 1576, 83, 284, 3994, 262, 10340, 286, 477, 15225, 286, 262, 198, 22704, 15879, 11, 4600, 55, 44646, 198, 37811, 198, 8818, 36899, 62, 71, 346, 4835, 62, 22570, 0, 7, 70, 3712, 22289, 46130, 90, 51, 5512, 1395, 3712, 38469, 11, 289, 3712, 51, 8, 810, 1391, 51, 92, 198, 220, 220, 220, 12076, 47408, 62, 7645, 3455, 0, 7, 55, 11, 289, 11, 308, 13, 65, 11, 308, 13, 77, 8, 198, 220, 220, 220, 1007, 3455, 62, 1462, 62, 897, 274, 0, 7, 55, 11, 308, 13, 65, 11, 308, 13, 77, 8, 198, 437, 198 ]
2.101979
2,324
#= Implement broadcast functionality for Sol =# Base.similar(sol::Sol{N}) where {N} = Sol(similar(sol.x), similar(sol.α)) Broadcast.broadcasted(::typeof(identity), s::Sol{N}) where {N} = s function Broadcast.materialize!(dest::Sol{N}, src::Sol{N}) where {N} dest.x .= src.x dest.α .= src.α end
[ 2, 28, 198, 3546, 26908, 7025, 11244, 329, 4294, 198, 46249, 198, 198, 14881, 13, 38610, 7, 34453, 3712, 36949, 90, 45, 30072, 810, 1391, 45, 92, 796, 198, 220, 220, 220, 4294, 7, 38610, 7, 34453, 13, 87, 828, 2092, 7, 34453, 13, 17394, 4008, 628, 198, 30507, 2701, 13, 36654, 2701, 276, 7, 3712, 4906, 1659, 7, 738, 414, 828, 264, 3712, 36949, 90, 45, 30072, 810, 1391, 45, 92, 796, 264, 628, 198, 8818, 44244, 13, 33665, 1096, 0, 7, 16520, 3712, 36949, 90, 45, 5512, 12351, 3712, 36949, 90, 45, 30072, 810, 1391, 45, 92, 198, 220, 220, 220, 2244, 13, 87, 764, 28, 12351, 13, 87, 198, 220, 220, 220, 2244, 13, 17394, 764, 28, 12351, 13, 17394, 198, 437, 198 ]
2.468254
126
<reponame>UnofficialJuliaMirrorSnapshots/MatLang.jl-05b439c0-bb3c-11e9-1d8d-1f0a9ebca87a developing = false; # are you developing the package or just using? if developing # ] add Revise # if you don't have it path = pwd() if path[end-6:end] != "MatLang" error("cd(to the MatLang path)") end push!(LOAD_PATH, ".") using Revise using MatLang else using MatLang end ################################################################ ################################################################ mzero0 = zerosM(:mat, 2) # same as zeros(2,2) mzero1 = zerosM(:mat, 2, like = zerosM(Int32, 2, 2)) # like method A=[2 1 2] mzero2 = zerosM(2, like=A) # same as zeros(Int64,2) mzero3 = zerosM(2) # same as zeros(2) mzero4 = zerosM(Int32, 2, 2) # same as zeros(Int32,2,2) # giving size as Tuple mzero5 = zerosM((2, 2)) # = zerosM(2,2) mzero6 = zerosM(Int32, (2, 2)) # giving size as an Array ## non-efficient Matlab way. Array should be Integer otherwise you will get errors. mzero7 = zerosM([2, 2]) mzero8 = zerosM(Int32, [2, 2]) mzero9 = zerosM([2, 2], like = [2.5 3.0]) ################################################################ mone0 = onesM(:mat, 2) # same as ones(2,2) mone1 = onesM(:mat, 2, like = onesM(Int32, 2, 2)) # like method A=[2 1 2] mone2 = onesM(2, like=A) # same as ones(Int64,2) mone3 = onesM(2) # same as ones(2) mone4 = onesM(Int32, 2, 2) # same as ones(Int32,2,2) # giving size as Tuple mone5 = onesM((2, 2)) # = onesM(2,2) mone6 = onesM(Int32, (2, 2)) # giving size as an Array ## non-efficient Matlab way. Array should be Integer otherwise you will get errors. mone7 = onesM([2, 2]) mone8 = onesM(Int32, [2, 2]) mone9 = onesM([2, 2], like = [2.5 3.0]) ################################################################ mrandom0 = randM(:mat, 2) # same as rand(2,2) mrandom1 = randM(:mat, 2, like = randM(Int32, 2, 2)) # like method A=[2 1 2] mrandom2 = randM(2, like=A) # same as rand(Int64,2) mrandom3 = randM(2) # same as rand(2) mrandom4 = randM(Int32, 2, 2) # same as rand(Int32,2,2) # giving size as Tuple mrandom5 = randM((2, 2)) # = randM(2,2) mrandom6 = randM(Int32, (2, 2)) # giving size as an Array ## non-efficient Matlab way. Array should be Integer otherwise you will get errors. mrandom7 = randM([2, 2]) mrandom8 = randM(Int32, [2, 2]) mrandom9 = randM([2, 2], like = [2.5 3.0]) ################################################################ mtrue0 = trueM(:mat, 2) # same as trues(2,2) mtrue1 = trueM(2) # same as trues(2) # giving size as Tuple mtrue2 = trueM((2, 2)) # = trues(2,2) # giving size as an Array ## non-efficient Matlab way. Array should be Integer otherwise you will get errors. mtrue3 = trueM([2, 2]) ################################################################ mfalse0 = falseM(:mat, 2) # same as falses(2,2) mfalse1 = falseM(2) # same as falses(2) # giving size as Tuple mfalse2 = falseM((2, 2)) # = falses(2,2) # giving size as an Array ## non-efficient Matlab way. Array should be Integer otherwise you will get errors. mfalse3 = falseM([2, 2]) ################################################################ mEye0 = eyeM(2); # [1 0 0; 0 1 0] mEye1 = eyeM(2, 3); # [1 0 0; 0 1 0] mEye2 = eyeM(Int32, 2, 3); # [1 0 0; 0 1 0] mEye3 = eyeM(2, 3, like = zerosM(Int8, 2, 2)) mEye4 = eyeM((2, 2)) # giving size as a Tuple. In Julia we use (2,2) instead of giving it as [2,2] mEye5 = eyeM(Int32, (2, 2)) # giving size as a Tuple. In Julia we use (2,2) instead of giving it as [2,2] mEye6 = eyeM([2, 2]) # non-efficient Matlab way mEye7 = eyeM(Int32, [2, 2]) # non-efficient Matlab way s1 = size(ones(2, 3)) # getting size from another matrix or calculation mEye8 = eyeM(s1) # giving size as a variable (Tuple). ################################################################ mDiag = diagM([2, 3, 4]) # [0 2 0 ; 0 3 0; 0 4] mDiag2 = diagM([2, 3, 4], 1) # [0 2 3 0; 0 0 3 0; 0 0 0 4; 0 0 0 0] mDiag3 = diagM([1 2 3; 4 5 6; 7 8 9]) # [1;5;9] mDiag4 = diagM([1 2 3; 4 5 6; 7 8 9], 1) # [2;6] ################################################################ A1 = 3 * ones(2, 2); A2 = 4 * ones(2, 2); A3 = rand(3, 3); mBlkdiag1 = blkdiagM(A1, A2, A3) mBlkdiag2 = blkdiagM(ones(2, 2), 2 * ones(2, 2)) # [ones(2, 2) zeros(2, 2); zeros(2, 2) 2 * ones(2, 2)] A1 = ones(2, 4); A2 = 2 * ones(3, 2); mBlkdiag3 = blkdiagM(A1, A2) # [ones(2,4) zeros(2,2); zeros(3,4) 2*ones(3,2)] mBlkdiag1obj = blkdiagM(:obj, A1, A2, A3) # returning BlockDiagonal object mBlkdiag2obj = blkdiagM(:obj, ones(2, 2), 2 * ones(2, 2)) # returning BlockDiagonal object for [ones(2, 2) zeros(2, 2); zeros(2, 2) 2 * ones(2, 2)] ################################################################ mCat1 = catM(1, ones(3, 3), zeros(3, 3)) # [ones(3, 3); zeros(3, 3)] mCat2 = catM(2, ones(3, 3), zeros(3, 3)) # [ones(3, 3) zeros(3, 3)] mCat3 = catM(1, ones(3, 3), zeros(3, 3), 2 * ones(3, 3)) # [ones(3, 3); zeros(3, 3); 2 * ones(3, 3)] mCat4 = catM(3, ones(2, 2, 2), zeros(2, 2, 2)) # [ones(2, 2, 2) zeros(2, 2, 2)] ################################################################ mHCat1 = horzcatM(ones(3, 3), zeros(3, 3)) # [ones(3, 3) zeros(3, 3)] ################################################################ mVCat1 = vertcatM(ones(3, 3), zeros(3, 3)) # [ones(3, 3); zeros(3, 3)] ################################################################ V1 = [1 2 3 4]; mRepelem1 = repelemM(V1, 3) # [1 1 1 2 2 2 3 3 3 4 4 4] # mRepelem2 = repelemM(V1, (3,2,1,1)) # [1 1 1 2 2 3 4] # mRepelem3 = repelemM(V1, vec([3 2 1 1])) # [1 1 1 2 2 3 4] ################################################################ mRempat1 = repmatM(10, 3, 2) # [10 10; 10 10; 10 10] V = [1; 2] mRempat2 = repmatM(V, 3, 2) # [[1; 2] [1; 2]; [1; 2] [1; 2]; [1; 2] [1; 2]] mRempat3 = repmatM(V, [3, 2]) # [[1; 2] [1; 2]; [1; 2] [1; 2]; [1; 2] [1; 2]] mRempat4 = repmatM(V, (3, 2)) # [[1; 2] [1; 2]; [1; 2] [1; 2]; [1; 2] [1; 2]] mRempat5 = repmatM(V, 2) # [[1; 2] [1; 2]; [1; 2] [1; 2]] mRempat6 = repmatM(V, 1, 3) # [[1; 2] [1; 2] [1; 2]] ################################################################ mLinspace1 = linspaceM(1, 10) # 1:10 mLinspace2 = linspaceM(1, 10, 2) # 1:2:10 == 1:2:9 mLinspace3 = linspaceM(:arr, 1, 10) # collect(1:10) mLinspace4 = linspaceM(:arr, 1, 10, 2) # collect(1:2:10) ################################################################ mLogspace1 = logspaceM(1, 5) # 50 logarithmically spaced points between 10^1 and 10^5 mLogspace2 = logspaceM(1, 5, 10) # 10 logarithmically spaced points between 10^1 and 10^5 mLogspace3 = logspaceM(1, 5, :equal) # [10.0^1, 10.0^2, 10.0^3, 10.0^4, 10.0^5] == 10.0.^(1:5) ################################################################ m1Meshgrid0, m2Meshgrid0 = meshgridM(1:2:5) # a 2-D rectangle spanning 1:2:5 in x and y direction == [[1;1;1][3;3;3] [5;5;5]] and [1 1 1; 3 3 3; 5 5 5] m1Meshgrid1, m2Meshgrid1 = meshgridM(1:2:5, 1:2:5) # a 2-D rectangle spanning 1:2:5 in x and y direction == ([1 3 5;1 3 5; 1 3 5],[1 1 1; 3 3 3; 5 5 5]) m1Meshgrid2, m2Meshgrid2, m3Meshgrid2 = meshgridM(1:6, 20:25, 5:10) # a 3-D rectangle spanning 1:6 in x, 20:25 in y, and 5:10 in z ################################################################ m1Ndgrid0, m2Ndgrid0 = ndgridM(1:2:5, dim = 2) # a 2-D rectangle spanning 1:2:5 in x and y direction == [1 1 1; 3 3 3; 5 5 5] and [1 3 5;1 3 5; 1 3 5] m1Ndgrid1, m2Ndgrid1 = ndgridM(1:2:5, 1:2:5) # a 2-D rectangle spanning 1:2:5 in x and y direction == ([1 1 1; 3 3 3; 5 5 5], [1 3 5;1 3 5; 1 3 5]) m1Ndgrid2, m2Ndgrid2, m3Ndgrid2 = ndgridM(1:6, 20:25, 5:10) # a 3-D rectangle spanning 1:6 in x, 20:25 in y, and 5:10 in z ################################################################ mFreqspace1 = freqspaceM(10, dim = 1) # 0:0.2:1 mFreqspace2 = freqspaceM(10, :whole, dim = 1) # 0:0.2:1.8 m1Freqspace3, m2Freqspace3 = freqspaceM(10, dim = 2) # returns two -1:0.2:0.8 m1Freqspace4, m2Freqspace4 = freqspaceM(10, :meshgrid, dim = 2) # returns mesgridM(-1:0.2:0.8, -1:0.2:0.8), which is two -1:0.2:0.8 ################################################################ A1 = [2 3 4 5 6 7; 1 2 3 4 5 6] nLength1 = lengthM(A1); # 6 A2 = ["Hi" 6; "Goodbye" 5; "Hello" 1] nLength2 = lengthM(A2); # 3 ################################################################ A1 = [2 3 4 5 6 7; 1 2 3 4 5 6] mSize1 = sizeM(:arr, A1); # [2; 6] tSize1 = sizeM(A1); # (2, 6) nA1Size2 = sizeM(A1, 2); # 6 sizeM(A1, 2) == 6 # true sizeM(:arr, A1, 2) == 6 # false sizeM(:arr, A1, 2) == [6] # true nA1Size1, nA1Size2 = sizeM(A1); # 2 and 6 A2 = rand(3, 5, 4) mSize2 = sizeM(:arr, A2, 2, 3); # [5; 4] tSize2 = sizeM(A2, 2, 3); # (5, 4) ################################################################ A = rand(3,4,5); nDim1 = ndims(A) # 3 ################################################################ nNumel1 = numelM(1:5) # 5 nNumel2 = numelM([1, 2, 3, 4]) # 4 nNumel3 = numelM([1 2; 3 4]) # 4 ################################################################ bIsscalar1 = isscalarM(1) # true bIsscalar2 = isscalarM(5 * ones(1, 1, 1)) # false # bIsscalar3 = isscalarM("H") # gives error # # bIsscalar4 = isscalarM("Hi") # gives error bIsscalar5 = isscalarM(["Hi"]) # false bIsscalar6 = isscalarM(["Hi" "Bye"]) # false bIsscalar7 = isscalarM('H') # true # becareful that in Julia, chars are always singular. bIsscalar8 = isscalarM(true) # true # Matlab way: bIsscalarMat1 = isscalarM(:mat, 1) # true bIsscalarMat2 = isscalarM(:mat, [1]) # true bIsscalarMat3 = isscalarM(:mat, 5 * ones(1, 1, 1)) # true bIsscalarMat4 = isscalarM(:mat, "H") # true bIsscalarMat5 = isscalarM(:mat, "Hi") # false bIsscalarMat6 = isscalarM(:mat, ["Hi"]) # true bIsscalarMat7 = isscalarM(:mat, ["Hi" "Bye"]) # false bIsscalarMat8 = isscalarM(:mat, 'H') # true # becareful that in Julia, chars are always singular. bIsscalarMat9 = isscalarM(:mat, true) # true ################################################################ A1 = [1; 2; 3] # or [1, 2, 3] bIsvector1 = isvectorM(A1) # true A2 = [1 2 3] bIsvector2 = isvectorM(A2) # false bIsvector3 = isvectorM(ones(3, 1)) # false bIsvector4 = isvectorM(ones(1, 3)) # false bIsvector5 = isvectorM(ones(3)) # true bIsvector6 = isvectorM(1) # false bIsvector7 = isvectorM("Hi") # false bIsvector8 = isvectorM(["Hi", "Bye"]) # true bIsMatrix9 = isvectorM(["Hi" "Bye"]) # false # Matlab Way: bIsvectorMat1 = isvectorM(:mat, A1) # true bIsvectorMat2 = isvectorM(:mat, A2) # true bIsvectorMat3 = isvectorM(:mat, ones(3, 1)) # true bIsvectorMat4 = isvectorM(:mat, ones(1, 3)) # true bIsvectorMat5 = isvectorM(:mat, ones(3)) # true bIsvectorMat6 = isvectorM(:mat, 1) # true bIsvectorMat7 = isvectorM(:mat, "Hi") # true bIsvectorMat8 = isvectorM(:mat, ["Hi", "Bye"]) # true ################################################################ A1 = [1 2 3; 3 5 6] bIsMatrix1 = ismatrixM(A1) # true A2 = [1;2;3] # or [1,2,3] bIsMatrix2 = ismatrixM(A2) # false bIsMatrix3 = ismatrixM(ones(3, 1)) # true bIsMatrix4 = ismatrixM(ones(1, 3)) # true bIsMatrix5 = ismatrixM(ones(3)) # false bIsMatrix6 = ismatrixM("Hi") # false bIsMatrix7 = ismatrixM(["Hi", "Bye"]) # false bIsMatrix8 = ismatrixM(["Hi" "Bye"]) # true # Matlab Way: bIsMatrixMat1 = ismatrixM(:mat, A1) # true bIsMatrixMat2 = ismatrixM(:mat, A2) # true bIsMatrixMat3 = ismatrixM(:mat, ones(3, 1)) # true bIsMatrixMat4 = ismatrixM(:mat, ones(1, 3)) # true bIsMatrixMat5 = ismatrixM(:mat, ones(3)) # true bIsMatrixMat6 = ismatrixM(:mat, "Hi") # true bIsMatrixMat7 = ismatrixM(:mat, ["Hi", "Bye"]) # true ################################################################ A1 = [1; 2; 3] # or [1, 2, 3] bIsrow1 = isrowM(A1) # false A2 = [1 2 3] bIsrow2 = isrowM(A2) # true bIsrow3 = isrowM(ones(3, 1)) # false bIsrow4 = isrowM(ones(1, 3)) # true bIsrow5 = isrowM(ones(3)) # false bIsrow6 = isrowM(1) # false bIsrow7 = isrowM("Hi") # false bIsrow8 = isrowM(["Hi", "Bye"]) # false bIsrow9 = isrowM(["Hi" "Bye"]) # true # Matlab Way: bIsrowMat1 = isrowM(:mat, A1) # false bIsrowMat2 = isrowM(:mat, A2) # true bIsrowMat3 = isrowM(:mat, ones(3, 1)) # false bIsrowMat4 = isrowM(:mat, ones(1, 3)) # true bIsrowMat5 = isrowM(:mat, ones(3)) # false bIsrowMat6 = isrowM(:mat, 1) # true bIsrowMat7 = isrowM(:mat, "Hi") # true bIsrowMat8 = isrowM(:mat, ["Hi", "Bye"]) # false ################################################################ A1 = [1; 2; 3] # or [1, 2, 3] bIscolumn1 = iscolumnM(A1) # false A2 = [1 2 3] bIscolumn2 = iscolumnM(A2) # false bIscolumn3 = iscolumnM(ones(3, 1)) # tue bIscolumn4 = iscolumnM(ones(1, 3)) #false bIscolumn5 = iscolumnM(ones(3)) # false bIscolumn6 = iscolumnM(1) # false bIscolumn7 = iscolumnM("Hi") # false bIscolumn8 = iscolumnM(["Hi", "Bye"]) # false bIscolumn9 = iscolumnM(["Hi" "Bye"]) # false # Matlab Way: bIscolumnMat1 = iscolumnM(:mat, A1) # true bIscolumnMat2 = iscolumnM(:mat, A2) # false bIscolumnMat3 = iscolumnM(:mat, ones(3, 1)) # true bIscolumnMat4 = iscolumnM(:mat, ones(1, 3)) # false bIscolumnMat5 = iscolumnM(:mat, ones(3)) # true bIscolumnMat6 = iscolumnM(:mat, 1) # true bIscolumnMat7 = iscolumnM(:mat, "Hi") # true bIscolumnMat8 = iscolumnM(:mat, ["Hi", "Bye"]) # true ################################################################ mSort0 = sortM([5, 3, 19, 20, 1, 4]) # [1, 3, 4, 5, 19, 20] A = [5, 3, 19, 20, 1, 4] mSort1, iSort1 = sortM(A, I = true) # returning sort index A[iSort1] == mSort1 mSort2 = sortM([5, 3, 19, 20, 1, 4], :descend) # [20,19,5,4,3,1] mSort3 = sortM([1 5 3; 4 1 10]) # [1 1 3; 4 5 10] mSort4 = sortM([1 5 3; 4 1 10], 2, :ascend) # [1 3 5; 1 4 10] B = [1 5 3; 4 1 10] mSort5, iSort5 = sortM(B, 2, :ascend, I = true) # [1 3 5; 1 4 10] B[iSort5] == mSort5 A = zerosM(Integer, 2, 2, 2) A[:, :, 1] = [2 3; 1 6] A[:, :, 2] = [-1 9; 0 12] mSort6 = sortM(A, 3) # 3D sort ################################################################ sFlip1 = flipM("Hi") # "iH" mFlip2 = flipM([1; 2; 3; 4]) #[4;3;2;1] mFlip3 = flipM([1 2; 3 4]) # flips every column: # [3 4; 1 2] mFlip4 = flipM([1 2; 3 4], 2) # flip along dims 2: #[2 1; 4 3] ################################################################ mRot1 = rot90M([1 2; 3 4]) #[2 4; 1 3] mRot2 = rot90M([1 2; 3 4], 3) # [3 1; 4 2] ################################################################ A1 = [2 3 4 5 6 7; 1 2 3 4 5 6] mTranspose1 = transposeM(A1) mTranspose2 = transposeM(:arr, A1) ################################################################ A1 = ones(2, 1, 2); # 3 dimensional mSqueeze1 = squeezeM(A1) # [1 1; 1 1] A2 = zeros(1, 4, 1); A2[:, 1:4, ] = [5; 3; 6; 0] mSqueeze2 = squeezeM(A2) # When it gets one dimensional, it is vertical. mSqueeze2 == [5; 3; 6; 0] # true mSqueeze2 == [5 3 6 0] # false ################################################################
[ 27, 7856, 261, 480, 29, 3118, 16841, 16980, 544, 27453, 1472, 43826, 20910, 14, 19044, 43, 648, 13, 20362, 12, 2713, 65, 47106, 66, 15, 12, 11848, 18, 66, 12, 1157, 68, 24, 12, 16, 67, 23, 67, 12, 16, 69, 15, 64, 24, 1765, 6888, 5774, 64, 198, 16244, 278, 796, 3991, 26, 1303, 389, 345, 5922, 262, 5301, 393, 655, 1262, 30, 198, 361, 5922, 198, 197, 2, 2361, 751, 5416, 786, 1303, 611, 345, 836, 470, 423, 340, 198, 220, 220, 220, 3108, 796, 279, 16993, 3419, 198, 220, 220, 220, 611, 3108, 58, 437, 12, 21, 25, 437, 60, 14512, 366, 19044, 43, 648, 1, 198, 220, 220, 220, 220, 220, 220, 220, 4049, 7203, 10210, 7, 1462, 262, 6550, 43, 648, 3108, 8, 4943, 198, 220, 220, 220, 886, 198, 220, 220, 220, 4574, 0, 7, 35613, 62, 34219, 11, 366, 19570, 198, 220, 220, 220, 1262, 5416, 786, 198, 220, 220, 220, 1262, 6550, 43, 648, 198, 17772, 198, 220, 220, 220, 1262, 6550, 43, 648, 198, 437, 198, 29113, 29113, 198, 29113, 29113, 198, 76, 22570, 15, 796, 1976, 27498, 44, 7, 25, 6759, 11, 362, 8, 1303, 976, 355, 1976, 27498, 7, 17, 11, 17, 8, 198, 198, 76, 22570, 16, 796, 1976, 27498, 44, 7, 25, 6759, 11, 362, 11, 588, 796, 1976, 27498, 44, 7, 5317, 2624, 11, 362, 11, 362, 4008, 1303, 588, 2446, 198, 198, 32, 41888, 17, 352, 362, 60, 198, 76, 22570, 17, 796, 1976, 27498, 44, 7, 17, 11, 588, 28, 32, 8, 1303, 976, 355, 1976, 27498, 7, 5317, 2414, 11, 17, 8, 198, 198, 76, 22570, 18, 796, 1976, 27498, 44, 7, 17, 8, 1303, 976, 355, 1976, 27498, 7, 17, 8, 198, 198, 76, 22570, 19, 796, 1976, 27498, 44, 7, 5317, 2624, 11, 362, 11, 362, 8, 1303, 976, 355, 1976, 27498, 7, 5317, 2624, 11, 17, 11, 17, 8, 198, 198, 2, 3501, 2546, 355, 309, 29291, 198, 76, 22570, 20, 796, 1976, 27498, 44, 19510, 17, 11, 362, 4008, 1303, 796, 1976, 27498, 44, 7, 17, 11, 17, 8, 198, 198, 76, 22570, 21, 796, 1976, 27498, 44, 7, 5317, 2624, 11, 357, 17, 11, 362, 4008, 198, 198, 2, 3501, 2546, 355, 281, 15690, 198, 2235, 1729, 12, 16814, 6550, 23912, 835, 13, 15690, 815, 307, 34142, 4306, 345, 481, 651, 8563, 13, 198, 198, 76, 22570, 22, 796, 1976, 27498, 44, 26933, 17, 11, 362, 12962, 198, 198, 76, 22570, 23, 796, 1976, 27498, 44, 7, 5317, 2624, 11, 685, 17, 11, 362, 12962, 198, 198, 76, 22570, 24, 796, 1976, 27498, 44, 26933, 17, 11, 362, 4357, 588, 796, 685, 17, 13, 20, 513, 13, 15, 12962, 198, 29113, 29113, 198, 47122, 15, 796, 3392, 44, 7, 25, 6759, 11, 362, 8, 1303, 976, 355, 3392, 7, 17, 11, 17, 8, 198, 198, 47122, 16, 796, 3392, 44, 7, 25, 6759, 11, 362, 11, 588, 796, 3392, 44, 7, 5317, 2624, 11, 362, 11, 362, 4008, 1303, 588, 2446, 198, 198, 32, 41888, 17, 352, 362, 60, 198, 47122, 17, 796, 3392, 44, 7, 17, 11, 588, 28, 32, 8, 1303, 976, 355, 3392, 7, 5317, 2414, 11, 17, 8, 198, 198, 47122, 18, 796, 3392, 44, 7, 17, 8, 1303, 976, 355, 3392, 7, 17, 8, 198, 198, 47122, 19, 796, 3392, 44, 7, 5317, 2624, 11, 362, 11, 362, 8, 1303, 976, 355, 3392, 7, 5317, 2624, 11, 17, 11, 17, 8, 198, 198, 2, 3501, 2546, 355, 309, 29291, 198, 47122, 20, 796, 3392, 44, 19510, 17, 11, 362, 4008, 1303, 796, 3392, 44, 7, 17, 11, 17, 8, 198, 198, 47122, 21, 796, 3392, 44, 7, 5317, 2624, 11, 357, 17, 11, 362, 4008, 198, 198, 2, 3501, 2546, 355, 281, 15690, 198, 2235, 1729, 12, 16814, 6550, 23912, 835, 13, 15690, 815, 307, 34142, 4306, 345, 481, 651, 8563, 13, 198, 198, 47122, 22, 796, 3392, 44, 26933, 17, 11, 362, 12962, 198, 198, 47122, 23, 796, 3392, 44, 7, 5317, 2624, 11, 685, 17, 11, 362, 12962, 198, 198, 47122, 24, 796, 3392, 44, 26933, 17, 11, 362, 4357, 588, 796, 685, 17, 13, 20, 513, 13, 15, 12962, 198, 29113, 29113, 198, 76, 25120, 15, 796, 43720, 44, 7, 25, 6759, 11, 362, 8, 1303, 976, 355, 43720, 7, 17, 11, 17, 8, 198, 198, 76, 25120, 16, 796, 43720, 44, 7, 25, 6759, 11, 362, 11, 588, 796, 43720, 44, 7, 5317, 2624, 11, 362, 11, 362, 4008, 1303, 588, 2446, 198, 198, 32, 41888, 17, 352, 362, 60, 198, 76, 25120, 17, 796, 43720, 44, 7, 17, 11, 588, 28, 32, 8, 1303, 976, 355, 43720, 7, 5317, 2414, 11, 17, 8, 198, 198, 76, 25120, 18, 796, 43720, 44, 7, 17, 8, 1303, 976, 355, 43720, 7, 17, 8, 198, 198, 76, 25120, 19, 796, 43720, 44, 7, 5317, 2624, 11, 362, 11, 362, 8, 1303, 976, 355, 43720, 7, 5317, 2624, 11, 17, 11, 17, 8, 198, 198, 2, 3501, 2546, 355, 309, 29291, 198, 76, 25120, 20, 796, 43720, 44, 19510, 17, 11, 362, 4008, 1303, 796, 43720, 44, 7, 17, 11, 17, 8, 198, 198, 76, 25120, 21, 796, 43720, 44, 7, 5317, 2624, 11, 357, 17, 11, 362, 4008, 198, 198, 2, 3501, 2546, 355, 281, 15690, 198, 2235, 1729, 12, 16814, 6550, 23912, 835, 13, 15690, 815, 307, 34142, 4306, 345, 481, 651, 8563, 13, 198, 198, 76, 25120, 22, 796, 43720, 44, 26933, 17, 11, 362, 12962, 198, 198, 76, 25120, 23, 796, 43720, 44, 7, 5317, 2624, 11, 685, 17, 11, 362, 12962, 198, 198, 76, 25120, 24, 796, 43720, 44, 26933, 17, 11, 362, 4357, 588, 796, 685, 17, 13, 20, 513, 13, 15, 12962, 198, 29113, 29113, 198, 76, 7942, 15, 796, 2081, 44, 7, 25, 6759, 11, 362, 8, 1303, 976, 355, 491, 947, 7, 17, 11, 17, 8, 198, 198, 76, 7942, 16, 796, 2081, 44, 7, 17, 8, 1303, 976, 355, 491, 947, 7, 17, 8, 198, 198, 2, 3501, 2546, 355, 309, 29291, 198, 76, 7942, 17, 796, 2081, 44, 19510, 17, 11, 362, 4008, 1303, 796, 491, 947, 7, 17, 11, 17, 8, 198, 198, 2, 3501, 2546, 355, 281, 15690, 198, 2235, 1729, 12, 16814, 6550, 23912, 835, 13, 15690, 815, 307, 34142, 4306, 345, 481, 651, 8563, 13, 198, 76, 7942, 18, 796, 2081, 44, 26933, 17, 11, 362, 12962, 198, 29113, 29113, 198, 76, 9562, 15, 796, 3991, 44, 7, 25, 6759, 11, 362, 8, 1303, 976, 355, 27807, 274, 7, 17, 11, 17, 8, 198, 198, 76, 9562, 16, 796, 3991, 44, 7, 17, 8, 1303, 976, 355, 27807, 274, 7, 17, 8, 198, 198, 2, 3501, 2546, 355, 309, 29291, 198, 76, 9562, 17, 796, 3991, 44, 19510, 17, 11, 362, 4008, 1303, 796, 27807, 274, 7, 17, 11, 17, 8, 198, 198, 2, 3501, 2546, 355, 281, 15690, 198, 2235, 1729, 12, 16814, 6550, 23912, 835, 13, 15690, 815, 307, 34142, 4306, 345, 481, 651, 8563, 13, 198, 76, 9562, 18, 796, 3991, 44, 26933, 17, 11, 362, 12962, 198, 29113, 29113, 198, 76, 24876, 15, 796, 4151, 44, 7, 17, 1776, 1303, 685, 16, 657, 657, 26, 657, 352, 657, 60, 198, 198, 76, 24876, 16, 796, 4151, 44, 7, 17, 11, 513, 1776, 1303, 685, 16, 657, 657, 26, 657, 352, 657, 60, 198, 198, 76, 24876, 17, 796, 4151, 44, 7, 5317, 2624, 11, 362, 11, 513, 1776, 1303, 685, 16, 657, 657, 26, 657, 352, 657, 60, 198, 198, 76, 24876, 18, 796, 4151, 44, 7, 17, 11, 513, 11, 588, 796, 1976, 27498, 44, 7, 5317, 23, 11, 362, 11, 362, 4008, 198, 198, 76, 24876, 19, 796, 4151, 44, 19510, 17, 11, 362, 4008, 220, 1303, 3501, 2546, 355, 257, 309, 29291, 13, 554, 22300, 356, 779, 357, 17, 11, 17, 8, 2427, 286, 3501, 340, 355, 685, 17, 11, 17, 60, 198, 198, 76, 24876, 20, 796, 4151, 44, 7, 5317, 2624, 11, 357, 17, 11, 362, 4008, 220, 1303, 3501, 2546, 355, 257, 309, 29291, 13, 554, 22300, 356, 779, 357, 17, 11, 17, 8, 2427, 286, 3501, 340, 355, 685, 17, 11, 17, 60, 198, 198, 76, 24876, 21, 796, 4151, 44, 26933, 17, 11, 362, 12962, 1303, 1729, 12, 16814, 6550, 23912, 835, 198, 198, 76, 24876, 22, 796, 4151, 44, 7, 5317, 2624, 11, 685, 17, 11, 362, 12962, 1303, 1729, 12, 16814, 6550, 23912, 835, 198, 198, 82, 16, 796, 2546, 7, 1952, 7, 17, 11, 513, 4008, 1303, 1972, 2546, 422, 1194, 17593, 393, 17952, 198, 76, 24876, 23, 796, 4151, 44, 7, 82, 16, 8, 220, 1303, 3501, 2546, 355, 257, 7885, 357, 51, 29291, 737, 198, 29113, 29113, 198, 76, 18683, 363, 796, 2566, 363, 44, 26933, 17, 11, 513, 11, 604, 12962, 1303, 685, 15, 362, 657, 2162, 657, 513, 657, 26, 657, 604, 60, 198, 198, 76, 18683, 363, 17, 796, 2566, 363, 44, 26933, 17, 11, 513, 11, 604, 4357, 352, 8, 1303, 685, 15, 362, 513, 657, 26, 657, 657, 513, 657, 26, 657, 657, 657, 604, 26, 657, 657, 657, 657, 60, 198, 198, 76, 18683, 363, 18, 796, 2566, 363, 44, 26933, 16, 362, 513, 26, 604, 642, 718, 26, 767, 807, 860, 12962, 1303, 685, 16, 26, 20, 26, 24, 60, 198, 198, 76, 18683, 363, 19, 796, 2566, 363, 44, 26933, 16, 362, 513, 26, 604, 642, 718, 26, 767, 807, 860, 4357, 352, 8, 1303, 685, 17, 26, 21, 60, 198, 29113, 29113, 198, 32, 16, 796, 513, 1635, 3392, 7, 17, 11, 362, 1776, 198, 32, 17, 796, 604, 1635, 3392, 7, 17, 11, 362, 1776, 198, 32, 18, 796, 43720, 7, 18, 11, 513, 1776, 198, 76, 3629, 74, 10989, 363, 16, 796, 698, 74, 10989, 363, 44, 7, 32, 16, 11, 317, 17, 11, 317, 18, 8, 198, 198, 76, 3629, 74, 10989, 363, 17, 796, 698, 74, 10989, 363, 44, 7, 1952, 7, 17, 11, 362, 828, 362, 1635, 3392, 7, 17, 11, 362, 4008, 1303, 685, 1952, 7, 17, 11, 362, 8, 1976, 27498, 7, 17, 11, 362, 1776, 1976, 27498, 7, 17, 11, 362, 8, 220, 362, 1635, 3392, 7, 17, 11, 362, 15437, 198, 198, 32, 16, 796, 3392, 7, 17, 11, 604, 1776, 198, 32, 17, 796, 362, 1635, 3392, 7, 18, 11, 362, 1776, 198, 76, 3629, 74, 10989, 363, 18, 796, 698, 74, 10989, 363, 44, 7, 32, 16, 11, 317, 17, 8, 1303, 685, 1952, 7, 17, 11, 19, 8, 1976, 27498, 7, 17, 11, 17, 1776, 1976, 27498, 7, 18, 11, 19, 8, 362, 9, 1952, 7, 18, 11, 17, 15437, 198, 198, 76, 3629, 74, 10989, 363, 16, 26801, 796, 698, 74, 10989, 363, 44, 7, 25, 26801, 11, 317, 16, 11, 317, 17, 11, 317, 18, 8, 1303, 8024, 9726, 18683, 27923, 2134, 198, 198, 76, 3629, 74, 10989, 363, 17, 26801, 796, 698, 74, 10989, 363, 44, 7, 25, 26801, 11, 3392, 7, 17, 11, 362, 828, 362, 1635, 3392, 7, 17, 11, 362, 4008, 1303, 8024, 9726, 18683, 27923, 2134, 329, 685, 1952, 7, 17, 11, 362, 8, 1976, 27498, 7, 17, 11, 362, 1776, 1976, 27498, 7, 17, 11, 362, 8, 220, 362, 1635, 3392, 7, 17, 11, 362, 15437, 198, 29113, 29113, 198, 76, 21979, 16, 796, 3797, 44, 7, 16, 11, 3392, 7, 18, 11, 513, 828, 1976, 27498, 7, 18, 11, 513, 4008, 1303, 685, 1952, 7, 18, 11, 513, 1776, 1976, 27498, 7, 18, 11, 513, 15437, 198, 198, 76, 21979, 17, 796, 3797, 44, 7, 17, 11, 3392, 7, 18, 11, 513, 828, 1976, 27498, 7, 18, 11, 513, 4008, 1303, 685, 1952, 7, 18, 11, 513, 8, 1976, 27498, 7, 18, 11, 513, 15437, 198, 198, 76, 21979, 18, 796, 3797, 44, 7, 16, 11, 3392, 7, 18, 11, 513, 828, 1976, 27498, 7, 18, 11, 513, 828, 362, 1635, 3392, 7, 18, 11, 513, 4008, 1303, 685, 1952, 7, 18, 11, 513, 1776, 1976, 27498, 7, 18, 11, 513, 1776, 362, 1635, 3392, 7, 18, 11, 513, 15437, 198, 198, 76, 21979, 19, 796, 3797, 44, 7, 18, 11, 3392, 7, 17, 11, 362, 11, 362, 828, 1976, 27498, 7, 17, 11, 362, 11, 362, 4008, 1303, 685, 1952, 7, 17, 11, 362, 11, 362, 8, 1976, 27498, 7, 17, 11, 362, 11, 362, 15437, 198, 29113, 29113, 198, 76, 16045, 265, 16, 796, 3076, 89, 9246, 44, 7, 1952, 7, 18, 11, 513, 828, 1976, 27498, 7, 18, 11, 513, 4008, 1303, 685, 1952, 7, 18, 11, 513, 8, 1976, 27498, 7, 18, 11, 513, 15437, 198, 29113, 29113, 198, 76, 15922, 265, 16, 796, 9421, 9246, 44, 7, 1952, 7, 18, 11, 513, 828, 1976, 27498, 7, 18, 11, 513, 4008, 1303, 685, 1952, 7, 18, 11, 513, 1776, 1976, 27498, 7, 18, 11, 513, 15437, 198, 29113, 29113, 198, 53, 16, 796, 685, 16, 362, 513, 604, 11208, 198, 76, 47541, 10671, 16, 796, 3172, 10671, 44, 7, 53, 16, 11, 513, 8, 1303, 685, 16, 352, 352, 362, 362, 362, 513, 513, 513, 604, 604, 604, 60, 198, 198, 2, 285, 47541, 10671, 17, 796, 3172, 10671, 44, 7, 53, 16, 11, 357, 18, 11, 17, 11, 16, 11, 16, 4008, 1303, 685, 16, 352, 352, 362, 362, 513, 604, 60, 198, 198, 2, 285, 47541, 10671, 18, 796, 3172, 10671, 44, 7, 53, 16, 11, 43030, 26933, 18, 362, 352, 352, 60, 4008, 1303, 685, 16, 352, 352, 362, 362, 513, 604, 60, 198, 29113, 29113, 198, 76, 8413, 8071, 16, 796, 1128, 6759, 44, 7, 940, 11, 513, 11, 362, 8, 1303, 685, 940, 838, 26, 838, 838, 26, 838, 838, 60, 198, 198, 53, 796, 685, 16, 26, 362, 60, 198, 76, 8413, 8071, 17, 796, 1128, 6759, 44, 7, 53, 11, 513, 11, 362, 8, 220, 220, 1303, 16410, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11907, 198, 198, 76, 8413, 8071, 18, 796, 1128, 6759, 44, 7, 53, 11, 685, 18, 11, 362, 12962, 1303, 16410, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11907, 198, 198, 76, 8413, 8071, 19, 796, 1128, 6759, 44, 7, 53, 11, 357, 18, 11, 362, 4008, 1303, 16410, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11907, 198, 198, 76, 8413, 8071, 20, 796, 1128, 6759, 44, 7, 53, 11, 362, 8, 1303, 16410, 16, 26, 362, 60, 685, 16, 26, 362, 11208, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11907, 198, 198, 76, 8413, 8071, 21, 796, 1128, 6759, 44, 7, 53, 11, 352, 11, 513, 8, 1303, 16410, 16, 26, 362, 60, 685, 16, 26, 362, 60, 685, 16, 26, 362, 11907, 198, 29113, 29113, 198, 32087, 1040, 10223, 16, 796, 300, 1040, 10223, 44, 7, 16, 11, 838, 8, 1303, 352, 25, 940, 198, 198, 32087, 1040, 10223, 17, 796, 300, 1040, 10223, 44, 7, 16, 11, 838, 11, 362, 8, 1303, 352, 25, 17, 25, 940, 6624, 352, 25, 17, 25, 24, 198, 198, 32087, 1040, 10223, 18, 796, 300, 1040, 10223, 44, 7, 25, 3258, 11, 352, 11, 838, 8, 1303, 2824, 7, 16, 25, 940, 8, 198, 198, 32087, 1040, 10223, 19, 796, 300, 1040, 10223, 44, 7, 25, 3258, 11, 352, 11, 838, 11, 362, 8, 1303, 2824, 7, 16, 25, 17, 25, 940, 8, 198, 29113, 29113, 198, 76, 11187, 13200, 16, 796, 2604, 13200, 44, 7, 16, 11, 642, 8, 1303, 2026, 2604, 283, 342, 76, 1146, 38980, 2173, 1022, 838, 61, 16, 290, 838, 61, 20, 198, 198, 76, 11187, 13200, 17, 796, 2604, 13200, 44, 7, 16, 11, 642, 11, 838, 8, 1303, 838, 2604, 283, 342, 76, 1146, 38980, 2173, 1022, 838, 61, 16, 290, 838, 61, 20, 198, 198, 76, 11187, 13200, 18, 796, 2604, 13200, 44, 7, 16, 11, 642, 11, 1058, 40496, 8, 1303, 685, 940, 13, 15, 61, 16, 11, 838, 13, 15, 61, 17, 11, 838, 13, 15, 61, 18, 11, 838, 13, 15, 61, 19, 11, 838, 13, 15, 61, 20, 60, 6624, 838, 13, 15, 13, 61, 7, 16, 25, 20, 8, 198, 29113, 29113, 198, 76, 16, 37031, 25928, 15, 11, 285, 17, 37031, 25928, 15, 796, 19609, 25928, 44, 7, 16, 25, 17, 25, 20, 8, 1303, 257, 362, 12, 35, 35991, 32557, 352, 25, 17, 25, 20, 287, 2124, 290, 331, 4571, 6624, 16410, 16, 26, 16, 26, 16, 7131, 18, 26, 18, 26, 18, 60, 685, 20, 26, 20, 26, 20, 11907, 290, 685, 16, 352, 352, 26, 513, 513, 513, 26, 642, 642, 642, 60, 198, 198, 76, 16, 37031, 25928, 16, 11, 285, 17, 37031, 25928, 16, 796, 19609, 25928, 44, 7, 16, 25, 17, 25, 20, 11, 352, 25, 17, 25, 20, 8, 1303, 220, 257, 362, 12, 35, 35991, 32557, 352, 25, 17, 25, 20, 287, 2124, 290, 331, 4571, 6624, 29565, 16, 513, 642, 26, 16, 513, 642, 26, 352, 513, 642, 38430, 16, 352, 352, 26, 513, 513, 513, 26, 642, 642, 642, 12962, 198, 198, 76, 16, 37031, 25928, 17, 11, 285, 17, 37031, 25928, 17, 11, 285, 18, 37031, 25928, 17, 796, 19609, 25928, 44, 7, 16, 25, 21, 11, 1160, 25, 1495, 11, 642, 25, 940, 8, 1303, 257, 513, 12, 35, 35991, 32557, 352, 25, 21, 287, 2124, 11, 1160, 25, 1495, 287, 331, 11, 290, 642, 25, 940, 287, 1976, 198, 29113, 29113, 198, 76, 16, 45, 67, 25928, 15, 11, 285, 17, 45, 67, 25928, 15, 796, 299, 67, 25928, 44, 7, 16, 25, 17, 25, 20, 11, 5391, 796, 362, 8, 1303, 257, 362, 12, 35, 35991, 32557, 352, 25, 17, 25, 20, 287, 2124, 290, 331, 4571, 6624, 685, 16, 352, 352, 26, 513, 513, 513, 26, 642, 642, 642, 60, 290, 685, 16, 513, 642, 26, 16, 513, 642, 26, 352, 513, 642, 60, 198, 198, 76, 16, 45, 67, 25928, 16, 11, 285, 17, 45, 67, 25928, 16, 796, 299, 67, 25928, 44, 7, 16, 25, 17, 25, 20, 11, 352, 25, 17, 25, 20, 8, 1303, 220, 257, 362, 12, 35, 35991, 32557, 352, 25, 17, 25, 20, 287, 2124, 290, 331, 4571, 6624, 29565, 16, 352, 352, 26, 513, 513, 513, 26, 642, 642, 642, 4357, 685, 16, 513, 642, 26, 16, 513, 642, 26, 352, 513, 642, 12962, 198, 198, 76, 16, 45, 67, 25928, 17, 11, 285, 17, 45, 67, 25928, 17, 11, 285, 18, 45, 67, 25928, 17, 796, 299, 67, 25928, 44, 7, 16, 25, 21, 11, 1160, 25, 1495, 11, 642, 25, 940, 8, 1303, 257, 513, 12, 35, 35991, 32557, 352, 25, 21, 287, 2124, 11, 1160, 25, 1495, 287, 331, 11, 290, 642, 25, 940, 287, 1976, 198, 29113, 29113, 198, 76, 20366, 80, 13200, 16, 796, 2030, 80, 13200, 44, 7, 940, 11, 5391, 796, 352, 8, 1303, 657, 25, 15, 13, 17, 25, 16, 198, 198, 76, 20366, 80, 13200, 17, 796, 2030, 80, 13200, 44, 7, 940, 11, 1058, 1929, 2305, 11, 5391, 796, 352, 8, 1303, 657, 25, 15, 13, 17, 25, 16, 13, 23, 198, 198, 76, 16, 20366, 80, 13200, 18, 11, 285, 17, 20366, 80, 13200, 18, 796, 2030, 80, 13200, 44, 7, 940, 11, 5391, 796, 362, 8, 1303, 5860, 734, 532, 16, 25, 15, 13, 17, 25, 15, 13, 23, 198, 198, 76, 16, 20366, 80, 13200, 19, 11, 285, 17, 20366, 80, 13200, 19, 796, 2030, 80, 13200, 44, 7, 940, 11, 1058, 76, 5069, 25928, 11, 5391, 796, 362, 8, 1303, 5860, 18842, 25928, 44, 32590, 16, 25, 15, 13, 17, 25, 15, 13, 23, 11, 532, 16, 25, 15, 13, 17, 25, 15, 13, 23, 828, 543, 318, 734, 532, 16, 25, 15, 13, 17, 25, 15, 13, 23, 198, 29113, 29113, 198, 32, 16, 796, 685, 17, 513, 604, 642, 718, 767, 26, 198, 220, 220, 220, 220, 220, 352, 362, 513, 604, 642, 718, 60, 198, 77, 24539, 16, 796, 4129, 44, 7, 32, 16, 1776, 1303, 718, 198, 198, 32, 17, 796, 14631, 17250, 1, 718, 26, 198, 220, 220, 220, 220, 220, 366, 10248, 16390, 1, 642, 26, 198, 220, 220, 220, 220, 220, 366, 15496, 1, 352, 60, 198, 77, 24539, 17, 796, 4129, 44, 7, 32, 17, 1776, 1303, 513, 198, 29113, 29113, 198, 32, 16, 796, 685, 17, 513, 604, 642, 718, 767, 26, 198, 220, 220, 220, 220, 220, 352, 362, 513, 604, 642, 718, 60, 198, 76, 10699, 16, 796, 2546, 44, 7, 25, 3258, 11, 317, 16, 1776, 1303, 685, 17, 26, 718, 60, 198, 83, 10699, 16, 796, 2546, 44, 7, 32, 16, 1776, 1303, 357, 17, 11, 718, 8, 198, 198, 77, 32, 16, 10699, 17, 796, 2546, 44, 7, 32, 16, 11, 362, 1776, 1303, 718, 198, 7857, 44, 7, 32, 16, 11, 362, 8, 6624, 718, 1303, 2081, 198, 7857, 44, 7, 25, 3258, 11, 317, 16, 11, 362, 8, 6624, 718, 1303, 3991, 198, 7857, 44, 7, 25, 3258, 11, 317, 16, 11, 362, 8, 6624, 685, 21, 60, 1303, 2081, 198, 198, 77, 32, 16, 10699, 16, 11, 299, 32, 16, 10699, 17, 796, 2546, 44, 7, 32, 16, 1776, 1303, 362, 290, 718, 198, 198, 32, 17, 796, 43720, 7, 18, 11, 642, 11, 604, 8, 198, 76, 10699, 17, 796, 2546, 44, 7, 25, 3258, 11, 317, 17, 11, 362, 11, 513, 1776, 1303, 685, 20, 26, 604, 60, 198, 83, 10699, 17, 796, 2546, 44, 7, 32, 17, 11, 362, 11, 513, 1776, 1303, 357, 20, 11, 604, 8, 198, 29113, 29113, 198, 32, 796, 43720, 7, 18, 11, 19, 11, 20, 1776, 198, 77, 29271, 16, 796, 299, 67, 12078, 7, 32, 8, 1303, 513, 198, 29113, 29113, 198, 77, 33111, 417, 16, 796, 997, 417, 44, 7, 16, 25, 20, 8, 1303, 642, 198, 198, 77, 33111, 417, 17, 796, 997, 417, 44, 26933, 16, 11, 362, 11, 513, 11, 604, 12962, 1303, 604, 198, 198, 77, 33111, 417, 18, 796, 997, 417, 44, 26933, 16, 362, 26, 513, 604, 12962, 1303, 604, 198, 29113, 29113, 198, 65, 27738, 9948, 283, 16, 796, 1189, 9948, 283, 44, 7, 16, 8, 1303, 2081, 198, 198, 65, 27738, 9948, 283, 17, 796, 1189, 9948, 283, 44, 7, 20, 1635, 3392, 7, 16, 11, 352, 11, 352, 4008, 1303, 3991, 198, 198, 2, 275, 27738, 9948, 283, 18, 796, 1189, 9948, 283, 44, 7203, 39, 4943, 1303, 3607, 4049, 198, 2, 198, 2, 275, 27738, 9948, 283, 19, 796, 1189, 9948, 283, 44, 7203, 17250, 4943, 1303, 3607, 4049, 198, 198, 65, 27738, 9948, 283, 20, 796, 1189, 9948, 283, 44, 7, 14692, 17250, 8973, 8, 1303, 3991, 198, 198, 65, 27738, 9948, 283, 21, 796, 1189, 9948, 283, 44, 7, 14692, 17250, 1, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 65, 27738, 9948, 283, 22, 796, 1189, 9948, 283, 44, 10786, 39, 11537, 1303, 2081, 1303, 639, 533, 913, 326, 287, 22300, 11, 34534, 389, 1464, 18032, 13, 198, 198, 65, 27738, 9948, 283, 23, 796, 1189, 9948, 283, 44, 7, 7942, 8, 1303, 2081, 198, 198, 2, 6550, 23912, 835, 25, 198, 65, 27738, 9948, 283, 19044, 16, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 352, 8, 1303, 2081, 198, 198, 65, 27738, 9948, 283, 19044, 17, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 685, 16, 12962, 1303, 2081, 198, 198, 65, 27738, 9948, 283, 19044, 18, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 642, 1635, 3392, 7, 16, 11, 352, 11, 352, 4008, 1303, 2081, 198, 198, 65, 27738, 9948, 283, 19044, 19, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 366, 39, 4943, 1303, 2081, 198, 198, 65, 27738, 9948, 283, 19044, 20, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 366, 17250, 4943, 1303, 3991, 198, 198, 65, 27738, 9948, 283, 19044, 21, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 14631, 17250, 8973, 8, 1303, 2081, 198, 198, 65, 27738, 9948, 283, 19044, 22, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 14631, 17250, 1, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 65, 27738, 9948, 283, 19044, 23, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 705, 39, 11537, 1303, 2081, 1303, 639, 533, 913, 326, 287, 22300, 11, 34534, 389, 1464, 18032, 13, 198, 198, 65, 27738, 9948, 283, 19044, 24, 796, 1189, 9948, 283, 44, 7, 25, 6759, 11, 2081, 8, 1303, 2081, 198, 29113, 29113, 198, 32, 16, 796, 685, 16, 26, 362, 26, 513, 60, 1303, 393, 685, 16, 11, 362, 11, 513, 60, 198, 65, 3792, 31364, 16, 796, 318, 31364, 44, 7, 32, 16, 8, 1303, 2081, 198, 198, 32, 17, 796, 685, 16, 362, 513, 60, 198, 65, 3792, 31364, 17, 796, 318, 31364, 44, 7, 32, 17, 8, 1303, 3991, 198, 198, 65, 3792, 31364, 18, 796, 318, 31364, 44, 7, 1952, 7, 18, 11, 352, 4008, 1303, 3991, 198, 198, 65, 3792, 31364, 19, 796, 318, 31364, 44, 7, 1952, 7, 16, 11, 513, 4008, 1303, 3991, 198, 198, 65, 3792, 31364, 20, 796, 318, 31364, 44, 7, 1952, 7, 18, 4008, 1303, 2081, 198, 198, 65, 3792, 31364, 21, 796, 318, 31364, 44, 7, 16, 8, 1303, 3991, 198, 198, 65, 3792, 31364, 22, 796, 318, 31364, 44, 7203, 17250, 4943, 1303, 3991, 198, 198, 65, 3792, 31364, 23, 796, 318, 31364, 44, 7, 14692, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 2081, 198, 198, 65, 3792, 46912, 24, 796, 318, 31364, 44, 7, 14692, 17250, 1, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 2, 6550, 23912, 6378, 25, 198, 65, 3792, 31364, 19044, 16, 796, 318, 31364, 44, 7, 25, 6759, 11, 317, 16, 8, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 17, 796, 318, 31364, 44, 7, 25, 6759, 11, 317, 17, 8, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 18, 796, 318, 31364, 44, 7, 25, 6759, 11, 3392, 7, 18, 11, 352, 4008, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 19, 796, 318, 31364, 44, 7, 25, 6759, 11, 3392, 7, 16, 11, 513, 4008, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 20, 796, 318, 31364, 44, 7, 25, 6759, 11, 3392, 7, 18, 4008, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 21, 796, 318, 31364, 44, 7, 25, 6759, 11, 352, 8, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 22, 796, 318, 31364, 44, 7, 25, 6759, 11, 366, 17250, 4943, 1303, 2081, 198, 198, 65, 3792, 31364, 19044, 23, 796, 318, 31364, 44, 7, 25, 6759, 11, 14631, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 2081, 198, 29113, 29113, 198, 32, 16, 796, 685, 16, 362, 513, 26, 513, 642, 718, 60, 198, 65, 3792, 46912, 16, 796, 318, 6759, 8609, 44, 7, 32, 16, 8, 1303, 2081, 198, 198, 32, 17, 796, 685, 16, 26, 17, 26, 18, 60, 1303, 393, 685, 16, 11, 17, 11, 18, 60, 198, 65, 3792, 46912, 17, 796, 318, 6759, 8609, 44, 7, 32, 17, 8, 1303, 3991, 198, 198, 65, 3792, 46912, 18, 796, 318, 6759, 8609, 44, 7, 1952, 7, 18, 11, 352, 4008, 1303, 2081, 198, 198, 65, 3792, 46912, 19, 796, 318, 6759, 8609, 44, 7, 1952, 7, 16, 11, 513, 4008, 1303, 2081, 198, 198, 65, 3792, 46912, 20, 796, 318, 6759, 8609, 44, 7, 1952, 7, 18, 4008, 1303, 3991, 198, 198, 65, 3792, 46912, 21, 796, 318, 6759, 8609, 44, 7203, 17250, 4943, 1303, 3991, 198, 198, 65, 3792, 46912, 22, 796, 318, 6759, 8609, 44, 7, 14692, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 65, 3792, 46912, 23, 796, 318, 6759, 8609, 44, 7, 14692, 17250, 1, 366, 3886, 68, 8973, 8, 1303, 2081, 198, 198, 2, 6550, 23912, 6378, 25, 198, 198, 65, 3792, 46912, 19044, 16, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 317, 16, 8, 1303, 2081, 198, 198, 65, 3792, 46912, 19044, 17, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 317, 17, 8, 1303, 2081, 198, 198, 65, 3792, 46912, 19044, 18, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 3392, 7, 18, 11, 352, 4008, 1303, 2081, 198, 198, 65, 3792, 46912, 19044, 19, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 3392, 7, 16, 11, 513, 4008, 1303, 2081, 198, 198, 65, 3792, 46912, 19044, 20, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 3392, 7, 18, 4008, 1303, 2081, 198, 198, 65, 3792, 46912, 19044, 21, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 366, 17250, 4943, 1303, 2081, 198, 198, 65, 3792, 46912, 19044, 22, 796, 318, 6759, 8609, 44, 7, 25, 6759, 11, 14631, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 2081, 198, 29113, 29113, 198, 32, 16, 796, 685, 16, 26, 362, 26, 513, 60, 1303, 393, 685, 16, 11, 362, 11, 513, 60, 198, 65, 3792, 808, 16, 796, 318, 808, 44, 7, 32, 16, 8, 1303, 3991, 198, 198, 32, 17, 796, 685, 16, 362, 513, 60, 198, 65, 3792, 808, 17, 796, 318, 808, 44, 7, 32, 17, 8, 1303, 2081, 198, 198, 65, 3792, 808, 18, 796, 318, 808, 44, 7, 1952, 7, 18, 11, 352, 4008, 1303, 3991, 198, 198, 65, 3792, 808, 19, 796, 318, 808, 44, 7, 1952, 7, 16, 11, 513, 4008, 1303, 2081, 198, 198, 65, 3792, 808, 20, 796, 318, 808, 44, 7, 1952, 7, 18, 4008, 1303, 3991, 198, 198, 65, 3792, 808, 21, 796, 318, 808, 44, 7, 16, 8, 1303, 3991, 198, 198, 65, 3792, 808, 22, 796, 318, 808, 44, 7203, 17250, 4943, 1303, 3991, 198, 198, 65, 3792, 808, 23, 796, 318, 808, 44, 7, 14692, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 65, 3792, 808, 24, 796, 318, 808, 44, 7, 14692, 17250, 1, 366, 3886, 68, 8973, 8, 1303, 2081, 198, 198, 2, 6550, 23912, 6378, 25, 198, 65, 3792, 808, 19044, 16, 796, 318, 808, 44, 7, 25, 6759, 11, 317, 16, 8, 1303, 3991, 198, 198, 65, 3792, 808, 19044, 17, 796, 318, 808, 44, 7, 25, 6759, 11, 317, 17, 8, 1303, 2081, 198, 198, 65, 3792, 808, 19044, 18, 796, 318, 808, 44, 7, 25, 6759, 11, 3392, 7, 18, 11, 352, 4008, 1303, 3991, 198, 198, 65, 3792, 808, 19044, 19, 796, 318, 808, 44, 7, 25, 6759, 11, 3392, 7, 16, 11, 513, 4008, 1303, 2081, 198, 198, 65, 3792, 808, 19044, 20, 796, 318, 808, 44, 7, 25, 6759, 11, 3392, 7, 18, 4008, 1303, 3991, 198, 198, 65, 3792, 808, 19044, 21, 796, 318, 808, 44, 7, 25, 6759, 11, 352, 8, 1303, 2081, 198, 198, 65, 3792, 808, 19044, 22, 796, 318, 808, 44, 7, 25, 6759, 11, 366, 17250, 4943, 1303, 2081, 198, 198, 65, 3792, 808, 19044, 23, 796, 318, 808, 44, 7, 25, 6759, 11, 14631, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 29113, 29113, 198, 32, 16, 796, 685, 16, 26, 362, 26, 513, 60, 1303, 393, 685, 16, 11, 362, 11, 513, 60, 198, 65, 40, 1416, 349, 4182, 16, 796, 318, 28665, 44, 7, 32, 16, 8, 1303, 3991, 198, 198, 32, 17, 796, 685, 16, 362, 513, 60, 198, 65, 40, 1416, 349, 4182, 17, 796, 318, 28665, 44, 7, 32, 17, 8, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 18, 796, 318, 28665, 44, 7, 1952, 7, 18, 11, 352, 4008, 1303, 256, 518, 198, 198, 65, 40, 1416, 349, 4182, 19, 796, 318, 28665, 44, 7, 1952, 7, 16, 11, 513, 4008, 1303, 9562, 198, 198, 65, 40, 1416, 349, 4182, 20, 796, 318, 28665, 44, 7, 1952, 7, 18, 4008, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 21, 796, 318, 28665, 44, 7, 16, 8, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 22, 796, 318, 28665, 44, 7203, 17250, 4943, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 23, 796, 318, 28665, 44, 7, 14692, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 24, 796, 318, 28665, 44, 7, 14692, 17250, 1, 366, 3886, 68, 8973, 8, 1303, 3991, 198, 198, 2, 6550, 23912, 6378, 25, 198, 65, 40, 1416, 349, 4182, 19044, 16, 796, 318, 28665, 44, 7, 25, 6759, 11, 317, 16, 8, 1303, 2081, 198, 198, 65, 40, 1416, 349, 4182, 19044, 17, 796, 318, 28665, 44, 7, 25, 6759, 11, 317, 17, 8, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 19044, 18, 796, 318, 28665, 44, 7, 25, 6759, 11, 3392, 7, 18, 11, 352, 4008, 1303, 2081, 198, 198, 65, 40, 1416, 349, 4182, 19044, 19, 796, 318, 28665, 44, 7, 25, 6759, 11, 3392, 7, 16, 11, 513, 4008, 1303, 3991, 198, 198, 65, 40, 1416, 349, 4182, 19044, 20, 796, 318, 28665, 44, 7, 25, 6759, 11, 3392, 7, 18, 4008, 1303, 2081, 198, 198, 65, 40, 1416, 349, 4182, 19044, 21, 796, 318, 28665, 44, 7, 25, 6759, 11, 352, 8, 1303, 2081, 198, 198, 65, 40, 1416, 349, 4182, 19044, 22, 796, 318, 28665, 44, 7, 25, 6759, 11, 366, 17250, 4943, 1303, 2081, 198, 198, 65, 40, 1416, 349, 4182, 19044, 23, 796, 318, 28665, 44, 7, 25, 6759, 11, 14631, 17250, 1600, 366, 3886, 68, 8973, 8, 1303, 2081, 198, 29113, 29113, 198, 76, 42758, 15, 796, 3297, 44, 26933, 20, 11, 513, 11, 678, 11, 1160, 11, 352, 11, 604, 12962, 1303, 685, 16, 11, 513, 11, 604, 11, 642, 11, 678, 11, 1160, 60, 198, 198, 32, 796, 685, 20, 11, 513, 11, 678, 11, 1160, 11, 352, 11, 604, 60, 198, 76, 42758, 16, 11, 1312, 42758, 16, 796, 3297, 44, 7, 32, 11, 314, 796, 2081, 8, 220, 1303, 8024, 3297, 6376, 198, 32, 58, 72, 42758, 16, 60, 6624, 285, 42758, 16, 198, 198, 76, 42758, 17, 796, 3297, 44, 26933, 20, 11, 513, 11, 678, 11, 1160, 11, 352, 11, 604, 4357, 1058, 20147, 437, 8, 1303, 685, 1238, 11, 1129, 11, 20, 11, 19, 11, 18, 11, 16, 60, 198, 198, 76, 42758, 18, 796, 3297, 44, 26933, 16, 642, 513, 26, 604, 352, 838, 12962, 1303, 685, 16, 352, 513, 26, 604, 642, 838, 60, 198, 198, 76, 42758, 19, 796, 3297, 44, 26933, 16, 642, 513, 26, 604, 352, 838, 4357, 362, 11, 1058, 3372, 437, 8, 1303, 685, 16, 513, 642, 26, 352, 604, 838, 60, 198, 198, 33, 796, 685, 16, 642, 513, 26, 604, 352, 838, 60, 198, 76, 42758, 20, 11, 1312, 42758, 20, 796, 3297, 44, 7, 33, 11, 362, 11, 1058, 3372, 437, 11, 314, 796, 2081, 8, 1303, 685, 16, 513, 642, 26, 352, 604, 838, 60, 198, 33, 58, 72, 42758, 20, 60, 6624, 285, 42758, 20, 198, 198, 32, 796, 1976, 27498, 44, 7, 46541, 11, 362, 11, 362, 11, 362, 8, 198, 32, 58, 45299, 1058, 11, 352, 60, 796, 685, 17, 513, 26, 352, 718, 60, 198, 32, 58, 45299, 1058, 11, 362, 60, 796, 25915, 16, 860, 26, 657, 1105, 60, 198, 76, 42758, 21, 796, 3297, 44, 7, 32, 11, 513, 8, 1303, 513, 35, 3297, 198, 29113, 29113, 198, 82, 7414, 541, 16, 796, 14283, 44, 7203, 17250, 4943, 1303, 366, 72, 39, 1, 198, 198, 76, 7414, 541, 17, 796, 14283, 44, 26933, 16, 26, 362, 26, 513, 26, 604, 12962, 1303, 58, 19, 26, 18, 26, 17, 26, 16, 60, 198, 198, 76, 7414, 541, 18, 796, 14283, 44, 26933, 16, 362, 26, 513, 604, 12962, 1303, 45971, 790, 5721, 25, 1303, 685, 18, 604, 26, 352, 362, 60, 198, 198, 76, 7414, 541, 19, 796, 14283, 44, 26933, 16, 362, 26, 513, 604, 4357, 362, 8, 1303, 14283, 1863, 5391, 82, 362, 25, 1303, 58, 17, 352, 26, 604, 513, 60, 198, 29113, 29113, 198, 76, 24864, 16, 796, 5724, 3829, 44, 26933, 16, 362, 26, 513, 604, 12962, 1303, 58, 17, 604, 26, 352, 513, 60, 198, 198, 76, 24864, 17, 796, 5724, 3829, 44, 26933, 16, 362, 26, 513, 604, 4357, 513, 8, 1303, 685, 18, 352, 26, 604, 362, 60, 198, 29113, 29113, 198, 32, 16, 796, 685, 17, 513, 604, 642, 718, 767, 26, 198, 220, 220, 220, 220, 220, 352, 362, 513, 604, 642, 718, 60, 198, 76, 8291, 3455, 16, 796, 1007, 3455, 44, 7, 32, 16, 8, 198, 198, 76, 8291, 3455, 17, 796, 1007, 3455, 44, 7, 25, 3258, 11, 317, 16, 8, 198, 29113, 29113, 198, 32, 16, 796, 3392, 7, 17, 11, 352, 11, 362, 1776, 1303, 513, 38517, 198, 76, 22266, 1453, 2736, 16, 796, 21229, 44, 7, 32, 16, 8, 1303, 685, 16, 352, 26, 352, 352, 60, 198, 198, 32, 17, 796, 1976, 27498, 7, 16, 11, 604, 11, 352, 1776, 198, 32, 17, 58, 45299, 352, 25, 19, 11, 2361, 796, 685, 20, 26, 513, 26, 718, 26, 657, 60, 198, 76, 22266, 1453, 2736, 17, 796, 21229, 44, 7, 32, 17, 8, 1303, 1649, 340, 3011, 530, 38517, 11, 340, 318, 11723, 13, 198, 198, 76, 22266, 1453, 2736, 17, 6624, 685, 20, 26, 513, 26, 718, 26, 657, 60, 1303, 2081, 198, 76, 22266, 1453, 2736, 17, 6624, 685, 20, 513, 718, 657, 60, 1303, 3991, 198, 29113, 29113, 198 ]
2.345561
6,297
""" equal_windows(N,window) Create interval sequence given a length `N` and window `window`. The last window chunk is not returned if leftover is less than `window`. """ function equal_windows(N::Int,window::Int) leftover = mod(N,window) 1:window:N-leftover end """ bootstrap_window(f,tokens,window) Calculate `f` on `window`-size chunks of `tokens`. """ function bootstrap_window(f::Function,tokens::Vector{T},window=1000) where T N = length(tokens) Float64[f(tokens[start:start+window-1]) for start in equal_windows(N,window)] end """ bootstrap_ci(xs) Calculates a 95% confidence interval given bootstrap sequence `xs`. """ bootstrap_ci(xs) = 1.96*std(xs)/sqrt(length(xs)) """ sttr(tokens,window) Calculate the Standardized Type-Token Ratio on `tokens` given `window` size. """ sttr(tokens,window) = mean(bootstrap_window(ttr,tokens,window))
[ 37811, 198, 220, 220, 220, 4961, 62, 28457, 7, 45, 11, 17497, 8, 198, 198, 16447, 16654, 8379, 1813, 257, 4129, 4600, 45, 63, 290, 4324, 4600, 17497, 44646, 198, 198, 464, 938, 4324, 16058, 318, 407, 4504, 611, 39191, 318, 1342, 621, 4600, 17497, 44646, 198, 37811, 198, 8818, 4961, 62, 28457, 7, 45, 3712, 5317, 11, 17497, 3712, 5317, 8, 198, 220, 220, 220, 39191, 796, 953, 7, 45, 11, 17497, 8, 198, 220, 220, 220, 352, 25, 17497, 25, 45, 12, 9464, 2502, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 6297, 26418, 62, 17497, 7, 69, 11, 83, 482, 641, 11, 17497, 8, 198, 198, 9771, 3129, 378, 4600, 69, 63, 319, 4600, 17497, 63, 12, 7857, 22716, 286, 4600, 83, 482, 641, 44646, 198, 37811, 198, 8818, 6297, 26418, 62, 17497, 7, 69, 3712, 22203, 11, 83, 482, 641, 3712, 38469, 90, 51, 5512, 17497, 28, 12825, 8, 810, 309, 198, 220, 220, 220, 399, 796, 4129, 7, 83, 482, 641, 8, 198, 220, 220, 220, 48436, 2414, 58, 69, 7, 83, 482, 641, 58, 9688, 25, 9688, 10, 17497, 12, 16, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 923, 287, 4961, 62, 28457, 7, 45, 11, 17497, 15437, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 6297, 26418, 62, 979, 7, 34223, 8, 198, 198, 9771, 3129, 689, 257, 6957, 4, 6628, 16654, 1813, 6297, 26418, 8379, 4600, 34223, 44646, 198, 37811, 198, 18769, 26418, 62, 979, 7, 34223, 8, 796, 352, 13, 4846, 9, 19282, 7, 34223, 20679, 31166, 17034, 7, 13664, 7, 34223, 4008, 198, 198, 37811, 198, 220, 220, 220, 336, 2213, 7, 83, 482, 641, 11, 17497, 8, 198, 198, 9771, 3129, 378, 262, 8997, 1143, 5994, 12, 30642, 33956, 319, 4600, 83, 482, 641, 63, 1813, 4600, 17497, 63, 2546, 13, 198, 37811, 198, 301, 2213, 7, 83, 482, 641, 11, 17497, 8, 796, 1612, 7, 18769, 26418, 62, 17497, 7, 926, 81, 11, 83, 482, 641, 11, 17497, 4008, 198 ]
2.627566
341
function tcm_predictMNL(N, u, assortments) M = size(assortments,1) v = zeros(Float64,size(assortments)) for m = 1 : M v[m,N] = 1.0 for p = 1 : N-1 v[m,p] = exp(u[p]) * assortments[m,p] end v[m,:] = v[m,:] / sum(v[m,:]) end return v end
[ 8818, 256, 11215, 62, 79, 17407, 44, 32572, 7, 45, 11, 334, 11, 840, 419, 902, 8, 198, 197, 44, 796, 2546, 7, 562, 419, 902, 11, 16, 8, 628, 197, 85, 796, 1976, 27498, 7, 43879, 2414, 11, 7857, 7, 562, 419, 902, 4008, 628, 220, 220, 220, 329, 285, 796, 352, 1058, 337, 198, 220, 220, 220, 220, 220, 220, 220, 410, 58, 76, 11, 45, 60, 796, 352, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 329, 279, 796, 352, 1058, 399, 12, 16, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 410, 58, 76, 11, 79, 60, 796, 1033, 7, 84, 58, 79, 12962, 1635, 840, 419, 902, 58, 76, 11, 79, 60, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 410, 58, 76, 11, 47715, 796, 410, 58, 76, 11, 47715, 1220, 2160, 7, 85, 58, 76, 11, 25, 12962, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1441, 410, 198, 437 ]
1.710983
173
<reponame>queryverse/DataValues.jl<filename>test/array/test_primitives.jl<gh_stars>1-10 using Test using DataValues @testset "DataValueArray: Primitives" begin n = rand(1:5) siz = [ rand(2:5) for i in n ] A = rand(siz...) M = rand(Bool, siz...) X = DataValueArray(A, M) i = rand(1:length(X)) @test values(X, i) == X.values[i] @test isna(X, i) == X.isna[i] I = [ rand(1:size(X, i)) for i in 1:n ] @test values(X, I...) == X.values[I...] @test isna(X, I...) == X.isna[I...] # ----- test Base.similar, Base.size ----------------------------------------# x = DataValueArray{Int}((5, 2)) @test isa(x, DataValueMatrix{Int}) @test size(x) === (5, 2) y = similar(x, DataValue{Int}, (3, 3)) @test isa(y, DataValueMatrix{Int}) @test size(y) === (3, 3) z = similar(x, DataValue{Int}, (2,)) @test isa(z, DataValueVector{Int}) @test size(z) === (2,) # test common use-patterns for 'similar' dv = DataValueArray{Int}(2) dm = DataValueArray{Int}(2, 2) dt = DataValueArray{Int}(2, 2, 2) similar(dv) similar(dm) similar(dt) similar(dv, 2) similar(dm, 2, 2) similar(dt, 2, 2, 2) # ----- test Base.copy/Base.copy! --------------------------------------------# # copy x = DataValueArray([1, 2, NA]) y = DataValueArray([3, NA, 5]) @test isequal(copy(x), x) @test isequal(copyto!(y, x), x) # copy! function nonbits(dv) ret = similar(dv, DataValue{Integer}) for ii = 1:length(dv) if !dv.isna[ii] ret[ii] = dv[ii] end end ret end set1 = Any[DataValueArray([1, NA, 3]), DataValueArray([NA, 5]), DataValueArray([1, 2, 3, 4, 5]), DataValueArray(Int[]), DataValueArray([NA, 5, 3]), DataValueArray([1, 5, 3])] set2 = map(nonbits, set1) for (dest, src, bigsrc, emptysrc, res1, res2) in Any[set1, set2] @test isequal(copyto!(copy(dest), src), res1) @test isequal(copyto!(copy(dest), 1, src), res1) @test isequal(copyto!(copy(dest), 2, src, 2), res2) @test isequal(copyto!(copy(dest), 2, src, 2, 1), res2) @test isequal(copyto!(copy(dest), 99, src, 99, 0), dest) @test isequal(copyto!(copy(dest), 1, emptysrc), dest) @test_throws BoundsError copyto!(dest, 1, emptysrc, 1) for idx in [0, 4] @test_throws BoundsError copyto!(dest, idx, src) @test_throws BoundsError copyto!(dest, idx, src, 1) @test_throws BoundsError copyto!(dest, idx, src, 1, 1) @test_throws BoundsError copyto!(dest, 1, src, idx) @test_throws BoundsError copyto!(dest, 1, src, idx, 1) end @test_throws ArgumentError copyto!(dest, 1, src, 1, -1) @test_throws BoundsError copyto!(dest, bigsrc) @test_throws BoundsError copyto!(dest, 3, src) @test_throws BoundsError copyto!(dest, 3, src, 1) @test_throws BoundsError copyto!(dest, 3, src, 1, 2) @test_throws BoundsError copyto!(dest, 1, src, 2, 2) end # ----- test Base.fill! ------------------------------------------------------# X = DataValueArray{Int}(10, 2) fill!(X, DataValue(10)) Y = DataValueArray{Float64}(10) fill!(Y, rand(Float64)) @test X.values == fill(10, 10, 2) @test isequal(X.isna, fill(false, 10, 2)) @test isequal(Y.isna, fill(false, 10)) fill!(X, DataValue()) @test isequal(X.isna, fill(true, 10, 2)) # ----- test Base.deepcopy ---------------------------------------------------# Y1 = deepcopy(Y) @test isequal(Y1, Y) @assert !(Y === Y1) # ----- test Base.resize! ----------------------------------------------------# resize!(Y1, 20) @test Y1.values[1:10] == Y.values[1:10] @test Y1.isna[1:10] == Y.isna[1:10] @test Y1.isna[11:20] == fill(true, 10) resize!(Y1, 5) @test Y1.values[1:5] == Y.values[1:5] @test Y1.isna[1:5] == Y.isna[1:5] # ----- test Base.reshape ----------------------------------------------------# Y1 = reshape(copy(Y), length(Y), 1) @test size(Y1) == (length(Y), 1) @test all(i -> isequal(Y1[i], Y[i]), 1:length(Y)) Y2 = reshape(Y1, 1, length(Y1)) @test size(Y2) == (1, length(Y1)) @test all(i -> isequal(Y1[i], Y2[i]), 1:length(Y2)) # Test that arrays share the same data Y2.values[1] += 1 Y2.isna[2] = true @test all(i -> isequal(Y1[i], Y2[i]), 1:length(Y2)) # ----- test Base.ndims ------------------------------------------------------# for n in 1:4 @test ndims(DataValueArray{Int}(collect(1:n)...)) == n end # ----- test Base.length -----------------------------------------------------# @test length(DataValueArray{Int}(10)) == 10 @test length(DataValueArray{Int}(5, 5)) == 25 @test length(DataValueArray{Int}((3, 3, 3))) == 27 # ----- test Base.lastindex ------------------------------------------------------# @test lastindex(DataValueArray(collect(1:10))) == 10 @test lastindex(DataValueArray([1, 2, nothing, 4, nothing])) == 5 # ----- test Base.find -------------------------------------------------------# z = DataValueArray(rand(Bool, 10)) @test (LinearIndices(z))[findall(x -> x != 0, z)] == (LinearIndices(z.values))[findall(z.values)] z = DataValueArray([false, true, false, true, false, true]) @test isequal((LinearIndices(z))[findall(x -> x != 0, z)], [2, 4, 6]) # ----- test dropna --------------------------------------------------------# # dropna(X::DataValueVector) z = DataValueArray([1, 2, 3, NA, 5, NA, 7, NA]) @test dropna(z) == [1, 2, 3, 5, 7] # dropna(X::AbstractVector) A = Any[1, 2, 3, DataValue(), 5, DataValue(), 7, DataValue()] @test dropna(A) == [1, 2, 3, 5, 7] # dropna(X::AbstractVector{<:DataValue}) B = [1, 2, 3, DataValue(), 5, DataValue(), 7, DataValue()] @test dropna(B) == [1, 2, 3, 5, 7] # assert dropna returns copy for !(DataValue <: eltype(X)) nullfree = [1, 2, 3, 4] returned_copy = dropna(nullfree) @test nullfree == returned_copy && !(nullfree === returned_copy) # ----- test dropna! -------------------------------------------------------# # for each, assert returned values are unwrapped and inplace change # dropna!(X::DataValueVector) @test dropna!(z) == [1, 2, 3, 5, 7] @test isequal(z, DataValueArray([1, 2, 3, 5, 7])) # dropna!(X::AbstractVector) @test dropna!(A) == [1, 2, 3, 5, 7] @test isequal(A, Any[1, 2, 3, 5, 7]) # dropna!(X::AbstractVector{<:DataValue}) @test dropna!(B) == [1, 2, 3, 5, 7] @test isequal(B, DataValue[1, 2, 3, 5, 7]) # when no nulls present, dropna! returns input vector returned_view = dropna!(nullfree) @test nullfree == returned_view && nullfree === returned_view # test that dropna! returns unwrapped values when DataValues are present X = [false, 1, :c, "string", DataValue("I am not null"), DataValue()] @test !any(x -> isa(x, DataValue), dropna!(X)) @test any(x -> isa(x, DataValue), X) Y = Any[false, 1, :c, "string", DataValue("I am not null"), DataValue()] @test !any(x -> isa(x, DataValue), dropna!(Y)) @test any(x -> isa(x, DataValue), Y) # ----- test any(isna, X) --------------------------------------------------# # any(isna, X::DataValueArray) z = DataValueArray([1, 2, 3, NA, 5, NA, 7, NA]) @test any(isna, z) == true @test any(isna, dropna(z)) == false z = DataValueArray{Int}(10) @test any(isna, z) == true # any(isna, A::AbstractArray) A2 = [DataValue(1), DataValue(2), DataValue(3)] @test any(isna, A2) == false push!(A2, DataValue{Int}()) @test any(isna, A2) == true # any(isna, xs::NTuple) @test any(isna, (DataValue(1), DataValue(2))) == false @test any(isna, (DataValue{Int}(), DataValue(1), 3, 6)) == true # any(isna, S::SubArray{T, N, U<:DataValueArray}) A = rand(10, 3, 3) M = rand(Bool, 10, 3, 3) X = DataValueArray(A, M) i, j = rand(1:3), rand(1:3) S = view(X, :, i, j) @test any(isna, S) == any(isna, X[:, i, j]) X = DataValueArray(A) S = view(X, :, i, j) @test any(isna, S) == false # ----- test all(isna, X) --------------------------------------------------# # all(isna, X::DataValueArray) z = DataValueArray{Int}(10) @test all(isna, z) == true z[1] = 10 @test all(isna, z) == false # all(isna, X::AbstractArray{<:DataValue}) @test all(isna, DataValue{Int}[DataValue(), DataValue()]) == true @test all(isna, DataValue{Int}[DataValue(1), DataValue()]) == false # all(isna, X::Any) @test all(isna, Any[DataValue(), DataValue()]) == true @test all(isna, [1, 2]) == false @test all(isna, 1:3) == false # ----- test Base.isnan ------------------------------------------------------# x = DataValueArray([1, 2, NaN, 4, 5, NaN, Inf, NA]) _x = map(isnan, x) @test isequal(_x, [false, false, true, false, false, true, false, false]) # ----- test Base.isfinite ---------------------------------------------------# _x = map(isfinite, x) @test isequal(_x, [true, true, false, true, true, false, false, false]) # ----- test conversion methods ----------------------------------------------# u = DataValueArray(collect(1:10)) v = DataValueArray{Int}(4, 4) fill!(v, 4) w = DataValueArray(['a', 'b', 'c', 'd', 'e', 'f', NA]) x = DataValueArray([(i, j, k) for i in 1:10, j in 1:10, k in 1:10]) y = DataValueArray([2, 4, 6, 8, 10]) z = DataValueArray([i * j for i in 1:10, j in 1:10]) _z = DataValueArray(reshape(collect(1:100), 10, 10), convert(Array{Bool}, reshape([mod(j, 2) for i in 1:10, j in 1:10], (10, 10)))) _x = DataValueArray([false, true, false, NA, false, true, NA]) a = [i * j * k for i in 1:2, j in 1:2, k in 1:2] b = collect(1:10) c = [i for i in 1:10, j in 1:10] e = convert(DataValueArray, a) f = convert(DataValueArray{Float64}, b) g = convert(DataValueArray, c) h = convert(DataValueArray{Float64}, g) @test_throws DataValueException convert(Array{Char,1}, w) @test convert(Array{Char,1}, DataValueArray(dropna(w))) == ['a', 'b', 'c', 'd', 'e', 'f'] @test_throws DataValueException convert(Array{Char}, w) @test convert(Array{Float64}, u) == Float64[1, 2, 3, 4, 5, 6, 7, 8, 9, 10] @test convert(Vector{Float64}, y) == Float64[2, 4, 6, 8, 10] @test convert(Matrix{Float64}, z) == Float64[i * j for i in 1:10, j in 1:10] @test_throws DataValueException convert(Array, w) @test convert(Array, v) == [4 4 4 4; 4 4 4 4; 4 4 4 4; 4 4 4 4] @test convert(Array, z) == [i * j for i in 1:10, j in 1:10] @test convert(Array, u) == [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] @test convert(Array, _x, false) == [false, true, false, false, false, true, false] @test convert(Array{Int,1}, _x, 0) == [0, 1, 0, 0, 0, 1, 0] @test convert(Vector, _x, false) == [false, true, false, false, false, true, false] @test sum(convert(Matrix, _z, 0)) == 2775 @test isequal(e[:, :, 1], DataValueArray([1 2; 2 4])) @test isequal(f, DataValueArray(Float64[i for i in 1:10])) @test isa(g, DataValueArray{Int,2}) @test isa(h, DataValueArray{Float64,2}) # Base.convert{T}(::Type{Vector}, X::DataValueVector{T}) X = DataValueArray([1, 2, 3, 4, 5]) @test convert(Vector, X) == [1, 2, 3, 4, 5] push!(X, DataValue()) @test_throws DataValueException convert(Vector, X) # Base.convert{T}(::Type{Matrix}, X::DataValueMatrix{T}) Y = DataValueArray([1 2; 3 4; 5 6; 7 8; 9 10]) @test convert(Matrix, Y) == [1 2; 3 4; 5 6; 7 8; 9 10] Z = DataValueArray([1 2; 3 4; 5 6; 7 8; 9 NA]) @test_throws DataValueException convert(Matrix, Z) # float(X::DataValueArray) A = rand(Int, 20) M = rand(Bool, 20) X = DataValueArray(A, M) @test isequal(map(float, X), DataValueArray(float(A), M)) # ----- test Base.hash (julia/base/hashing.jl:5) -----------------------------# # Omitted for now, pending investigation into DataValueArray-specific # method. # TODO: reinstate testing once decision whether or not to implement # DataValueArray-specific hash method is reached. # ----- test unique (julia/base/set.jl:107) ----------------------------------# x = DataValueArray([1, NA, -2, 1, NA, 4]) @assert isequal(unique(x), DataValueArray([1, NA, -2, 4])) @assert isequal(unique(reverse(x)), DataValueArray([4, NA, 1, -2])) end
[ 27, 7856, 261, 480, 29, 22766, 4399, 14, 6601, 40161, 13, 20362, 27, 34345, 29, 9288, 14, 18747, 14, 9288, 62, 19795, 20288, 13, 20362, 27, 456, 62, 30783, 29, 16, 12, 940, 198, 3500, 6208, 201, 198, 3500, 6060, 40161, 201, 198, 201, 198, 31, 9288, 2617, 366, 6601, 11395, 19182, 25, 11460, 20288, 1, 2221, 201, 198, 201, 198, 220, 220, 220, 299, 796, 43720, 7, 16, 25, 20, 8, 201, 198, 220, 220, 220, 264, 528, 796, 685, 43720, 7, 17, 25, 20, 8, 329, 1312, 287, 299, 2361, 201, 198, 220, 220, 220, 317, 796, 43720, 7, 82, 528, 23029, 201, 198, 220, 220, 220, 337, 796, 43720, 7, 33, 970, 11, 264, 528, 23029, 201, 198, 220, 220, 220, 1395, 796, 6060, 11395, 19182, 7, 32, 11, 337, 8, 201, 198, 220, 220, 220, 1312, 796, 43720, 7, 16, 25, 13664, 7, 55, 4008, 201, 198, 220, 220, 220, 2488, 9288, 3815, 7, 55, 11, 1312, 8, 6624, 1395, 13, 27160, 58, 72, 60, 201, 198, 220, 220, 220, 2488, 9288, 2125, 64, 7, 55, 11, 1312, 8, 6624, 1395, 13, 271, 2616, 58, 72, 60, 201, 198, 220, 220, 220, 314, 796, 685, 43720, 7, 16, 25, 7857, 7, 55, 11, 1312, 4008, 329, 1312, 287, 352, 25, 77, 2361, 201, 198, 220, 220, 220, 2488, 9288, 3815, 7, 55, 11, 314, 23029, 6624, 1395, 13, 27160, 58, 40, 22345, 201, 198, 220, 220, 220, 2488, 9288, 2125, 64, 7, 55, 11, 314, 23029, 6624, 1395, 13, 271, 2616, 58, 40, 22345, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 38610, 11, 7308, 13, 7857, 220, 20368, 982, 2, 201, 198, 201, 198, 220, 220, 220, 2124, 796, 6060, 11395, 19182, 90, 5317, 92, 19510, 20, 11, 362, 4008, 201, 198, 220, 220, 220, 2488, 9288, 318, 64, 7, 87, 11, 6060, 11395, 46912, 90, 5317, 30072, 201, 198, 220, 220, 220, 2488, 9288, 2546, 7, 87, 8, 24844, 357, 20, 11, 362, 8, 201, 198, 201, 198, 220, 220, 220, 331, 796, 2092, 7, 87, 11, 6060, 11395, 90, 5317, 5512, 357, 18, 11, 513, 4008, 201, 198, 220, 220, 220, 2488, 9288, 318, 64, 7, 88, 11, 6060, 11395, 46912, 90, 5317, 30072, 201, 198, 220, 220, 220, 2488, 9288, 2546, 7, 88, 8, 24844, 357, 18, 11, 513, 8, 201, 198, 201, 198, 220, 220, 220, 1976, 796, 2092, 7, 87, 11, 6060, 11395, 90, 5317, 5512, 357, 17, 11, 4008, 201, 198, 220, 220, 220, 2488, 9288, 318, 64, 7, 89, 11, 6060, 11395, 38469, 90, 5317, 30072, 201, 198, 220, 220, 220, 2488, 9288, 2546, 7, 89, 8, 24844, 357, 17, 35751, 201, 198, 201, 198, 2, 1332, 2219, 779, 12, 33279, 82, 329, 705, 38610, 6, 201, 198, 220, 220, 220, 288, 85, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 17, 8, 201, 198, 220, 220, 220, 288, 76, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 17, 11, 362, 8, 201, 198, 220, 220, 220, 288, 83, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 17, 11, 362, 11, 362, 8, 201, 198, 201, 198, 220, 220, 220, 2092, 7, 67, 85, 8, 201, 198, 220, 220, 220, 2092, 7, 36020, 8, 201, 198, 220, 220, 220, 2092, 7, 28664, 8, 201, 198, 201, 198, 220, 220, 220, 2092, 7, 67, 85, 11, 362, 8, 201, 198, 220, 220, 220, 2092, 7, 36020, 11, 362, 11, 362, 8, 201, 198, 220, 220, 220, 2092, 7, 28664, 11, 362, 11, 362, 11, 362, 8, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 30073, 14, 14881, 13, 30073, 0, 20368, 10541, 2, 201, 198, 201, 198, 2, 4866, 201, 198, 220, 220, 220, 2124, 796, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 11746, 12962, 201, 198, 220, 220, 220, 331, 796, 6060, 11395, 19182, 26933, 18, 11, 11746, 11, 642, 12962, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 7, 87, 828, 2124, 8, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 88, 11, 2124, 828, 2124, 8, 201, 198, 201, 198, 201, 198, 2, 4866, 0, 201, 198, 220, 220, 220, 2163, 1729, 9895, 7, 67, 85, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 796, 2092, 7, 67, 85, 11, 6060, 11395, 90, 46541, 30072, 201, 198, 220, 220, 220, 220, 220, 220, 220, 329, 21065, 796, 352, 25, 13664, 7, 67, 85, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 67, 85, 13, 271, 2616, 58, 4178, 60, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1005, 58, 4178, 60, 796, 288, 85, 58, 4178, 60, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 220, 220, 220, 220, 1005, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 900, 16, 796, 4377, 58, 6601, 11395, 19182, 26933, 16, 11, 11746, 11, 513, 46570, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 26933, 4535, 11, 642, 46570, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 513, 11, 604, 11, 642, 46570, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 7, 5317, 21737, 828, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 26933, 4535, 11, 642, 11, 513, 46570, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 26933, 16, 11, 642, 11, 513, 12962, 60, 201, 198, 220, 220, 220, 900, 17, 796, 3975, 7, 13159, 9895, 11, 900, 16, 8, 201, 198, 201, 198, 220, 220, 220, 329, 357, 16520, 11, 12351, 11, 1263, 10677, 11, 23909, 893, 6015, 11, 581, 16, 11, 581, 17, 8, 287, 4377, 58, 2617, 16, 11, 900, 17, 60, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 30073, 7, 16520, 828, 12351, 828, 581, 16, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 30073, 7, 16520, 828, 352, 11, 12351, 828, 581, 16, 8, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 30073, 7, 16520, 828, 362, 11, 12351, 11, 362, 828, 581, 17, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 30073, 7, 16520, 828, 362, 11, 12351, 11, 362, 11, 352, 828, 581, 17, 8, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 30073, 7, 16520, 828, 7388, 11, 12351, 11, 7388, 11, 657, 828, 2244, 8, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 7, 30073, 1462, 0, 7, 30073, 7, 16520, 828, 352, 11, 23909, 893, 6015, 828, 2244, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 352, 11, 23909, 893, 6015, 11, 352, 8, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 329, 4686, 87, 287, 685, 15, 11, 604, 60, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 4686, 87, 11, 12351, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 4686, 87, 11, 12351, 11, 352, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 4686, 87, 11, 12351, 11, 352, 11, 352, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 352, 11, 12351, 11, 4686, 87, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 352, 11, 12351, 11, 4686, 87, 11, 352, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 45751, 12331, 4866, 1462, 0, 7, 16520, 11, 352, 11, 12351, 11, 352, 11, 532, 16, 8, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 1263, 10677, 8, 201, 198, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 513, 11, 12351, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 513, 11, 12351, 11, 352, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 513, 11, 12351, 11, 352, 11, 362, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 347, 3733, 12331, 4866, 1462, 0, 7, 16520, 11, 352, 11, 12351, 11, 362, 11, 362, 8, 201, 198, 220, 220, 220, 886, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 20797, 0, 20368, 19351, 438, 2, 201, 198, 201, 198, 220, 220, 220, 1395, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 940, 11, 362, 8, 201, 198, 220, 220, 220, 6070, 0, 7, 55, 11, 6060, 11395, 7, 940, 4008, 201, 198, 220, 220, 220, 575, 796, 6060, 11395, 19182, 90, 43879, 2414, 92, 7, 940, 8, 201, 198, 220, 220, 220, 6070, 0, 7, 56, 11, 43720, 7, 43879, 2414, 4008, 201, 198, 201, 198, 220, 220, 220, 2488, 9288, 1395, 13, 27160, 6624, 6070, 7, 940, 11, 838, 11, 362, 8, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 55, 13, 271, 2616, 11, 6070, 7, 9562, 11, 838, 11, 362, 4008, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 56, 13, 271, 2616, 11, 6070, 7, 9562, 11, 838, 4008, 201, 198, 201, 198, 220, 220, 220, 6070, 0, 7, 55, 11, 6060, 11395, 28955, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 55, 13, 271, 2616, 11, 6070, 7, 7942, 11, 838, 11, 362, 4008, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 22089, 30073, 20368, 1783, 6329, 2, 201, 198, 201, 198, 220, 220, 220, 575, 16, 796, 2769, 30073, 7, 56, 8, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 56, 16, 11, 575, 8, 201, 198, 220, 220, 220, 2488, 30493, 5145, 7, 56, 24844, 575, 16, 8, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 411, 1096, 0, 20368, 19351, 2, 201, 198, 201, 198, 220, 220, 220, 47558, 0, 7, 56, 16, 11, 1160, 8, 201, 198, 220, 220, 220, 2488, 9288, 575, 16, 13, 27160, 58, 16, 25, 940, 60, 6624, 575, 13, 27160, 58, 16, 25, 940, 60, 201, 198, 220, 220, 220, 2488, 9288, 575, 16, 13, 271, 2616, 58, 16, 25, 940, 60, 6624, 575, 13, 271, 2616, 58, 16, 25, 940, 60, 201, 198, 220, 220, 220, 2488, 9288, 575, 16, 13, 271, 2616, 58, 1157, 25, 1238, 60, 6624, 6070, 7, 7942, 11, 838, 8, 201, 198, 201, 198, 220, 220, 220, 47558, 0, 7, 56, 16, 11, 642, 8, 201, 198, 220, 220, 220, 2488, 9288, 575, 16, 13, 27160, 58, 16, 25, 20, 60, 6624, 575, 13, 27160, 58, 16, 25, 20, 60, 201, 198, 220, 220, 220, 2488, 9288, 575, 16, 13, 271, 2616, 58, 16, 25, 20, 60, 6624, 575, 13, 271, 2616, 58, 16, 25, 20, 60, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 3447, 1758, 20368, 19351, 2, 201, 198, 201, 198, 220, 220, 220, 575, 16, 796, 27179, 1758, 7, 30073, 7, 56, 828, 4129, 7, 56, 828, 352, 8, 201, 198, 220, 220, 220, 2488, 9288, 2546, 7, 56, 16, 8, 6624, 357, 13664, 7, 56, 828, 352, 8, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 72, 4613, 318, 40496, 7, 56, 16, 58, 72, 4357, 575, 58, 72, 46570, 352, 25, 13664, 7, 56, 4008, 201, 198, 220, 220, 220, 575, 17, 796, 27179, 1758, 7, 56, 16, 11, 352, 11, 4129, 7, 56, 16, 4008, 201, 198, 220, 220, 220, 2488, 9288, 2546, 7, 56, 17, 8, 6624, 357, 16, 11, 4129, 7, 56, 16, 4008, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 72, 4613, 318, 40496, 7, 56, 16, 58, 72, 4357, 575, 17, 58, 72, 46570, 352, 25, 13664, 7, 56, 17, 4008, 201, 198, 2, 6208, 326, 26515, 2648, 262, 976, 1366, 201, 198, 220, 220, 220, 575, 17, 13, 27160, 58, 16, 60, 15853, 352, 201, 198, 220, 220, 220, 575, 17, 13, 271, 2616, 58, 17, 60, 796, 2081, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 72, 4613, 318, 40496, 7, 56, 16, 58, 72, 4357, 575, 17, 58, 72, 46570, 352, 25, 13664, 7, 56, 17, 4008, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 358, 12078, 20368, 19351, 438, 2, 201, 198, 201, 198, 220, 220, 220, 329, 299, 287, 352, 25, 19, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 299, 67, 12078, 7, 6601, 11395, 19182, 90, 5317, 92, 7, 33327, 7, 16, 25, 77, 26513, 4008, 6624, 299, 201, 198, 220, 220, 220, 886, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 13664, 20368, 19351, 12, 2, 201, 198, 201, 198, 220, 220, 220, 2488, 9288, 4129, 7, 6601, 11395, 19182, 90, 5317, 92, 7, 940, 4008, 6624, 838, 201, 198, 220, 220, 220, 2488, 9288, 4129, 7, 6601, 11395, 19182, 90, 5317, 92, 7, 20, 11, 642, 4008, 6624, 1679, 201, 198, 220, 220, 220, 2488, 9288, 4129, 7, 6601, 11395, 19182, 90, 5317, 92, 19510, 18, 11, 513, 11, 513, 22305, 6624, 2681, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 12957, 9630, 20368, 19351, 438, 2, 201, 198, 201, 198, 220, 220, 220, 2488, 9288, 938, 9630, 7, 6601, 11395, 19182, 7, 33327, 7, 16, 25, 940, 22305, 6624, 838, 201, 198, 220, 220, 220, 2488, 9288, 938, 9630, 7, 6601, 11395, 19182, 26933, 16, 11, 362, 11, 2147, 11, 604, 11, 2147, 60, 4008, 6624, 642, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 19796, 20368, 19351, 6329, 2, 201, 198, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 7, 25192, 7, 33, 970, 11, 838, 4008, 201, 198, 220, 220, 220, 2488, 9288, 357, 14993, 451, 5497, 1063, 7, 89, 4008, 58, 19796, 439, 7, 87, 4613, 2124, 14512, 657, 11, 1976, 15437, 6624, 357, 14993, 451, 5497, 1063, 7, 89, 13, 27160, 4008, 58, 19796, 439, 7, 89, 13, 27160, 15437, 201, 198, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 26933, 9562, 11, 2081, 11, 3991, 11, 2081, 11, 3991, 11, 2081, 12962, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 19510, 14993, 451, 5497, 1063, 7, 89, 4008, 58, 19796, 439, 7, 87, 4613, 2124, 14512, 657, 11, 1976, 8, 4357, 685, 17, 11, 604, 11, 718, 12962, 201, 198, 201, 198, 2, 37404, 1332, 4268, 2616, 20368, 22369, 2, 201, 198, 201, 198, 2, 4268, 2616, 7, 55, 3712, 6601, 11395, 38469, 8, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 513, 11, 11746, 11, 642, 11, 11746, 11, 767, 11, 11746, 12962, 201, 198, 220, 220, 220, 2488, 9288, 4268, 2616, 7, 89, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 201, 198, 201, 198, 2, 4268, 2616, 7, 55, 3712, 23839, 38469, 8, 201, 198, 220, 220, 220, 317, 796, 4377, 58, 16, 11, 362, 11, 513, 11, 6060, 11395, 22784, 642, 11, 6060, 11395, 22784, 767, 11, 6060, 11395, 3419, 60, 201, 198, 220, 220, 220, 2488, 9288, 4268, 2616, 7, 32, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 201, 198, 201, 198, 2, 4268, 2616, 7, 55, 3712, 23839, 38469, 90, 27, 25, 6601, 11395, 30072, 201, 198, 220, 220, 220, 347, 796, 685, 16, 11, 362, 11, 513, 11, 6060, 11395, 22784, 642, 11, 6060, 11395, 22784, 767, 11, 6060, 11395, 3419, 60, 201, 198, 220, 220, 220, 2488, 9288, 4268, 2616, 7, 33, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 201, 198, 2, 6818, 4268, 2616, 5860, 4866, 329, 5145, 7, 6601, 11395, 1279, 25, 1288, 4906, 7, 55, 4008, 201, 198, 220, 220, 220, 9242, 5787, 796, 685, 16, 11, 362, 11, 513, 11, 604, 60, 201, 198, 220, 220, 220, 4504, 62, 30073, 796, 4268, 2616, 7, 8423, 5787, 8, 201, 198, 220, 220, 220, 2488, 9288, 9242, 5787, 6624, 4504, 62, 30073, 11405, 5145, 7, 8423, 5787, 24844, 4504, 62, 30073, 8, 201, 198, 201, 198, 2, 37404, 1332, 4268, 2616, 0, 20368, 19351, 6329, 2, 201, 198, 201, 198, 2, 329, 1123, 11, 6818, 4504, 3815, 389, 7379, 430, 1496, 290, 287, 5372, 1487, 201, 198, 2, 4268, 2616, 0, 7, 55, 3712, 6601, 11395, 38469, 8, 201, 198, 220, 220, 220, 2488, 9288, 4268, 2616, 0, 7, 89, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 89, 11, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 4008, 201, 198, 201, 198, 2, 4268, 2616, 0, 7, 55, 3712, 23839, 38469, 8, 201, 198, 220, 220, 220, 2488, 9288, 4268, 2616, 0, 7, 32, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 32, 11, 4377, 58, 16, 11, 362, 11, 513, 11, 642, 11, 767, 12962, 201, 198, 201, 198, 2, 4268, 2616, 0, 7, 55, 3712, 23839, 38469, 90, 27, 25, 6601, 11395, 30072, 201, 198, 220, 220, 220, 2488, 9288, 4268, 2616, 0, 7, 33, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 642, 11, 767, 60, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 33, 11, 6060, 11395, 58, 16, 11, 362, 11, 513, 11, 642, 11, 767, 12962, 201, 198, 201, 198, 2, 618, 645, 9242, 82, 1944, 11, 4268, 2616, 0, 5860, 5128, 15879, 201, 198, 220, 220, 220, 4504, 62, 1177, 796, 4268, 2616, 0, 7, 8423, 5787, 8, 201, 198, 220, 220, 220, 2488, 9288, 9242, 5787, 6624, 4504, 62, 1177, 11405, 9242, 5787, 24844, 4504, 62, 1177, 201, 198, 201, 198, 2, 1332, 326, 4268, 2616, 0, 5860, 7379, 430, 1496, 3815, 618, 6060, 40161, 389, 1944, 201, 198, 220, 220, 220, 1395, 796, 685, 9562, 11, 352, 11, 1058, 66, 11, 366, 8841, 1600, 6060, 11395, 7203, 40, 716, 407, 9242, 12340, 6060, 11395, 3419, 60, 201, 198, 220, 220, 220, 2488, 9288, 5145, 1092, 7, 87, 4613, 318, 64, 7, 87, 11, 6060, 11395, 828, 4268, 2616, 0, 7, 55, 4008, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 87, 4613, 318, 64, 7, 87, 11, 6060, 11395, 828, 1395, 8, 201, 198, 220, 220, 220, 575, 796, 4377, 58, 9562, 11, 352, 11, 1058, 66, 11, 366, 8841, 1600, 6060, 11395, 7203, 40, 716, 407, 9242, 12340, 6060, 11395, 3419, 60, 201, 198, 220, 220, 220, 2488, 9288, 5145, 1092, 7, 87, 4613, 318, 64, 7, 87, 11, 6060, 11395, 828, 4268, 2616, 0, 7, 56, 4008, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 87, 4613, 318, 64, 7, 87, 11, 6060, 11395, 828, 575, 8, 201, 198, 201, 198, 2, 37404, 1332, 597, 7, 271, 2616, 11, 1395, 8, 20368, 1783, 438, 2, 201, 198, 201, 198, 2, 597, 7, 271, 2616, 11, 1395, 3712, 6601, 11395, 19182, 8, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 513, 11, 11746, 11, 642, 11, 11746, 11, 767, 11, 11746, 12962, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 1976, 8, 6624, 2081, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 4268, 2616, 7, 89, 4008, 6624, 3991, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 940, 8, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 1976, 8, 6624, 2081, 201, 198, 201, 198, 2, 597, 7, 271, 2616, 11, 317, 3712, 23839, 19182, 8, 201, 198, 220, 220, 220, 317, 17, 796, 685, 6601, 11395, 7, 16, 828, 6060, 11395, 7, 17, 828, 6060, 11395, 7, 18, 15437, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 317, 17, 8, 6624, 3991, 201, 198, 220, 220, 220, 4574, 0, 7, 32, 17, 11, 6060, 11395, 90, 5317, 92, 28955, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 317, 17, 8, 6624, 2081, 201, 198, 201, 198, 2, 597, 7, 271, 2616, 11, 2124, 82, 3712, 11251, 29291, 8, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 357, 6601, 11395, 7, 16, 828, 6060, 11395, 7, 17, 22305, 6624, 3991, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 357, 6601, 11395, 90, 5317, 92, 22784, 6060, 11395, 7, 16, 828, 513, 11, 718, 4008, 6624, 2081, 201, 198, 201, 198, 2, 597, 7, 271, 2616, 11, 311, 3712, 7004, 19182, 90, 51, 11, 399, 11, 471, 27, 25, 6601, 11395, 19182, 30072, 201, 198, 220, 220, 220, 317, 796, 43720, 7, 940, 11, 513, 11, 513, 8, 201, 198, 220, 220, 220, 337, 796, 43720, 7, 33, 970, 11, 838, 11, 513, 11, 513, 8, 201, 198, 220, 220, 220, 1395, 796, 6060, 11395, 19182, 7, 32, 11, 337, 8, 201, 198, 220, 220, 220, 1312, 11, 474, 796, 43720, 7, 16, 25, 18, 828, 43720, 7, 16, 25, 18, 8, 201, 198, 220, 220, 220, 311, 796, 1570, 7, 55, 11, 1058, 11, 1312, 11, 474, 8, 201, 198, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 311, 8, 6624, 597, 7, 271, 2616, 11, 1395, 58, 45299, 1312, 11, 474, 12962, 201, 198, 220, 220, 220, 1395, 796, 6060, 11395, 19182, 7, 32, 8, 201, 198, 220, 220, 220, 311, 796, 1570, 7, 55, 11, 1058, 11, 1312, 11, 474, 8, 201, 198, 220, 220, 220, 2488, 9288, 597, 7, 271, 2616, 11, 311, 8, 6624, 3991, 201, 198, 201, 198, 201, 198, 2, 37404, 1332, 477, 7, 271, 2616, 11, 1395, 8, 20368, 1783, 438, 2, 201, 198, 201, 198, 2, 477, 7, 271, 2616, 11, 1395, 3712, 6601, 11395, 19182, 8, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 940, 8, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 1976, 8, 6624, 2081, 201, 198, 220, 220, 220, 1976, 58, 16, 60, 796, 838, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 1976, 8, 6624, 3991, 201, 198, 201, 198, 2, 477, 7, 271, 2616, 11, 1395, 3712, 23839, 19182, 90, 27, 25, 6601, 11395, 30072, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 6060, 11395, 90, 5317, 92, 58, 6601, 11395, 22784, 6060, 11395, 3419, 12962, 6624, 2081, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 6060, 11395, 90, 5317, 92, 58, 6601, 11395, 7, 16, 828, 6060, 11395, 3419, 12962, 6624, 3991, 201, 198, 201, 198, 2, 477, 7, 271, 2616, 11, 1395, 3712, 7149, 8, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 4377, 58, 6601, 11395, 22784, 6060, 11395, 3419, 12962, 6624, 2081, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 685, 16, 11, 362, 12962, 6624, 3991, 201, 198, 220, 220, 220, 2488, 9288, 477, 7, 271, 2616, 11, 352, 25, 18, 8, 6624, 3991, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 271, 12647, 20368, 19351, 438, 2, 201, 198, 201, 198, 220, 220, 220, 2124, 796, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 11013, 45, 11, 604, 11, 642, 11, 11013, 45, 11, 4806, 11, 11746, 12962, 201, 198, 220, 220, 220, 4808, 87, 796, 3975, 7, 271, 12647, 11, 2124, 8, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 28264, 87, 11, 685, 9562, 11, 3991, 11, 2081, 11, 3991, 11, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3991, 11, 2081, 11, 3991, 11, 3991, 12962, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 4468, 9504, 20368, 1783, 6329, 2, 201, 198, 201, 198, 220, 220, 220, 4808, 87, 796, 3975, 7, 4468, 9504, 11, 2124, 8, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 28264, 87, 11, 685, 7942, 11, 2081, 11, 3991, 11, 2081, 11, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2081, 11, 3991, 11, 3991, 11, 3991, 12962, 201, 198, 201, 198, 2, 37404, 1332, 11315, 5050, 20368, 26171, 2, 201, 198, 201, 198, 220, 220, 220, 334, 796, 6060, 11395, 19182, 7, 33327, 7, 16, 25, 940, 4008, 201, 198, 220, 220, 220, 410, 796, 6060, 11395, 19182, 90, 5317, 92, 7, 19, 11, 604, 8, 201, 198, 220, 220, 220, 6070, 0, 7, 85, 11, 604, 8, 201, 198, 220, 220, 220, 266, 796, 6060, 11395, 19182, 7, 17816, 64, 3256, 705, 65, 3256, 705, 66, 3256, 705, 67, 3256, 705, 68, 3256, 705, 69, 3256, 11746, 12962, 201, 198, 220, 220, 220, 2124, 796, 6060, 11395, 19182, 26933, 7, 72, 11, 474, 11, 479, 8, 329, 1312, 287, 352, 25, 940, 11, 474, 287, 352, 25, 940, 11, 479, 287, 352, 25, 940, 12962, 201, 198, 220, 220, 220, 331, 796, 6060, 11395, 19182, 26933, 17, 11, 604, 11, 718, 11, 807, 11, 838, 12962, 201, 198, 220, 220, 220, 1976, 796, 6060, 11395, 19182, 26933, 72, 1635, 474, 329, 1312, 287, 352, 25, 940, 11, 474, 287, 352, 25, 940, 12962, 201, 198, 220, 220, 220, 4808, 89, 796, 6060, 11395, 19182, 7, 3447, 1758, 7, 33327, 7, 16, 25, 3064, 828, 838, 11, 838, 828, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10385, 7, 19182, 90, 33, 970, 5512, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 27179, 1758, 26933, 4666, 7, 73, 11, 362, 8, 329, 1312, 287, 352, 25, 940, 11, 474, 287, 352, 25, 940, 4357, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 940, 11, 838, 35514, 201, 198, 220, 220, 220, 4808, 87, 796, 6060, 11395, 19182, 26933, 9562, 11, 2081, 11, 3991, 11, 11746, 11, 3991, 11, 2081, 11, 11746, 12962, 201, 198, 220, 220, 220, 257, 796, 685, 72, 1635, 474, 1635, 479, 329, 1312, 287, 352, 25, 17, 11, 474, 287, 352, 25, 17, 11, 479, 287, 352, 25, 17, 60, 201, 198, 220, 220, 220, 275, 796, 2824, 7, 16, 25, 940, 8, 201, 198, 220, 220, 220, 269, 796, 685, 72, 329, 1312, 287, 352, 25, 940, 11, 474, 287, 352, 25, 940, 60, 201, 198, 201, 198, 220, 220, 220, 304, 796, 10385, 7, 6601, 11395, 19182, 11, 257, 8, 201, 198, 220, 220, 220, 277, 796, 10385, 7, 6601, 11395, 19182, 90, 43879, 2414, 5512, 275, 8, 201, 198, 220, 220, 220, 308, 796, 10385, 7, 6601, 11395, 19182, 11, 269, 8, 201, 198, 220, 220, 220, 289, 796, 10385, 7, 6601, 11395, 19182, 90, 43879, 2414, 5512, 308, 8, 201, 198, 201, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 6060, 11395, 16922, 10385, 7, 19182, 90, 12441, 11, 16, 5512, 266, 8, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 90, 12441, 11, 16, 5512, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 7, 14781, 2616, 7, 86, 22305, 6624, 37250, 64, 3256, 705, 65, 3256, 705, 66, 3256, 705, 67, 3256, 705, 68, 3256, 705, 69, 20520, 201, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 6060, 11395, 16922, 10385, 7, 19182, 90, 12441, 5512, 266, 8, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 90, 43879, 2414, 5512, 334, 8, 6624, 48436, 2414, 58, 16, 11, 362, 11, 513, 11, 604, 11, 642, 11, 718, 11, 767, 11, 807, 11, 860, 11, 838, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 38469, 90, 43879, 2414, 5512, 331, 8, 6624, 48436, 2414, 58, 17, 11, 604, 11, 718, 11, 807, 11, 838, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 46912, 90, 43879, 2414, 5512, 1976, 8, 6624, 48436, 2414, 58, 72, 1635, 474, 329, 1312, 287, 352, 25, 940, 11, 474, 287, 352, 25, 940, 60, 201, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 6060, 11395, 16922, 10385, 7, 19182, 11, 266, 8, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 11, 410, 8, 6624, 685, 19, 604, 604, 604, 26, 604, 604, 604, 604, 26, 604, 604, 604, 604, 26, 604, 604, 604, 604, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 11, 1976, 8, 6624, 685, 72, 1635, 474, 329, 1312, 287, 352, 25, 940, 11, 474, 287, 352, 25, 940, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 11, 334, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 604, 11, 642, 11, 718, 11, 767, 11, 807, 11, 860, 11, 838, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 11, 4808, 87, 11, 3991, 8, 6624, 685, 9562, 11, 2081, 11, 3991, 11, 3991, 11, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3991, 11, 2081, 11, 3991, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 19182, 90, 5317, 11, 16, 5512, 4808, 87, 11, 657, 8, 6624, 685, 15, 11, 352, 11, 657, 11, 657, 11, 657, 11, 352, 11, 657, 60, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 38469, 11, 4808, 87, 11, 3991, 8, 6624, 685, 9562, 11, 2081, 11, 3991, 11, 3991, 11, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3991, 11, 2081, 11, 3991, 60, 201, 198, 220, 220, 220, 2488, 9288, 2160, 7, 1102, 1851, 7, 46912, 11, 4808, 89, 11, 657, 4008, 6624, 2681, 2425, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 68, 58, 45299, 1058, 11, 352, 4357, 6060, 11395, 19182, 26933, 16, 362, 26, 362, 604, 60, 4008, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 69, 11, 6060, 11395, 19182, 7, 43879, 2414, 58, 72, 329, 1312, 287, 352, 25, 940, 60, 4008, 201, 198, 220, 220, 220, 2488, 9288, 318, 64, 7, 70, 11, 6060, 11395, 19182, 90, 5317, 11, 17, 30072, 201, 198, 220, 220, 220, 2488, 9288, 318, 64, 7, 71, 11, 6060, 11395, 19182, 90, 43879, 2414, 11, 17, 30072, 201, 198, 201, 198, 2, 7308, 13, 1102, 1851, 90, 51, 92, 7, 3712, 6030, 90, 38469, 5512, 1395, 3712, 6601, 11395, 38469, 90, 51, 30072, 201, 198, 220, 220, 220, 1395, 796, 6060, 11395, 19182, 26933, 16, 11, 362, 11, 513, 11, 604, 11, 642, 12962, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 38469, 11, 1395, 8, 6624, 685, 16, 11, 362, 11, 513, 11, 604, 11, 642, 60, 201, 198, 220, 220, 220, 4574, 0, 7, 55, 11, 6060, 11395, 28955, 201, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 6060, 11395, 16922, 10385, 7, 38469, 11, 1395, 8, 201, 198, 201, 198, 2, 7308, 13, 1102, 1851, 90, 51, 92, 7, 3712, 6030, 90, 46912, 5512, 1395, 3712, 6601, 11395, 46912, 90, 51, 30072, 201, 198, 220, 220, 220, 575, 796, 6060, 11395, 19182, 26933, 16, 362, 26, 513, 604, 26, 642, 718, 26, 767, 807, 26, 860, 838, 12962, 201, 198, 220, 220, 220, 2488, 9288, 10385, 7, 46912, 11, 575, 8, 6624, 685, 16, 362, 26, 513, 604, 26, 642, 718, 26, 767, 807, 26, 860, 838, 60, 201, 198, 220, 220, 220, 1168, 796, 6060, 11395, 19182, 26933, 16, 362, 26, 513, 604, 26, 642, 718, 26, 767, 807, 26, 860, 11746, 12962, 201, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 6060, 11395, 16922, 10385, 7, 46912, 11, 1168, 8, 201, 198, 201, 198, 2, 12178, 7, 55, 3712, 6601, 11395, 19182, 8, 201, 198, 220, 220, 220, 317, 796, 43720, 7, 5317, 11, 1160, 8, 201, 198, 220, 220, 220, 337, 796, 43720, 7, 33, 970, 11, 1160, 8, 201, 198, 220, 220, 220, 1395, 796, 6060, 11395, 19182, 7, 32, 11, 337, 8, 201, 198, 220, 220, 220, 2488, 9288, 318, 40496, 7, 8899, 7, 22468, 11, 1395, 828, 6060, 11395, 19182, 7, 22468, 7, 32, 828, 337, 4008, 201, 198, 201, 198, 2, 37404, 1332, 7308, 13, 17831, 357, 73, 43640, 14, 8692, 14, 71, 2140, 13, 20362, 25, 20, 8, 34400, 32501, 2, 201, 198, 201, 198, 2, 440, 3291, 329, 783, 11, 13310, 3645, 656, 6060, 11395, 19182, 12, 11423, 201, 198, 2, 2446, 13, 201, 198, 2, 16926, 46, 25, 6865, 5219, 4856, 1752, 2551, 1771, 393, 407, 284, 3494, 201, 198, 2, 6060, 11395, 19182, 12, 11423, 12234, 2446, 318, 4251, 13, 201, 198, 201, 198, 2, 37404, 1332, 3748, 357, 73, 43640, 14, 8692, 14, 2617, 13, 20362, 25, 15982, 8, 20368, 438, 2, 201, 198, 201, 198, 220, 220, 220, 2124, 796, 6060, 11395, 19182, 26933, 16, 11, 11746, 11, 532, 17, 11, 352, 11, 11746, 11, 604, 12962, 201, 198, 220, 220, 220, 2488, 30493, 318, 40496, 7, 34642, 7, 87, 828, 6060, 11395, 19182, 26933, 16, 11, 11746, 11, 532, 17, 11, 604, 60, 4008, 201, 198, 220, 220, 220, 2488, 30493, 318, 40496, 7, 34642, 7, 50188, 7, 87, 36911, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6060, 11395, 19182, 26933, 19, 11, 11746, 11, 352, 11, 532, 17, 60, 4008, 201, 198, 201, 198, 201, 198, 201, 198, 437, 201, 198 ]
2.192735
5,946
#= @author : <NAME> <<EMAIL>> <NAME> <<EMAIL>> =# using Plots pyplot() using Distributions using LaTeXStrings # == Set parameters == # srand(42) # reproducible results n = 250 # Choice of n k = 10000 # Number of draws of Y_n dist = Exponential(1./2.) # Exponential distribution, lambda = 1/2 μ, s = mean(dist), std(dist) # == Draw underlying RVs. Each row contains a draw of X_1,..,X_n == # data = rand(dist, k, n) # == Compute mean of each row, producing k draws of \bar X_n == # sample_means = mean(data, 2) # == Generate observations of Y_n == # Y = sqrt(n) * (sample_means .- μ) # == Plot == # xmin, xmax = -3 * s, 3 * s histogram(Y, nbins=60, alpha=0.5, xlims=(xmin, xmax), norm=true, label="") xgrid = linspace(xmin, xmax, 200) plot!(xgrid, pdf.(Normal(0.0, s), xgrid), color=:black, linewidth=2, label=LaTeXString("\$N(0, \\sigma^2=$(s^2))\$"), legendfont=font(12))
[ 2, 28, 198, 198, 31, 9800, 1058, 1279, 20608, 29, 9959, 27630, 4146, 4211, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1279, 20608, 29, 9959, 27630, 4146, 4211, 198, 198, 46249, 198, 3500, 1345, 1747, 198, 9078, 29487, 3419, 198, 3500, 46567, 507, 198, 3500, 4689, 49568, 13290, 654, 198, 198, 2, 6624, 5345, 10007, 6624, 1303, 198, 82, 25192, 7, 3682, 8, 220, 1303, 8186, 37369, 2482, 198, 77, 796, 8646, 220, 220, 220, 1303, 18502, 286, 299, 198, 74, 796, 33028, 220, 1303, 7913, 286, 14293, 286, 575, 62, 77, 198, 17080, 796, 5518, 35470, 7, 16, 19571, 17, 2014, 220, 1303, 5518, 35470, 6082, 11, 37456, 796, 352, 14, 17, 198, 34703, 11, 264, 796, 1612, 7, 17080, 828, 14367, 7, 17080, 8, 198, 198, 2, 6624, 15315, 10238, 371, 23266, 13, 5501, 5752, 4909, 257, 3197, 286, 1395, 62, 16, 11, 492, 11, 55, 62, 77, 6624, 1303, 198, 7890, 796, 43720, 7, 17080, 11, 479, 11, 299, 8, 198, 198, 2, 6624, 3082, 1133, 1612, 286, 1123, 5752, 11, 9194, 479, 14293, 286, 3467, 5657, 1395, 62, 77, 6624, 1303, 198, 39873, 62, 1326, 504, 796, 1612, 7, 7890, 11, 362, 8, 198, 198, 2, 6624, 2980, 378, 13050, 286, 575, 62, 77, 6624, 1303, 198, 56, 796, 19862, 17034, 7, 77, 8, 1635, 357, 39873, 62, 1326, 504, 764, 12, 18919, 8, 198, 198, 2, 6624, 28114, 6624, 1303, 198, 87, 1084, 11, 2124, 9806, 796, 532, 18, 1635, 264, 11, 513, 1635, 264, 198, 10034, 21857, 7, 56, 11, 299, 65, 1040, 28, 1899, 11, 17130, 28, 15, 13, 20, 11, 2124, 2475, 82, 16193, 87, 1084, 11, 2124, 9806, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2593, 28, 7942, 11, 6167, 2625, 4943, 198, 87, 25928, 796, 300, 1040, 10223, 7, 87, 1084, 11, 2124, 9806, 11, 939, 8, 198, 29487, 0, 7, 87, 25928, 11, 37124, 12195, 26447, 7, 15, 13, 15, 11, 264, 828, 2124, 25928, 828, 3124, 28, 25, 13424, 11, 198, 220, 220, 220, 220, 220, 9493, 413, 5649, 28, 17, 11, 6167, 28, 14772, 49568, 10100, 7203, 59, 3, 45, 7, 15, 11, 26867, 82, 13495, 61, 17, 43641, 7, 82, 61, 17, 4008, 59, 3, 12340, 198, 220, 220, 220, 220, 220, 8177, 10331, 28, 10331, 7, 1065, 4008, 198 ]
2.347826
391
<filename>ray.jl include("Vec3.jl") struct ray origin::Vec3; direction::Vec3; point_at_parameter(r::ray, t::Number) = r.origin + t*r.direction; end function color(r::ray)::Vec3 unit_direction = unit_vector(r.direction()); t = 0.5*(y(unit_direction) + 1.0); return (1.0-t)*Vec3(1.0, 1.0, 1.0) + t*Vec3(0.5, 0.7, 1.0); end
[ 27, 34345, 29, 2433, 13, 20362, 198, 17256, 7203, 53, 721, 18, 13, 20362, 4943, 198, 198, 7249, 26842, 198, 220, 220, 220, 8159, 3712, 53, 721, 18, 26, 198, 220, 220, 220, 4571, 3712, 53, 721, 18, 26, 198, 220, 220, 220, 966, 62, 265, 62, 17143, 2357, 7, 81, 3712, 2433, 11, 256, 3712, 15057, 8, 796, 374, 13, 47103, 1343, 256, 9, 81, 13, 37295, 26, 198, 437, 198, 198, 8818, 3124, 7, 81, 3712, 2433, 2599, 25, 53, 721, 18, 198, 220, 220, 220, 4326, 62, 37295, 796, 4326, 62, 31364, 7, 81, 13, 37295, 35430, 198, 220, 220, 220, 256, 796, 657, 13, 20, 9, 7, 88, 7, 20850, 62, 37295, 8, 1343, 352, 13, 15, 1776, 198, 220, 220, 220, 1441, 357, 16, 13, 15, 12, 83, 27493, 53, 721, 18, 7, 16, 13, 15, 11, 352, 13, 15, 11, 352, 13, 15, 8, 1343, 256, 9, 53, 721, 18, 7, 15, 13, 20, 11, 657, 13, 22, 11, 352, 13, 15, 1776, 198, 437, 198 ]
2.017442
172
""" u,v,η,sst = run_model() runs ShallowWaters with default parameters as defined in src/DefaultParameters.jl # Examples ```jldoc julia> u,v,η,sst = run_model(Float64,nx=200,output=true) ``` """ function run_model(::Type{T}=Float32; # number format kwargs... # all additional parameters ) where {T<:Real} P = Parameter(T=T;kwargs...) return run_model(T,P) end function run_model(P::Parameter) @unpack T = P return run_model(T,P) end function run_model(::Type{T},P::Parameter) where {T<:Real} @unpack Tprog = P G = Grid{T,Tprog}(P) C = Constants{T,Tprog}(P,G) F = Forcing{T}(P,G) S = ModelSetup{T,Tprog}(P,G,C,F) Prog = initial_conditions(Tprog,S) Diag = preallocate(T,Tprog,G) Prog = time_integration(Prog,Diag,S) return Prog end
[ 37811, 628, 220, 220, 220, 334, 11, 85, 11, 138, 115, 11, 82, 301, 796, 1057, 62, 19849, 3419, 198, 198, 48381, 911, 12154, 54, 8605, 351, 4277, 10007, 355, 5447, 287, 12351, 14, 19463, 48944, 13, 20362, 198, 198, 2, 21066, 198, 15506, 63, 73, 335, 420, 198, 73, 43640, 29, 334, 11, 85, 11, 138, 115, 11, 82, 301, 796, 1057, 62, 19849, 7, 43879, 2414, 11, 77, 87, 28, 2167, 11, 22915, 28, 7942, 8, 198, 15506, 63, 198, 37811, 198, 8818, 1057, 62, 19849, 7, 3712, 6030, 90, 51, 92, 28, 43879, 2624, 26, 220, 220, 220, 220, 1303, 1271, 5794, 198, 220, 220, 220, 479, 86, 22046, 986, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 477, 3224, 10007, 198, 220, 220, 220, 1267, 810, 1391, 51, 27, 25, 15633, 92, 628, 220, 220, 220, 350, 796, 25139, 2357, 7, 51, 28, 51, 26, 46265, 22046, 23029, 198, 220, 220, 220, 1441, 1057, 62, 19849, 7, 51, 11, 47, 8, 198, 437, 198, 198, 8818, 1057, 62, 19849, 7, 47, 3712, 36301, 8, 198, 220, 220, 220, 2488, 403, 8002, 309, 796, 350, 198, 220, 220, 220, 1441, 1057, 62, 19849, 7, 51, 11, 47, 8, 198, 437, 198, 198, 8818, 1057, 62, 19849, 7, 3712, 6030, 90, 51, 5512, 47, 3712, 36301, 8, 810, 1391, 51, 27, 25, 15633, 92, 628, 220, 220, 220, 2488, 403, 8002, 309, 1676, 70, 796, 350, 628, 220, 220, 220, 402, 796, 24846, 90, 51, 11, 51, 1676, 70, 92, 7, 47, 8, 198, 220, 220, 220, 327, 796, 4757, 1187, 90, 51, 11, 51, 1676, 70, 92, 7, 47, 11, 38, 8, 198, 220, 220, 220, 376, 796, 1114, 2259, 90, 51, 92, 7, 47, 11, 38, 8, 198, 220, 220, 220, 311, 796, 9104, 40786, 90, 51, 11, 51, 1676, 70, 92, 7, 47, 11, 38, 11, 34, 11, 37, 8, 628, 220, 220, 220, 1041, 70, 796, 4238, 62, 17561, 1756, 7, 51, 1676, 70, 11, 50, 8, 198, 220, 220, 220, 6031, 363, 796, 662, 439, 13369, 7, 51, 11, 51, 1676, 70, 11, 38, 8, 628, 220, 220, 220, 1041, 70, 796, 640, 62, 18908, 1358, 7, 2964, 70, 11, 18683, 363, 11, 50, 8, 198, 220, 220, 220, 1441, 1041, 70, 198, 437, 198 ]
2.077114
402
struct IMDP <: MDP{Float64, Int} end function POMDPs.transition(m::IMDP, s, a) ImplicitDistribution(s, a) do s, a, rng return s + a + rand(rng) end end m = IMDP() td = transition(m, 1.0, 1) @test 2 <= rand(td) <= 3 impldist(m) = ImplicitDistribution(m) do m, rng return rand(rng, m) end @test rand(impldist(Int)) isa Int
[ 7249, 8959, 6322, 1279, 25, 337, 6322, 90, 43879, 2414, 11, 2558, 92, 886, 198, 198, 8818, 350, 2662, 6322, 82, 13, 7645, 653, 7, 76, 3712, 3955, 6322, 11, 264, 11, 257, 8, 198, 220, 220, 220, 34347, 3628, 20344, 3890, 7, 82, 11, 257, 8, 466, 264, 11, 257, 11, 374, 782, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 264, 1343, 257, 1343, 43720, 7, 81, 782, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 76, 796, 8959, 6322, 3419, 198, 198, 8671, 796, 6801, 7, 76, 11, 352, 13, 15, 11, 352, 8, 198, 31, 9288, 362, 19841, 43720, 7, 8671, 8, 19841, 513, 198, 198, 11011, 335, 396, 7, 76, 8, 796, 34347, 3628, 20344, 3890, 7, 76, 8, 466, 285, 11, 374, 782, 198, 220, 220, 220, 1441, 43720, 7, 81, 782, 11, 285, 8, 198, 437, 198, 31, 9288, 43720, 7, 11011, 335, 396, 7, 5317, 4008, 318, 64, 2558, 198 ]
2.142857
161
<reponame>JuliaGaussianProcesses/AbstractGP module AbstractGPs using Distributions using FillArrays using LinearAlgebra using PDMats: AbstractPDMat, ScalMat using Reexport @reexport using KernelFunctions using Random using Statistics using StatsBase using RecipesBase using IrrationalConstants: log2π using KernelFunctions: ColVecs, RowVecs using ChainRulesCore: ChainRulesCore export GP, rand!, mean, cov, var, std, mean_and_cov, mean_and_var, marginals, logpdf, elbo, dtc, posterior, VFE, DTC, update_posterior, LatentGP, ColVecs, RowVecs # Various bits of utility functionality. include("util/common_covmat_ops.jl") # AbstractGP interface. include("abstract_gp.jl") # FiniteGP object that describes the projection of a GP at points x. include("finite_gp_projection.jl") # Basic GP object, e.g. to define the prior. include("mean_function.jl") include("base_gp.jl") # Efficient exact posterior GP implementation. include("exact_gpr_posterior.jl") # Approximate sparse GP inference for Gaussian likelihood. include("sparse_approximations.jl") # LatentGP and LatentFiniteGP objects to accommodate GPs with non-Gaussian likelihoods. include("latent_gp.jl") # Plotting utilities. include("util/plotting.jl") # Testing utilities. include("util/TestUtils.jl") # Deprecations. include("deprecations.jl") end # module
[ 27, 7856, 261, 480, 29, 16980, 544, 35389, 31562, 18709, 274, 14, 23839, 16960, 198, 21412, 27741, 38, 12016, 198, 198, 3500, 46567, 507, 198, 3500, 27845, 3163, 20477, 198, 3500, 44800, 2348, 29230, 198, 3500, 14340, 44, 1381, 25, 27741, 5760, 19044, 11, 34529, 19044, 198, 3500, 797, 39344, 198, 31, 631, 87, 634, 1262, 32169, 24629, 2733, 198, 3500, 14534, 198, 3500, 14370, 198, 3500, 20595, 14881, 198, 3500, 44229, 14881, 198, 3500, 5686, 20310, 34184, 1187, 25, 2604, 17, 46582, 198, 198, 3500, 32169, 24629, 2733, 25, 1623, 53, 721, 82, 11, 11314, 53, 721, 82, 198, 198, 3500, 21853, 37766, 14055, 25, 21853, 37766, 14055, 198, 198, 39344, 14714, 11, 198, 220, 220, 220, 43720, 28265, 198, 220, 220, 220, 1612, 11, 198, 220, 220, 220, 39849, 11, 198, 220, 220, 220, 1401, 11, 198, 220, 220, 220, 14367, 11, 198, 220, 220, 220, 1612, 62, 392, 62, 66, 709, 11, 198, 220, 220, 220, 1612, 62, 392, 62, 7785, 11, 198, 220, 220, 220, 6145, 6897, 11, 198, 220, 220, 220, 2604, 12315, 11, 198, 220, 220, 220, 1288, 2127, 11, 198, 220, 220, 220, 288, 23047, 11, 198, 220, 220, 220, 34319, 11, 198, 220, 220, 220, 569, 15112, 11, 198, 220, 220, 220, 360, 4825, 11, 198, 220, 220, 220, 4296, 62, 79, 6197, 1504, 11, 198, 220, 220, 220, 5476, 298, 16960, 11, 198, 220, 220, 220, 1623, 53, 721, 82, 11, 198, 220, 220, 220, 11314, 53, 721, 82, 198, 198, 2, 26386, 10340, 286, 10361, 11244, 13, 198, 17256, 7203, 22602, 14, 11321, 62, 66, 709, 6759, 62, 2840, 13, 20362, 4943, 198, 198, 2, 27741, 16960, 7071, 13, 198, 17256, 7203, 397, 8709, 62, 31197, 13, 20362, 4943, 198, 198, 2, 4463, 578, 16960, 2134, 326, 8477, 262, 20128, 286, 257, 14714, 379, 2173, 2124, 13, 198, 17256, 7203, 69, 9504, 62, 31197, 62, 16302, 295, 13, 20362, 4943, 198, 198, 2, 14392, 14714, 2134, 11, 304, 13, 70, 13, 284, 8160, 262, 3161, 13, 198, 17256, 7203, 32604, 62, 8818, 13, 20362, 4943, 198, 17256, 7203, 8692, 62, 31197, 13, 20362, 4943, 198, 198, 2, 412, 5632, 2748, 34319, 14714, 7822, 13, 198, 17256, 7203, 1069, 529, 62, 70, 1050, 62, 79, 6197, 1504, 13, 20362, 4943, 198, 198, 2, 2034, 13907, 1920, 29877, 14714, 32278, 329, 12822, 31562, 14955, 13, 198, 17256, 7203, 82, 29572, 62, 1324, 13907, 320, 602, 13, 20362, 4943, 198, 198, 2, 5476, 298, 16960, 290, 5476, 298, 37, 9504, 16960, 5563, 284, 15550, 402, 12016, 351, 1729, 12, 35389, 31562, 14955, 82, 13, 198, 17256, 7203, 15460, 298, 62, 31197, 13, 20362, 4943, 198, 198, 2, 28114, 889, 20081, 13, 198, 17256, 7203, 22602, 14, 29487, 889, 13, 20362, 4943, 198, 198, 2, 23983, 20081, 13, 198, 17256, 7203, 22602, 14, 14402, 18274, 4487, 13, 20362, 4943, 198, 198, 2, 2129, 8344, 602, 13, 198, 17256, 7203, 10378, 8344, 602, 13, 20362, 4943, 198, 198, 437, 1303, 8265, 198 ]
2.814889
497
using Flase, Test world = World( v0 = 1., n_dogs = 120, boxsize = 10.0, motion = BrownianMotion( noise = 0.5, friction = 1.0 ), sheeps = DenseSheeps( 10, n_sheeps = 10, ) ) simulation = FiniteSimulation(; dt = 0.2, end_time = 100.0, world = world, plotter = UnicodePlotter() ) @testset "Move items" begin old_grid = copy(simulation.world.sheeps.grid) @test simulation.time[] < simulation.t_sheep_boredom[] @test Flase.move_sheep!( simulation ) == false simulation.time[] = simulation.t_sheep_boredom[] + 1 @test Flase.move_sheep!( simulation ) == true simulation.time[] = zero( simulation.time[] ) @test old_grid != simulation.world.sheeps.grid end # testset @testset "Interactions" begin pos = simulation.world.dogs.member[3].position @test all(pos .< Flase.getSheepCoords(simulation.world, pos)) end
[ 3500, 1610, 589, 11, 6208, 198, 198, 6894, 796, 2159, 7, 198, 220, 220, 220, 410, 15, 796, 352, 1539, 198, 220, 220, 220, 299, 62, 22242, 796, 7982, 11, 198, 220, 220, 220, 3091, 7857, 796, 838, 13, 15, 11, 198, 220, 220, 220, 6268, 796, 4373, 666, 45740, 7, 198, 220, 220, 220, 220, 220, 220, 220, 7838, 796, 657, 13, 20, 11, 198, 220, 220, 220, 220, 220, 220, 220, 23822, 796, 352, 13, 15, 198, 220, 220, 220, 220, 220, 220, 220, 10612, 198, 220, 220, 220, 15900, 82, 796, 360, 1072, 3347, 25386, 7, 198, 220, 220, 220, 220, 220, 220, 220, 838, 11, 198, 220, 220, 220, 220, 220, 220, 220, 299, 62, 7091, 25386, 796, 838, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 1267, 198, 14323, 1741, 796, 4463, 578, 8890, 1741, 7, 26, 198, 220, 220, 220, 288, 83, 796, 657, 13, 17, 11, 198, 220, 220, 220, 886, 62, 2435, 796, 1802, 13, 15, 11, 198, 220, 220, 220, 995, 796, 995, 11, 198, 220, 220, 220, 7110, 353, 796, 34371, 43328, 353, 3419, 198, 220, 220, 220, 1267, 198, 198, 31, 9288, 2617, 366, 21774, 3709, 1, 2221, 198, 220, 220, 220, 1468, 62, 25928, 796, 4866, 7, 14323, 1741, 13, 6894, 13, 7091, 25386, 13, 25928, 8, 198, 220, 220, 220, 2488, 9288, 18640, 13, 2435, 21737, 1279, 18640, 13, 83, 62, 7091, 538, 62, 65, 1850, 296, 21737, 198, 220, 220, 220, 2488, 9288, 1610, 589, 13, 21084, 62, 7091, 538, 0, 7, 18640, 1267, 6624, 3991, 198, 220, 220, 220, 18640, 13, 2435, 21737, 796, 18640, 13, 83, 62, 7091, 538, 62, 65, 1850, 296, 21737, 1343, 352, 198, 220, 220, 220, 2488, 9288, 1610, 589, 13, 21084, 62, 7091, 538, 0, 7, 18640, 1267, 6624, 2081, 198, 220, 220, 220, 18640, 13, 2435, 21737, 796, 6632, 7, 18640, 13, 2435, 21737, 1267, 198, 220, 220, 220, 2488, 9288, 1468, 62, 25928, 14512, 18640, 13, 6894, 13, 7091, 25386, 13, 25928, 198, 437, 1303, 1332, 2617, 198, 198, 31, 9288, 2617, 366, 9492, 4658, 1, 2221, 198, 220, 220, 220, 1426, 796, 18640, 13, 6894, 13, 22242, 13, 19522, 58, 18, 4083, 9150, 198, 220, 220, 220, 2488, 9288, 477, 7, 1930, 764, 27, 1610, 589, 13, 1136, 3347, 538, 7222, 3669, 7, 14323, 1741, 13, 6894, 11, 1426, 4008, 198, 437, 198 ]
2.315136
403
seed!(12345) function testSortedUniforms(low, high, h, N) function cdf(x::Float64) return x end samples = sampleSortedUniforms(N) ## check that they are sorted first for j in 2:N if samples[j] < samples[j-1] return 0.0 end end i::Int64 = 0 function sampler() i = i + 1 return samples[i] end return testGOFContinuous(cdf, sampler, low, high, h, N) end @test testSortedUniforms(0.01, 0.99, 0.01, 2^21) > 0.01 @test testSortedUniforms(0.02, 0.98, 0.02, 2^10) > 0.01
[ 28826, 0, 7, 10163, 2231, 8, 198, 198, 8818, 1332, 50, 9741, 3118, 6933, 82, 7, 9319, 11, 1029, 11, 289, 11, 399, 8, 198, 220, 2163, 269, 7568, 7, 87, 3712, 43879, 2414, 8, 198, 220, 220, 220, 1441, 2124, 198, 220, 886, 198, 220, 8405, 796, 6291, 50, 9741, 3118, 6933, 82, 7, 45, 8, 198, 220, 22492, 2198, 326, 484, 389, 23243, 717, 198, 220, 329, 474, 287, 362, 25, 45, 198, 220, 220, 220, 611, 8405, 58, 73, 60, 1279, 8405, 58, 73, 12, 16, 60, 198, 220, 220, 220, 220, 220, 1441, 657, 13, 15, 198, 220, 220, 220, 886, 198, 220, 886, 198, 220, 1312, 3712, 5317, 2414, 796, 657, 198, 220, 2163, 6072, 20053, 3419, 198, 220, 220, 220, 1312, 796, 1312, 1343, 352, 198, 220, 220, 220, 1441, 8405, 58, 72, 60, 198, 220, 886, 198, 220, 1441, 1332, 11230, 37, 17875, 5623, 7, 66, 7568, 11, 6072, 20053, 11, 1877, 11, 1029, 11, 289, 11, 399, 8, 198, 437, 198, 198, 31, 9288, 1332, 50, 9741, 3118, 6933, 82, 7, 15, 13, 486, 11, 657, 13, 2079, 11, 657, 13, 486, 11, 362, 61, 2481, 8, 1875, 657, 13, 486, 198, 31, 9288, 1332, 50, 9741, 3118, 6933, 82, 7, 15, 13, 2999, 11, 657, 13, 4089, 11, 657, 13, 2999, 11, 362, 61, 940, 8, 1875, 657, 13, 486, 198 ]
2.221739
230
<gh_stars>1-10 using ITensors using KrylovKit using Random: seed! seed!(1234) struct TransferMatrix A::ITensor end function (T::TransferMatrix)(v::ITensor) A = addtags(T.A, "ket"; tags = "Link") Adag = addtags(dag(T.A), "bra"; tags = "Link") return noprime(A * v * Adag) end χ = 10 d = 2 l = Index(χ, "Link") s = Index(d, "Site") A = randomITensor(dag(l)', s, l) T = TransferMatrix(A) b = randomITensor(addtags(dag(l), "bra"), addtags(l, "ket")) b += swaptags(dag(b), "bra", "ket") # Solve Tx = b x, con = linsolve(T, b; krylovdim = 80, tol = 1e-4) @show con @show norm(T(x) - b)
[ 27, 456, 62, 30783, 29, 16, 12, 940, 198, 3500, 7283, 641, 669, 198, 3500, 41662, 27086, 20827, 198, 3500, 14534, 25, 9403, 0, 198, 198, 28826, 0, 7, 1065, 2682, 8, 198, 198, 7249, 20558, 46912, 198, 220, 317, 3712, 2043, 22854, 198, 437, 198, 198, 8818, 357, 51, 3712, 43260, 46912, 5769, 85, 3712, 2043, 22854, 8, 198, 220, 317, 796, 751, 31499, 7, 51, 13, 32, 11, 366, 7126, 8172, 15940, 796, 366, 11280, 4943, 198, 220, 1215, 363, 796, 751, 31499, 7, 67, 363, 7, 51, 13, 32, 828, 366, 16057, 8172, 15940, 796, 366, 11280, 4943, 198, 220, 1441, 299, 404, 81, 524, 7, 32, 1635, 410, 1635, 1215, 363, 8, 198, 437, 198, 198, 139, 229, 796, 838, 198, 67, 796, 362, 198, 198, 75, 796, 12901, 7, 139, 229, 11, 366, 11280, 4943, 198, 82, 796, 12901, 7, 67, 11, 366, 29123, 4943, 198, 198, 32, 796, 4738, 2043, 22854, 7, 67, 363, 7, 75, 8, 3256, 264, 11, 300, 8, 198, 198, 51, 796, 20558, 46912, 7, 32, 8, 198, 65, 796, 4738, 2043, 22854, 7, 2860, 31499, 7, 67, 363, 7, 75, 828, 366, 16057, 12340, 751, 31499, 7, 75, 11, 366, 7126, 48774, 198, 65, 15853, 1509, 2373, 3775, 7, 67, 363, 7, 65, 828, 366, 16057, 1600, 366, 7126, 4943, 198, 198, 2, 4294, 303, 309, 87, 796, 275, 198, 87, 11, 369, 796, 300, 1040, 6442, 7, 51, 11, 275, 26, 479, 563, 27086, 27740, 796, 4019, 11, 284, 75, 796, 352, 68, 12, 19, 8, 198, 198, 31, 12860, 369, 198, 198, 31, 12860, 2593, 7, 51, 7, 87, 8, 532, 275, 8, 628 ]
2.162455
277
## ----------- Linear GradRule # Defined by probGrad(h = hMin), which varies by college, and hMax where probGrad hits max (common to all colleges). """ $(SIGNATURES) Switches for linear graduation rule. It can operate on h levels or gains. On h levels: Grad prob is linear in h between hMin and hMax. Each college has a calibrated values for prob grad(h = hMin). On h gains: Grad prob is linear in (h - h0). Each college has a calibrated value for prob grad(h gain = hMin) """ Base.@kwdef mutable struct GradRuleSwitchesLinear <: GradRuleSwitches tFirstGrad :: TimeInt = 4 "Number of courses required for graduation" minNcForGrad :: ncInt = 40 "Number of 2 year colleges (cannot graduate from those)" n2Year :: ncInt = 1 "Number of colleges" nColleges :: ncInt = 4 # Min and max grad prob when graduation is feasible. gradProbMin :: Double = 0.05 gradProbMax :: Double = 0.95 # Grad prob depends on levels or gains useHcLevel :: Bool = true # Does grad rule vary by college byCollege :: Bool = true # h level (or h-h0 value) for which min grad prob is reached. hMin :: Double = 2.0 # Are better colleges harder (or the other way around)? betterHarder :: Bool = true end Base.@kwdef mutable struct GradRuleSetLinear <: GradRuleSet @grad_rule_set_common # Grad prob at h = hMin (or h-h0 = 0) probHminV :: BoundedVector{Double} # h level (or h-h0) for which min grad prob is reached. hMin :: Double # h (or h - h0) at which gradProbMax is reached (the same for all colleges) hMax :: Double switches :: GradRuleSwitchesLinear end ## For one college struct GradRuleLinear <: GradRule # Can graduate after at least this many years tFirstGrad :: TimeInt # Grad prob at h = hMin or at (h-h0) = hMin probHmin :: Double # h level (or h-h0) for which min grad prob is reached. hMin :: Double # Grad prob reaches max at h = hMax (or at h - h0 = hMax) hMax :: Double gradProbMin :: Double gradProbMax :: Double # Min no of courses attempted (cumulative) nMin :: ncInt useHcLevel :: Bool end function Base.show(io :: IO, g :: GradRuleLinear) print(io, "Linear graduation rule in") if use_hc_level(g) print(io, " h levels. "); else print(io, " h gains. "); end print(io, "hMin = $(h_min(g)), hMax = $(h_max(g))"); end """ $(SIGNATURES) Table with settings. Columns are explanation and values. All formatted into strings. """ function settings_table(gs :: GradRuleSwitchesLinear) nc = n_colleges(gs); tFirstGrad = Int(t_first_grad(gs, nc)); minNcToGrad = Int(min_courses_to_grad(gs, nc; modelUnits = false)); harderStr = gs.betterHarder ? "harder" : "easier"; return [ "Graduation rule" "Linear in h"; "Time to graduation" "$tFirstGrad"; "Min courses for graduation" "$minNcToGrad"; "Better colleges are" harderStr ] end function settings_list(gs :: GradRuleSwitchesLinear, st) nc = n_colleges(gs); tFirstGrad = symbol_entry(st, :tGradMin, Int(t_first_grad(gs, nc))); minNcToGrad = symbol_entry(st, :nGrad, Int(min_courses_to_grad(gs, nc; modelUnits = false))); probGradMin = symbol_entry(st, :probGradMin, grad_prob_min(gs)); probGradMax = symbol_entry(st, :probGradMax, grad_prob_max(gs)); return [tFirstGrad, minNcToGrad, probGradMin, probGradMax] end use_hc_level(switches :: GradRuleSwitchesLinear) = switches.useHcLevel; h_min(switches :: GradRuleSwitchesLinear) = switches.hMin; h_min(gs :: GradRuleSetLinear) = h_min(gs.switches); h_min(g :: GradRuleLinear) = g.hMin; h_max(gs :: GradRuleSetLinear) = gs.hMax; h_max(g :: GradRuleLinear) = g.hMax; grad_colleges(gs :: GradRuleSetLinear) = grad_colleges(gs.switches); grad_prob_hmin(g :: GradRuleLinear) = g.probHmin; varies_by_college(switches :: GradRuleSwitchesLinear) = switches.byCollege; grad_rule_same!(switches :: GradRuleSwitchesLinear) = switches.byCollege = false; better_easier!(switches :: GradRuleSwitchesLinear) = switches.betterHarder = false; """ $(SIGNATURES) For all colleges. Assumes college 1 is a 2 year college. Others are 4 year colleges. """ function make_grad_rule_set(objId :: ObjectId, grSwitches :: GradRuleSwitchesLinear) pProbHmin = init_prob_hmin(objId, grSwitches); hMin = h_min(grSwitches); if use_hc_level(grSwitches) hMax = Double(4.0); pHRatio = Param(:hMax, ldescription(:hGradMax), lsymbol(:hGradMax), hMax, hMax, hMin + Double(1.0), hMin + Double(6.0), true); else # Change in h at which grad prob hits max lb = hMin + Double(0.2); hMax = lb + Double(0.8); pHRatio = Param(:hMax, ldescription(:dhGradMax), lsymbol(:dhGradMax), hMax, hMax, lb, Double(5.0), true); end pvec = ParamVector(objId, [pHRatio]); gs = GradRuleSetLinear(objId = objId, hMin = hMin, hMax = hMax, probHminV = pProbHmin, switches = grSwitches, pvec = pvec); @assert validate_grad_set(gs) return gs end function validate_grad_set(gr :: GradRuleSetLinear) isValid = (n_colleges(gr) > 1); if any(grad_prob_at_hmin(gr) .>= gr.switches.gradProbMax) isValid = false; @warn "Grad prob at hMin > gradProbMax in $gr" end return isValid end # Only for colleges that produce graduates. # Must be less than gradProbMax function init_prob_hmin(parentId :: ObjectId, grSwitches :: GradRuleSwitchesLinear) objId = make_child_id(parentId, :probHminV); if varies_by_college(grSwitches) nc = length(grad_colleges(grSwitches)); else # The same grad prob at hMin for all colleges. nc = 1; end # The Bool argument implies a decreasing vector pMax = grSwitches.gradProbMax - 0.05; # The Bool argument means that better colleges are harder or easier if grSwitches.betterHarder slope = :decreasing; else slope = :increasing; # should be :nonmonotone ++++++ end p = BoundedVector(objId, ParamVector(objId), slope, zero(Double), pMax, fill(Double(0.5), nc)); set_pvector!(p; description = ldescription(:probHminV), symbol = lsymbol(:probHminV)); return p end function grad_prob_at_hmin(gs :: GradRuleSetLinear, ic :: Integer) if can_graduate(gs, ic) if varies_by_college(gs) # Index into list of colleges that can graduate (also into values of probH1V) gIdx = findfirst(grad_colleges(gs) .== ic); else # There is only one value to retrieve. The same for all colleges. gIdx = 1; end probH1 = ModelParams.values(gs.probHminV, gIdx); else probH1 = zero(Double); end return probH1 end grad_prob_at_hmin(gs :: GradRuleSetLinear) = [grad_prob_at_hmin(gs, ic) for ic = 1 : n_colleges(gs)]; """ $(SIGNATURES) Make grad rule for one college """ function make_grad_rule(gs :: GradRuleSetLinear, iCollege :: Integer) probHmin = grad_prob_at_hmin(gs, iCollege); g = GradRuleLinear(t_first_grad(gs, iCollege), probHmin, h_min(gs), h_max(gs), grad_prob_min(gs), grad_prob_max(gs), min_courses_to_grad(gs, iCollege), use_hc_level(gs)); @assert validate_gr(g) "Invalid $g" return g end # function make_test_grad_rule(switches :: GradRuleSwitchesLinear) # return GradRuleLinear(t_first_grad(switches, 3), Double(0.5), # h_min(switches), Double(4.0), # switches.gradProbMin, switches.gradProbMax, switches.minNcForGrad, # use_hc_level(switches)) # end function validate_gr(g :: GradRuleLinear) isValid = true; if h_min(g) > h_max(g) isValid = false; @warn "h_min = $(h_min(g)) > h_max = $(h_max(g))" end return isValid end ## Graduation probability at end of t # One state function grad_prob(g :: GradRuleLinear, t :: Integer, h :: Double, n :: T1, h0 :: Double) where T1 <: Integer if can_graduate(g, t) if n >= min_courses_to_grad(g, t) if use_hc_level(g) # At h = 1: g.probH1. Then linear in up to g.hMax. dh = h - h_min(g); dhMax = h_max(g) - h_min(g); else # At dh = 0: g.probH1. Then linear in dh up to g.hMax. dh = h - h0 - h_min(g); dhMax = h_max(g) - h_min(g); end @assert dhMax > 0.0 "Negative dhMax: $dhMax in $g" dProb = g.gradProbMax - grad_prob_hmin(g); @assert dProb > 0.01 "Invalid dProb: $dProb" gProb = grad_prob_hmin(g) + dh / dhMax * dProb; gProb = min(g.gradProbMax, max(g.gradProbMin, gProb)); else gProb = zero(Double); end else gProb = zero(Double); end return gProb end # -----------------
[ 2235, 24200, 6329, 44800, 17701, 31929, 198, 2, 2896, 1389, 416, 1861, 42731, 7, 71, 796, 289, 9452, 828, 543, 17806, 416, 4152, 11, 290, 289, 11518, 810, 1861, 42731, 7127, 3509, 357, 11321, 284, 477, 15273, 737, 198, 198, 37811, 198, 197, 3, 7, 46224, 47471, 8, 198, 198, 10462, 9249, 329, 14174, 21571, 3896, 13, 632, 460, 8076, 319, 289, 2974, 393, 8810, 13, 198, 198, 2202, 289, 2974, 25, 17701, 1861, 318, 14174, 287, 289, 1022, 289, 9452, 290, 289, 11518, 13, 5501, 4152, 468, 257, 48050, 3815, 329, 1861, 3915, 7, 71, 796, 289, 9452, 737, 198, 198, 2202, 289, 8810, 25, 17701, 1861, 318, 14174, 287, 357, 71, 532, 289, 15, 737, 5501, 4152, 468, 257, 48050, 1988, 329, 1861, 3915, 7, 71, 4461, 796, 289, 9452, 8, 198, 37811, 198, 14881, 13, 31, 46265, 4299, 4517, 540, 2878, 17701, 31929, 10462, 9249, 14993, 451, 1279, 25, 17701, 31929, 10462, 9249, 198, 220, 220, 220, 256, 5962, 42731, 7904, 3862, 5317, 796, 604, 198, 220, 220, 220, 366, 15057, 286, 10902, 2672, 329, 21571, 1, 198, 220, 220, 220, 949, 45, 66, 1890, 42731, 7904, 299, 66, 5317, 796, 2319, 198, 220, 220, 220, 366, 15057, 286, 362, 614, 15273, 357, 66, 34574, 10428, 422, 883, 16725, 198, 220, 220, 220, 299, 17, 17688, 7904, 299, 66, 5317, 796, 352, 198, 220, 220, 220, 366, 15057, 286, 15273, 1, 198, 220, 220, 220, 299, 5216, 1455, 274, 7904, 299, 66, 5317, 796, 604, 198, 220, 220, 220, 1303, 1855, 290, 3509, 3915, 1861, 618, 21571, 318, 23498, 13, 220, 198, 220, 220, 220, 3915, 2964, 65, 9452, 7904, 11198, 796, 657, 13, 2713, 198, 220, 220, 220, 3915, 2964, 65, 11518, 7904, 11198, 796, 657, 13, 3865, 198, 220, 220, 220, 1303, 17701, 1861, 8338, 319, 2974, 393, 8810, 198, 220, 220, 220, 779, 39, 66, 4971, 7904, 347, 970, 796, 2081, 198, 220, 220, 220, 1303, 8314, 3915, 3896, 7565, 416, 4152, 198, 220, 220, 220, 416, 38951, 7904, 347, 970, 796, 2081, 628, 220, 220, 220, 1303, 289, 1241, 357, 273, 289, 12, 71, 15, 1988, 8, 329, 543, 949, 3915, 1861, 318, 4251, 13, 220, 198, 220, 220, 220, 289, 9452, 7904, 11198, 796, 362, 13, 15, 198, 220, 220, 220, 1303, 4231, 1365, 15273, 7069, 357, 273, 262, 584, 835, 1088, 19427, 198, 220, 220, 220, 1365, 17309, 263, 7904, 347, 970, 796, 2081, 198, 437, 628, 198, 14881, 13, 31, 46265, 4299, 4517, 540, 2878, 17701, 31929, 7248, 14993, 451, 1279, 25, 17701, 31929, 7248, 198, 220, 220, 220, 2488, 9744, 62, 25135, 62, 2617, 62, 11321, 198, 220, 220, 220, 1303, 17701, 1861, 379, 289, 796, 289, 9452, 357, 273, 289, 12, 71, 15, 796, 657, 8, 198, 220, 220, 220, 1861, 39, 1084, 53, 7904, 347, 6302, 38469, 90, 25628, 92, 198, 220, 220, 220, 1303, 289, 1241, 357, 273, 289, 12, 71, 15, 8, 329, 543, 949, 3915, 1861, 318, 4251, 13, 220, 198, 220, 220, 220, 289, 9452, 7904, 11198, 220, 198, 220, 220, 220, 1303, 289, 357, 273, 289, 532, 289, 15, 8, 379, 543, 3915, 2964, 65, 11518, 318, 4251, 357, 1169, 976, 329, 477, 15273, 8, 198, 220, 220, 220, 289, 11518, 7904, 11198, 198, 220, 220, 220, 18225, 7904, 17701, 31929, 10462, 9249, 14993, 451, 198, 437, 628, 198, 2235, 1114, 530, 4152, 198, 7249, 17701, 31929, 14993, 451, 1279, 25, 17701, 31929, 198, 220, 220, 220, 1303, 1680, 10428, 706, 379, 1551, 428, 867, 812, 198, 220, 220, 220, 256, 5962, 42731, 7904, 3862, 5317, 198, 220, 220, 220, 1303, 17701, 1861, 379, 289, 796, 289, 9452, 220, 393, 379, 357, 71, 12, 71, 15, 8, 796, 289, 9452, 198, 220, 220, 220, 1861, 39, 1084, 7904, 11198, 198, 220, 220, 220, 1303, 289, 1241, 357, 273, 289, 12, 71, 15, 8, 329, 543, 949, 3915, 1861, 318, 4251, 13, 220, 198, 220, 220, 220, 289, 9452, 7904, 11198, 198, 220, 220, 220, 1303, 17701, 1861, 12229, 3509, 379, 289, 796, 289, 11518, 357, 273, 379, 289, 532, 289, 15, 796, 289, 11518, 8, 198, 220, 220, 220, 289, 11518, 7904, 11198, 198, 220, 220, 220, 3915, 2964, 65, 9452, 7904, 11198, 198, 220, 220, 220, 3915, 2964, 65, 11518, 7904, 11198, 198, 220, 220, 220, 1303, 1855, 645, 286, 10902, 7482, 357, 36340, 13628, 8, 198, 220, 220, 220, 299, 9452, 7904, 299, 66, 5317, 198, 220, 220, 220, 779, 39, 66, 4971, 7904, 347, 970, 198, 437, 628, 628, 198, 8818, 7308, 13, 12860, 7, 952, 7904, 24418, 11, 308, 7904, 17701, 31929, 14993, 451, 8, 198, 220, 220, 220, 3601, 7, 952, 11, 366, 14993, 451, 21571, 3896, 287, 4943, 198, 220, 220, 220, 611, 779, 62, 71, 66, 62, 5715, 7, 70, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 952, 11, 366, 289, 2974, 13, 366, 1776, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 952, 11, 366, 289, 8810, 13, 366, 1776, 198, 220, 220, 220, 886, 198, 220, 220, 220, 3601, 7, 952, 11, 366, 71, 9452, 796, 29568, 71, 62, 1084, 7, 70, 36911, 289, 11518, 796, 29568, 71, 62, 9806, 7, 70, 4008, 15341, 198, 437, 628, 198, 37811, 198, 197, 3, 7, 46224, 47471, 8, 198, 198, 10962, 351, 6460, 13, 29201, 82, 389, 7468, 290, 3815, 13, 198, 3237, 39559, 656, 13042, 13, 198, 37811, 198, 8818, 6460, 62, 11487, 7, 14542, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 198, 220, 220, 220, 299, 66, 796, 299, 62, 4033, 1455, 274, 7, 14542, 1776, 198, 220, 220, 220, 256, 5962, 42731, 796, 2558, 7, 83, 62, 11085, 62, 9744, 7, 14542, 11, 299, 66, 18125, 198, 220, 220, 220, 949, 45, 66, 2514, 42731, 796, 2558, 7, 1084, 62, 66, 39975, 62, 1462, 62, 9744, 7, 14542, 11, 299, 66, 26, 2746, 3118, 896, 796, 3991, 18125, 198, 220, 220, 220, 7069, 13290, 796, 308, 82, 13, 27903, 17309, 263, 220, 5633, 220, 366, 10424, 263, 1, 220, 1058, 220, 366, 30412, 959, 8172, 198, 220, 220, 220, 1441, 685, 198, 220, 220, 220, 220, 220, 220, 220, 366, 42731, 2288, 3896, 1, 220, 366, 14993, 451, 287, 289, 8172, 198, 220, 220, 220, 220, 220, 220, 220, 366, 7575, 284, 21571, 1, 220, 17971, 83, 5962, 42731, 8172, 198, 220, 220, 220, 220, 220, 220, 220, 366, 9452, 10902, 329, 21571, 1, 220, 17971, 1084, 45, 66, 2514, 42731, 8172, 198, 220, 220, 220, 220, 220, 220, 220, 366, 28971, 15273, 389, 1, 220, 7069, 13290, 198, 220, 220, 220, 2361, 198, 437, 198, 198, 8818, 6460, 62, 4868, 7, 14542, 7904, 17701, 31929, 10462, 9249, 14993, 451, 11, 336, 8, 198, 220, 220, 220, 299, 66, 796, 299, 62, 4033, 1455, 274, 7, 14542, 1776, 198, 220, 220, 220, 256, 5962, 42731, 796, 220, 6194, 62, 13000, 7, 301, 11, 1058, 83, 42731, 9452, 11, 2558, 7, 83, 62, 11085, 62, 9744, 7, 14542, 11, 299, 66, 4008, 1776, 198, 220, 220, 220, 949, 45, 66, 2514, 42731, 796, 6194, 62, 13000, 7, 301, 11, 1058, 77, 42731, 11, 2558, 7, 1084, 62, 66, 39975, 62, 1462, 62, 9744, 7, 14542, 11, 299, 66, 26, 2746, 3118, 896, 796, 3991, 4008, 1776, 198, 220, 220, 220, 1861, 42731, 9452, 796, 6194, 62, 13000, 7, 301, 11, 1058, 1676, 65, 42731, 9452, 11, 3915, 62, 1676, 65, 62, 1084, 7, 14542, 18125, 198, 220, 220, 220, 1861, 42731, 11518, 796, 6194, 62, 13000, 7, 301, 11, 1058, 1676, 65, 42731, 11518, 11, 3915, 62, 1676, 65, 62, 9806, 7, 14542, 18125, 198, 220, 220, 220, 1441, 685, 83, 5962, 42731, 11, 949, 45, 66, 2514, 42731, 11, 1861, 42731, 9452, 11, 1861, 42731, 11518, 60, 198, 437, 628, 198, 1904, 62, 71, 66, 62, 5715, 7, 2032, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 796, 198, 220, 220, 220, 18225, 13, 1904, 39, 66, 4971, 26, 198, 198, 71, 62, 1084, 7, 2032, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 796, 18225, 13, 71, 9452, 26, 198, 71, 62, 1084, 7, 14542, 7904, 17701, 31929, 7248, 14993, 451, 8, 796, 289, 62, 1084, 7, 14542, 13, 2032, 9249, 1776, 198, 71, 62, 1084, 7, 70, 7904, 17701, 31929, 14993, 451, 8, 796, 308, 13, 71, 9452, 26, 198, 198, 71, 62, 9806, 7, 14542, 7904, 17701, 31929, 7248, 14993, 451, 8, 796, 308, 82, 13, 71, 11518, 26, 198, 71, 62, 9806, 7, 70, 7904, 17701, 31929, 14993, 451, 8, 796, 308, 13, 71, 11518, 26, 198, 198, 9744, 62, 4033, 1455, 274, 7, 14542, 7904, 17701, 31929, 7248, 14993, 451, 8, 796, 3915, 62, 4033, 1455, 274, 7, 14542, 13, 2032, 9249, 1776, 198, 198, 9744, 62, 1676, 65, 62, 71, 1084, 7, 70, 7904, 17701, 31929, 14993, 451, 8, 796, 308, 13, 1676, 65, 39, 1084, 26, 198, 198, 85, 3166, 62, 1525, 62, 44107, 7, 2032, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 796, 220, 198, 220, 220, 220, 18225, 13, 1525, 38951, 26, 198, 9744, 62, 25135, 62, 31642, 0, 7, 2032, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 796, 198, 220, 220, 220, 18225, 13, 1525, 38951, 796, 3991, 26, 198, 198, 27903, 62, 30412, 959, 0, 7, 2032, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 796, 220, 198, 220, 220, 220, 18225, 13, 27903, 17309, 263, 796, 3991, 26, 628, 198, 37811, 198, 197, 3, 7, 46224, 47471, 8, 198, 198, 1890, 477, 15273, 13, 198, 8021, 8139, 4152, 352, 318, 257, 362, 614, 4152, 13, 12691, 389, 604, 614, 15273, 13, 198, 37811, 198, 8818, 787, 62, 9744, 62, 25135, 62, 2617, 7, 26801, 7390, 7904, 9515, 7390, 11, 220, 220, 198, 220, 220, 220, 1036, 10462, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 628, 220, 220, 220, 279, 2964, 65, 39, 1084, 796, 2315, 62, 1676, 65, 62, 71, 1084, 7, 26801, 7390, 11, 1036, 10462, 9249, 1776, 198, 220, 220, 220, 289, 9452, 796, 289, 62, 1084, 7, 2164, 10462, 9249, 1776, 628, 220, 220, 220, 611, 779, 62, 71, 66, 62, 5715, 7, 2164, 10462, 9249, 8, 198, 220, 220, 220, 220, 220, 220, 220, 289, 11518, 796, 11198, 7, 19, 13, 15, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 279, 17184, 39485, 796, 25139, 7, 25, 71, 11518, 11, 300, 11213, 7, 25, 71, 42731, 11518, 828, 300, 1837, 23650, 7, 25, 71, 42731, 11518, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 11518, 11, 289, 11518, 11, 289, 9452, 1343, 11198, 7, 16, 13, 15, 828, 289, 9452, 1343, 11198, 7, 21, 13, 15, 828, 2081, 1776, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 9794, 287, 289, 379, 543, 3915, 1861, 7127, 3509, 198, 220, 220, 220, 220, 220, 220, 220, 18360, 796, 289, 9452, 1343, 11198, 7, 15, 13, 17, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 289, 11518, 796, 18360, 1343, 11198, 7, 15, 13, 23, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 279, 17184, 39485, 796, 25139, 7, 25, 71, 11518, 11, 300, 11213, 7, 25, 34985, 42731, 11518, 828, 300, 1837, 23650, 7, 25, 34985, 42731, 11518, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 11518, 11, 289, 11518, 11, 18360, 11, 11198, 7, 20, 13, 15, 828, 2081, 1776, 198, 220, 220, 220, 886, 628, 220, 220, 220, 279, 35138, 796, 25139, 38469, 7, 26801, 7390, 11, 220, 685, 79, 17184, 39485, 36563, 198, 220, 220, 220, 308, 82, 796, 17701, 31929, 7248, 14993, 451, 7, 26801, 7390, 796, 26181, 7390, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 289, 9452, 796, 289, 9452, 11, 289, 11518, 796, 289, 11518, 11, 1861, 39, 1084, 53, 796, 279, 2964, 65, 39, 1084, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 18225, 796, 1036, 10462, 9249, 11, 279, 35138, 796, 279, 35138, 1776, 198, 220, 220, 220, 2488, 30493, 26571, 62, 9744, 62, 2617, 7, 14542, 8, 198, 220, 220, 220, 1441, 308, 82, 198, 437, 628, 198, 8818, 26571, 62, 9744, 62, 2617, 7, 2164, 7904, 17701, 31929, 7248, 14993, 451, 8, 198, 220, 220, 220, 318, 47139, 796, 357, 77, 62, 4033, 1455, 274, 7, 2164, 8, 1875, 352, 1776, 198, 220, 220, 220, 611, 597, 7, 9744, 62, 1676, 65, 62, 265, 62, 71, 1084, 7, 2164, 8, 764, 29, 28, 1036, 13, 2032, 9249, 13, 9744, 2964, 65, 11518, 8, 198, 220, 220, 220, 220, 220, 220, 220, 318, 47139, 796, 3991, 26, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 40539, 366, 42731, 1861, 379, 289, 9452, 1875, 3915, 2964, 65, 11518, 287, 720, 2164, 1, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 318, 47139, 198, 437, 628, 198, 198, 2, 5514, 329, 15273, 326, 4439, 19087, 13, 198, 2, 12039, 307, 1342, 621, 3915, 2964, 65, 11518, 198, 8818, 2315, 62, 1676, 65, 62, 71, 1084, 7, 8000, 7390, 7904, 9515, 7390, 11, 220, 198, 220, 220, 220, 1036, 10462, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 628, 220, 220, 220, 26181, 7390, 796, 787, 62, 9410, 62, 312, 7, 8000, 7390, 11, 1058, 1676, 65, 39, 1084, 53, 1776, 198, 220, 220, 220, 611, 17806, 62, 1525, 62, 44107, 7, 2164, 10462, 9249, 8, 198, 220, 220, 220, 220, 220, 220, 220, 299, 66, 796, 4129, 7, 9744, 62, 4033, 1455, 274, 7, 2164, 10462, 9249, 18125, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 383, 976, 3915, 1861, 379, 289, 9452, 329, 477, 15273, 13, 198, 220, 220, 220, 220, 220, 220, 220, 299, 66, 796, 352, 26, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1303, 383, 347, 970, 4578, 15565, 257, 24030, 15879, 198, 220, 220, 220, 279, 11518, 796, 1036, 10462, 9249, 13, 9744, 2964, 65, 11518, 532, 657, 13, 2713, 26, 198, 220, 220, 220, 1303, 383, 347, 970, 4578, 1724, 326, 1365, 15273, 389, 7069, 393, 4577, 198, 220, 220, 220, 611, 1036, 10462, 9249, 13, 27903, 17309, 263, 198, 220, 220, 220, 220, 220, 220, 220, 22638, 796, 1058, 12501, 260, 2313, 26, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 22638, 796, 1058, 42647, 26, 220, 1303, 815, 307, 1058, 13159, 2144, 313, 505, 1343, 14030, 10, 198, 220, 220, 220, 886, 198, 220, 220, 220, 279, 796, 347, 6302, 38469, 7, 26801, 7390, 11, 25139, 38469, 7, 26801, 7390, 828, 220, 198, 220, 220, 220, 220, 220, 220, 220, 22638, 11, 198, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 25628, 828, 279, 11518, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 6070, 7, 25628, 7, 15, 13, 20, 828, 299, 66, 18125, 198, 220, 220, 220, 900, 62, 79, 31364, 0, 7, 79, 26, 6764, 796, 300, 11213, 7, 25, 1676, 65, 39, 1084, 53, 828, 220, 198, 220, 220, 220, 220, 220, 220, 220, 6194, 796, 300, 1837, 23650, 7, 25, 1676, 65, 39, 1084, 53, 18125, 198, 220, 220, 220, 1441, 279, 198, 437, 198, 198, 8818, 3915, 62, 1676, 65, 62, 265, 62, 71, 1084, 7, 14542, 7904, 17701, 31929, 7248, 14993, 451, 11, 14158, 7904, 34142, 8, 198, 220, 220, 220, 611, 460, 62, 17680, 7, 14542, 11, 14158, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 17806, 62, 1525, 62, 44107, 7, 14542, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 12901, 656, 1351, 286, 15273, 326, 460, 10428, 357, 14508, 656, 3815, 286, 1861, 39, 16, 53, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 308, 7390, 87, 796, 1064, 11085, 7, 9744, 62, 4033, 1455, 274, 7, 14542, 8, 764, 855, 14158, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1318, 318, 691, 530, 1988, 284, 19818, 13, 383, 976, 329, 477, 15273, 13, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 308, 7390, 87, 796, 352, 26, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1861, 39, 16, 796, 9104, 10044, 4105, 13, 27160, 7, 14542, 13, 1676, 65, 39, 1084, 53, 11, 308, 7390, 87, 1776, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 1861, 39, 16, 796, 6632, 7, 25628, 1776, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 1861, 39, 16, 198, 437, 198, 198, 9744, 62, 1676, 65, 62, 265, 62, 71, 1084, 7, 14542, 7904, 17701, 31929, 7248, 14993, 451, 8, 796, 220, 198, 220, 220, 220, 685, 9744, 62, 1676, 65, 62, 265, 62, 71, 1084, 7, 14542, 11, 14158, 8, 220, 329, 14158, 796, 352, 1058, 299, 62, 4033, 1455, 274, 7, 14542, 8, 11208, 628, 198, 37811, 198, 197, 3, 7, 46224, 47471, 8, 198, 198, 12050, 3915, 3896, 329, 530, 4152, 198, 37811, 198, 8818, 787, 62, 9744, 62, 25135, 7, 14542, 7904, 17701, 31929, 7248, 14993, 451, 11, 1312, 38951, 7904, 34142, 8, 198, 220, 220, 220, 1861, 39, 1084, 796, 3915, 62, 1676, 65, 62, 265, 62, 71, 1084, 7, 14542, 11, 1312, 38951, 1776, 198, 220, 220, 220, 308, 796, 17701, 31929, 14993, 451, 7, 83, 62, 11085, 62, 9744, 7, 14542, 11, 1312, 38951, 828, 198, 220, 220, 220, 220, 220, 220, 220, 1861, 39, 1084, 11, 289, 62, 1084, 7, 14542, 828, 289, 62, 9806, 7, 14542, 828, 3915, 62, 1676, 65, 62, 1084, 7, 14542, 828, 3915, 62, 1676, 65, 62, 9806, 7, 14542, 828, 198, 220, 220, 220, 220, 220, 220, 220, 949, 62, 66, 39975, 62, 1462, 62, 9744, 7, 14542, 11, 1312, 38951, 828, 198, 220, 220, 220, 220, 220, 220, 220, 779, 62, 71, 66, 62, 5715, 7, 14542, 18125, 198, 220, 220, 220, 2488, 30493, 26571, 62, 2164, 7, 70, 8, 220, 366, 44651, 720, 70, 1, 198, 220, 220, 220, 1441, 308, 198, 437, 198, 198, 2, 2163, 787, 62, 9288, 62, 9744, 62, 25135, 7, 2032, 9249, 7904, 17701, 31929, 10462, 9249, 14993, 451, 8, 198, 2, 220, 220, 220, 220, 1441, 17701, 31929, 14993, 451, 7, 83, 62, 11085, 62, 9744, 7, 2032, 9249, 11, 513, 828, 11198, 7, 15, 13, 20, 828, 220, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 289, 62, 1084, 7, 2032, 9249, 828, 11198, 7, 19, 13, 15, 828, 220, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 18225, 13, 9744, 2964, 65, 9452, 11, 18225, 13, 9744, 2964, 65, 11518, 11, 18225, 13, 1084, 45, 66, 1890, 42731, 11, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 779, 62, 71, 66, 62, 5715, 7, 2032, 9249, 4008, 198, 2, 886, 628, 198, 8818, 26571, 62, 2164, 7, 70, 7904, 17701, 31929, 14993, 451, 8, 198, 220, 220, 220, 318, 47139, 796, 2081, 26, 198, 220, 220, 220, 611, 289, 62, 1084, 7, 70, 8, 1875, 289, 62, 9806, 7, 70, 8, 198, 220, 220, 220, 220, 220, 220, 220, 318, 47139, 796, 3991, 26, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 40539, 366, 71, 62, 1084, 796, 29568, 71, 62, 1084, 7, 70, 4008, 1875, 289, 62, 9806, 796, 29568, 71, 62, 9806, 7, 70, 4008, 1, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 318, 47139, 198, 437, 628, 198, 2235, 17701, 2288, 12867, 379, 886, 286, 256, 198, 2, 1881, 1181, 198, 8818, 3915, 62, 1676, 65, 7, 70, 7904, 17701, 31929, 14993, 451, 11, 256, 7904, 34142, 11, 289, 7904, 11198, 11, 299, 7904, 309, 16, 11, 198, 220, 220, 220, 289, 15, 7904, 11198, 8, 810, 309, 16, 1279, 25, 34142, 628, 220, 220, 220, 611, 460, 62, 17680, 7, 70, 11, 256, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 299, 18189, 949, 62, 66, 39975, 62, 1462, 62, 9744, 7, 70, 11, 256, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 779, 62, 71, 66, 62, 5715, 7, 70, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1629, 289, 796, 352, 25, 308, 13, 1676, 65, 39, 16, 13, 3244, 14174, 287, 510, 284, 308, 13, 71, 11518, 13, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 34590, 796, 289, 532, 289, 62, 1084, 7, 70, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 34590, 11518, 796, 289, 62, 9806, 7, 70, 8, 532, 289, 62, 1084, 7, 70, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2073, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1629, 34590, 796, 657, 25, 308, 13, 1676, 65, 39, 16, 13, 3244, 14174, 287, 34590, 510, 284, 308, 13, 71, 11518, 13, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 34590, 796, 289, 532, 289, 15, 532, 289, 62, 1084, 7, 70, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 34590, 11518, 796, 289, 62, 9806, 7, 70, 8, 532, 289, 62, 1084, 7, 70, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 30493, 34590, 11518, 1875, 657, 13, 15, 220, 366, 32863, 876, 34590, 11518, 25, 720, 34985, 11518, 287, 720, 70, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 2964, 65, 796, 308, 13, 9744, 2964, 65, 11518, 532, 3915, 62, 1676, 65, 62, 71, 1084, 7, 70, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 30493, 288, 2964, 65, 1875, 657, 13, 486, 220, 366, 44651, 288, 2964, 65, 25, 720, 67, 2964, 65, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 308, 2964, 65, 796, 3915, 62, 1676, 65, 62, 71, 1084, 7, 70, 8, 1343, 34590, 1220, 34590, 11518, 1635, 288, 2964, 65, 26, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 308, 2964, 65, 796, 949, 7, 70, 13, 9744, 2964, 65, 11518, 11, 3509, 7, 70, 13, 9744, 2964, 65, 9452, 11, 308, 2964, 65, 18125, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 308, 2964, 65, 796, 6632, 7, 25628, 1776, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 308, 2964, 65, 796, 6632, 7, 25628, 1776, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 308, 2964, 65, 198, 437, 628, 198, 2, 34400, 12 ]
2.316253
3,864
# included in runtests.jl using Test using WebSockets import WebSockets:HTTP, base64encode, throwto, OPCODE_TEXT, locked_write import Base.BufferStream include("client_server_functions.jl") const FURL = "ws://127.0.0.1" const FPORT = 8092 @info "Start a server with a ws handler that is unresponsive. \nClose from client side. The " * " close handshake aborts after $(WebSockets.TIMEOUT_CLOSEHANDSHAKE) seconds..." s = WebSockets.ServerWS( req::HTTP.Request -> HTTP.Response(200), (req::HTTP.Request, ws::WebSocket) -> begin for i=1:16 sleep(1) i < 11 && println(i) end return end) startserver(s, url=SURL, port=FPORT) res = WebSockets.open((_) -> nothing, "$(FURL):$(FPORT)"); @test res.status == 101 close(s) @info "Start a server with a ws handler that always reads guarded." sleep(1) s = WebSockets.ServerWS( req -> HTTP.Response(200), (req, ws_serv) -> begin while isopen(ws_serv) WebSockets.readguarded(ws_serv) end end); startserver(s, url=SURL, port=FPORT) sleep(1) @info "Attempt to read guarded from a closing ws|client. Check for return false." sleep(1) WebSockets.open("$(FURL):$(FPORT)") do ws_client close(ws_client) data = WebSockets.readguarded(ws_client) @test (UInt8[], false) == data end; sleep(1) @info "Attempt to write guarded from a closing ws|client. Check for return false." sleep(1) WebSockets.open("$(FURL):$(FPORT)") do ws_client close(ws_client) data = WebSockets.writeguarded(ws_client, "writethis") @test false == data end; sleep(1) @info "Attempt to read from closing ws|client. Check caught error." sleep(1) try WebSockets.open("$(FURL):$(FPORT)") do ws_client close(ws_client) read(ws_client) end catch err @test typeof(err) <: ErrorException @test err.msg == "Attempt to read from closed WebSocket|client. First isopen(ws), or use readguarded(ws)!" end sleep(1) @info "Attempt to write to a closing ws|client (this takes some time, there is no check in WebSockets against it). Check caught error." sleep(1) try WebSockets.open("$(FURL):$(FPORT)") do ws_client close(ws_client) write(ws_client, "writethis") end catch err show(err) @test typeof(err) <: WebSocketClosedError @test err.message == " while open ws|client: stream is closed or unusable" end close(s) @info "Start a server. The wshandler use global channels for inspecting caught errors." sleep(1) chfromserv=Channel(2) s = WebSockets.ServerWS( req-> HTTP.Response(200), ws_serv->begin while isopen(ws_serv) try read(ws_serv) catch err put!(chfromserv, err) put!(chfromserv, stacktrace(catch_backtrace())[1:2]) end end end); startserver(s, url=SURL, port=FPORT) sleep(3) @info "Open a ws|client, close it out of protocol. Check server error on channel." global res = WebSockets.open((ws)-> close(ws.socket), "$(FURL):$(FPORT)") @test res.status == 101 sleep(1) global err = take!(chfromserv) @test typeof(err) <: WebSocketClosedError @test err.message == " while read(ws|server) BoundsError(UInt8[], (1,))" global stack_trace = take!(chfromserv) if VERSION <= v"1.0.2" # Stack trace on master is zero. Unknown cause. @test length(stack_trace) == 2 end close(s) sleep(1) @info "Start a server. Errors are output on built-in channel" sleep(1) s = WebSockets.ServerWS( req-> HTTP.Response(200), ws_serv->begin while isopen(ws_serv) read(ws_serv) end end); startserver(s, url=SURL, port=FPORT) sleep(3) @info "Open a ws|client, close it out of protocol. Check server error on server.out channel." sleep(1) WebSockets.open((ws)-> close(ws.socket), "$(FURL):$(FPORT)"); global err = take!(s.out) @test typeof(err) <: WebSocketClosedError @test err.message == " while read(ws|server) BoundsError(UInt8[], (1,))" sleep(1) global stack_trace = take!(s.out); if VERSION <= v"1.0.2" # Stack trace on master is zero. Unknown cause. @test length(stack_trace) in [5, 6] end while isready(s.out) take!(s.out) end close(s) startserver(s, url=SURL, port=FPORT) sleep(3) @info "Open ws|clients, close using every status code from RFC 6455 7.4.1\n" * " Verify error messages on server.out reflect the codes." sleep(1) for (ke, va) in WebSockets.codeDesc @info "Closing ws|client with reason ", ke, " ", va sleep(0.3) WebSockets.open((ws)-> close(ws, statusnumber = ke), "$(FURL):$(FPORT)") wait(s.out) global err = take!(s.out) @test typeof(err) <: WebSocketClosedError @test err.message == "ws|server respond to OPCODE_CLOSE $ke:$va" wait(s.out) stacktra = take!(s.out) if VERSION <= v"1.0.2" # Unknown cause, nighly behaves differently @test length(stacktra) == 0 end while isready(s.out) take!(s.out) end sleep(1) end @info "Open a ws|client, close it using a status code from RFC 6455 7.4.1\n" * " and also a custom reason string. Verify error messages on server.out reflect the codes." sleep(1) global va = 1000 @info "Closing ws|client with reason", va, " ", WebSockets.codeDesc[va], " and goodbye!" WebSockets.open((ws)-> close(ws, statusnumber = va, freereason = "goodbye!"), "$(FURL):$(FPORT)") wait(s.out) global err = take!(s.out) @test typeof(err) <: WebSocketClosedError @test err.message == "ws|server respond to OPCODE_CLOSE 1000:goodbye!" global stack_trace = take!(s.out) sleep(1) @info "Open a ws|client. Throw an InterruptException to it. Check that the ws|server\n " * "error shows the reason for the close." sleep(1) function selfinterruptinghandler(ws) task = @async WebSockets.open((ws)-> read(ws), "$(FURL):$(FPORT)") sleep(3) @async Base.throwto(task, InterruptException()) sleep(1) nothing end WebSockets.open(selfinterruptinghandler, "$(FURL):$(FPORT)") sleep(6) global err = take!(s.out) @test typeof(err) <: WebSocketClosedError @test err.message == "ws|server respond to OPCODE_CLOSE 1006: while read(ws|client received InterruptException." global stack_trace = take!(s.out) close(s) @info "Trigger check_upgrade WebSocketErrors " let noupgrade, noconnectionupgrade, key key = base64encode(rand(UInt8, 16)) noupgrade = WebSockets.Request("GET", "/", [ "Connection" => "Upgrade", "Sec-WebSocket-Key" => key, "Sec-WebSocket-Version" => "13" ]) @test_throws WebSockets.WebSocketError WebSockets.check_upgrade(noupgrade) noconnectionupgrade = WebSockets.Request("GET", "/", [ "Upgrade" => "websocket", "Sec-WebSocket-Key" => key, "Sec-WebSocket-Version" => "13" ]) @test_throws WebSockets.WebSocketError WebSockets.check_upgrade(noconnectionupgrade) end sleep(2)
[ 2, 3017, 287, 1057, 41989, 13, 20362, 198, 3500, 6208, 198, 3500, 5313, 50, 11603, 198, 11748, 5313, 50, 11603, 25, 40717, 11, 198, 220, 220, 220, 220, 220, 220, 2779, 2414, 268, 8189, 11, 198, 220, 220, 220, 220, 220, 220, 3714, 1462, 11, 198, 220, 220, 220, 220, 220, 220, 440, 5662, 16820, 62, 32541, 11, 198, 220, 220, 220, 220, 220, 220, 8970, 62, 13564, 198, 11748, 7308, 13, 28632, 12124, 198, 17256, 7203, 16366, 62, 15388, 62, 12543, 2733, 13, 20362, 4943, 198, 9979, 376, 21886, 796, 366, 18504, 1378, 16799, 13, 15, 13, 15, 13, 16, 1, 198, 9979, 376, 15490, 796, 807, 2931, 17, 198, 198, 31, 10951, 366, 10434, 257, 4382, 351, 257, 266, 82, 21360, 326, 318, 555, 39772, 13, 3467, 77, 26125, 422, 5456, 1735, 13, 383, 366, 1635, 198, 220, 220, 220, 220, 220, 366, 1969, 42231, 450, 2096, 706, 29568, 13908, 50, 11603, 13, 34694, 12425, 62, 32737, 39, 1565, 5258, 7801, 7336, 8, 4201, 9313, 198, 82, 796, 5313, 50, 11603, 13, 10697, 19416, 7, 198, 220, 220, 220, 43089, 3712, 40717, 13, 18453, 4613, 14626, 13, 31077, 7, 2167, 828, 198, 220, 220, 220, 357, 42180, 3712, 40717, 13, 18453, 11, 266, 82, 3712, 13908, 39105, 8, 4613, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 28, 16, 25, 1433, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3993, 7, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1312, 1279, 1367, 11405, 44872, 7, 72, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 198, 220, 220, 220, 886, 8, 198, 198, 9688, 15388, 7, 82, 11, 19016, 28, 50, 21886, 11, 2493, 28, 5837, 9863, 8, 198, 198, 411, 796, 5313, 50, 11603, 13, 9654, 19510, 62, 8, 4613, 2147, 11, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 15341, 198, 31, 9288, 581, 13, 13376, 6624, 8949, 198, 19836, 7, 82, 8, 198, 198, 31, 10951, 366, 10434, 257, 4382, 351, 257, 266, 82, 21360, 326, 1464, 9743, 28178, 526, 198, 42832, 7, 16, 8, 198, 82, 796, 5313, 50, 11603, 13, 10697, 19416, 7, 198, 220, 220, 220, 43089, 4613, 14626, 13, 31077, 7, 2167, 828, 198, 220, 220, 220, 357, 42180, 11, 266, 82, 62, 3168, 8, 4613, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 981, 318, 9654, 7, 18504, 62, 3168, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5313, 50, 11603, 13, 961, 5162, 10676, 7, 18504, 62, 3168, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 1776, 198, 9688, 15388, 7, 82, 11, 19016, 28, 50, 21886, 11, 2493, 28, 5837, 9863, 8, 198, 42832, 7, 16, 8, 198, 198, 31, 10951, 366, 37177, 284, 1100, 28178, 422, 257, 9605, 266, 82, 91, 16366, 13, 6822, 329, 1441, 3991, 526, 198, 42832, 7, 16, 8, 198, 13908, 50, 11603, 13, 9654, 7203, 3, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 466, 266, 82, 62, 16366, 198, 220, 220, 220, 220, 220, 220, 220, 1969, 7, 18504, 62, 16366, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1366, 796, 5313, 50, 11603, 13, 961, 5162, 10676, 7, 18504, 62, 16366, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 357, 52, 5317, 23, 58, 4357, 3991, 8, 6624, 1366, 198, 220, 220, 220, 886, 26, 198, 42832, 7, 16, 8, 628, 198, 31, 10951, 366, 37177, 284, 3551, 28178, 422, 257, 9605, 266, 82, 91, 16366, 13, 6822, 329, 1441, 3991, 526, 198, 42832, 7, 16, 8, 198, 13908, 50, 11603, 13, 9654, 7203, 3, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 466, 266, 82, 62, 16366, 198, 220, 220, 220, 1969, 7, 18504, 62, 16366, 8, 198, 220, 220, 220, 1366, 796, 5313, 50, 11603, 13, 13564, 5162, 10676, 7, 18504, 62, 16366, 11, 366, 8933, 2788, 271, 4943, 198, 220, 220, 220, 2488, 9288, 3991, 6624, 1366, 198, 437, 26, 198, 42832, 7, 16, 8, 628, 198, 31, 10951, 366, 37177, 284, 1100, 422, 9605, 266, 82, 91, 16366, 13, 6822, 4978, 4049, 526, 198, 42832, 7, 16, 8, 198, 28311, 198, 220, 220, 220, 5313, 50, 11603, 13, 9654, 7203, 3, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 466, 266, 82, 62, 16366, 198, 220, 220, 220, 220, 220, 220, 220, 1969, 7, 18504, 62, 16366, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1100, 7, 18504, 62, 16366, 8, 198, 220, 220, 220, 886, 198, 40198, 11454, 198, 220, 220, 220, 2488, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 13047, 16922, 198, 220, 220, 220, 2488, 9288, 11454, 13, 19662, 6624, 366, 37177, 284, 1100, 422, 4838, 5313, 39105, 91, 16366, 13, 3274, 318, 9654, 7, 18504, 828, 393, 779, 1100, 5162, 10676, 7, 18504, 8, 2474, 198, 437, 198, 42832, 7, 16, 8, 628, 198, 31, 10951, 366, 37177, 284, 3551, 284, 257, 9605, 266, 82, 91, 16366, 357, 5661, 2753, 617, 640, 11, 612, 318, 645, 2198, 198, 220, 220, 220, 220, 220, 287, 5313, 50, 11603, 1028, 340, 737, 6822, 4978, 4049, 526, 198, 42832, 7, 16, 8, 198, 28311, 198, 220, 220, 220, 5313, 50, 11603, 13, 9654, 7203, 3, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 466, 266, 82, 62, 16366, 198, 220, 220, 220, 220, 220, 220, 220, 1969, 7, 18504, 62, 16366, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3551, 7, 18504, 62, 16366, 11, 366, 8933, 2788, 271, 4943, 198, 220, 220, 220, 886, 198, 40198, 11454, 198, 220, 220, 220, 905, 7, 8056, 8, 198, 220, 220, 220, 220, 2488, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 5313, 39105, 2601, 1335, 12331, 198, 220, 220, 220, 220, 2488, 9288, 11454, 13, 20500, 6624, 366, 981, 1280, 266, 82, 91, 16366, 25, 4269, 318, 4838, 393, 7242, 540, 1, 198, 437, 198, 198, 19836, 7, 82, 8, 198, 198, 31, 10951, 366, 10434, 257, 4382, 13, 383, 266, 1477, 392, 1754, 779, 3298, 9619, 329, 49889, 4978, 8563, 526, 198, 42832, 7, 16, 8, 198, 354, 6738, 3168, 28, 29239, 7, 17, 8, 198, 82, 796, 5313, 50, 11603, 13, 10697, 19416, 7, 198, 220, 220, 220, 43089, 3784, 14626, 13, 31077, 7, 2167, 828, 198, 220, 220, 220, 266, 82, 62, 3168, 3784, 27471, 198, 220, 220, 220, 220, 220, 220, 220, 981, 318, 9654, 7, 18504, 62, 3168, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1949, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1100, 7, 18504, 62, 3168, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4929, 11454, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1234, 0, 7, 354, 6738, 3168, 11, 11454, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1234, 0, 7, 354, 6738, 3168, 11, 8931, 40546, 7, 40198, 62, 1891, 40546, 28955, 58, 16, 25, 17, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 1776, 198, 9688, 15388, 7, 82, 11, 19016, 28, 50, 21886, 11, 2493, 28, 5837, 9863, 8, 198, 42832, 7, 18, 8, 198, 198, 31, 10951, 366, 11505, 257, 266, 82, 91, 16366, 11, 1969, 340, 503, 286, 8435, 13, 6822, 4382, 4049, 319, 6518, 526, 198, 20541, 581, 796, 5313, 50, 11603, 13, 9654, 19510, 18504, 8, 3784, 1969, 7, 18504, 13, 44971, 828, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 198, 31, 9288, 581, 13, 13376, 6624, 8949, 198, 42832, 7, 16, 8, 198, 20541, 11454, 796, 1011, 0, 7, 354, 6738, 3168, 8, 198, 31, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 5313, 39105, 2601, 1335, 12331, 198, 31, 9288, 11454, 13, 20500, 6624, 366, 981, 1100, 7, 18504, 91, 15388, 8, 347, 3733, 12331, 7, 52, 5317, 23, 58, 4357, 357, 16, 11, 4008, 1, 198, 20541, 8931, 62, 40546, 796, 1011, 0, 7, 354, 6738, 3168, 8, 198, 361, 44156, 2849, 19841, 410, 1, 16, 13, 15, 13, 17, 1, 198, 220, 220, 220, 1303, 23881, 12854, 319, 4958, 318, 6632, 13, 16185, 2728, 13, 198, 220, 220, 220, 2488, 9288, 4129, 7, 25558, 62, 40546, 8, 6624, 362, 198, 437, 198, 198, 19836, 7, 82, 8, 198, 198, 42832, 7, 16, 8, 198, 198, 31, 10951, 366, 10434, 257, 4382, 13, 44225, 389, 5072, 319, 3170, 12, 259, 6518, 1, 198, 42832, 7, 16, 8, 198, 82, 796, 5313, 50, 11603, 13, 10697, 19416, 7, 198, 220, 220, 220, 43089, 3784, 14626, 13, 31077, 7, 2167, 828, 198, 220, 220, 220, 266, 82, 62, 3168, 3784, 27471, 198, 220, 220, 220, 220, 220, 220, 220, 981, 318, 9654, 7, 18504, 62, 3168, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1100, 7, 18504, 62, 3168, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 1776, 198, 9688, 15388, 7, 82, 11, 19016, 28, 50, 21886, 11, 2493, 28, 5837, 9863, 8, 198, 42832, 7, 18, 8, 198, 198, 31, 10951, 366, 11505, 257, 266, 82, 91, 16366, 11, 1969, 340, 503, 286, 8435, 13, 6822, 4382, 4049, 319, 4382, 13, 448, 6518, 526, 198, 42832, 7, 16, 8, 198, 13908, 50, 11603, 13, 9654, 19510, 18504, 8, 3784, 1969, 7, 18504, 13, 44971, 828, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 15341, 198, 20541, 11454, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 31, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 5313, 39105, 2601, 1335, 12331, 198, 31, 9288, 11454, 13, 20500, 6624, 366, 981, 1100, 7, 18504, 91, 15388, 8, 347, 3733, 12331, 7, 52, 5317, 23, 58, 4357, 357, 16, 11, 4008, 1, 198, 42832, 7, 16, 8, 198, 20541, 8931, 62, 40546, 796, 1011, 0, 7, 82, 13, 448, 1776, 198, 361, 44156, 2849, 19841, 410, 1, 16, 13, 15, 13, 17, 1, 198, 220, 220, 220, 1303, 23881, 12854, 319, 4958, 318, 6632, 13, 16185, 2728, 13, 198, 220, 220, 220, 2488, 9288, 4129, 7, 25558, 62, 40546, 8, 287, 685, 20, 11, 718, 60, 198, 437, 198, 198, 4514, 318, 1493, 7, 82, 13, 448, 8, 198, 220, 220, 220, 1011, 0, 7, 82, 13, 448, 8, 198, 437, 628, 198, 19836, 7, 82, 8, 198, 9688, 15388, 7, 82, 11, 19016, 28, 50, 21886, 11, 2493, 28, 5837, 9863, 8, 198, 42832, 7, 18, 8, 198, 198, 31, 10951, 366, 11505, 266, 82, 91, 565, 2334, 11, 1969, 1262, 790, 3722, 2438, 422, 30978, 718, 30505, 767, 13, 19, 13, 16, 59, 77, 1, 1635, 198, 220, 220, 220, 220, 220, 366, 220, 49899, 4049, 6218, 319, 4382, 13, 448, 4079, 262, 12416, 526, 198, 42832, 7, 16, 8, 198, 1640, 357, 365, 11, 46935, 8, 287, 5313, 50, 11603, 13, 8189, 24564, 198, 220, 220, 220, 2488, 10951, 366, 2601, 2752, 266, 82, 91, 16366, 351, 1738, 33172, 885, 11, 366, 33172, 46935, 198, 220, 220, 220, 3993, 7, 15, 13, 18, 8, 198, 220, 220, 220, 5313, 50, 11603, 13, 9654, 19510, 18504, 8, 3784, 1969, 7, 18504, 11, 3722, 17618, 796, 885, 828, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 198, 220, 220, 220, 4043, 7, 82, 13, 448, 8, 198, 220, 220, 220, 3298, 11454, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 220, 220, 220, 2488, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 5313, 39105, 2601, 1335, 12331, 198, 220, 220, 220, 2488, 9288, 11454, 13, 20500, 6624, 366, 18504, 91, 15388, 3031, 284, 440, 5662, 16820, 62, 32737, 720, 365, 25, 3, 6862, 1, 198, 220, 220, 220, 4043, 7, 82, 13, 448, 8, 198, 220, 220, 220, 8931, 9535, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 220, 220, 220, 611, 44156, 2849, 19841, 410, 1, 16, 13, 15, 13, 17, 1, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 16185, 2728, 11, 299, 394, 306, 39341, 10338, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 25558, 9535, 8, 6624, 657, 198, 220, 220, 220, 886, 198, 220, 220, 220, 981, 318, 1493, 7, 82, 13, 448, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1011, 0, 7, 82, 13, 448, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 3993, 7, 16, 8, 198, 437, 198, 198, 31, 10951, 366, 11505, 257, 266, 82, 91, 16366, 11, 1969, 340, 1262, 257, 3722, 2438, 422, 30978, 718, 30505, 767, 13, 19, 13, 16, 59, 77, 1, 1635, 198, 220, 220, 220, 220, 220, 366, 290, 635, 257, 2183, 1738, 4731, 13, 49899, 4049, 6218, 319, 4382, 13, 448, 4079, 262, 12416, 526, 198, 198, 42832, 7, 16, 8, 198, 20541, 46935, 796, 8576, 198, 31, 10951, 366, 2601, 2752, 266, 82, 91, 16366, 351, 1738, 1600, 46935, 11, 366, 33172, 5313, 50, 11603, 13, 8189, 24564, 58, 6862, 4357, 366, 290, 24829, 2474, 198, 13908, 50, 11603, 13, 9654, 19510, 18504, 8, 3784, 1969, 7, 18504, 11, 3722, 17618, 796, 46935, 11, 2030, 567, 888, 796, 366, 11274, 16390, 2474, 828, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 198, 17077, 7, 82, 13, 448, 8, 198, 20541, 11454, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 31, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 5313, 39105, 2601, 1335, 12331, 198, 31, 9288, 11454, 13, 20500, 6624, 366, 18504, 91, 15388, 3031, 284, 440, 5662, 16820, 62, 32737, 8576, 25, 11274, 16390, 2474, 198, 20541, 8931, 62, 40546, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 42832, 7, 16, 8, 198, 198, 31, 10951, 366, 11505, 257, 266, 82, 91, 16366, 13, 22481, 281, 4225, 3622, 16922, 284, 340, 13, 6822, 326, 262, 266, 82, 91, 15388, 59, 77, 366, 1635, 198, 220, 220, 220, 366, 18224, 2523, 262, 1738, 329, 262, 1969, 526, 198, 42832, 7, 16, 8, 198, 8818, 2116, 3849, 3622, 278, 30281, 7, 18504, 8, 198, 220, 220, 220, 4876, 796, 2488, 292, 13361, 5313, 50, 11603, 13, 9654, 19510, 18504, 8, 3784, 1100, 7, 18504, 828, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 198, 220, 220, 220, 3993, 7, 18, 8, 198, 220, 220, 220, 2488, 292, 13361, 7308, 13, 16939, 1462, 7, 35943, 11, 4225, 3622, 16922, 28955, 198, 220, 220, 220, 3993, 7, 16, 8, 198, 220, 220, 220, 2147, 198, 437, 198, 13908, 50, 11603, 13, 9654, 7, 944, 3849, 3622, 278, 30281, 11, 17971, 7, 37, 21886, 2599, 3, 7, 5837, 9863, 8, 4943, 198, 42832, 7, 21, 8, 198, 20541, 11454, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 31, 9288, 2099, 1659, 7, 8056, 8, 1279, 25, 5313, 39105, 2601, 1335, 12331, 198, 31, 9288, 11454, 13, 20500, 6624, 366, 18504, 91, 15388, 3031, 284, 440, 5662, 16820, 62, 32737, 1802, 21, 25, 981, 1100, 7, 18504, 91, 16366, 2722, 4225, 3622, 16922, 526, 198, 20541, 8931, 62, 40546, 796, 1011, 0, 7, 82, 13, 448, 8, 198, 198, 19836, 7, 82, 8, 198, 198, 31, 10951, 366, 48344, 2198, 62, 929, 9526, 5313, 39105, 9139, 5965, 366, 198, 1616, 299, 10486, 9526, 11, 299, 36221, 1606, 295, 929, 9526, 11, 1994, 198, 220, 220, 220, 1994, 796, 2779, 2414, 268, 8189, 7, 25192, 7, 52, 5317, 23, 11, 1467, 4008, 198, 220, 220, 220, 299, 10486, 9526, 796, 5313, 50, 11603, 13, 18453, 7203, 18851, 1600, 12813, 1600, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 32048, 1, 5218, 366, 44948, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 6558, 12, 13908, 39105, 12, 9218, 1, 5218, 1994, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 6558, 12, 13908, 39105, 12, 14815, 1, 5218, 366, 1485, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33761, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 5313, 50, 11603, 13, 13908, 39105, 12331, 5313, 50, 11603, 13, 9122, 62, 929, 9526, 7, 77, 10486, 9526, 8, 198, 220, 220, 220, 299, 36221, 1606, 295, 929, 9526, 796, 5313, 50, 11603, 13, 18453, 7203, 18851, 1600, 12813, 1600, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 44948, 1, 5218, 366, 732, 1443, 5459, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 6558, 12, 13908, 39105, 12, 9218, 1, 5218, 1994, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 6558, 12, 13908, 39105, 12, 14815, 1, 5218, 366, 1485, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33761, 198, 220, 220, 220, 2488, 9288, 62, 400, 8516, 5313, 50, 11603, 13, 13908, 39105, 12331, 5313, 50, 11603, 13, 9122, 62, 929, 9526, 7, 77, 36221, 1606, 295, 929, 9526, 8, 198, 437, 198, 198, 42832, 7, 17, 8, 198 ]
2.365229
2,968
isacidic(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].type == "Acidic") isaliphatic(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].type == "Aliphatic") isaromatic(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].type == "Aromatic") isbasic(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].type == "Basic") ischarged(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].charge != 0) ishydrophobic(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].hydrophobic == true) isneutral(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].charge == 0) isnonpolar(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].polar == false) ispolar(atom::Atom) = (i = which_natural_aminoacid(atom)) == 0 ? false : (natural_aminoacids[i].polar == true) isprotein(atom::Atom; newres = nothing) = (atom.resname == newres || which_natural_aminoacid(atom) != 0) ? true : false isprotein(residue::Residue; newres = nothing) = isprotein(residue.atoms[residue.range[begin]]; newres = newres) backbone_atoms = ["N", "CA", "C", "O"] isbackbone(atom::Atom; backbone_atoms = backbone_atoms) = which_natural_aminoacid(atom) == 0 ? false : (atom.name in backbone_atoms) not_side_chain_atoms = ["N", "CA", "C", "O", "HN", "H", "HA", "HT1", "HT2", "HT3"] issidechain(atom::Atom; not_side_chain_atoms = not_side_chain_atoms) = which_natural_aminoacid(atom) == 0 ? false : (!(atom.name in not_side_chain_atoms)) water_residues = ["HOH", "OH2", "TIP3", "TIP3P", "TIP4P", "TIP5P", "TIP7P", "SPC", "SPCE"] iswater(atom::Atom; water_residues = water_residues) = (findfirst(isequal(atom.resname), water_residues) != nothing)
[ 271, 46309, 291, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 198, 220, 220, 220, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 4906, 6624, 366, 12832, 312, 291, 4943, 198, 198, 28456, 13323, 1512, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 198, 220, 220, 220, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 4906, 6624, 366, 2348, 13323, 1512, 4943, 198, 198, 271, 283, 13730, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 198, 220, 220, 220, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 4906, 6624, 366, 32, 398, 1512, 4943, 198, 198, 271, 35487, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 198, 220, 220, 220, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 4906, 6624, 366, 26416, 4943, 198, 198, 271, 17200, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 10136, 14512, 657, 8, 198, 198, 680, 5173, 10051, 20803, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 198, 220, 220, 220, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 15511, 10051, 20803, 6624, 2081, 8, 198, 198, 271, 29797, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 10136, 6624, 657, 8, 198, 198, 271, 13159, 79, 6192, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 198, 220, 220, 220, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 79, 6192, 6624, 3991, 8, 198, 198, 8802, 6192, 7, 37696, 3712, 2953, 296, 8, 796, 198, 220, 220, 220, 357, 72, 796, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 4008, 6624, 657, 5633, 3991, 1058, 357, 11802, 62, 321, 2879, 330, 2340, 58, 72, 4083, 79, 6192, 6624, 2081, 8, 198, 198, 271, 48693, 7, 37696, 3712, 2953, 296, 26, 649, 411, 796, 2147, 8, 796, 198, 220, 220, 220, 357, 37696, 13, 411, 3672, 6624, 649, 411, 8614, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 8, 14512, 657, 8, 5633, 2081, 1058, 3991, 198, 198, 271, 48693, 7, 411, 312, 518, 3712, 4965, 312, 518, 26, 649, 411, 796, 2147, 8, 796, 198, 220, 220, 220, 318, 48693, 7, 411, 312, 518, 13, 265, 3150, 58, 411, 312, 518, 13, 9521, 58, 27471, 60, 11208, 649, 411, 796, 649, 411, 8, 198, 198, 1891, 15992, 62, 265, 3150, 796, 14631, 45, 1600, 366, 8141, 1600, 366, 34, 1600, 366, 46, 8973, 198, 271, 1891, 15992, 7, 37696, 3712, 2953, 296, 26, 32774, 62, 265, 3150, 796, 32774, 62, 265, 3150, 8, 796, 198, 220, 220, 220, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 8, 6624, 657, 5633, 3991, 1058, 357, 37696, 13, 3672, 287, 32774, 62, 265, 3150, 8, 198, 198, 1662, 62, 1589, 62, 7983, 62, 265, 3150, 796, 14631, 45, 1600, 366, 8141, 1600, 366, 34, 1600, 366, 46, 1600, 366, 39, 45, 1600, 366, 39, 1600, 366, 7801, 1600, 366, 6535, 16, 1600, 366, 6535, 17, 1600, 366, 6535, 18, 8973, 198, 747, 485, 7983, 7, 37696, 3712, 2953, 296, 26, 407, 62, 1589, 62, 7983, 62, 265, 3150, 796, 407, 62, 1589, 62, 7983, 62, 265, 3150, 8, 796, 198, 220, 220, 220, 543, 62, 11802, 62, 321, 2879, 46309, 7, 37696, 8, 6624, 657, 5633, 3991, 1058, 22759, 7, 37696, 13, 3672, 287, 407, 62, 1589, 62, 7983, 62, 265, 3150, 4008, 198, 198, 7050, 62, 411, 312, 947, 796, 14631, 39, 12096, 1600, 366, 12096, 17, 1600, 366, 51, 4061, 18, 1600, 366, 51, 4061, 18, 47, 1600, 366, 51, 4061, 19, 47, 1600, 366, 51, 4061, 20, 47, 1600, 366, 51, 4061, 22, 47, 1600, 366, 4303, 34, 1600, 366, 4303, 5222, 8973, 198, 271, 7050, 7, 37696, 3712, 2953, 296, 26, 1660, 62, 411, 312, 947, 796, 1660, 62, 411, 312, 947, 8, 796, 198, 220, 220, 220, 357, 19796, 11085, 7, 786, 13255, 7, 37696, 13, 411, 3672, 828, 1660, 62, 411, 312, 947, 8, 14512, 2147, 8, 198 ]
2.362336
839
# --- # title: 1261. Find Elements in a Contaminated Binary Tree # id: problem1261 # author: <NAME> # date: 2020-10-31 # difficulty: Medium # categories: Hash Table, Tree # link: <https://leetcode.com/problems/find-elements-in-a-contaminated-binary-tree/description/> # hidden: true # --- # # Given a binary tree with the following rules: # # 1. `root.val == 0` # 2. If `treeNode.val == x` and `treeNode.left != null`, then `treeNode.left.val == 2 * x + 1` # 3. If `treeNode.val == x` and `treeNode.right != null`, then `treeNode.right.val == 2 * x + 2` # # Now the binary tree is contaminated, which means all `treeNode.val` have been # changed to `-1`. # # You need to first recover the binary tree and then implement the # `FindElements` class: # # * `FindElements(TreeNode* root)` Initializes the object with a contamined binary tree, you need to recover it first. # * `bool find(int target)` Return if the `target` value exists in the recovered binary tree. # # # # **Example 1:** # # **![](https://assets.leetcode.com/uploads/2019/11/06/untitled- # diagram-4-1.jpg)** # # # # **Input** # ["FindElements","find","find"] # [[[-1,null,-1]],[1],[2]] # **Output** # [null,false,true] # **Explanation** # FindElements findElements = new FindElements([-1,null,-1]); # findElements.find(1); // return False # findElements.find(2); // return True # # **Example 2:** # # **![](https://assets.leetcode.com/uploads/2019/11/06/untitled-diagram-4.jpg)** # # # # **Input** # ["FindElements","find","find","find"] # [[[-1,-1,-1,-1,-1]],[1],[3],[5]] # **Output** # [null,true,true,false] # **Explanation** # FindElements findElements = new FindElements([-1,-1,-1,-1,-1]); # findElements.find(1); // return True # findElements.find(3); // return True # findElements.find(5); // return False # # **Example 3:** # # **![](https://assets.leetcode.com/uploads/2019/11/07/untitled- # diagram-4-1-1.jpg)** # # # # **Input** # ["FindElements","find","find","find","find"] # [[[-1,null,-1,-1,null,-1]],[2],[3],[4],[5]] # **Output** # [null,true,false,false,true] # **Explanation** # FindElements findElements = new FindElements([-1,null,-1,-1,null,-1]); # findElements.find(2); // return True # findElements.find(3); // return False # findElements.find(4); // return False # findElements.find(5); // return True # # # # # **Constraints:** # # * `TreeNode.val == -1` # * The height of the binary tree is less than or equal to `20` # * The total number of nodes is between `[1, 10^4]` # * Total calls of `find()` is between `[1, 10^4]` # * `0 <= target <= 10^6` # # ## @lc code=start using LeetCode ## add your code here: ## @lc code=end
[ 2, 11420, 198, 2, 3670, 25, 1105, 5333, 13, 9938, 26632, 287, 257, 2345, 321, 3898, 45755, 12200, 198, 2, 4686, 25, 1917, 1065, 5333, 198, 2, 1772, 25, 1279, 20608, 29, 198, 2, 3128, 25, 12131, 12, 940, 12, 3132, 198, 2, 8722, 25, 13398, 198, 2, 9376, 25, 21059, 8655, 11, 12200, 198, 2, 2792, 25, 1279, 5450, 1378, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 19796, 12, 68, 3639, 12, 259, 12, 64, 12, 3642, 321, 3898, 12, 39491, 12, 21048, 14, 11213, 15913, 198, 2, 7104, 25, 2081, 198, 2, 11420, 198, 2, 220, 198, 2, 11259, 257, 13934, 5509, 351, 262, 1708, 3173, 25, 198, 2, 220, 198, 2, 220, 220, 352, 13, 4600, 15763, 13, 2100, 6624, 657, 63, 198, 2, 220, 220, 362, 13, 1002, 4600, 21048, 19667, 13, 2100, 6624, 2124, 63, 290, 4600, 21048, 19667, 13, 9464, 14512, 9242, 47671, 788, 4600, 21048, 19667, 13, 9464, 13, 2100, 6624, 362, 1635, 2124, 1343, 352, 63, 198, 2, 220, 220, 513, 13, 1002, 4600, 21048, 19667, 13, 2100, 6624, 2124, 63, 290, 4600, 21048, 19667, 13, 3506, 14512, 9242, 47671, 788, 4600, 21048, 19667, 13, 3506, 13, 2100, 6624, 362, 1635, 2124, 1343, 362, 63, 198, 2, 220, 198, 2, 2735, 262, 13934, 5509, 318, 23543, 11, 543, 1724, 477, 4600, 21048, 19667, 13, 2100, 63, 423, 587, 198, 2, 3421, 284, 4600, 12, 16, 44646, 198, 2, 220, 198, 2, 921, 761, 284, 717, 8551, 262, 13934, 5509, 290, 788, 3494, 262, 198, 2, 4600, 16742, 36, 3639, 63, 1398, 25, 198, 2, 220, 198, 2, 220, 220, 1635, 4600, 16742, 36, 3639, 7, 27660, 19667, 9, 6808, 8, 63, 20768, 4340, 262, 2134, 351, 257, 14244, 1389, 13934, 5509, 11, 345, 761, 284, 8551, 340, 717, 13, 198, 2, 220, 220, 1635, 4600, 30388, 1064, 7, 600, 2496, 8, 63, 8229, 611, 262, 4600, 16793, 63, 1988, 7160, 287, 262, 11911, 13934, 5509, 13, 198, 2, 220, 198, 2, 220, 198, 2, 220, 198, 2, 12429, 16281, 352, 25, 1174, 198, 2, 220, 198, 2, 12429, 0, 58, 16151, 5450, 1378, 19668, 13, 293, 316, 8189, 13, 785, 14, 39920, 14, 23344, 14, 1157, 14, 3312, 14, 2797, 7803, 12, 198, 2, 16362, 12, 19, 12, 16, 13, 9479, 8, 1174, 198, 2, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 12429, 20560, 1174, 198, 2, 220, 220, 220, 220, 14631, 16742, 36, 3639, 2430, 19796, 2430, 19796, 8973, 198, 2, 220, 220, 220, 220, 16410, 58, 12, 16, 11, 8423, 12095, 16, 60, 38430, 16, 38430, 17, 11907, 198, 2, 220, 220, 220, 220, 12429, 26410, 1174, 198, 2, 220, 220, 220, 220, 685, 8423, 11, 9562, 11, 7942, 60, 198, 2, 220, 220, 220, 220, 12429, 3109, 11578, 341, 1174, 198, 2, 220, 220, 220, 220, 9938, 36, 3639, 1064, 36, 3639, 796, 649, 9938, 36, 3639, 26933, 12, 16, 11, 8423, 12095, 16, 36563, 220, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 16, 1776, 3373, 1441, 10352, 220, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 17, 1776, 3373, 1441, 6407, 220, 198, 2, 220, 198, 2, 12429, 16281, 362, 25, 1174, 198, 2, 220, 198, 2, 12429, 0, 58, 16151, 5450, 1378, 19668, 13, 293, 316, 8189, 13, 785, 14, 39920, 14, 23344, 14, 1157, 14, 3312, 14, 2797, 7803, 12, 10989, 6713, 12, 19, 13, 9479, 8, 1174, 198, 2, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 12429, 20560, 1174, 198, 2, 220, 220, 220, 220, 14631, 16742, 36, 3639, 2430, 19796, 2430, 19796, 2430, 19796, 8973, 198, 2, 220, 220, 220, 220, 16410, 58, 12, 16, 12095, 16, 12095, 16, 12095, 16, 12095, 16, 60, 38430, 16, 38430, 18, 38430, 20, 11907, 198, 2, 220, 220, 220, 220, 12429, 26410, 1174, 198, 2, 220, 220, 220, 220, 685, 8423, 11, 7942, 11, 7942, 11, 9562, 60, 198, 2, 220, 220, 220, 220, 12429, 3109, 11578, 341, 1174, 198, 2, 220, 220, 220, 220, 9938, 36, 3639, 1064, 36, 3639, 796, 649, 9938, 36, 3639, 26933, 12, 16, 12095, 16, 12095, 16, 12095, 16, 12095, 16, 36563, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 16, 1776, 3373, 1441, 6407, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 18, 1776, 3373, 1441, 6407, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 20, 1776, 3373, 1441, 10352, 198, 2, 220, 198, 2, 12429, 16281, 513, 25, 1174, 198, 2, 220, 198, 2, 12429, 0, 58, 16151, 5450, 1378, 19668, 13, 293, 316, 8189, 13, 785, 14, 39920, 14, 23344, 14, 1157, 14, 2998, 14, 2797, 7803, 12, 198, 2, 16362, 12, 19, 12, 16, 12, 16, 13, 9479, 8, 1174, 198, 2, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 220, 220, 220, 12429, 20560, 1174, 198, 2, 220, 220, 220, 220, 14631, 16742, 36, 3639, 2430, 19796, 2430, 19796, 2430, 19796, 2430, 19796, 8973, 198, 2, 220, 220, 220, 220, 16410, 58, 12, 16, 11, 8423, 12095, 16, 12095, 16, 11, 8423, 12095, 16, 60, 38430, 17, 38430, 18, 38430, 19, 38430, 20, 11907, 198, 2, 220, 220, 220, 220, 12429, 26410, 1174, 198, 2, 220, 220, 220, 220, 685, 8423, 11, 7942, 11, 9562, 11, 9562, 11, 7942, 60, 198, 2, 220, 220, 220, 220, 12429, 3109, 11578, 341, 1174, 198, 2, 220, 220, 220, 220, 9938, 36, 3639, 1064, 36, 3639, 796, 649, 9938, 36, 3639, 26933, 12, 16, 11, 8423, 12095, 16, 12095, 16, 11, 8423, 12095, 16, 36563, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 17, 1776, 3373, 1441, 6407, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 18, 1776, 3373, 1441, 10352, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 19, 1776, 3373, 1441, 10352, 198, 2, 220, 220, 220, 220, 1064, 36, 3639, 13, 19796, 7, 20, 1776, 3373, 1441, 6407, 198, 2, 220, 220, 220, 220, 220, 198, 2, 220, 198, 2, 220, 198, 2, 220, 198, 2, 12429, 3103, 2536, 6003, 25, 1174, 198, 2, 220, 198, 2, 220, 220, 1635, 4600, 27660, 19667, 13, 2100, 6624, 532, 16, 63, 198, 2, 220, 220, 1635, 383, 6001, 286, 262, 13934, 5509, 318, 1342, 621, 393, 4961, 284, 4600, 1238, 63, 198, 2, 220, 220, 1635, 383, 2472, 1271, 286, 13760, 318, 1022, 4600, 58, 16, 11, 838, 61, 19, 60, 63, 198, 2, 220, 220, 1635, 7472, 3848, 286, 4600, 19796, 3419, 63, 318, 1022, 4600, 58, 16, 11, 838, 61, 19, 60, 63, 198, 2, 220, 220, 1635, 4600, 15, 19841, 2496, 19841, 838, 61, 21, 63, 198, 2, 220, 198, 2, 220, 198, 2235, 2488, 44601, 2438, 28, 9688, 198, 3500, 1004, 316, 10669, 198, 198, 2235, 751, 534, 2438, 994, 25, 198, 2235, 2488, 44601, 2438, 28, 437, 198 ]
2.371212
1,188
push!(LOAD_PATH, "@stdlib") import Pkg; Pkg.add("Conda"); using Conda try run(`which nvcc`) ENV["GPU"] = 1 Pkg.build("ADCME") catch end using ADCME @info "Install Boost" CONDA = get_conda() run(`$CONDA install libboost==1.73.0=h3ff78a5_11`) # run(`$CONDA install boost==1.73.0`) @info "Install AMGCL" UNZIP = joinpath(ADCME.BINDIR, "unzip") if !isdir("$(@__DIR__)/amgcl") download("https://github.com/ddemidov/amgcl/archive/master.zip", "$(@__DIR__)/amgcl.zip") run(`$UNZIP -o $(@__DIR__)/amgcl.zip -d $(@__DIR__)`) mv("$(@__DIR__)/amgcl-master","$(@__DIR__)/amgcl", force=true) rm("$(@__DIR__)/amgcl.zip") end @info "Build Custom Operators" change_directory("CustomOps/build") require_file("build.ninja") do ADCME.cmake() end ADCME.make()
[ 14689, 0, 7, 35613, 62, 34219, 11, 44212, 19282, 8019, 4943, 198, 11748, 350, 10025, 26, 350, 10025, 13, 2860, 7203, 34, 13533, 15341, 220, 198, 3500, 9724, 64, 198, 28311, 220, 198, 220, 220, 220, 1057, 7, 63, 4758, 299, 85, 535, 63, 8, 198, 220, 220, 220, 12964, 53, 14692, 33346, 8973, 796, 352, 198, 220, 220, 220, 350, 10025, 13, 11249, 7203, 2885, 34, 11682, 4943, 198, 40198, 198, 437, 198, 3500, 49169, 11682, 220, 198, 198, 31, 10951, 366, 15798, 19835, 1, 198, 10943, 5631, 796, 651, 62, 66, 13533, 3419, 198, 5143, 7, 63, 3, 10943, 5631, 2721, 9195, 39521, 855, 16, 13, 4790, 13, 15, 28, 71, 18, 487, 3695, 64, 20, 62, 1157, 63, 8, 198, 2, 1057, 7, 63, 3, 10943, 5631, 2721, 5750, 855, 16, 13, 4790, 13, 15, 63, 8, 198, 198, 31, 10951, 366, 15798, 3001, 38, 5097, 1, 198, 4944, 57, 4061, 796, 4654, 6978, 7, 2885, 34, 11682, 13, 33, 12115, 4663, 11, 366, 403, 13344, 4943, 198, 361, 5145, 9409, 343, 7203, 3, 7, 31, 834, 34720, 834, 20679, 321, 70, 565, 4943, 198, 220, 220, 220, 4321, 7203, 5450, 1378, 12567, 13, 785, 14, 1860, 368, 312, 709, 14, 321, 70, 565, 14, 17474, 14, 9866, 13, 13344, 1600, 17971, 7, 31, 834, 34720, 834, 20679, 321, 70, 565, 13, 13344, 4943, 198, 220, 220, 220, 1057, 7, 63, 3, 4944, 57, 4061, 532, 78, 29568, 31, 834, 34720, 834, 20679, 321, 70, 565, 13, 13344, 532, 67, 29568, 31, 834, 34720, 834, 8, 63, 8, 198, 220, 220, 220, 285, 85, 7203, 3, 7, 31, 834, 34720, 834, 20679, 321, 70, 565, 12, 9866, 2430, 3, 7, 31, 834, 34720, 834, 20679, 321, 70, 565, 1600, 2700, 28, 7942, 8, 198, 220, 220, 220, 42721, 7203, 3, 7, 31, 834, 34720, 834, 20679, 321, 70, 565, 13, 13344, 4943, 198, 437, 198, 198, 31, 10951, 366, 15580, 8562, 6564, 2024, 1, 198, 3803, 62, 34945, 7203, 15022, 41472, 14, 11249, 4943, 198, 46115, 62, 7753, 7203, 11249, 13, 35073, 6592, 4943, 466, 198, 220, 220, 220, 49169, 11682, 13, 11215, 539, 3419, 198, 437, 198, 2885, 34, 11682, 13, 15883, 3419, 628, 198 ]
2.113821
369
<filename>src/gradients/zygote.jl import Base.getproperty import Base.findmin import Base.findmax import Base.push! using Zygote: @adjoint, @nograd import Zygote.literal_getproperty # ---- # # Vec3 # # ---- # # Hack to avoid nothing in the gradient due to typemax @adjoint bigmul(x::T) where {T} = bigmul(x), Δ -> (zero(T),) @adjoint Vec3(a, b, c) = Vec3(a, b, c), Δ -> (Δ.x, Δ.y, Δ.z) @adjoint literal_getproperty(v::Vec3, ::Val{:x}) = getproperty(v, :x), Δ -> (Vec3(Δ, zero(v.y), zero(v.z)), nothing) @adjoint literal_getproperty(v::Vec3, ::Val{:y}) = getproperty(v, :y), Δ -> (Vec3(zero(v.x), Δ, zero(v.z)), nothing) @adjoint literal_getproperty(v::Vec3, ::Val{:z}) = getproperty(v, :z), Δ -> (Vec3(zero(v.x), zero(v.y), Δ), nothing) @adjoint function dot(a::Vec3, b::Vec3) dot(a, b), Δ -> begin Δ = map(x -> isnothing(x) ? zero(eltype(a.x)) : x, Δ) t1 = Δ * b t2 = Δ * a if length(a.x) != length(t1.x) t1 = Vec3(sum(t1.x), sum(t1.y), sum(t1.z)) end if length(b.x) != length(t2.x) t2 = Vec3(sum(t2.x), sum(t2.y), sum(t2.z)) end return (t1, t2) end end # The purpose of this adjoint is to ensure type inference works # in the backward pass @adjoint function cross(a::Vec3{T}, b::Vec3{T}) where {T} cross(a, b), Δ -> begin ∇a = zero(a) ∇b = zero(b) x = (Δ.z .* b.y) .- (Δ.y .* b.z) y = (Δ.x .* b.z) .- (Δ.z .* b.x) z = (Δ.y .* b.x) .- (Δ.x .* b.y) if length(a.x) == 1 ∇a.x .= sum(x) ∇a.y .= sum(y) ∇a.z .= sum(z) else ∇a.x .= x ∇a.y .= y ∇a.z .= z end x = (Δ.y .* a.z) .- (Δ.z .* a.y) y = (Δ.z .* a.x) .- (Δ.x .* a.z) z = (Δ.x .* a.y) .- (Δ.y .* a.x) if length(b.x) == 1 ∇b.x .= sum(x) ∇b.y .= sum(y) ∇b.z .= sum(z) else ∇b.x .= x ∇b.y .= y ∇b.z .= z end return (∇a, ∇b) end end @adjoint place(a::Vec3, cond) = place(a, cond), Δ -> (Vec3(Δ.x[cond], Δ.y[cond], Δ.z[cond]), nothing) @adjoint place(a::Array, cond) = place(a, cond), Δ -> (Δ[cond], nothing) @adjoint place_idx!(a::Vec3, b::Vec3, idx) = place_idx!(a, b, idx), Δ -> (zero(Δ), Vec3(Δ[idx]...), nothing) # ----- # # Light # # ----- # # -------------- # # - PointLight - # # -------------- # @adjoint PointLight(color::Vec3, intensity, pos::Vec3) = PointLight(color, intensity, pos), Δ -> (Δ.color, Δ.intensity, Δ.position) @adjoint literal_getproperty(p::PointLight, ::Val{:color}) = getproperty(p, :color), Δ -> (PointLight(Δ, zero(p.intensity), zero(p.position)), nothing) @adjoint literal_getproperty(p::PointLight, ::Val{:intensity}) = getproperty(p, :intensity), Δ -> (PointLight(zero(p.color), Δ, zero(p.position)), nothing) @adjoint literal_getproperty(p::PointLight, ::Val{:position}) = getproperty(p, :position), Δ -> (PointLight(zero(p.color), zero(p.intensity), Δ), nothing) # ---------------- # # - DistantLight - # # ---------------- # @adjoint DistantLight(color::Vec3, intensity, direction::Vec3) = DistantLight(color, intensity, direction), Δ -> (Δ.color, Δ.intensity, Δ.direction) @adjoint literal_getproperty(d::DistantLight, ::Val{:color}) = getproperty(d, :color), Δ -> (DistantLight(Δ, zero(d.intensity), zero(d.direction)), nothing) @adjoint literal_getproperty(d::DistantLight, ::Val{:intensity}) = getproperty(d, :intensity), Δ -> (DistantLight(zero(d.color), Δ, zero(d.direction)), nothing) @adjoint literal_getproperty(d::DistantLight, ::Val{:direction}) = getproperty(d, :direction), Δ -> (DistantLight(zero(d.color), zero(d.intensity), Δ), nothing) # -------- # # Material # # -------- # @adjoint Material(color_ambient, color_diffuse, color_specular, specular_exponent, reflection, texture_ambient, texture_diffuse, texture_specular, uv_coordinates) = Material(color_ambient, color_diffuse, color_specular, specular_exponent, reflection, texture_ambient, texture_diffuse, texture_specular, uv_coordinates), Δ -> (Δ.color_ambient, Δ.color_diffuse, Δ.color_specular, Δ.specular_exponent, Δ.reflection, Δ.texture_ambient, Δ.texture_diffuse, Δ.texture_specular, Δ.uv_coordinates) @adjoint literal_getproperty(m::Material, ::Val{:color_ambient}) = getproperty(m, :color_ambient), Δ -> (Material(Δ, zero(m.color_diffuse), zero(m.color_specular), zero(m.specular_exponent), zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:color_diffuse}) = getproperty(m, :color_diffuse), Δ -> (Material(zero(m.color_ambient), Δ, zero(m.color_specular), zero(m.specular_exponent), zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:color_specular}) = getproperty(m, :color_specular), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), Δ, zero(m.specular_exponent), zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:specular_exponent}) = getproperty(m, :specular_exponent), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), zero(m.color_specular), Δ, zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:reflection}) = getproperty(m, :reflection), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), zero(m.color_specular), zero(m.specular_exponent), Δ, isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:texture_ambient}) = getproperty(m, :texture_ambient), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), zero(m.color_specular), zero(m.specular_exponent), zero(m.reflection), Δ, isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:texture_diffuse}) = getproperty(m, :texture_diffuse), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), zero(m.color_specular), zero(m.specular_exponent), zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), Δ, isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:texture_specular}) = getproperty(m, :texture_specular), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), zero(m.color_specular), zero(m.specular_exponent), zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), Δ, isnothing(m.uv_coordinates) ? nothing : zero.(m.uv_coordinates)), nothing) @adjoint literal_getproperty(m::Material, ::Val{:uv_coordinates}) = getproperty(m, :uv_coordinates), Δ -> (Material(zero(m.color_ambient), zero(m.color_diffuse), zero(m.color_specular), zero(m.specular_exponent), zero(m.reflection), isnothing(m.texture_ambient) ? nothing : zero(m.texture_ambient), isnothing(m.texture_diffuse) ? nothing : zero(m.texture_diffuse), isnothing(m.texture_specular) ? nothing : zero(m.texture_specular), Δ), nothing) # ------- # # Objects # # ------- # # ---------- # # - Sphere - # # ---------- # @adjoint Sphere(center, radius, material::Material) = Sphere(center, radius, material), Δ -> (Δ.sphere, Δ.radius, Δ.material) @adjoint literal_getproperty(s::Sphere, ::Val{:center}) = getproperty(s, :center), Δ -> (Sphere(Δ, zero(s.radius), zero(s.material)), nothing) @adjoint literal_getproperty(s::Sphere, ::Val{:radius}) = getproperty(s, :radius), Δ -> (Sphere(zero(s.center), Δ, zero(s.material)), nothing) @adjoint literal_getproperty(s::Sphere, ::Val{:material}) = getproperty(s, :material), Δ -> (Sphere(zero(s.center), zero(s.radius), Δ), nothing) # ------------ # # - Triangle - # # ------------ # @adjoint Triangle(v1, v2, v3, material::Material) = Triangle(v1, v2, v3, material), Δ -> (Δ.v1, Δ.v2, Δ.v3, Δ.material) @adjoint literal_getproperty(t::Triangle, ::Val{:v1}) = getproperty(t, :v1), Δ -> (Triangle(Δ, zero(t.v2), zero(t.v3), zero(t.material)), nothing) @adjoint literal_getproperty(t::Triangle, ::Val{:v2}) = getproperty(t, :v2), Δ -> (Triangle(zero(t.v1), Δ, zero(t.v3), zero(t.material)), nothing) @adjoint literal_getproperty(t::Triangle, ::Val{:v3}) = getproperty(t, :v3), Δ -> (Triangle(zero(t.v1), zero(t.v2), Δ, zero(t.material)), nothing) @adjoint literal_getproperty(t::Triangle, ::Val{:material}) = getproperty(t, :material), Δ -> (Triangle(zero(t.v1), zero(t.v2), zero(t.v3), Δ), nothing) # ---------------- # # - TriangleMesh - # # ---------------- # #= @adjoint TriangleMesh(tm, mat, ftmp) = TriangleMesh(tm, mat, ftmp), Δ -> (Δ.triangulated_mesh, Δ.material, Δ.ftmp) @adjoint function literal_getproperty(t::TriangleMesh, ::Val{:triangulated_mesh}) tm = getproperty(t, :triangulated_mesh) z = eltype(tm[1].v1.x) mat = Material(PlainColor(rgb(z)), z) return tm, Δ -> (TriangleMesh(Δ, mat, FixedTriangleMeshParams(IdDict(), [Vec3(z)])), nothing) end @adjoint function literal_getproperty(t::TriangleMesh, ::Val{:material}) mat = getproperty(t, :material) z = eltype(t.triangulated_mesh[1].v1.x) tm = [Triangle([Vec3(z)]...) for _ in 1:length(t.triangulated_mesh)] return mat, Δ -> (TriangleMesh(tm, Δ, FixedTriangleMeshParams(IdDict(), [Vec3(z)])), nothing) end @adjoint function literal_getproperty(t::TriangleMesh, ::Val{:ftmp}) z = eltype(t.triangulated_mesh[1].v1.x) mat = Material(PlainColor(rgb(z)), z) tm = [Triangle([Vec3(z)]...) for _ in 1:length(t.triangulated_mesh)] return getproperty(t, :ftmp), Δ -> (TriangleMesh(tm, mat, Δ), nothing) end @adjoint FixedTriangleMeshParams(isect, n) = FixedTriangleMeshParams(isect, n), Δ -> (Δ.isect, Δ.n) # The gradients for this params are never used so fill them with anything as long # as they are consistent with the types @adjoint literal_getproperty(ftmp::FixedTriangleMeshParams, ::Val{f}) where {f} = getproperty(ftmp, f), Δ -> (FixedTriangleMeshParams(IdDict(), ftmp.normals[1:1])) =# # ------ # # Camera # # ------ # @adjoint Camera(lf, la, vfov, focus, fp) = Camera(lf, la, vfov, focus, fp), Δ -> (Δ.lookfrom, Δ.lookat, Δ.vfov, Δ.focus, Δ.fixedparams) @adjoint literal_getproperty(c::Camera, ::Val{:lookfrom}) = getproperty(c, :lookfrom), Δ -> (Camera(Δ, zero(c.lookat), zero(c.vfov), zero(c.focus), zero(c.fixedparams)), nothing) @adjoint literal_getproperty(c::Camera, ::Val{:lookat}) = getproperty(c, :lookat), Δ -> (Camera(zero(c.lookfrom), Δ, zero(c.vfov), zero(c.focus), zero(c.fixedparams)), nothing) @adjoint literal_getproperty(c::Camera, ::Val{:vfov}) = getproperty(c, :vfov), Δ -> (Camera(zero(c.lookfrom), zero(c.lookat), Δ, zero(c.focus), zero(c.fixedparams)), nothing) @adjoint literal_getproperty(c::Camera, ::Val{:focus}) = getproperty(c, :focus), Δ -> (Camera(zero(c.lookfrom), zero(c.lookat), zero(c.vfov), Δ, zero(c.fixedparams)), nothing) @adjoint literal_getproperty(c::Camera, ::Val{:fixedparams}) = getproperty(c, :fixedparams), Δ -> (Camera(zero(c.lookfrom), zero(c.lookat), zero(c.vfov), zero(c.focus), Δ), nothing) @adjoint FixedCameraParams(vup, w, h) = FixedCameraParams(vup, w, h), Δ -> (Δ.vup, Δ.width, Δ.height) @adjoint literal_getproperty(fcp::FixedCameraParams, ::Val{f}) where {f} = getproperty(fcp, f), Δ -> (zero(fcp), nothing) # ------- # # ImUtils # # ------- # @adjoint function zeroonenorm(x) mini, indmin = findmin(x) maxi, indmax = findmax(x) res = (x .- mini) ./ (maxi - mini) function ∇zeroonenorm(Δ) ∇x = similar(x) fill!(∇x, 1 / (maxi - mini)) res1 = (x .- maxi) ./ (maxi - mini)^2 ∇x[indmin] = sum(res1) - minimum(res1) res2 = - res ./ (maxi - mini) ∇x[indmax] = sum(res2) - minimum(res2) return (∇x .* Δ, ) end return res, ∇zeroonenorm end # ----------------- # # General Functions # # ----------------- # for func in (:findmin, :findmax) @eval begin @adjoint function $(func)(xs::AbstractArray; dims = :) y = $(func)(xs, dims = dims) function dfunc(Δ) res = zero(xs) res[y[2]] .= Δ[1] return (res, nothing) end return y, dfunc end end end @adjoint reducehcat(x) = reduce(hcat, x), Δ -> ([Δ[:, i] for i in 1:length(x)], ) @adjoint push!(arr, val) = push!(arr, val), Δ -> (Δ[1:end-1], Δ[end]) @nograd fill @nograd function update_index!(arr, i, j, val) arr[i, j] = val end
[ 27, 34345, 29, 10677, 14, 9744, 2334, 14, 7357, 70, 1258, 13, 20362, 198, 11748, 7308, 13, 1136, 26745, 198, 11748, 7308, 13, 19796, 1084, 198, 11748, 7308, 13, 19796, 9806, 198, 11748, 7308, 13, 14689, 0, 198, 198, 3500, 1168, 35641, 1258, 25, 2488, 41255, 1563, 11, 2488, 77, 519, 6335, 198, 198, 11748, 1168, 35641, 1258, 13, 18250, 1691, 62, 1136, 26745, 198, 198, 2, 13498, 1303, 198, 2, 38692, 18, 1303, 198, 2, 13498, 1303, 198, 198, 2, 18281, 284, 3368, 2147, 287, 262, 31312, 2233, 284, 2170, 368, 897, 198, 31, 41255, 1563, 1263, 76, 377, 7, 87, 3712, 51, 8, 810, 1391, 51, 92, 796, 1263, 76, 377, 7, 87, 828, 37455, 4613, 357, 22570, 7, 51, 828, 8, 198, 198, 31, 41255, 1563, 38692, 18, 7, 64, 11, 275, 11, 269, 8, 796, 38692, 18, 7, 64, 11, 275, 11, 269, 828, 37455, 4613, 357, 138, 242, 13, 87, 11, 37455, 13, 88, 11, 37455, 13, 89, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 85, 3712, 53, 721, 18, 11, 7904, 7762, 90, 25, 87, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 85, 11, 1058, 87, 828, 37455, 4613, 357, 53, 721, 18, 7, 138, 242, 11, 6632, 7, 85, 13, 88, 828, 6632, 7, 85, 13, 89, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 85, 3712, 53, 721, 18, 11, 7904, 7762, 90, 25, 88, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 85, 11, 1058, 88, 828, 37455, 4613, 357, 53, 721, 18, 7, 22570, 7, 85, 13, 87, 828, 37455, 11, 6632, 7, 85, 13, 89, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 85, 3712, 53, 721, 18, 11, 7904, 7762, 90, 25, 89, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 85, 11, 1058, 89, 828, 37455, 4613, 357, 53, 721, 18, 7, 22570, 7, 85, 13, 87, 828, 6632, 7, 85, 13, 88, 828, 37455, 828, 2147, 8, 198, 198, 31, 41255, 1563, 2163, 16605, 7, 64, 3712, 53, 721, 18, 11, 275, 3712, 53, 721, 18, 8, 197, 198, 220, 220, 220, 16605, 7, 64, 11, 275, 828, 37455, 4613, 2221, 197, 198, 220, 220, 220, 220, 220, 220, 220, 37455, 796, 3975, 7, 87, 4613, 318, 22366, 7, 87, 8, 5633, 6632, 7, 417, 4906, 7, 64, 13, 87, 4008, 1058, 2124, 11, 37455, 8, 197, 198, 220, 220, 220, 220, 220, 220, 220, 256, 16, 796, 37455, 1635, 275, 197, 198, 220, 220, 220, 220, 220, 220, 220, 256, 17, 796, 37455, 1635, 257, 197, 198, 220, 220, 220, 220, 220, 220, 220, 611, 4129, 7, 64, 13, 87, 8, 14512, 4129, 7, 83, 16, 13, 87, 8, 197, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 16, 796, 38692, 18, 7, 16345, 7, 83, 16, 13, 87, 828, 2160, 7, 83, 16, 13, 88, 828, 2160, 7, 83, 16, 13, 89, 4008, 197, 198, 220, 220, 220, 220, 220, 220, 220, 886, 197, 198, 220, 220, 220, 220, 220, 220, 220, 611, 4129, 7, 65, 13, 87, 8, 14512, 4129, 7, 83, 17, 13, 87, 8, 197, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 17, 796, 38692, 18, 7, 16345, 7, 83, 17, 13, 87, 828, 2160, 7, 83, 17, 13, 88, 828, 2160, 7, 83, 17, 13, 89, 4008, 197, 198, 220, 220, 220, 220, 220, 220, 220, 886, 197, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 357, 83, 16, 11, 256, 17, 8, 197, 198, 220, 220, 220, 886, 197, 198, 437, 198, 220, 220, 220, 220, 198, 2, 383, 4007, 286, 428, 9224, 1563, 318, 284, 4155, 2099, 32278, 2499, 198, 2, 287, 262, 19528, 1208, 198, 31, 41255, 1563, 2163, 3272, 7, 64, 3712, 53, 721, 18, 90, 51, 5512, 275, 3712, 53, 721, 18, 90, 51, 30072, 810, 1391, 51, 92, 198, 220, 220, 220, 3272, 7, 64, 11, 275, 828, 37455, 4613, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 796, 6632, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 796, 6632, 7, 65, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2124, 796, 357, 138, 242, 13, 89, 764, 9, 275, 13, 88, 8, 764, 12, 357, 138, 242, 13, 88, 764, 9, 275, 13, 89, 8, 198, 220, 220, 220, 220, 220, 220, 220, 331, 796, 357, 138, 242, 13, 87, 764, 9, 275, 13, 89, 8, 764, 12, 357, 138, 242, 13, 89, 764, 9, 275, 13, 87, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1976, 796, 357, 138, 242, 13, 88, 764, 9, 275, 13, 87, 8, 764, 12, 357, 138, 242, 13, 87, 764, 9, 275, 13, 88, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 4129, 7, 64, 13, 87, 8, 6624, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 13, 87, 764, 28, 2160, 7, 87, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 13, 88, 764, 28, 2160, 7, 88, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 13, 89, 764, 28, 2160, 7, 89, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 13, 87, 764, 28, 2124, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 13, 88, 764, 28, 331, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 64, 13, 89, 764, 28, 1976, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 2124, 796, 357, 138, 242, 13, 88, 764, 9, 257, 13, 89, 8, 764, 12, 357, 138, 242, 13, 89, 764, 9, 257, 13, 88, 8, 198, 220, 220, 220, 220, 220, 220, 220, 331, 796, 357, 138, 242, 13, 89, 764, 9, 257, 13, 87, 8, 764, 12, 357, 138, 242, 13, 87, 764, 9, 257, 13, 89, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1976, 796, 357, 138, 242, 13, 87, 764, 9, 257, 13, 88, 8, 764, 12, 357, 138, 242, 13, 88, 764, 9, 257, 13, 87, 8, 198, 220, 220, 220, 220, 220, 220, 220, 611, 4129, 7, 65, 13, 87, 8, 6624, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 13, 87, 764, 28, 2160, 7, 87, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 13, 88, 764, 28, 2160, 7, 88, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 13, 89, 764, 28, 2160, 7, 89, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 13, 87, 764, 28, 2124, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 13, 88, 764, 28, 331, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 65, 13, 89, 764, 28, 1976, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 357, 24861, 229, 64, 11, 18872, 229, 65, 8, 198, 220, 220, 220, 886, 198, 437, 198, 198, 31, 41255, 1563, 1295, 7, 64, 3712, 53, 721, 18, 11, 1779, 8, 796, 1295, 7, 64, 11, 1779, 828, 37455, 4613, 357, 53, 721, 18, 7, 138, 242, 13, 87, 58, 17561, 4357, 37455, 13, 88, 58, 17561, 4357, 37455, 13, 89, 58, 17561, 46570, 2147, 8, 198, 198, 31, 41255, 1563, 1295, 7, 64, 3712, 19182, 11, 1779, 8, 796, 1295, 7, 64, 11, 1779, 828, 37455, 4613, 357, 138, 242, 58, 17561, 4357, 2147, 8, 198, 198, 31, 41255, 1563, 1295, 62, 312, 87, 0, 7, 64, 3712, 53, 721, 18, 11, 275, 3712, 53, 721, 18, 11, 4686, 87, 8, 796, 1295, 62, 312, 87, 0, 7, 64, 11, 275, 11, 4686, 87, 828, 37455, 4613, 357, 22570, 7, 138, 242, 828, 38692, 18, 7, 138, 242, 58, 312, 87, 60, 986, 828, 2147, 8, 198, 198, 2, 37404, 1303, 198, 2, 4401, 1303, 198, 2, 37404, 1303, 198, 198, 2, 220, 26171, 1303, 198, 2, 532, 6252, 15047, 532, 1303, 198, 2, 220, 26171, 1303, 198, 198, 31, 41255, 1563, 6252, 15047, 7, 8043, 3712, 53, 721, 18, 11, 12245, 11, 1426, 3712, 53, 721, 18, 8, 796, 198, 220, 220, 220, 6252, 15047, 7, 8043, 11, 12245, 11, 1426, 828, 37455, 4613, 357, 138, 242, 13, 8043, 11, 37455, 13, 47799, 11, 37455, 13, 9150, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 79, 3712, 12727, 15047, 11, 7904, 7762, 90, 25, 8043, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 79, 11, 1058, 8043, 828, 37455, 4613, 357, 12727, 15047, 7, 138, 242, 11, 6632, 7, 79, 13, 47799, 828, 6632, 7, 79, 13, 9150, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 79, 3712, 12727, 15047, 11, 7904, 7762, 90, 25, 47799, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 79, 11, 1058, 47799, 828, 37455, 4613, 357, 12727, 15047, 7, 22570, 7, 79, 13, 8043, 828, 37455, 11, 6632, 7, 79, 13, 9150, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 79, 3712, 12727, 15047, 11, 7904, 7762, 90, 25, 9150, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 79, 11, 1058, 9150, 828, 37455, 4613, 357, 12727, 15047, 7, 22570, 7, 79, 13, 8043, 828, 6632, 7, 79, 13, 47799, 828, 37455, 828, 2147, 8, 198, 198, 2, 34400, 1303, 198, 2, 532, 4307, 415, 15047, 532, 1303, 198, 2, 34400, 1303, 198, 198, 31, 41255, 1563, 4307, 415, 15047, 7, 8043, 3712, 53, 721, 18, 11, 12245, 11, 4571, 3712, 53, 721, 18, 8, 796, 198, 220, 220, 220, 4307, 415, 15047, 7, 8043, 11, 12245, 11, 4571, 828, 37455, 4613, 357, 138, 242, 13, 8043, 11, 37455, 13, 47799, 11, 37455, 13, 37295, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 67, 3712, 35, 10167, 15047, 11, 7904, 7762, 90, 25, 8043, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 67, 11, 1058, 8043, 828, 37455, 4613, 357, 35, 10167, 15047, 7, 138, 242, 11, 6632, 7, 67, 13, 47799, 828, 6632, 7, 67, 13, 37295, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 67, 3712, 35, 10167, 15047, 11, 7904, 7762, 90, 25, 47799, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 67, 11, 1058, 47799, 828, 37455, 4613, 357, 35, 10167, 15047, 7, 22570, 7, 67, 13, 8043, 828, 37455, 11, 6632, 7, 67, 13, 37295, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 67, 3712, 35, 10167, 15047, 11, 7904, 7762, 90, 25, 37295, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 67, 11, 1058, 37295, 828, 37455, 4613, 357, 35, 10167, 15047, 7, 22570, 7, 67, 13, 8043, 828, 6632, 7, 67, 13, 47799, 828, 37455, 828, 2147, 8, 198, 198, 2, 24200, 1303, 198, 2, 14633, 1303, 198, 2, 24200, 1303, 198, 198, 31, 41255, 1563, 14633, 7, 8043, 62, 4131, 1153, 11, 3124, 62, 26069, 1904, 11, 3124, 62, 4125, 10440, 11, 1020, 934, 62, 11201, 3471, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 14580, 11, 11743, 62, 4131, 1153, 11, 11743, 62, 26069, 1904, 11, 11743, 62, 4125, 10440, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 334, 85, 62, 37652, 17540, 8, 796, 198, 220, 220, 220, 14633, 7, 8043, 62, 4131, 1153, 11, 3124, 62, 26069, 1904, 11, 3124, 62, 4125, 10440, 11, 1020, 934, 62, 11201, 3471, 11, 14580, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 11743, 62, 4131, 1153, 11, 11743, 62, 26069, 1904, 11, 11743, 62, 4125, 10440, 11, 334, 85, 62, 37652, 17540, 828, 198, 220, 220, 220, 37455, 4613, 357, 138, 242, 13, 8043, 62, 4131, 1153, 11, 37455, 13, 8043, 62, 26069, 1904, 11, 37455, 13, 8043, 62, 4125, 10440, 11, 37455, 13, 4125, 10440, 62, 11201, 3471, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 37455, 13, 5420, 1564, 11, 37455, 13, 41293, 62, 4131, 1153, 11, 37455, 13, 41293, 62, 26069, 1904, 11, 37455, 13, 41293, 62, 4125, 10440, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 37455, 13, 14795, 62, 37652, 17540, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 8043, 62, 4131, 1153, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 8043, 62, 4131, 1153, 828, 37455, 4613, 357, 17518, 7, 138, 242, 11, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 8043, 62, 26069, 1904, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 8043, 62, 26069, 1904, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 37455, 11, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 8043, 62, 4125, 10440, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 8043, 62, 4125, 10440, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 37455, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 220, 220, 220, 220, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 4125, 10440, 62, 11201, 3471, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 4125, 10440, 62, 11201, 3471, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 37455, 11, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 5420, 1564, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 5420, 1564, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 37455, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 41293, 62, 4131, 1153, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 41293, 62, 4131, 1153, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 5420, 1564, 828, 37455, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 41293, 62, 26069, 1904, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 41293, 62, 26069, 1904, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 37455, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 41293, 62, 4125, 10440, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 41293, 62, 4125, 10440, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 37455, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 14795, 62, 37652, 17540, 8, 5633, 2147, 1058, 6632, 12195, 76, 13, 14795, 62, 37652, 17540, 36911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 76, 3712, 17518, 11, 7904, 7762, 90, 25, 14795, 62, 37652, 17540, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 76, 11, 1058, 14795, 62, 37652, 17540, 828, 37455, 4613, 357, 17518, 7, 22570, 7, 76, 13, 8043, 62, 4131, 1153, 828, 6632, 7, 76, 13, 8043, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 8043, 62, 4125, 10440, 828, 6632, 7, 76, 13, 4125, 10440, 62, 11201, 3471, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 76, 13, 5420, 1564, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4131, 1153, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4131, 1153, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 26069, 1904, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 26069, 1904, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 22366, 7, 76, 13, 41293, 62, 4125, 10440, 8, 5633, 2147, 1058, 6632, 7, 76, 13, 41293, 62, 4125, 10440, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 37455, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2147, 8, 198, 2, 35656, 1303, 198, 2, 35832, 1303, 198, 2, 35656, 1303, 198, 198, 2, 24200, 438, 1303, 198, 2, 532, 31798, 532, 1303, 198, 2, 24200, 438, 1303, 198, 198, 31, 41255, 1563, 31798, 7, 16159, 11, 16874, 11, 2587, 3712, 17518, 8, 796, 198, 220, 220, 220, 31798, 7, 16159, 11, 16874, 11, 2587, 828, 37455, 4613, 357, 138, 242, 13, 2777, 1456, 11, 37455, 13, 42172, 11, 37455, 13, 33665, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 82, 3712, 38882, 11, 7904, 7762, 90, 25, 16159, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 82, 11, 1058, 16159, 828, 37455, 4613, 357, 38882, 7, 138, 242, 11, 6632, 7, 82, 13, 42172, 828, 6632, 7, 82, 13, 33665, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 82, 3712, 38882, 11, 7904, 7762, 90, 25, 42172, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 82, 11, 1058, 42172, 828, 37455, 4613, 357, 38882, 7, 22570, 7, 82, 13, 16159, 828, 37455, 11, 6632, 7, 82, 13, 33665, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 82, 3712, 38882, 11, 7904, 7762, 90, 25, 33665, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 82, 11, 1058, 33665, 828, 37455, 4613, 357, 38882, 7, 22570, 7, 82, 13, 16159, 828, 6632, 7, 82, 13, 42172, 828, 37455, 828, 2147, 8, 198, 220, 220, 220, 220, 198, 2, 220, 10541, 1303, 198, 2, 532, 33233, 532, 1303, 198, 2, 220, 10541, 1303, 198, 220, 220, 198, 31, 41255, 1563, 33233, 7, 85, 16, 11, 410, 17, 11, 410, 18, 11, 2587, 3712, 17518, 8, 796, 198, 220, 220, 220, 33233, 7, 85, 16, 11, 410, 17, 11, 410, 18, 11, 2587, 828, 37455, 4613, 357, 138, 242, 13, 85, 16, 11, 37455, 13, 85, 17, 11, 37455, 13, 85, 18, 11, 37455, 13, 33665, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 11, 7904, 7762, 90, 25, 85, 16, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 83, 11, 1058, 85, 16, 828, 37455, 4613, 357, 14824, 9248, 7, 138, 242, 11, 6632, 7, 83, 13, 85, 17, 828, 6632, 7, 83, 13, 85, 18, 828, 6632, 7, 83, 13, 33665, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 11, 7904, 7762, 90, 25, 85, 17, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 83, 11, 1058, 85, 17, 828, 37455, 4613, 357, 14824, 9248, 7, 22570, 7, 83, 13, 85, 16, 828, 37455, 11, 6632, 7, 83, 13, 85, 18, 828, 6632, 7, 83, 13, 33665, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 11, 7904, 7762, 90, 25, 85, 18, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 83, 11, 1058, 85, 18, 828, 37455, 4613, 357, 14824, 9248, 7, 22570, 7, 83, 13, 85, 16, 828, 6632, 7, 83, 13, 85, 17, 828, 37455, 11, 6632, 7, 83, 13, 33665, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 11, 7904, 7762, 90, 25, 33665, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 83, 11, 1058, 33665, 828, 37455, 4613, 357, 14824, 9248, 7, 22570, 7, 83, 13, 85, 16, 828, 6632, 7, 83, 13, 85, 17, 828, 6632, 7, 83, 13, 85, 18, 828, 37455, 828, 2147, 8, 198, 198, 2, 34400, 1303, 198, 2, 532, 33233, 37031, 532, 1303, 198, 2, 34400, 1303, 198, 198, 2, 28, 198, 31, 41255, 1563, 33233, 37031, 7, 17209, 11, 2603, 11, 10117, 3149, 8, 796, 198, 220, 220, 220, 33233, 37031, 7, 17209, 11, 2603, 11, 10117, 3149, 828, 37455, 4613, 357, 138, 242, 13, 28461, 648, 4817, 62, 76, 5069, 11, 37455, 13, 33665, 11, 37455, 13, 701, 3149, 8, 198, 198, 31, 41255, 1563, 2163, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 37031, 11, 7904, 7762, 90, 25, 28461, 648, 4817, 62, 76, 5069, 30072, 198, 220, 220, 220, 256, 76, 796, 651, 26745, 7, 83, 11, 1058, 28461, 648, 4817, 62, 76, 5069, 8, 198, 220, 220, 220, 1976, 796, 1288, 4906, 7, 17209, 58, 16, 4083, 85, 16, 13, 87, 8, 198, 220, 220, 220, 2603, 796, 14633, 7, 3646, 391, 10258, 7, 81, 22296, 7, 89, 36911, 1976, 8, 198, 220, 220, 220, 1441, 256, 76, 11, 37455, 4613, 357, 14824, 9248, 37031, 7, 138, 242, 11, 2603, 11, 10832, 14824, 9248, 37031, 10044, 4105, 7, 7390, 35, 713, 22784, 685, 53, 721, 18, 7, 89, 8, 12962, 828, 2147, 8, 198, 437, 198, 198, 31, 41255, 1563, 2163, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 37031, 11, 7904, 7762, 90, 25, 33665, 30072, 198, 220, 220, 220, 2603, 796, 651, 26745, 7, 83, 11, 1058, 33665, 8, 198, 220, 220, 220, 1976, 796, 1288, 4906, 7, 83, 13, 28461, 648, 4817, 62, 76, 5069, 58, 16, 4083, 85, 16, 13, 87, 8, 198, 220, 220, 220, 256, 76, 796, 685, 14824, 9248, 26933, 53, 721, 18, 7, 89, 15437, 23029, 329, 4808, 287, 352, 25, 13664, 7, 83, 13, 28461, 648, 4817, 62, 76, 5069, 15437, 198, 220, 220, 220, 1441, 2603, 11, 37455, 4613, 357, 14824, 9248, 37031, 7, 17209, 11, 37455, 11, 10832, 14824, 9248, 37031, 10044, 4105, 7, 7390, 35, 713, 22784, 685, 53, 721, 18, 7, 89, 8, 12962, 828, 2147, 8, 198, 437, 198, 198, 31, 41255, 1563, 2163, 18875, 62, 1136, 26745, 7, 83, 3712, 14824, 9248, 37031, 11, 7904, 7762, 90, 25, 701, 3149, 30072, 198, 220, 220, 220, 1976, 796, 1288, 4906, 7, 83, 13, 28461, 648, 4817, 62, 76, 5069, 58, 16, 4083, 85, 16, 13, 87, 8, 198, 220, 220, 220, 2603, 796, 14633, 7, 3646, 391, 10258, 7, 81, 22296, 7, 89, 36911, 1976, 8, 198, 220, 220, 220, 256, 76, 796, 685, 14824, 9248, 26933, 53, 721, 18, 7, 89, 15437, 23029, 329, 4808, 287, 352, 25, 13664, 7, 83, 13, 28461, 648, 4817, 62, 76, 5069, 15437, 198, 220, 220, 220, 1441, 651, 26745, 7, 83, 11, 1058, 701, 3149, 828, 37455, 4613, 357, 14824, 9248, 37031, 7, 17209, 11, 2603, 11, 37455, 828, 2147, 8, 198, 437, 198, 198, 31, 41255, 1563, 10832, 14824, 9248, 37031, 10044, 4105, 7, 271, 478, 11, 299, 8, 796, 198, 220, 220, 220, 10832, 14824, 9248, 37031, 10044, 4105, 7, 271, 478, 11, 299, 828, 37455, 4613, 357, 138, 242, 13, 271, 478, 11, 37455, 13, 77, 8, 198, 198, 2, 383, 3915, 2334, 329, 428, 42287, 389, 1239, 973, 523, 6070, 606, 351, 1997, 355, 890, 198, 2, 355, 484, 389, 6414, 351, 262, 3858, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 701, 3149, 3712, 13715, 14824, 9248, 37031, 10044, 4105, 11, 7904, 7762, 90, 69, 30072, 810, 1391, 69, 92, 796, 198, 220, 220, 220, 651, 26745, 7, 701, 3149, 11, 277, 828, 37455, 4613, 357, 13715, 14824, 9248, 37031, 10044, 4105, 7, 7390, 35, 713, 22784, 10117, 3149, 13, 27237, 874, 58, 16, 25, 16, 60, 4008, 198, 46249, 198, 198, 2, 40103, 1303, 198, 2, 20432, 1303, 198, 2, 40103, 1303, 198, 198, 31, 41255, 1563, 20432, 7, 1652, 11, 8591, 11, 410, 69, 709, 11, 2962, 11, 277, 79, 8, 796, 198, 220, 220, 220, 20432, 7, 1652, 11, 8591, 11, 410, 69, 709, 11, 2962, 11, 277, 79, 828, 37455, 4613, 357, 138, 242, 13, 5460, 6738, 11, 37455, 13, 5460, 265, 11, 37455, 13, 85, 69, 709, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 37455, 13, 37635, 11, 37455, 13, 34021, 37266, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 66, 3712, 35632, 11, 7904, 7762, 90, 25, 5460, 6738, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 66, 11, 1058, 5460, 6738, 828, 37455, 4613, 357, 35632, 7, 138, 242, 11, 6632, 7, 66, 13, 5460, 265, 828, 6632, 7, 66, 13, 85, 69, 709, 828, 6632, 7, 66, 13, 37635, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 66, 13, 34021, 37266, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 66, 3712, 35632, 11, 7904, 7762, 90, 25, 5460, 265, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 66, 11, 1058, 5460, 265, 828, 37455, 4613, 357, 35632, 7, 22570, 7, 66, 13, 5460, 6738, 828, 37455, 11, 6632, 7, 66, 13, 85, 69, 709, 828, 6632, 7, 66, 13, 37635, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 66, 13, 34021, 37266, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 66, 3712, 35632, 11, 7904, 7762, 90, 25, 85, 69, 709, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 66, 11, 1058, 85, 69, 709, 828, 37455, 4613, 357, 35632, 7, 22570, 7, 66, 13, 5460, 6738, 828, 6632, 7, 66, 13, 5460, 265, 828, 37455, 11, 6632, 7, 66, 13, 37635, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 66, 13, 34021, 37266, 36911, 2147, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 66, 3712, 35632, 11, 7904, 7762, 90, 25, 37635, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 66, 11, 1058, 37635, 828, 37455, 4613, 357, 35632, 7, 22570, 7, 66, 13, 5460, 6738, 828, 6632, 7, 66, 13, 5460, 265, 828, 6632, 7, 66, 13, 85, 69, 709, 828, 37455, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 66, 13, 34021, 37266, 36911, 2147, 8, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 66, 3712, 35632, 11, 7904, 7762, 90, 25, 34021, 37266, 30072, 796, 198, 220, 220, 220, 651, 26745, 7, 66, 11, 1058, 34021, 37266, 828, 37455, 4613, 357, 35632, 7, 22570, 7, 66, 13, 5460, 6738, 828, 6632, 7, 66, 13, 5460, 265, 828, 6632, 7, 66, 13, 85, 69, 709, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6632, 7, 66, 13, 37635, 828, 37455, 828, 2147, 8, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 198, 198, 31, 41255, 1563, 10832, 35632, 10044, 4105, 7, 85, 929, 11, 266, 11, 289, 8, 796, 198, 220, 220, 220, 10832, 35632, 10044, 4105, 7, 85, 929, 11, 266, 11, 289, 828, 37455, 4613, 357, 138, 242, 13, 85, 929, 11, 37455, 13, 10394, 11, 37455, 13, 17015, 8, 198, 198, 31, 41255, 1563, 18875, 62, 1136, 26745, 7, 69, 13155, 3712, 13715, 35632, 10044, 4105, 11, 7904, 7762, 90, 69, 30072, 810, 1391, 69, 92, 796, 198, 220, 220, 220, 651, 26745, 7, 69, 13155, 11, 277, 828, 37455, 4613, 357, 22570, 7, 69, 13155, 828, 2147, 8, 198, 220, 220, 198, 2, 35656, 1303, 197, 198, 2, 1846, 18274, 4487, 1303, 197, 198, 2, 35656, 1303, 197, 198, 198, 31, 41255, 1563, 2163, 1976, 263, 2049, 268, 579, 7, 87, 8, 197, 198, 220, 220, 220, 9927, 11, 773, 1084, 796, 1064, 1084, 7, 87, 8, 197, 198, 220, 220, 220, 3509, 72, 11, 773, 9806, 796, 1064, 9806, 7, 87, 8, 197, 198, 220, 220, 220, 581, 796, 357, 87, 764, 12, 9927, 8, 24457, 357, 9806, 72, 532, 9927, 8, 197, 198, 220, 220, 220, 2163, 18872, 229, 9107, 2049, 268, 579, 7, 138, 242, 8, 197, 198, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 87, 796, 2092, 7, 87, 8, 197, 198, 220, 220, 220, 220, 220, 220, 220, 6070, 0, 7, 24861, 229, 87, 11, 352, 1220, 357, 9806, 72, 532, 9927, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 581, 16, 796, 357, 87, 764, 12, 3509, 72, 8, 24457, 357, 9806, 72, 532, 9927, 8, 61, 17, 198, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 87, 58, 521, 1084, 60, 796, 2160, 7, 411, 16, 8, 532, 5288, 7, 411, 16, 8, 220, 198, 220, 220, 220, 220, 220, 220, 220, 581, 17, 796, 532, 581, 24457, 357, 9806, 72, 532, 9927, 8, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 18872, 229, 87, 58, 521, 9806, 60, 796, 2160, 7, 411, 17, 8, 532, 5288, 7, 411, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 357, 24861, 229, 87, 764, 9, 37455, 11, 1267, 197, 198, 220, 220, 220, 886, 197, 198, 220, 220, 220, 1441, 581, 11, 18872, 229, 9107, 2049, 268, 579, 197, 198, 437, 198, 198, 2, 34400, 12, 1303, 198, 2, 3611, 40480, 1303, 198, 2, 34400, 12, 1303, 198, 198, 1640, 25439, 287, 357, 25, 19796, 1084, 11, 1058, 19796, 9806, 8, 198, 220, 220, 220, 2488, 18206, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 41255, 1563, 2163, 29568, 20786, 5769, 34223, 3712, 23839, 19182, 26, 5391, 82, 796, 14373, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 796, 29568, 20786, 5769, 34223, 11, 5391, 82, 796, 5391, 82, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2163, 288, 20786, 7, 138, 242, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 581, 796, 6632, 7, 34223, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 581, 58, 88, 58, 17, 11907, 764, 28, 37455, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 357, 411, 11, 2147, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1441, 331, 11, 288, 20786, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 437, 198, 198, 31, 41255, 1563, 4646, 71, 9246, 7, 87, 8, 796, 4646, 7, 71, 9246, 11, 2124, 828, 37455, 4613, 29565, 138, 242, 58, 45299, 1312, 60, 329, 1312, 287, 352, 25, 13664, 7, 87, 8, 4357, 1267, 198, 198, 31, 41255, 1563, 4574, 0, 7, 3258, 11, 1188, 8, 796, 4574, 0, 7, 3258, 11, 1188, 828, 37455, 4613, 357, 138, 242, 58, 16, 25, 437, 12, 16, 4357, 37455, 58, 437, 12962, 198, 198, 31, 77, 519, 6335, 6070, 198, 198, 31, 77, 519, 6335, 2163, 4296, 62, 9630, 0, 7, 3258, 11, 1312, 11, 474, 11, 1188, 8, 198, 220, 220, 220, 5240, 58, 72, 11, 474, 60, 796, 1188, 198, 437, 220, 198 ]
1.893308
9,101
<filename>src/callback.jl # Callbacks functions function fbs_trace(t, θ, loss, reg) @printf("iter %5d : loss = %8.4f, reg = %8.4f, total = %8.4f, ", t, loss, reg, loss+reg) @printf("non zero = %d\n", sum(θ .!= 0.)) end function fista_trace(t, θ, loss, reg, α) @printf("iter %5d : loss = %8.4f, reg = %8.4f, total = %8.4f, ", t, loss, reg, loss+reg) @printf("α = %4.2f, non zero = %d\n", α, sum(θ .!= 0.)) end function fasta_trace(t, θ, loss, reg, λ, α, bt) @printf("iter %5d : loss = %8.4f, reg = %8.4f, total = %8.4f, ", t, loss, reg, loss+reg) @printf("λ = %8.5f, α = %4.2f, backtracks = %2d, non zero = %d\n", λ, α, bt, sum(θ .!= 0.)) end
[ 27, 34345, 29, 10677, 14, 47423, 13, 20362, 198, 2, 4889, 10146, 5499, 198, 198, 8818, 277, 1443, 62, 40546, 7, 83, 11, 7377, 116, 11, 2994, 11, 842, 8, 198, 220, 220, 220, 2488, 37435, 7203, 2676, 4064, 20, 67, 1058, 2994, 796, 4064, 23, 13, 19, 69, 11, 842, 796, 4064, 23, 13, 19, 69, 11, 2472, 796, 4064, 23, 13, 19, 69, 11, 33172, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 11, 2994, 11, 842, 11, 2994, 10, 2301, 8, 198, 220, 220, 220, 2488, 37435, 7203, 13159, 6632, 796, 4064, 67, 59, 77, 1600, 2160, 7, 138, 116, 764, 0, 28, 657, 2014, 8, 198, 437, 198, 198, 8818, 277, 12523, 62, 40546, 7, 83, 11, 7377, 116, 11, 2994, 11, 842, 11, 26367, 8, 198, 220, 220, 220, 2488, 37435, 7203, 2676, 4064, 20, 67, 1058, 2994, 796, 4064, 23, 13, 19, 69, 11, 842, 796, 4064, 23, 13, 19, 69, 11, 2472, 796, 4064, 23, 13, 19, 69, 11, 33172, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 11, 2994, 11, 842, 11, 2994, 10, 2301, 8, 198, 220, 220, 220, 2488, 37435, 7203, 17394, 796, 4064, 19, 13, 17, 69, 11, 1729, 6632, 796, 4064, 67, 59, 77, 1600, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 26367, 11, 2160, 7, 138, 116, 764, 0, 28, 657, 2014, 8, 198, 437, 198, 198, 8818, 3049, 64, 62, 40546, 7, 83, 11, 7377, 116, 11, 2994, 11, 842, 11, 7377, 119, 11, 26367, 11, 275, 83, 8, 198, 220, 220, 220, 2488, 37435, 7203, 2676, 4064, 20, 67, 1058, 2994, 796, 4064, 23, 13, 19, 69, 11, 842, 796, 4064, 23, 13, 19, 69, 11, 2472, 796, 4064, 23, 13, 19, 69, 11, 33172, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 256, 11, 2994, 11, 842, 11, 2994, 10, 2301, 8, 198, 220, 220, 220, 2488, 37435, 7203, 39377, 796, 4064, 23, 13, 20, 69, 11, 26367, 796, 4064, 19, 13, 17, 69, 11, 736, 46074, 796, 4064, 17, 67, 11, 1729, 6632, 796, 4064, 67, 59, 77, 1600, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 7377, 119, 11, 26367, 11, 275, 83, 11, 2160, 7, 138, 116, 764, 0, 28, 657, 2014, 8, 198, 437, 628 ]
1.825871
402
include("../utils.jl") include("group_utils.jl") @testset "Circle group" begin G = CircleGroup() @test repr(G) == "CircleGroup()" @test base_manifold(G) === Circle{ℂ}() @testset "identity overloads" begin @test identity(G, Identity(G)) === Identity(G) @test inv(G, Identity(G)) === Identity(G) y = [Complex(0.0)] @test identity!(G, y, [Complex(1.0)]) === y @test y == [Complex(1.0)] y = [1.0 * im] v = [Complex(0.5)] @test translate_diff(G, Identity(G), y, v) === v end @testset "scalar points" begin pts = [1.0 + 0.0im, 0.0 + 1.0im, (1.0 + 1.0im) / √2] vpts = [0.0 + 0.5im] @test compose(G, pts[2], pts[1]) ≈ pts[2] * pts[1] @test translate_diff(G, pts[2], pts[1], vpts[1]) ≈ pts[2] * vpts[1] test_group(G, pts, vpts; test_diff = true, test_mutating = false) end @testset "vector points" begin pts = [[1.0 + 0.0im], [0.0 + 1.0im], [(1.0 + 1.0im) / √2]] vpts = [[0.0 + 0.5im]] @test compose(G, pts[2], pts[1]) ≈ pts[2] .* pts[1] @test translate_diff(G, pts[2], pts[1], vpts[1]) ≈ pts[2] .* vpts[1] test_group(G, pts, vpts; test_diff = true, test_mutating = true) end @testset "Group forwards to decorated" begin pts = [[1.0 + 0.0im], [0.0 + 1.0im], [(1.0 + 1.0im) / √2]] test_manifold( G, pts, test_forward_diff = false, test_reverse_diff = false, test_vector_spaces = false, test_project_tangent = true, test_musical_isomorphisms = false, test_vector_transport = true, is_mutating = true, exp_log_atol_multiplier = 2.0, is_tangent_atol_multiplier = 2.0, ) end end
[ 17256, 7203, 40720, 26791, 13, 20362, 4943, 198, 17256, 7203, 8094, 62, 26791, 13, 20362, 4943, 198, 198, 31, 9288, 2617, 366, 31560, 293, 1448, 1, 2221, 198, 220, 220, 220, 402, 796, 16291, 13247, 3419, 198, 220, 220, 220, 2488, 9288, 41575, 7, 38, 8, 6624, 366, 31560, 293, 13247, 3419, 1, 628, 220, 220, 220, 2488, 9288, 2779, 62, 805, 361, 727, 7, 38, 8, 24844, 16291, 90, 158, 226, 224, 92, 3419, 628, 220, 220, 220, 2488, 9288, 2617, 366, 738, 414, 31754, 82, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5369, 7, 38, 11, 27207, 7, 38, 4008, 24844, 27207, 7, 38, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 800, 7, 38, 11, 27207, 7, 38, 4008, 24844, 27207, 7, 38, 8, 198, 220, 220, 220, 220, 220, 220, 220, 331, 796, 685, 5377, 11141, 7, 15, 13, 15, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5369, 0, 7, 38, 11, 331, 11, 685, 5377, 11141, 7, 16, 13, 15, 8, 12962, 24844, 331, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 331, 6624, 685, 5377, 11141, 7, 16, 13, 15, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 331, 796, 685, 16, 13, 15, 1635, 545, 60, 198, 220, 220, 220, 220, 220, 220, 220, 410, 796, 685, 5377, 11141, 7, 15, 13, 20, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 15772, 62, 26069, 7, 38, 11, 27207, 7, 38, 828, 331, 11, 410, 8, 24844, 410, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 1416, 282, 283, 2173, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 43344, 796, 685, 16, 13, 15, 1343, 657, 13, 15, 320, 11, 657, 13, 15, 1343, 352, 13, 15, 320, 11, 357, 16, 13, 15, 1343, 352, 13, 15, 320, 8, 1220, 18872, 248, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 410, 457, 82, 796, 685, 15, 13, 15, 1343, 657, 13, 20, 320, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 36664, 7, 38, 11, 43344, 58, 17, 4357, 43344, 58, 16, 12962, 15139, 230, 43344, 58, 17, 60, 1635, 43344, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 15772, 62, 26069, 7, 38, 11, 43344, 58, 17, 4357, 43344, 58, 16, 4357, 410, 457, 82, 58, 16, 12962, 15139, 230, 43344, 58, 17, 60, 1635, 410, 457, 82, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 8094, 7, 38, 11, 43344, 11, 410, 457, 82, 26, 1332, 62, 26069, 796, 2081, 11, 1332, 62, 21973, 803, 796, 3991, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 31364, 2173, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 43344, 796, 16410, 16, 13, 15, 1343, 657, 13, 15, 320, 4357, 685, 15, 13, 15, 1343, 352, 13, 15, 320, 4357, 47527, 16, 13, 15, 1343, 352, 13, 15, 320, 8, 1220, 18872, 248, 17, 11907, 198, 220, 220, 220, 220, 220, 220, 220, 410, 457, 82, 796, 16410, 15, 13, 15, 1343, 657, 13, 20, 320, 11907, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 36664, 7, 38, 11, 43344, 58, 17, 4357, 43344, 58, 16, 12962, 15139, 230, 43344, 58, 17, 60, 764, 9, 43344, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 15772, 62, 26069, 7, 38, 11, 43344, 58, 17, 4357, 43344, 58, 16, 4357, 410, 457, 82, 58, 16, 12962, 15139, 230, 43344, 58, 17, 60, 764, 9, 410, 457, 82, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 8094, 7, 38, 11, 43344, 11, 410, 457, 82, 26, 1332, 62, 26069, 796, 2081, 11, 1332, 62, 21973, 803, 796, 2081, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 13247, 22052, 284, 24789, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 43344, 796, 16410, 16, 13, 15, 1343, 657, 13, 15, 320, 4357, 685, 15, 13, 15, 1343, 352, 13, 15, 320, 4357, 47527, 16, 13, 15, 1343, 352, 13, 15, 320, 8, 1220, 18872, 248, 17, 11907, 198, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 805, 361, 727, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 402, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 43344, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 11813, 62, 26069, 796, 3991, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 50188, 62, 26069, 796, 3991, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 31364, 62, 2777, 2114, 796, 3991, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 16302, 62, 83, 648, 298, 796, 2081, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 14664, 605, 62, 271, 25831, 6583, 796, 3991, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1332, 62, 31364, 62, 7645, 634, 796, 2081, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 62, 21973, 803, 796, 2081, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1033, 62, 6404, 62, 265, 349, 62, 47945, 959, 796, 362, 13, 15, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 318, 62, 83, 648, 298, 62, 265, 349, 62, 47945, 959, 796, 362, 13, 15, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 886, 198, 437, 198 ]
1.86345
974
using OptimTools using Base.Test # test exact line search for quadratic Q = 10*speye(40) f(x) = 0.5*dot(x,Q*x) df(x) = Q*x d2f(x) = Q x0 = randn(40) exactLS = (f,df,fk,dfk,xk,pk)-> (-dot(pk,dfk)/dot(pk,Q*pk),1) goldenLSf = (f,df,dk,dfk,xk,pk) -> goldenLS(f,xk,pk,0.0,5.0) println("Test SD,NLCG,BFGS with exact line search ") # steepest descent x1,flag1,his1 = sd(f,df,x0,maxIter=1000,atol=1e-6,out=0,lineSearch=exactLS) @test norm(x1)<1e-6*norm(x0) x2,flag2,his2 = sd(f,df,x0,maxIter=1000,atol=1e-6,out=0, lineSearch=exactLS) @test norm(x2)<1e-6 @test size(his2,1)==2 #should converge in one iteration # nlcg x1,flag1,his1 = nlcg(f,df,x0,maxIter=1000,atol=1e-6,out=0) @test norm(x1)<1e-6*norm(x0) x2,flag2,his2 = nlcg(f,df,x0,maxIter=1000,atol=1e-6,out=0, lineSearch=exactLS) @test norm(x2)<1e-6 @test size(his2,1)==2 #should converge in one iteration # bfgs x1,flag1,his1 = bfgs(f,df,x0,maxIter=1000,atol=1e-6,out=0) @test norm(x1)<1e-6*norm(x0) x2,flag2,his2 = bfgs(f,df,x0,maxIter=1000,atol=1e-6,out=0, lineSearch=exactLS) @test norm(x2)<1e-6 @test size(his2,1)==2 #should converge in one iteration println("Done!") println("Test SD,NLCG,BFGS with golden line search ") # steepest descent x1,flag1,his1 = sd(f,df,x0,maxIter=1000,atol=1e-6,out=0,lineSearch=goldenLSf) @test norm(x1)<1e-6*norm(x0) x2,flag2,his2 = sd(f,df,x0,maxIter=1000,atol=1e-6,out=0, lineSearch=goldenLSf) @test norm(x2)<1e-6 # nlcg x1,flag1,his1 = nlcg(f,df,x0,maxIter=1000,atol=1e-6,out=0) @test norm(x1)<1e-6*norm(x0) x2,flag2,his2 = nlcg(f,df,x0,maxIter=1000,atol=1e-6,out=0, lineSearch=goldenLSf) @test norm(x2)<1e-6 # bfgs x1,flag1,his1 = bfgs(f,df,x0,maxIter=1000,atol=1e-6,out=0) @test norm(x1)<1e-6*norm(x0) x2,flag2,his2 = bfgs(f,df,x0,maxIter=1000,atol=1e-6,out=0, lineSearch=goldenLSf) @test norm(x2)<1e-6 println("Done!")
[ 3500, 30011, 33637, 198, 3500, 7308, 13, 14402, 198, 198, 2, 1332, 2748, 1627, 2989, 329, 15094, 81, 1512, 198, 48, 796, 838, 9, 4125, 5948, 7, 1821, 8, 198, 69, 7, 87, 8, 220, 220, 220, 796, 657, 13, 20, 9, 26518, 7, 87, 11, 48, 9, 87, 8, 198, 7568, 7, 87, 8, 220, 220, 796, 1195, 9, 87, 198, 67, 17, 69, 7, 87, 8, 220, 796, 1195, 198, 87, 15, 796, 43720, 77, 7, 1821, 8, 198, 198, 1069, 529, 6561, 220, 796, 357, 69, 11, 7568, 11, 69, 74, 11, 7568, 74, 11, 87, 74, 11, 79, 74, 8, 3784, 13841, 26518, 7, 79, 74, 11, 7568, 74, 20679, 26518, 7, 79, 74, 11, 48, 9, 79, 74, 828, 16, 8, 198, 24267, 268, 6561, 69, 796, 357, 69, 11, 7568, 11, 34388, 11, 7568, 74, 11, 87, 74, 11, 79, 74, 8, 4613, 10861, 6561, 7, 69, 11, 87, 74, 11, 79, 74, 11, 15, 13, 15, 11, 20, 13, 15, 8, 198, 198, 35235, 7203, 14402, 9834, 11, 45, 5639, 38, 11, 29499, 14313, 351, 2748, 1627, 2989, 366, 8, 198, 2, 14559, 395, 18598, 198, 87, 16, 11, 32109, 16, 11, 14363, 16, 796, 45647, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1370, 18243, 28, 1069, 529, 6561, 8, 198, 31, 9288, 2593, 7, 87, 16, 8, 27, 16, 68, 12, 21, 9, 27237, 7, 87, 15, 8, 198, 87, 17, 11, 32109, 17, 11, 14363, 17, 796, 45647, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1627, 18243, 28, 1069, 529, 6561, 8, 198, 31, 9288, 2593, 7, 87, 17, 8, 27, 16, 68, 12, 21, 198, 31, 9288, 2546, 7, 14363, 17, 11, 16, 8, 855, 17, 1303, 21754, 47873, 287, 530, 24415, 198, 198, 2, 299, 44601, 70, 198, 87, 16, 11, 32109, 16, 11, 14363, 16, 796, 299, 44601, 70, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 8, 198, 31, 9288, 2593, 7, 87, 16, 8, 27, 16, 68, 12, 21, 9, 27237, 7, 87, 15, 8, 198, 87, 17, 11, 32109, 17, 11, 14363, 17, 796, 299, 44601, 70, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1627, 18243, 28, 1069, 529, 6561, 8, 198, 31, 9288, 2593, 7, 87, 17, 8, 27, 16, 68, 12, 21, 198, 31, 9288, 2546, 7, 14363, 17, 11, 16, 8, 855, 17, 1303, 21754, 47873, 287, 530, 24415, 198, 198, 2, 275, 69, 14542, 198, 87, 16, 11, 32109, 16, 11, 14363, 16, 796, 275, 69, 14542, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 8, 198, 31, 9288, 2593, 7, 87, 16, 8, 27, 16, 68, 12, 21, 9, 27237, 7, 87, 15, 8, 198, 87, 17, 11, 32109, 17, 11, 14363, 17, 796, 275, 69, 14542, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1627, 18243, 28, 1069, 529, 6561, 8, 198, 31, 9288, 2593, 7, 87, 17, 8, 27, 16, 68, 12, 21, 198, 31, 9288, 2546, 7, 14363, 17, 11, 16, 8, 855, 17, 1303, 21754, 47873, 287, 530, 24415, 198, 198, 35235, 7203, 45677, 2474, 8, 198, 198, 35235, 7203, 14402, 9834, 11, 45, 5639, 38, 11, 29499, 14313, 351, 10861, 1627, 2989, 366, 8, 198, 2, 14559, 395, 18598, 198, 87, 16, 11, 32109, 16, 11, 14363, 16, 796, 45647, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1370, 18243, 28, 24267, 268, 6561, 69, 8, 198, 31, 9288, 2593, 7, 87, 16, 8, 27, 16, 68, 12, 21, 9, 27237, 7, 87, 15, 8, 198, 87, 17, 11, 32109, 17, 11, 14363, 17, 796, 45647, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1627, 18243, 28, 24267, 268, 6561, 69, 8, 198, 31, 9288, 2593, 7, 87, 17, 8, 27, 16, 68, 12, 21, 198, 198, 2, 299, 44601, 70, 198, 87, 16, 11, 32109, 16, 11, 14363, 16, 796, 299, 44601, 70, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 8, 198, 31, 9288, 2593, 7, 87, 16, 8, 27, 16, 68, 12, 21, 9, 27237, 7, 87, 15, 8, 198, 87, 17, 11, 32109, 17, 11, 14363, 17, 796, 299, 44601, 70, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1627, 18243, 28, 24267, 268, 6561, 69, 8, 198, 31, 9288, 2593, 7, 87, 17, 8, 27, 16, 68, 12, 21, 198, 198, 2, 275, 69, 14542, 198, 87, 16, 11, 32109, 16, 11, 14363, 16, 796, 275, 69, 14542, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 8, 198, 31, 9288, 2593, 7, 87, 16, 8, 27, 16, 68, 12, 21, 9, 27237, 7, 87, 15, 8, 198, 87, 17, 11, 32109, 17, 11, 14363, 17, 796, 275, 69, 14542, 7, 69, 11, 7568, 11, 87, 15, 11, 9806, 29993, 28, 12825, 11, 265, 349, 28, 16, 68, 12, 21, 11, 448, 28, 15, 11, 1627, 18243, 28, 24267, 268, 6561, 69, 8, 198, 31, 9288, 2593, 7, 87, 17, 8, 27, 16, 68, 12, 21, 198, 198, 35235, 7203, 45677, 2474, 8, 198 ]
1.80773
1,009
module GlobalDiffEq using Reexport @reexport using DiffEqBase import OrdinaryDiffEq, Richardson abstract type GlobalDiffEqAlgorithm <: DiffEqBase.AbstractODEAlgorithm end struct GlobalRichardson{A} <: GlobalDiffEqAlgorithm alg::A end function DiffEqBase.__solve(prob::Union{DiffEqBase.AbstractODEProblem,DiffEqBase.AbstractDAEProblem}, alg::GlobalRichardson, args...; dt,kwargs...) opt = Dict(kwargs) otheropts = delete!(copy(opt), :dt) tstops = get(opt, :tstops, range(prob.tspan[1], stop=prob.tspan[2], step=dt)) local sol val, err = Richardson.extrapolate(dt, rtol=get(opt, :reltol, 1e-3), atol=get(opt, :abstol, 1e-6), contract=0.5) do _dt sol = solve(prob, alg.alg, args...; dt=_dt, adaptive=false, otheropts...) sol.(tstops) end return sol end export GlobalRichardson end
[ 21412, 8060, 28813, 36, 80, 198, 198, 3500, 797, 39344, 198, 31, 631, 87, 634, 1262, 10631, 36, 80, 14881, 198, 198, 11748, 14230, 3219, 28813, 36, 80, 11, 21679, 198, 198, 397, 8709, 2099, 8060, 28813, 36, 80, 2348, 42289, 1279, 25, 10631, 36, 80, 14881, 13, 23839, 16820, 2348, 42289, 886, 198, 198, 7249, 8060, 14868, 1371, 261, 90, 32, 92, 1279, 25, 8060, 28813, 36, 80, 2348, 42289, 198, 220, 220, 220, 435, 70, 3712, 32, 198, 437, 198, 198, 8818, 10631, 36, 80, 14881, 13, 834, 82, 6442, 7, 1676, 65, 3712, 38176, 90, 28813, 36, 80, 14881, 13, 23839, 16820, 40781, 11, 28813, 36, 80, 14881, 13, 23839, 5631, 36, 40781, 5512, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 435, 70, 3712, 22289, 14868, 1371, 261, 11, 26498, 986, 26, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 83, 11, 46265, 22046, 23029, 198, 220, 220, 220, 2172, 796, 360, 713, 7, 46265, 22046, 8, 198, 220, 220, 220, 267, 1169, 305, 457, 82, 796, 12233, 0, 7, 30073, 7, 8738, 828, 1058, 28664, 8, 198, 220, 220, 220, 256, 301, 2840, 796, 651, 7, 8738, 11, 1058, 83, 301, 2840, 11, 2837, 7, 1676, 65, 13, 912, 6839, 58, 16, 4357, 2245, 28, 1676, 65, 13, 912, 6839, 58, 17, 4357, 2239, 28, 28664, 4008, 198, 220, 220, 220, 1957, 1540, 198, 220, 220, 220, 1188, 11, 11454, 796, 21679, 13, 2302, 2416, 27976, 7, 28664, 11, 374, 83, 349, 28, 1136, 7, 8738, 11, 1058, 2411, 83, 349, 11, 352, 68, 12, 18, 828, 379, 349, 28, 1136, 7, 8738, 11, 1058, 397, 301, 349, 11, 352, 68, 12, 21, 828, 2775, 28, 15, 13, 20, 8, 466, 4808, 28664, 198, 220, 220, 220, 220, 220, 220, 220, 1540, 796, 8494, 7, 1676, 65, 11, 435, 70, 13, 14016, 11, 26498, 986, 26, 288, 83, 28, 62, 28664, 11, 29605, 28, 9562, 11, 267, 1169, 305, 457, 82, 23029, 198, 220, 220, 220, 220, 220, 220, 220, 1540, 12195, 83, 301, 2840, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 1540, 198, 437, 198, 198, 39344, 8060, 14868, 1371, 261, 198, 198, 437, 198 ]
2.189655
406
<filename>test/NfRel/FracIdeal.jl<gh_stars>0 @testset "Relative fractional ideals" begin Qx, x = FlintQQ["x"] f = x^2 + 12*x - 92 K, a = number_field(f, "a") OK = maximal_order(K) Ky, y = K["y"] g = y^2 - 54*y - 73 L, b = number_field(g, "b") OL = maximal_order(L) I = L(fmpq(1, 2))*OL @test denominator(I) == fmpz(2) @test Hecke.isintegral(I.den*I) PM = basis_pmat(OL) PM.matrix[1, 1] = K(fmpq(1, 2)) PM.matrix[2, 1] = K() PM.matrix[2, 2] = K(fmpq(1, 3)) PM = pseudo_hnf(PM, :lowerleft) J = frac_ideal(OL, PM) @test denominator(J) == fmpz(6) @test Hecke.isintegral(J.den*J) end
[ 27, 34345, 29, 9288, 14, 45, 69, 6892, 14, 6732, 330, 7390, 2287, 13, 20362, 27, 456, 62, 30783, 29, 15, 198, 31, 9288, 2617, 366, 6892, 876, 13390, 282, 22247, 1, 2221, 198, 220, 1195, 87, 11, 2124, 796, 21660, 48, 48, 14692, 87, 8973, 198, 220, 277, 796, 2124, 61, 17, 1343, 1105, 9, 87, 532, 10190, 198, 220, 509, 11, 257, 796, 1271, 62, 3245, 7, 69, 11, 366, 64, 4943, 198, 220, 7477, 796, 40708, 62, 2875, 7, 42, 8, 198, 220, 11118, 11, 331, 796, 509, 14692, 88, 8973, 198, 220, 308, 796, 331, 61, 17, 532, 7175, 9, 88, 532, 8854, 198, 220, 406, 11, 275, 796, 1271, 62, 3245, 7, 70, 11, 366, 65, 4943, 198, 220, 22258, 796, 40708, 62, 2875, 7, 43, 8, 628, 220, 314, 796, 406, 7, 69, 3149, 80, 7, 16, 11, 362, 4008, 9, 3535, 198, 220, 2488, 9288, 31457, 1352, 7, 40, 8, 6624, 277, 3149, 89, 7, 17, 8, 198, 220, 2488, 9288, 679, 66, 365, 13, 271, 18908, 1373, 7, 40, 13, 6559, 9, 40, 8, 628, 220, 3122, 796, 4308, 62, 4426, 265, 7, 3535, 8, 198, 220, 3122, 13, 6759, 8609, 58, 16, 11, 352, 60, 796, 509, 7, 69, 3149, 80, 7, 16, 11, 362, 4008, 198, 220, 3122, 13, 6759, 8609, 58, 17, 11, 352, 60, 796, 509, 3419, 198, 220, 3122, 13, 6759, 8609, 58, 17, 11, 362, 60, 796, 509, 7, 69, 3149, 80, 7, 16, 11, 513, 4008, 198, 220, 3122, 796, 24543, 62, 21116, 69, 7, 5868, 11, 1058, 21037, 9464, 8, 198, 220, 449, 796, 1216, 330, 62, 485, 282, 7, 3535, 11, 3122, 8, 198, 220, 2488, 9288, 31457, 1352, 7, 41, 8, 6624, 277, 3149, 89, 7, 21, 8, 198, 220, 2488, 9288, 679, 66, 365, 13, 271, 18908, 1373, 7, 41, 13, 6559, 9, 41, 8, 198, 437, 198 ]
1.952681
317
using ContactStructures plotlyjs() plot_along_xy_grid(-2:0.5:2,-2:0.5:2,0,standard_structure; markersize = 2.5,ε = 0.25) plot!(xlims=(-3, 3), ylims=(-3,3), zlims=(-3,3),legend=false)
[ 3500, 14039, 44909, 942, 198, 198, 29487, 306, 8457, 3419, 198, 29487, 62, 24176, 62, 5431, 62, 25928, 32590, 17, 25, 15, 13, 20, 25, 17, 12095, 17, 25, 15, 13, 20, 25, 17, 11, 15, 11, 20307, 62, 301, 5620, 26, 220, 19736, 1096, 796, 362, 13, 20, 11, 30950, 796, 657, 13, 1495, 8, 198, 29487, 0, 7, 87, 2475, 82, 16193, 12, 18, 11, 513, 828, 331, 2475, 82, 16193, 12, 18, 11, 18, 828, 1976, 2475, 82, 16193, 12, 18, 11, 18, 828, 1455, 437, 28, 9562, 8, 220, 220, 628 ]
1.978947
95
<gh_stars>1-10 module Rank using DataStructures using Base: tail export extrema_filter # Max-min filter # This is an implementation of the Lemire max-min filter # http://arxiv.org/abs/cs.DS/0610046 # Monotonic wedge immutable Wedge{T} L::CircularDeque{T} U::CircularDeque{T} end (::Type{Wedge{T}}){T}(n::Integer) = Wedge(CircularDeque{T}(n), CircularDeque{T}(n)) function Base.push!(W::Wedge, i::Integer) push!(W.L, i) push!(W.U, i) W end function addtoback!(W::Wedge, A, i, J) mn, mx = A[i, J] @inbounds while !isempty(W.L) && mn < A[back(W.L), J][1] pop!(W.L) end @inbounds while !isempty(W.U) && mx > A[back(W.U), J][2] pop!(W.U) end push!(W.L, i) push!(W.U, i) W end function Base.empty!(W::Wedge) empty!(W.L) empty!(W.U) W end @inline function getextrema(A, W::Wedge, J) (A[front(W.L), J][1], A[front(W.U), J][2]) end """ extrema_filter(A, window) --> Array{(min,max)} Calculate the running min/max over a window of width `window[d]` along dimension `d`, centered on the current point. The returned array has the same indices as the input `A`. """ function extrema_filter{T,N}(A::AbstractArray{T,N}, window::NTuple{N,Integer}) _extrema_filter!([(a,a) for a in A], window...) end extrema_filter(A::AbstractArray, window::AbstractArray) = extrema_filter(A, (window...,)) extrema_filter(A::AbstractArray, window) = error("`window` must have the same number of entries as dimensions of `A`") extrema_filter{T,N}(A::AbstractArray{T,N}, window::Integer) = extrema_filter(A, ntuple(d->window, Val{N})) function _extrema_filter!(A::Array, w1, w...) if w1 > 1 a = first(A) cache = ntuple(i->a, w1>>1) _extrema_filter1!(A, w1, cache) end _extrema_filter!(permutedims(A, [2:ndims(A);1]), w...) end _extrema_filter!(A::Array) = A # Extrema-filtering along "columns" (dimension 1). This implements Lemire # Algorithm 1, with the following modifications: # - multidimensional array support by looping over trailing dimensions # - working with min/max pairs rather than plain values, to # facilitate multidimensional processing # - output for all points of the array, handling the edges as max-min # over halfwindow on either side function _extrema_filter1!{T}(A::AbstractArray{Tuple{T,T}}, window::Int, cache) # Initialise the internal wedges # U[1], L[1] are the location of the global (within the window) maximum and minimum # U[2], L[2] are the maximum and minimum over (U1, end] and (L1, end], respectively W = Wedge{Int}(window+1) tmp = Array{Tuple{T,T}}(window) c = z = first(cache) inds = indices(A) inds1 = inds[1] halfwindow = window>>1 iw = min(last(inds1), first(inds1)+window-1) for J in CartesianRange(tail(inds)) empty!(W) # Leading edge. We can't overwrite any values yet in A because # we'll need them again in later computations. for i = first(inds1):iw addtoback!(W, A, i, J) c, cache = cyclecache(cache, getextrema(A, W, J)) end # Process the rest of the "column" for i = iw+1:last(inds1) A[i-window, J] = c if i == window+front(W.U) shift!(W.U) end if i == window+front(W.L) shift!(W.L) end addtoback!(W, A, i, J) c, cache = cyclecache(cache, getextrema(A, W, J)) end for i = last(inds1)-window+1:last(inds1)-1 if i >= first(inds1) A[i, J] = c end if i == front(W.U) shift!(W.U) end if i == front(W.L) shift!(W.L) end c, cache = cyclecache(cache, getextrema(A, W, J)) end A[last(inds1), J] = c end A end # This is slightly faster than a circular buffer @inline cyclecache(b, x) = b[1], (Base.tail(b)..., x) end
[ 27, 456, 62, 30783, 29, 16, 12, 940, 198, 21412, 10916, 198, 198, 3500, 6060, 44909, 942, 198, 3500, 7308, 25, 7894, 198, 198, 39344, 1070, 260, 2611, 62, 24455, 198, 198, 2, 5436, 12, 1084, 8106, 198, 198, 2, 770, 318, 281, 7822, 286, 262, 20607, 557, 3509, 12, 1084, 8106, 198, 2, 2638, 1378, 283, 87, 452, 13, 2398, 14, 8937, 14, 6359, 13, 5258, 14, 3312, 3064, 3510, 198, 198, 2, 2892, 313, 9229, 35901, 198, 8608, 18187, 3300, 469, 90, 51, 92, 198, 220, 220, 220, 406, 3712, 31560, 934, 5005, 4188, 90, 51, 92, 198, 220, 220, 220, 471, 3712, 31560, 934, 5005, 4188, 90, 51, 92, 198, 437, 198, 7, 3712, 6030, 90, 54, 14907, 90, 51, 11709, 19953, 51, 92, 7, 77, 3712, 46541, 8, 796, 3300, 469, 7, 31560, 934, 5005, 4188, 90, 51, 92, 7, 77, 828, 7672, 934, 5005, 4188, 90, 51, 92, 7, 77, 4008, 198, 198, 8818, 7308, 13, 14689, 0, 7, 54, 3712, 54, 14907, 11, 1312, 3712, 46541, 8, 198, 220, 220, 220, 4574, 0, 7, 54, 13, 43, 11, 1312, 8, 198, 220, 220, 220, 4574, 0, 7, 54, 13, 52, 11, 1312, 8, 198, 220, 220, 220, 370, 198, 437, 198, 198, 8818, 751, 83, 672, 441, 0, 7, 54, 3712, 54, 14907, 11, 317, 11, 1312, 11, 449, 8, 198, 220, 220, 220, 285, 77, 11, 285, 87, 796, 317, 58, 72, 11, 449, 60, 198, 220, 220, 220, 2488, 259, 65, 3733, 981, 5145, 271, 28920, 7, 54, 13, 43, 8, 11405, 285, 77, 1279, 317, 58, 1891, 7, 54, 13, 43, 828, 449, 7131, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1461, 0, 7, 54, 13, 43, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 2488, 259, 65, 3733, 981, 5145, 271, 28920, 7, 54, 13, 52, 8, 11405, 285, 87, 1875, 317, 58, 1891, 7, 54, 13, 52, 828, 449, 7131, 17, 60, 198, 220, 220, 220, 220, 220, 220, 220, 1461, 0, 7, 54, 13, 52, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 4574, 0, 7, 54, 13, 43, 11, 1312, 8, 198, 220, 220, 220, 4574, 0, 7, 54, 13, 52, 11, 1312, 8, 198, 220, 220, 220, 370, 198, 437, 198, 198, 8818, 7308, 13, 28920, 0, 7, 54, 3712, 54, 14907, 8, 198, 220, 220, 220, 6565, 0, 7, 54, 13, 43, 8, 198, 220, 220, 220, 6565, 0, 7, 54, 13, 52, 8, 198, 220, 220, 220, 370, 198, 437, 198, 198, 31, 45145, 2163, 651, 2302, 260, 2611, 7, 32, 11, 370, 3712, 54, 14907, 11, 449, 8, 198, 220, 220, 220, 357, 32, 58, 8534, 7, 54, 13, 43, 828, 449, 7131, 16, 4357, 317, 58, 8534, 7, 54, 13, 52, 828, 449, 7131, 17, 12962, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 1070, 260, 2611, 62, 24455, 7, 32, 11, 4324, 8, 14610, 15690, 90, 7, 1084, 11, 9806, 38165, 198, 198, 9771, 3129, 378, 262, 2491, 949, 14, 9806, 625, 257, 4324, 286, 9647, 4600, 17497, 58, 67, 60, 63, 1863, 198, 46156, 4600, 67, 47671, 19254, 319, 262, 1459, 966, 13, 383, 4504, 7177, 468, 198, 1169, 976, 36525, 355, 262, 5128, 4600, 32, 44646, 198, 37811, 198, 8818, 1070, 260, 2611, 62, 24455, 90, 51, 11, 45, 92, 7, 32, 3712, 23839, 19182, 90, 51, 11, 45, 5512, 4324, 3712, 11251, 29291, 90, 45, 11, 46541, 30072, 198, 220, 220, 220, 4808, 2302, 260, 2611, 62, 24455, 0, 26933, 7, 64, 11, 64, 8, 329, 257, 287, 317, 4357, 4324, 23029, 198, 437, 198, 2302, 260, 2611, 62, 24455, 7, 32, 3712, 23839, 19182, 11, 4324, 3712, 23839, 19182, 8, 796, 1070, 260, 2611, 62, 24455, 7, 32, 11, 357, 17497, 986, 11, 4008, 198, 2302, 260, 2611, 62, 24455, 7, 32, 3712, 23839, 19182, 11, 4324, 8, 796, 4049, 7203, 63, 17497, 63, 1276, 423, 262, 976, 1271, 286, 12784, 355, 15225, 286, 4600, 32, 63, 4943, 198, 198, 2302, 260, 2611, 62, 24455, 90, 51, 11, 45, 92, 7, 32, 3712, 23839, 19182, 90, 51, 11, 45, 5512, 4324, 3712, 46541, 8, 796, 1070, 260, 2611, 62, 24455, 7, 32, 11, 299, 83, 29291, 7, 67, 3784, 17497, 11, 3254, 90, 45, 92, 4008, 198, 198, 8818, 4808, 2302, 260, 2611, 62, 24455, 0, 7, 32, 3712, 19182, 11, 266, 16, 11, 266, 23029, 198, 220, 220, 220, 611, 266, 16, 1875, 352, 198, 220, 220, 220, 220, 220, 220, 220, 257, 796, 717, 7, 32, 8, 198, 220, 220, 220, 220, 220, 220, 220, 12940, 796, 299, 83, 29291, 7, 72, 3784, 64, 11, 266, 16, 4211, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 4808, 2302, 260, 2611, 62, 24455, 16, 0, 7, 32, 11, 266, 16, 11, 12940, 8, 198, 220, 220, 220, 886, 198, 220, 220, 220, 4808, 2302, 260, 2611, 62, 24455, 0, 7, 16321, 7241, 12078, 7, 32, 11, 685, 17, 25, 358, 12078, 7, 32, 1776, 16, 46570, 266, 23029, 198, 437, 198, 62, 2302, 260, 2611, 62, 24455, 0, 7, 32, 3712, 19182, 8, 796, 317, 198, 198, 2, 5683, 260, 2611, 12, 10379, 20212, 1863, 366, 28665, 82, 1, 357, 46156, 352, 737, 770, 23986, 20607, 557, 198, 2, 978, 42289, 352, 11, 351, 262, 1708, 19008, 25, 198, 2, 220, 220, 532, 1963, 312, 16198, 7177, 1104, 416, 9052, 278, 625, 25462, 15225, 198, 2, 220, 220, 532, 1762, 351, 949, 14, 9806, 14729, 2138, 621, 8631, 3815, 11, 284, 198, 2, 220, 220, 220, 220, 15570, 1963, 312, 16198, 7587, 198, 2, 220, 220, 532, 5072, 329, 477, 2173, 286, 262, 7177, 11, 9041, 262, 13015, 355, 3509, 12, 1084, 198, 2, 220, 220, 220, 220, 625, 2063, 17497, 319, 2035, 1735, 198, 8818, 4808, 2302, 260, 2611, 62, 24455, 16, 0, 90, 51, 92, 7, 32, 3712, 23839, 19182, 90, 51, 29291, 90, 51, 11, 51, 92, 5512, 4324, 3712, 5317, 11, 12940, 8, 198, 220, 220, 220, 1303, 20768, 786, 262, 5387, 29445, 3212, 198, 220, 220, 220, 1303, 471, 58, 16, 4357, 406, 58, 16, 60, 389, 262, 4067, 286, 262, 3298, 357, 33479, 262, 4324, 8, 5415, 290, 5288, 198, 220, 220, 220, 1303, 471, 58, 17, 4357, 406, 58, 17, 60, 389, 262, 5415, 290, 5288, 625, 357, 52, 16, 11, 886, 60, 290, 357, 43, 16, 11, 886, 4357, 8148, 198, 220, 220, 220, 370, 796, 3300, 469, 90, 5317, 92, 7, 17497, 10, 16, 8, 198, 220, 220, 220, 45218, 796, 15690, 90, 51, 29291, 90, 51, 11, 51, 11709, 7, 17497, 8, 198, 220, 220, 220, 269, 796, 1976, 796, 717, 7, 23870, 8, 628, 220, 220, 220, 773, 82, 796, 36525, 7, 32, 8, 198, 220, 220, 220, 773, 82, 16, 796, 773, 82, 58, 16, 60, 198, 220, 220, 220, 2063, 17497, 796, 4324, 4211, 16, 198, 220, 220, 220, 1312, 86, 796, 949, 7, 12957, 7, 521, 82, 16, 828, 717, 7, 521, 82, 16, 47762, 17497, 12, 16, 8, 198, 220, 220, 220, 329, 449, 287, 13690, 35610, 17257, 7, 13199, 7, 521, 82, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 6565, 0, 7, 54, 8, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 43225, 5743, 13, 775, 460, 470, 49312, 597, 3815, 1865, 287, 317, 780, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 356, 1183, 761, 606, 757, 287, 1568, 2653, 602, 13, 198, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 796, 717, 7, 521, 82, 16, 2599, 14246, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 751, 83, 672, 441, 0, 7, 54, 11, 317, 11, 1312, 11, 449, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 11, 12940, 796, 6772, 23870, 7, 23870, 11, 651, 2302, 260, 2611, 7, 32, 11, 370, 11, 449, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 10854, 262, 1334, 286, 262, 366, 28665, 1, 198, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 796, 1312, 86, 10, 16, 25, 12957, 7, 521, 82, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 317, 58, 72, 12, 17497, 11, 449, 60, 796, 269, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 1312, 6624, 4324, 10, 8534, 7, 54, 13, 52, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6482, 0, 7, 54, 13, 52, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 1312, 6624, 4324, 10, 8534, 7, 54, 13, 43, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6482, 0, 7, 54, 13, 43, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 751, 83, 672, 441, 0, 7, 54, 11, 317, 11, 1312, 11, 449, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 11, 12940, 796, 6772, 23870, 7, 23870, 11, 651, 2302, 260, 2611, 7, 32, 11, 370, 11, 449, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 796, 938, 7, 521, 82, 16, 13219, 17497, 10, 16, 25, 12957, 7, 521, 82, 16, 13219, 16, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 1312, 18189, 717, 7, 521, 82, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 317, 58, 72, 11, 449, 60, 796, 269, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 1312, 6624, 2166, 7, 54, 13, 52, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6482, 0, 7, 54, 13, 52, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 1312, 6624, 2166, 7, 54, 13, 43, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6482, 0, 7, 54, 13, 43, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 11, 12940, 796, 6772, 23870, 7, 23870, 11, 651, 2302, 260, 2611, 7, 32, 11, 370, 11, 449, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 317, 58, 12957, 7, 521, 82, 16, 828, 449, 60, 796, 269, 198, 220, 220, 220, 886, 198, 220, 220, 220, 317, 198, 437, 198, 198, 2, 770, 318, 4622, 5443, 621, 257, 18620, 11876, 198, 31, 45145, 6772, 23870, 7, 65, 11, 2124, 8, 796, 275, 58, 16, 4357, 357, 14881, 13, 13199, 7, 65, 26513, 11, 2124, 8, 198, 198, 437, 198 ]
2.111581
1,891
# Functions # Point #rand(rng::Random.AbstractRNG, ::Random.SamplerType{Point{T, N}}) where N where T = Point{T, N}(NTuple{N, T}(rand(rng, T, N))) distance(p1::Point{T, N}, p2::Point{T, N}) where N where T = sqrt(sum((p1.coordinates .- p2.coordinates).^2)) function area(arr::Array{Point{T, 2}, 1}) where T length(arr) <= 2 && error("Area for two points cannot be computed!") area = 0.0 x = 2 y = 3 flag = false while(x <= length(arr) && y <= length(arr)) a = distance(arr[1], arr[x]) b = distance(arr[x], arr[y]) c = distance(arr[1], arr[y]) s = (a + b + c)/2.0 area += sqrt(s*(s - a)*(s - b)*(s - c)) if flag == false flag = true x = y + 1 else flag = false y = x + 1 end end return area end function convexHull(points::Array{Point{T,2},1}) where T if length(points) < 3 error("Minimum three points required") end n = length(points) function orientation(p::Point{T, 2}, q::Point{T, 2}, r::Point{T, 2}) where T <: Real v = (q.coordinates[2] - p.coordinates[2])*(r.coordinates[1] - q.coordinates[1])- (q.coordinates[1] - p.coordinates[1])*(r.coordinates[2] - q.coordinates[2]) if v == 0 return 0 end return v > 0 ? 1 : 2 end hull = Array{Point{T, 2}, 1}(undef, 0) l = 1 for i in 2:n if points[i].coordinates[1] < points[l].coordinates[1] l = i end end p = l - 1 q = -1 while true push!(hull, points[p + 1]) q = (p + 1) % n for i in 0:(n - 1) if(orientation(points[p + 1], points[i + 1], points[q+1]) == 2) q = i end end p = q if p == l - 1 break end end return hull end # Line function distance(p::Point{T, N}, l::Line{T, N}) where N where T t = dot(p.coordinates .- l.p.coordinates, l.v)/dot(l.v, l.v) return norm(p.coordinates .- l.p.coordinates .- t*l.v) end distance(l::Line{T, N}, p::Point{T, N}) where N where T = distance(p::Point{T, N}, l::Line{T, N}) function distance(l1::Line{T, N}, l2::Line{T, N}; err = 1e-10) where N where T if norm(l1.v .- l2.v) ≦ err return distance(l1.p, l2) else return zero(T) end end # Plane function distance(p::Point{T, N}, q::Plane{T, N}) where N where T x = distance(p, q.p) y = distance(p, q.n) return sqrt(x^2 - y^2) end function boundingbox(a::Array{Point{T, N}, 1}) where N where T mn = Array{T,1}(undef, N) mn .= typemax(T) mx = Array{T,1}(undef, N) mx .= typemin(T) for i in 1:N, j in 1:length(a) mn[i] = min(mn[i], a[j].coordinates[i]) mx[i] = max(mx[i], a[j].coordinates[i]) end return (Point{T, N}(mn), Point{T, N}(mx)) end
[ 2, 40480, 201, 198, 201, 198, 2, 6252, 201, 198, 2, 25192, 7, 81, 782, 3712, 29531, 13, 23839, 49, 10503, 11, 7904, 29531, 13, 16305, 20053, 6030, 90, 12727, 90, 51, 11, 399, 11709, 8, 810, 399, 810, 309, 796, 6252, 90, 51, 11, 399, 92, 7, 11251, 29291, 90, 45, 11, 309, 92, 7, 25192, 7, 81, 782, 11, 309, 11, 399, 22305, 201, 198, 30246, 7, 79, 16, 3712, 12727, 90, 51, 11, 399, 5512, 279, 17, 3712, 12727, 90, 51, 11, 399, 30072, 810, 399, 810, 309, 796, 19862, 17034, 7, 16345, 19510, 79, 16, 13, 37652, 17540, 764, 12, 279, 17, 13, 37652, 17540, 737, 61, 17, 4008, 201, 198, 201, 198, 8818, 1989, 7, 3258, 3712, 19182, 90, 12727, 90, 51, 11, 362, 5512, 352, 30072, 810, 309, 201, 198, 220, 220, 220, 4129, 7, 3258, 8, 19841, 362, 11405, 4049, 7203, 30547, 329, 734, 2173, 2314, 307, 29231, 2474, 8, 201, 198, 220, 220, 220, 1989, 796, 657, 13, 15, 201, 198, 220, 220, 220, 2124, 796, 362, 201, 198, 220, 220, 220, 331, 796, 513, 201, 198, 220, 220, 220, 6056, 796, 3991, 201, 198, 220, 220, 220, 981, 7, 87, 19841, 4129, 7, 3258, 8, 11405, 331, 19841, 4129, 7, 3258, 4008, 201, 198, 220, 220, 220, 220, 220, 220, 220, 257, 796, 5253, 7, 3258, 58, 16, 4357, 5240, 58, 87, 12962, 201, 198, 220, 220, 220, 220, 220, 220, 220, 275, 796, 5253, 7, 3258, 58, 87, 4357, 5240, 58, 88, 12962, 201, 198, 220, 220, 220, 220, 220, 220, 220, 269, 796, 5253, 7, 3258, 58, 16, 4357, 5240, 58, 88, 12962, 201, 198, 220, 220, 220, 220, 220, 220, 220, 264, 796, 357, 64, 1343, 275, 1343, 269, 20679, 17, 13, 15, 201, 198, 220, 220, 220, 220, 220, 220, 220, 1989, 15853, 19862, 17034, 7, 82, 9, 7, 82, 532, 257, 27493, 7, 82, 532, 275, 27493, 7, 82, 532, 269, 4008, 201, 198, 220, 220, 220, 220, 220, 220, 220, 611, 6056, 6624, 3991, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6056, 796, 2081, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2124, 796, 331, 1343, 352, 201, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6056, 796, 3991, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 796, 2124, 1343, 352, 201, 198, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 1441, 1989, 201, 198, 437, 201, 198, 201, 198, 8818, 24748, 87, 39, 724, 7, 13033, 3712, 19182, 90, 12727, 90, 51, 11, 17, 5512, 16, 30072, 810, 309, 201, 198, 220, 220, 220, 611, 4129, 7, 13033, 8, 1279, 513, 201, 198, 220, 220, 220, 220, 220, 220, 220, 4049, 7203, 44046, 1115, 2173, 2672, 4943, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 299, 796, 4129, 7, 13033, 8, 201, 198, 220, 220, 220, 2163, 12852, 7, 79, 3712, 12727, 90, 51, 11, 362, 5512, 10662, 3712, 12727, 90, 51, 11, 362, 5512, 374, 3712, 12727, 90, 51, 11, 362, 30072, 810, 309, 1279, 25, 6416, 201, 198, 220, 220, 220, 220, 220, 220, 220, 410, 796, 357, 80, 13, 37652, 17540, 58, 17, 60, 532, 279, 13, 37652, 17540, 58, 17, 12962, 9, 7, 81, 13, 37652, 17540, 58, 16, 60, 532, 10662, 13, 37652, 17540, 58, 16, 12962, 12, 357, 80, 13, 37652, 17540, 58, 16, 60, 532, 279, 13, 37652, 17540, 58, 16, 12962, 9, 7, 81, 13, 37652, 17540, 58, 17, 60, 532, 10662, 13, 37652, 17540, 58, 17, 12962, 201, 198, 220, 220, 220, 220, 220, 220, 220, 611, 410, 6624, 657, 1441, 657, 886, 201, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 410, 1875, 657, 5633, 352, 1058, 362, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 23644, 796, 15690, 90, 12727, 90, 51, 11, 362, 5512, 352, 92, 7, 917, 891, 11, 657, 8, 201, 198, 220, 220, 220, 300, 796, 352, 201, 198, 220, 220, 220, 329, 1312, 287, 362, 25, 77, 201, 198, 220, 220, 220, 220, 220, 220, 220, 611, 2173, 58, 72, 4083, 37652, 17540, 58, 16, 60, 1279, 2173, 58, 75, 4083, 37652, 17540, 58, 16, 60, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 300, 796, 1312, 201, 198, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 279, 796, 300, 532, 352, 201, 198, 220, 220, 220, 10662, 796, 532, 16, 201, 198, 220, 220, 220, 981, 2081, 201, 198, 220, 220, 220, 220, 220, 220, 220, 4574, 0, 7, 71, 724, 11, 2173, 58, 79, 1343, 352, 12962, 201, 198, 220, 220, 220, 220, 220, 220, 220, 10662, 796, 357, 79, 1343, 352, 8, 4064, 299, 201, 198, 220, 220, 220, 220, 220, 220, 220, 329, 1312, 287, 657, 37498, 77, 532, 352, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 7, 13989, 341, 7, 13033, 58, 79, 1343, 352, 4357, 2173, 58, 72, 1343, 352, 4357, 2173, 58, 80, 10, 16, 12962, 6624, 362, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10662, 796, 1312, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 220, 220, 220, 220, 279, 796, 10662, 201, 198, 220, 220, 220, 220, 220, 220, 220, 611, 279, 6624, 300, 532, 352, 201, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2270, 201, 198, 220, 220, 220, 220, 220, 220, 220, 886, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 1441, 23644, 201, 198, 437, 201, 198, 2, 6910, 201, 198, 8818, 5253, 7, 79, 3712, 12727, 90, 51, 11, 399, 5512, 300, 3712, 13949, 90, 51, 11, 399, 30072, 810, 399, 810, 309, 201, 198, 220, 220, 220, 256, 796, 16605, 7, 79, 13, 37652, 17540, 764, 12, 300, 13, 79, 13, 37652, 17540, 11, 300, 13, 85, 20679, 26518, 7, 75, 13, 85, 11, 300, 13, 85, 8, 201, 198, 220, 220, 220, 1441, 2593, 7, 79, 13, 37652, 17540, 764, 12, 300, 13, 79, 13, 37652, 17540, 764, 12, 256, 9, 75, 13, 85, 8, 201, 198, 437, 201, 198, 30246, 7, 75, 3712, 13949, 90, 51, 11, 399, 5512, 279, 3712, 12727, 90, 51, 11, 399, 30072, 810, 399, 810, 309, 796, 5253, 7, 79, 3712, 12727, 90, 51, 11, 399, 5512, 300, 3712, 13949, 90, 51, 11, 399, 30072, 201, 198, 201, 198, 8818, 5253, 7, 75, 16, 3712, 13949, 90, 51, 11, 399, 5512, 300, 17, 3712, 13949, 90, 51, 11, 399, 19629, 11454, 796, 352, 68, 12, 940, 8, 810, 399, 810, 309, 201, 198, 220, 220, 220, 611, 2593, 7, 75, 16, 13, 85, 764, 12, 300, 17, 13, 85, 8, 15139, 99, 11454, 201, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 5253, 7, 75, 16, 13, 79, 11, 300, 17, 8, 201, 198, 220, 220, 220, 2073, 201, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 6632, 7, 51, 8, 201, 198, 220, 220, 220, 886, 201, 198, 437, 201, 198, 201, 198, 2, 36829, 201, 198, 201, 198, 8818, 5253, 7, 79, 3712, 12727, 90, 51, 11, 399, 5512, 10662, 3712, 3646, 1531, 90, 51, 11, 399, 30072, 810, 399, 810, 309, 201, 198, 220, 220, 220, 2124, 796, 5253, 7, 79, 11, 10662, 13, 79, 8, 201, 198, 220, 220, 220, 331, 796, 5253, 7, 79, 11, 10662, 13, 77, 8, 201, 198, 220, 220, 220, 1441, 19862, 17034, 7, 87, 61, 17, 532, 331, 61, 17, 8, 201, 198, 437, 201, 198, 201, 198, 8818, 5421, 278, 3524, 7, 64, 3712, 19182, 90, 12727, 90, 51, 11, 399, 5512, 352, 30072, 810, 399, 810, 309, 201, 198, 220, 220, 220, 285, 77, 796, 15690, 90, 51, 11, 16, 92, 7, 917, 891, 11, 399, 8, 201, 198, 220, 220, 220, 285, 77, 764, 28, 2170, 368, 897, 7, 51, 8, 201, 198, 220, 220, 220, 285, 87, 796, 15690, 90, 51, 11, 16, 92, 7, 917, 891, 11, 399, 8, 201, 198, 220, 220, 220, 285, 87, 764, 28, 2170, 14857, 7, 51, 8, 201, 198, 220, 220, 220, 329, 1312, 287, 352, 25, 45, 11, 474, 287, 352, 25, 13664, 7, 64, 8, 201, 198, 220, 220, 220, 220, 220, 220, 220, 285, 77, 58, 72, 60, 796, 949, 7, 10295, 58, 72, 4357, 257, 58, 73, 4083, 37652, 17540, 58, 72, 12962, 201, 198, 220, 220, 220, 220, 220, 220, 220, 285, 87, 58, 72, 60, 796, 3509, 7, 36802, 58, 72, 4357, 257, 58, 73, 4083, 37652, 17540, 58, 72, 12962, 201, 198, 220, 220, 220, 886, 201, 198, 220, 220, 220, 1441, 357, 12727, 90, 51, 11, 399, 92, 7, 10295, 828, 6252, 90, 51, 11, 399, 92, 7, 36802, 4008, 201, 198, 437, 201, 198 ]
1.905318
1,542
# functions to download the data const FILESIZES = CSV.read(joinpath(DIR,"metadata","filesizes.csv"), DataFrame) # _download is a modified MIT expat licensed code from HTTP.jl # https://github.com/JuliaWeb/HTTP.jl/blob/668e7e68747bb333ebde13af8d16add5b82b3b8a/src/download.jl#L92 function _download(url::AbstractString, file_path::AbstractString; headers = [], progress = nothing, # nothing or Progress or ParallelProgress filesize = typemax(Int), update_period = 1, kw...) if isnothing(progress) update_period = Inf end HTTP.open("GET", url, headers; kw...) do stream eof(stream) && return # don't do anything for streams we can't read (yet) downloaded_bytes = 0 prev_time = Dates.now() function report_callback() prev_time = Dates.now() completion_progress = downloaded_bytes # we stay stuck at 99% if file is bigger than expected update!(progress, min(completion_progress, filesize-1)) end Base.open(file_path, "w") do fh while !eof(stream) downloaded_bytes += write(fh, readavailable(stream)) if !isinf(update_period) if Dates.now() - prev_time > Dates.Millisecond(round(1000update_period)) report_callback() end end end end if !isinf(update_period) finish!(progress) end end return end function get_file_size(siteid::Integer, compressed::Bool) col = compressed ? ".csv.gz" : ".csv" return ceil(Int, FILESIZES[siteid, col]) end function download_site_csv(source, siteid, path_to_data_folder; kw...) if source === :zenodo return download_site_csv_from_zenodo(siteid, path_to_data_folder; kw...) elseif source === :schneider return download_site_csv_from_schneider(siteid, path_to_data_folder; kw...) else error("Source $(repr(source)) not found") end end function download_sites_data(path_to_data_folder, sitesid = 1:70; source = :zenodo, kw...) for siteid in sitesid download_site_csv(source, siteid, path_to_data_folder; kw...) end return end function download_pv(path_to_data_folder; kw...) download_pv_csv_from_zenodo(path_to_data_folder; kw...) return end function download_sites_data_parallel(path_to_data_folder, sitesid = 1:70; progress = true, max_threads = 4, compressed = true, source = :zenodo, kw...) file_sizes = get_file_size.(sitesid, compressed) if progress ext = compressed ? ".csv.gz" : ".csv" mprog = MultipleProgress(length(sitesid), file_sizes; kws = [(:desc => "Downloading $j$ext ",) for j in sitesid], desc = "Downloading files... ", dt = 0.1) end i = firstindex(sitesid) - 1 @sync for p in 1:max_threads @async while true idx = (i += 1) idx > lastindex(sitesid) && break download_site_csv(source, sitesid[idx], path_to_data_folder; progress = progress ? mprog[idx] : false, compressed = compressed, file_size = file_sizes[idx], kw...) end end progress && finish!(mprog) return end
[ 2, 5499, 284, 4321, 262, 1366, 198, 198, 9979, 34020, 1546, 14887, 1546, 796, 44189, 13, 961, 7, 22179, 6978, 7, 34720, 553, 38993, 2430, 16624, 4340, 13, 40664, 12340, 6060, 19778, 8, 198, 198, 2, 4808, 15002, 318, 257, 9518, 17168, 1033, 265, 11971, 2438, 422, 14626, 13, 20362, 198, 2, 3740, 1378, 12567, 13, 785, 14, 16980, 544, 13908, 14, 40717, 13, 20362, 14, 2436, 672, 14, 35809, 68, 22, 68, 39925, 2857, 11848, 20370, 1765, 2934, 1485, 1878, 23, 67, 1433, 2860, 20, 65, 6469, 65, 18, 65, 23, 64, 14, 10677, 14, 15002, 13, 20362, 2, 43, 5892, 198, 198, 8818, 4808, 15002, 7, 6371, 3712, 23839, 10100, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2393, 62, 6978, 3712, 23839, 10100, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 24697, 796, 685, 4357, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4371, 796, 2147, 11, 1303, 2147, 393, 18387, 393, 42945, 32577, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3696, 1096, 796, 2170, 368, 897, 7, 5317, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4296, 62, 41007, 796, 352, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 86, 23029, 628, 220, 220, 220, 611, 318, 22366, 7, 33723, 8, 198, 220, 220, 220, 220, 220, 220, 220, 4296, 62, 41007, 796, 4806, 198, 220, 220, 220, 886, 628, 220, 220, 220, 14626, 13, 9654, 7203, 18851, 1600, 19016, 11, 24697, 26, 479, 86, 23029, 466, 4269, 198, 220, 220, 220, 220, 220, 220, 220, 304, 1659, 7, 5532, 8, 11405, 1441, 220, 1303, 836, 470, 466, 1997, 329, 15190, 356, 460, 470, 1100, 357, 25907, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 15680, 62, 33661, 796, 657, 198, 220, 220, 220, 220, 220, 220, 220, 8654, 62, 2435, 796, 44712, 13, 2197, 3419, 628, 220, 220, 220, 220, 220, 220, 220, 2163, 989, 62, 47423, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8654, 62, 2435, 796, 44712, 13, 2197, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 11939, 62, 33723, 796, 15680, 62, 33661, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 356, 2652, 7819, 379, 7388, 4, 611, 2393, 318, 5749, 621, 2938, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4296, 0, 7, 33723, 11, 949, 7, 785, 24547, 62, 33723, 11, 3696, 1096, 12, 16, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 7308, 13, 9654, 7, 7753, 62, 6978, 11, 366, 86, 4943, 466, 277, 71, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 981, 5145, 68, 1659, 7, 5532, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15680, 62, 33661, 15853, 3551, 7, 69, 71, 11, 1100, 15182, 7, 5532, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 271, 10745, 7, 19119, 62, 41007, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 611, 44712, 13, 2197, 3419, 532, 8654, 62, 2435, 1875, 44712, 13, 22603, 27866, 623, 7, 744, 7, 12825, 19119, 62, 41007, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 989, 62, 47423, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 611, 5145, 271, 10745, 7, 19119, 62, 41007, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5461, 0, 7, 33723, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 198, 437, 198, 198, 8818, 651, 62, 7753, 62, 7857, 7, 15654, 312, 3712, 46541, 11, 25388, 3712, 33, 970, 8, 198, 220, 220, 220, 951, 796, 25388, 5633, 27071, 40664, 13, 34586, 1, 1058, 27071, 40664, 1, 198, 220, 220, 220, 1441, 2906, 346, 7, 5317, 11, 34020, 1546, 14887, 1546, 58, 15654, 312, 11, 951, 12962, 198, 437, 198, 198, 8818, 4321, 62, 15654, 62, 40664, 7, 10459, 11, 2524, 312, 11, 3108, 62, 1462, 62, 7890, 62, 43551, 26, 479, 86, 23029, 198, 220, 220, 220, 611, 2723, 24844, 1058, 4801, 24313, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 4321, 62, 15654, 62, 40664, 62, 6738, 62, 4801, 24313, 7, 15654, 312, 11, 3108, 62, 1462, 62, 7890, 62, 43551, 26, 479, 86, 23029, 198, 220, 220, 220, 2073, 361, 2723, 24844, 1058, 20601, 710, 1304, 198, 220, 220, 220, 220, 220, 220, 220, 1441, 4321, 62, 15654, 62, 40664, 62, 6738, 62, 20601, 710, 1304, 7, 15654, 312, 11, 3108, 62, 1462, 62, 7890, 62, 43551, 26, 479, 86, 23029, 198, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 4049, 7203, 7416, 29568, 260, 1050, 7, 10459, 4008, 407, 1043, 4943, 198, 220, 220, 220, 886, 198, 437, 198, 198, 8818, 4321, 62, 49315, 62, 7890, 7, 6978, 62, 1462, 62, 7890, 62, 43551, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5043, 312, 796, 352, 25, 2154, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2723, 796, 1058, 4801, 24313, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 86, 23029, 198, 220, 220, 220, 329, 2524, 312, 287, 5043, 312, 198, 220, 220, 220, 220, 220, 220, 220, 4321, 62, 15654, 62, 40664, 7, 10459, 11, 2524, 312, 11, 3108, 62, 1462, 62, 7890, 62, 43551, 26, 479, 86, 23029, 198, 220, 220, 220, 886, 198, 220, 220, 220, 1441, 198, 437, 198, 198, 8818, 4321, 62, 79, 85, 7, 6978, 62, 1462, 62, 7890, 62, 43551, 26, 479, 86, 23029, 198, 220, 220, 220, 4321, 62, 79, 85, 62, 40664, 62, 6738, 62, 4801, 24313, 7, 6978, 62, 1462, 62, 7890, 62, 43551, 26, 479, 86, 23029, 198, 220, 220, 220, 1441, 198, 437, 198, 198, 8818, 4321, 62, 49315, 62, 7890, 62, 1845, 29363, 7, 6978, 62, 1462, 62, 7890, 62, 43551, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5043, 312, 796, 352, 25, 2154, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4371, 796, 2081, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3509, 62, 16663, 82, 796, 604, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 25388, 796, 2081, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2723, 796, 1058, 4801, 24313, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 86, 23029, 198, 220, 220, 220, 220, 198, 220, 220, 220, 2393, 62, 82, 4340, 796, 651, 62, 7753, 62, 7857, 12195, 49315, 312, 11, 25388, 8, 198, 220, 220, 220, 220, 198, 220, 220, 220, 611, 4371, 198, 220, 220, 220, 220, 220, 220, 220, 1070, 796, 25388, 5633, 27071, 40664, 13, 34586, 1, 1058, 27071, 40664, 1, 198, 220, 220, 220, 220, 220, 220, 220, 285, 1676, 70, 796, 20401, 32577, 7, 13664, 7, 49315, 312, 828, 2393, 62, 82, 4340, 26, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 18504, 796, 47527, 25, 20147, 5218, 366, 10002, 278, 720, 73, 3, 2302, 33172, 8, 329, 474, 287, 5043, 312, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1715, 796, 366, 10002, 278, 3696, 986, 33172, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 83, 796, 657, 13, 16, 8, 198, 220, 220, 220, 886, 628, 220, 220, 220, 1312, 796, 717, 9630, 7, 49315, 312, 8, 532, 352, 198, 220, 220, 220, 2488, 27261, 329, 279, 287, 352, 25, 9806, 62, 16663, 82, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 292, 13361, 981, 2081, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4686, 87, 796, 357, 72, 15853, 352, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4686, 87, 1875, 938, 9630, 7, 49315, 312, 8, 11405, 2270, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4321, 62, 15654, 62, 40664, 7, 10459, 11, 5043, 312, 58, 312, 87, 4357, 3108, 62, 1462, 62, 7890, 62, 43551, 26, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4371, 796, 4371, 5633, 285, 1676, 70, 58, 312, 87, 60, 1058, 3991, 11, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 25388, 796, 25388, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2393, 62, 7857, 796, 2393, 62, 82, 4340, 58, 312, 87, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 479, 86, 23029, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 220, 220, 220, 4371, 11405, 5461, 0, 7, 76, 1676, 70, 8, 198, 220, 220, 220, 1441, 198, 437, 198 ]
1.90927
2,028
using HTTP using JSON struct Client Query::Function serverUrl::Function headers::Function serverAuth::Function end struct Result Info Data::String end """ Queryclient(url::String,data::String; vars::Dict=Dict(),auth::String="Bearer <PASSWORD>", headers::Dict=Dict(),getlink::Bool=false,check::Bool=false,operationName::Union{String, Nothing}=nothing) Execute a query with all available parameters """ function Queryclient(url::String,data::String; vars::Dict=Dict(),auth::String="Bearer <PASSWORD>", headers::Dict=Dict(),getlink::Bool=false, check::Bool=false,operationName::Union{String, Nothing}=nothing) if (check) Validatequery(Parse(data)) end if (getlink == true) #------------ link =url*"?query="*HTTP.escapeuri(data) if operationName !== nothing && length(operationName) > 0 link=link*"&operationName="*operationName end if length(vars)>0 link=link*"&variables="*HTTP.escapeuri(JSON.json(vars)) end return link #------------ else myjson = Dict("query"=>data,"variables" => vars,"operationName" => operationName) my_headers = HTTP.mkheaders(["Accept" => "application/json","Content-Type" => "application/json" ,"Authorization" => auth]) for (key, value) in headers HTTP.setheader(my_headers,key => value ) end r = HTTP.post(url,my_headers,JSON.json(myjson)) return Result(r,String(r.body)) end end """ Queryclient(queryurl::String) Execute the query in link format and return the result. """ function Queryclient(queryurl::String) r=HTTP.get(queryurl) return Result(r,String(r.body)) end """ GraphQLClient(url::String; auth::String="Bearer <PASSWORD>", headers::Dict=Dict()) Stores the parameters of the query for later use, returns a Client object """ function GraphQLClient(url::String; auth::String="Bearer 0<PASSWORD>", headers::Dict=Dict()) my_url::String= url my_auth::String= auth my_headersextras::Dict= headers function serverUrl(url::String) my_url = url end function setheaders(headers::Dict) my_headersextras=headers end function serverAuth(auth::String) my_auth= auth end function Query(data::String; vars::Dict=Dict(),getlink::Bool=false,check::Bool=false,operationName::Union{String, Nothing}=nothing) return Queryclient(my_url,data,vars=vars,auth=my_auth,headers=my_headersextras,getlink=getlink,operationName=operationName,check=check) end return Client(Query,serverUrl,setheaders,serverAuth) end
[ 3500, 14626, 198, 3500, 19449, 198, 198, 7249, 20985, 198, 197, 20746, 3712, 22203, 198, 197, 15388, 28165, 3712, 22203, 198, 197, 50145, 3712, 22203, 198, 197, 15388, 30515, 3712, 22203, 198, 437, 198, 198, 7249, 25414, 198, 197, 12360, 198, 197, 6601, 3712, 10100, 198, 437, 628, 198, 37811, 198, 220, 220, 220, 43301, 16366, 7, 6371, 3712, 10100, 11, 7890, 3712, 10100, 26, 410, 945, 3712, 35, 713, 28, 35, 713, 22784, 18439, 3712, 10100, 2625, 3856, 11258, 1279, 47924, 54, 12532, 29, 1600, 24697, 3712, 35, 713, 28, 35, 713, 22784, 1136, 8726, 3712, 33, 970, 28, 9562, 11, 9122, 3712, 33, 970, 28, 9562, 11, 27184, 5376, 3712, 38176, 90, 10100, 11, 10528, 92, 28, 22366, 8, 628, 220, 8393, 1133, 257, 12405, 351, 477, 1695, 10007, 198, 37811, 198, 8818, 43301, 16366, 7, 6371, 3712, 10100, 11, 7890, 3712, 10100, 26, 198, 197, 197, 197, 197, 197, 410, 945, 3712, 35, 713, 28, 35, 713, 22784, 18439, 3712, 10100, 2625, 3856, 11258, 1279, 47924, 54, 12532, 29, 1600, 198, 197, 197, 197, 197, 197, 24697, 3712, 35, 713, 28, 35, 713, 22784, 1136, 8726, 3712, 33, 970, 28, 9562, 11, 198, 197, 197, 197, 197, 197, 2198, 3712, 33, 970, 28, 9562, 11, 27184, 5376, 3712, 38176, 90, 10100, 11, 10528, 92, 28, 22366, 8, 628, 197, 361, 357, 9122, 8, 198, 197, 197, 7762, 20540, 22766, 7, 10044, 325, 7, 7890, 4008, 198, 197, 437, 628, 197, 361, 357, 1136, 8726, 6624, 2081, 8, 198, 197, 197, 2, 10541, 198, 197, 197, 8726, 796, 6371, 9, 13984, 22766, 2625, 9, 40717, 13, 41915, 9900, 7, 7890, 8, 628, 197, 197, 361, 4905, 5376, 5145, 855, 2147, 11405, 4129, 7, 27184, 5376, 8, 1875, 657, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2792, 28, 8726, 9, 1, 5, 27184, 5376, 2625, 9, 27184, 5376, 198, 197, 197, 437, 628, 197, 197, 361, 4129, 7, 85, 945, 8, 29, 15, 198, 197, 197, 197, 8726, 28, 8726, 9, 1, 5, 25641, 2977, 2625, 9, 40717, 13, 41915, 9900, 7, 40386, 13, 17752, 7, 85, 945, 4008, 198, 197, 197, 437, 198, 197, 197, 7783, 2792, 198, 197, 197, 2, 10541, 198, 197, 17772, 628, 197, 197, 1820, 17752, 796, 360, 713, 7203, 22766, 1, 14804, 7890, 553, 25641, 2977, 1, 5218, 410, 945, 553, 27184, 5376, 1, 5218, 4905, 5376, 8, 198, 197, 197, 1820, 62, 50145, 796, 14626, 13, 28015, 50145, 7, 14692, 38855, 1, 5218, 366, 31438, 14, 17752, 2430, 19746, 12, 6030, 1, 5218, 366, 31438, 14, 17752, 1, 42911, 13838, 1634, 1, 5218, 6284, 12962, 198, 197, 197, 1640, 357, 2539, 11, 1988, 8, 287, 24697, 198, 197, 197, 197, 40717, 13, 2617, 25677, 7, 1820, 62, 50145, 11, 2539, 5218, 1988, 1267, 198, 197, 197, 437, 198, 197, 197, 81, 796, 14626, 13, 7353, 7, 6371, 11, 1820, 62, 50145, 11, 40386, 13, 17752, 7, 1820, 17752, 4008, 198, 197, 197, 7783, 25414, 7, 81, 11, 10100, 7, 81, 13, 2618, 4008, 628, 197, 437, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 43301, 16366, 7, 22766, 6371, 3712, 10100, 8, 628, 220, 8393, 1133, 262, 12405, 287, 2792, 5794, 290, 1441, 262, 1255, 13, 198, 37811, 198, 8818, 43301, 16366, 7, 22766, 6371, 3712, 10100, 8, 198, 197, 81, 28, 40717, 13, 1136, 7, 22766, 6371, 8, 198, 197, 7783, 25414, 7, 81, 11, 10100, 7, 81, 13, 2618, 4008, 198, 437, 198, 198, 37811, 198, 220, 220, 220, 29681, 9711, 11792, 7, 6371, 3712, 10100, 26, 6284, 3712, 10100, 2625, 3856, 11258, 1279, 47924, 54, 12532, 29, 1600, 24697, 3712, 35, 713, 28, 35, 713, 28955, 628, 220, 41835, 262, 10007, 286, 262, 12405, 329, 1568, 779, 11, 5860, 257, 20985, 2134, 198, 37811, 198, 8818, 29681, 9711, 11792, 7, 6371, 3712, 10100, 26, 6284, 3712, 10100, 2625, 3856, 11258, 657, 27, 47924, 54, 12532, 29, 1600, 24697, 3712, 35, 713, 28, 35, 713, 28955, 628, 197, 1820, 62, 6371, 3712, 10100, 28, 19016, 198, 197, 1820, 62, 18439, 3712, 10100, 28, 6284, 198, 197, 1820, 62, 25677, 325, 742, 8847, 3712, 35, 713, 28, 24697, 628, 197, 8818, 4382, 28165, 7, 6371, 3712, 10100, 8, 198, 197, 197, 1820, 62, 6371, 796, 19016, 198, 197, 437, 628, 197, 8818, 900, 50145, 7, 50145, 3712, 35, 713, 8, 198, 197, 220, 220, 220, 616, 62, 25677, 325, 742, 8847, 28, 50145, 198, 197, 437, 628, 197, 8818, 4382, 30515, 7, 18439, 3712, 10100, 8, 198, 197, 197, 1820, 62, 18439, 28, 6284, 198, 197, 437, 628, 197, 8818, 43301, 7, 7890, 3712, 10100, 26, 410, 945, 3712, 35, 713, 28, 35, 713, 22784, 1136, 8726, 3712, 33, 970, 28, 9562, 11, 9122, 3712, 33, 970, 28, 9562, 11, 27184, 5376, 3712, 38176, 90, 10100, 11, 10528, 92, 28, 22366, 8, 628, 197, 197, 7783, 43301, 16366, 7, 1820, 62, 6371, 11, 7890, 11, 85, 945, 28, 85, 945, 11, 18439, 28, 1820, 62, 18439, 11, 50145, 28, 1820, 62, 25677, 325, 742, 8847, 11, 1136, 8726, 28, 1136, 8726, 11, 27184, 5376, 28, 27184, 5376, 11, 9122, 28, 9122, 8, 628, 197, 437, 628, 197, 7783, 20985, 7, 20746, 11, 15388, 28165, 11, 2617, 50145, 11, 15388, 30515, 8, 198, 437 ]
2.807298
877
<gh_stars>100-1000 using DataFrames, Dash, DashHtmlComponents, DashCoreComponents, PlotlyJS, UrlDownload df2 = DataFrame(urldownload("https://raw.githubusercontent.com/plotly/datasets/master/country_indicators.csv")) dropmissing!(df2) rename!(df2, Dict(:"Year" => "year")) available_indicators = unique(df2[!, "Indicator Name"]) years = unique(df2[!, "year"]) app = dash() app.layout = html_div() do html_div( children = [ dcc_dropdown( id = "xaxis-column", options = [ (label = i, value = i) for i in available_indicators ], value = "Fertility rate, total (births per woman)", ), dcc_radioitems( id = "xaxis-type", options = [(label = i, value = i) for i in ["linear", "log"]], value = "linear", ), ], style = (width = "48%", display = "inline-block"), ), html_div( children = [ dcc_dropdown( id = "yaxis-column", options = [ (label = i, value = i) for i in available_indicators ], value = "Life expectancy at birth, total (years)", ), dcc_radioitems( id = "yaxis-type", options = [(label = i, value = i) for i in ["linear", "log"]], value = "linear", ), ], style = (width = "48%", display = "inline-block", float = "right"), ), dcc_graph(id = "indicator-graphic"), dcc_slider( id = "year-slider-2", min = minimum(years), max = maximum(years), marks = Dict([Symbol(v) => Symbol(v) for v in years]), value = minimum(years), step = nothing, ) end callback!( app, Output("indicator-graphic", "figure"), Input("xaxis-column", "value"), Input("yaxis-column", "value"), Input("xaxis-type", "value"), Input("yaxis-type", "value"), Input("year-slider-2", "value"), ) do xaxis_column_name, yaxis_column_name, xaxis_type, yaxis_type, year_value df2f = df2[df2.year .== year_value, :] return Plot( df2f[df2f[!, Symbol("Indicator Name")] .== xaxis_column_name, :Value], df2f[df2f[!, Symbol("Indicator Name")] .== yaxis_column_name, :Value], Layout( xaxis_type = xaxis_type == "Linear" ? "linear" : "log", xaxis_title = xaxis_column_name, yaxis_title = yaxis_column_name, yaxis_type = yaxis_type == "Linear" ? "linear" : "log", hovermode = "closest", ), kind = "scatter", text = df2f[ df2f[Symbol("Indicator Name")] .== yaxis_column_name, Symbol("Country Name"), ], mode = "markers", marker_size = 15, marker_opacity = 0.5, marker_line_width = 0.5, marker_line_color = "white" ) end run_server(app, "0.0.0.0", debug = true)
[ 27, 456, 62, 30783, 29, 3064, 12, 12825, 198, 3500, 6060, 35439, 11, 16189, 11, 16189, 39, 20369, 7293, 3906, 11, 16189, 14055, 7293, 3906, 11, 28114, 306, 20120, 11, 8799, 75, 10002, 628, 198, 7568, 17, 796, 6060, 19778, 7, 333, 335, 593, 2220, 7203, 5450, 1378, 1831, 13, 12567, 43667, 13, 785, 14, 29487, 306, 14, 19608, 292, 1039, 14, 9866, 14, 19315, 62, 521, 44549, 13, 40664, 48774, 198, 198, 14781, 45688, 0, 7, 7568, 17, 8, 198, 198, 918, 480, 0, 7, 7568, 17, 11, 360, 713, 7, 11097, 17688, 1, 5218, 366, 1941, 48774, 198, 198, 15182, 62, 521, 44549, 796, 3748, 7, 7568, 17, 58, 28265, 366, 5497, 26407, 6530, 8973, 8, 198, 19002, 796, 3748, 7, 7568, 17, 58, 28265, 366, 1941, 8973, 8, 198, 198, 1324, 796, 14470, 3419, 198, 198, 1324, 13, 39786, 796, 27711, 62, 7146, 3419, 466, 198, 220, 220, 220, 27711, 62, 7146, 7, 198, 220, 220, 220, 220, 220, 220, 220, 1751, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 535, 62, 14781, 2902, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4686, 796, 366, 87, 22704, 12, 28665, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3689, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 18242, 796, 1312, 11, 1988, 796, 1312, 8, 329, 1312, 287, 1695, 62, 521, 44549, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16589, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1988, 796, 366, 37, 27651, 2494, 11, 2472, 357, 24280, 82, 583, 2415, 42501, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10612, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 535, 62, 37004, 23814, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4686, 796, 366, 87, 22704, 12, 4906, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3689, 796, 47527, 18242, 796, 1312, 11, 1988, 796, 1312, 8, 329, 1312, 287, 14631, 29127, 1600, 366, 6404, 8973, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1988, 796, 366, 29127, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10612, 198, 220, 220, 220, 220, 220, 220, 220, 16589, 198, 220, 220, 220, 220, 220, 220, 220, 3918, 796, 357, 10394, 796, 366, 2780, 4, 1600, 3359, 796, 366, 45145, 12, 9967, 12340, 198, 220, 220, 220, 10612, 198, 220, 220, 220, 27711, 62, 7146, 7, 198, 220, 220, 220, 220, 220, 220, 220, 1751, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 535, 62, 14781, 2902, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4686, 796, 366, 88, 22704, 12, 28665, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3689, 796, 685, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 18242, 796, 1312, 11, 1988, 796, 1312, 8, 329, 1312, 287, 1695, 62, 521, 44549, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16589, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1988, 796, 366, 14662, 29098, 379, 4082, 11, 2472, 357, 19002, 42501, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10612, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 535, 62, 37004, 23814, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4686, 796, 366, 88, 22704, 12, 4906, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3689, 796, 47527, 18242, 796, 1312, 11, 1988, 796, 1312, 8, 329, 1312, 287, 14631, 29127, 1600, 366, 6404, 8973, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1988, 796, 366, 29127, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10612, 198, 220, 220, 220, 220, 220, 220, 220, 16589, 198, 220, 220, 220, 220, 220, 220, 220, 3918, 796, 357, 10394, 796, 366, 2780, 4, 1600, 3359, 796, 366, 45145, 12, 9967, 1600, 12178, 796, 366, 3506, 12340, 198, 220, 220, 220, 10612, 198, 220, 220, 220, 288, 535, 62, 34960, 7, 312, 796, 366, 521, 26407, 12, 70, 22262, 12340, 198, 220, 220, 220, 288, 535, 62, 6649, 1304, 7, 198, 220, 220, 220, 220, 220, 220, 220, 4686, 796, 366, 1941, 12, 6649, 1304, 12, 17, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 949, 796, 5288, 7, 19002, 828, 198, 220, 220, 220, 220, 220, 220, 220, 3509, 796, 5415, 7, 19002, 828, 198, 220, 220, 220, 220, 220, 220, 220, 8849, 796, 360, 713, 26933, 13940, 23650, 7, 85, 8, 5218, 38357, 7, 85, 8, 329, 410, 287, 812, 46570, 198, 220, 220, 220, 220, 220, 220, 220, 1988, 796, 5288, 7, 19002, 828, 198, 220, 220, 220, 220, 220, 220, 220, 2239, 796, 2147, 11, 198, 220, 220, 220, 1267, 198, 437, 198, 198, 47423, 0, 7, 198, 220, 220, 220, 598, 11, 198, 220, 220, 220, 25235, 7203, 521, 26407, 12, 70, 22262, 1600, 366, 26875, 12340, 198, 220, 220, 220, 23412, 7203, 87, 22704, 12, 28665, 1600, 366, 8367, 12340, 198, 220, 220, 220, 23412, 7203, 88, 22704, 12, 28665, 1600, 366, 8367, 12340, 198, 220, 220, 220, 23412, 7203, 87, 22704, 12, 4906, 1600, 366, 8367, 12340, 198, 220, 220, 220, 23412, 7203, 88, 22704, 12, 4906, 1600, 366, 8367, 12340, 198, 220, 220, 220, 23412, 7203, 1941, 12, 6649, 1304, 12, 17, 1600, 366, 8367, 12340, 198, 8, 466, 2124, 22704, 62, 28665, 62, 3672, 11, 331, 22704, 62, 28665, 62, 3672, 11, 2124, 22704, 62, 4906, 11, 331, 22704, 62, 4906, 11, 614, 62, 8367, 198, 220, 220, 220, 47764, 17, 69, 796, 47764, 17, 58, 7568, 17, 13, 1941, 764, 855, 614, 62, 8367, 11, 1058, 60, 198, 220, 220, 220, 1441, 28114, 7, 198, 220, 220, 220, 220, 220, 220, 220, 47764, 17, 69, 58, 7568, 17, 69, 58, 28265, 38357, 7203, 5497, 26407, 6530, 4943, 60, 764, 855, 2124, 22704, 62, 28665, 62, 3672, 11, 1058, 11395, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 47764, 17, 69, 58, 7568, 17, 69, 58, 28265, 38357, 7203, 5497, 26407, 6530, 4943, 60, 764, 855, 331, 22704, 62, 28665, 62, 3672, 11, 1058, 11395, 4357, 198, 220, 220, 220, 220, 220, 220, 220, 47639, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2124, 22704, 62, 4906, 796, 2124, 22704, 62, 4906, 6624, 366, 14993, 451, 1, 5633, 366, 29127, 1, 1058, 366, 6404, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2124, 22704, 62, 7839, 796, 2124, 22704, 62, 28665, 62, 3672, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 22704, 62, 7839, 796, 331, 22704, 62, 28665, 62, 3672, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 331, 22704, 62, 4906, 796, 331, 22704, 62, 4906, 6624, 366, 14993, 451, 1, 5633, 366, 29127, 1, 1058, 366, 6404, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 20599, 14171, 796, 366, 565, 418, 395, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 10612, 198, 220, 220, 220, 220, 220, 220, 220, 1611, 796, 366, 1416, 1436, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 2420, 796, 47764, 17, 69, 58, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 47764, 17, 69, 58, 13940, 23650, 7203, 5497, 26407, 6530, 4943, 60, 764, 855, 331, 22704, 62, 28665, 62, 3672, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 38357, 7203, 33921, 6530, 12340, 198, 220, 220, 220, 220, 220, 220, 220, 16589, 198, 220, 220, 220, 220, 220, 220, 220, 4235, 796, 366, 4102, 364, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 18364, 62, 7857, 796, 1315, 11, 198, 220, 220, 220, 220, 220, 220, 220, 18364, 62, 404, 4355, 796, 657, 13, 20, 11, 198, 220, 220, 220, 220, 220, 220, 220, 18364, 62, 1370, 62, 10394, 796, 657, 13, 20, 11, 198, 220, 220, 220, 220, 220, 220, 220, 18364, 62, 1370, 62, 8043, 796, 366, 11186, 1, 198, 220, 220, 220, 1267, 198, 437, 198, 198, 5143, 62, 15388, 7, 1324, 11, 366, 15, 13, 15, 13, 15, 13, 15, 1600, 14257, 796, 2081, 8, 198 ]
1.988823
1,521
using PENBBControl using Test @testset "PENBBControl.jl" begin # Write your tests here. end
[ 3500, 350, 1677, 33833, 756, 3225, 198, 3500, 6208, 198, 198, 31, 9288, 2617, 366, 47, 1677, 33833, 756, 3225, 13, 20362, 1, 2221, 198, 220, 220, 220, 1303, 19430, 534, 5254, 994, 13, 198, 437, 198 ]
2.621622
37
using RDatasets, DataFrames, FixedEffectModels, Base.Test x = dataset("plm", "Cigar") x[:pState] = pool(x[:State]) x[:pYear] = pool(x[:Year]) result = reg(Sales ~ NDI, x) show(result) predict(result, x) residuals(result, x) reg(Sales ~ CPI + (Price = Pimin), x) result = reg(Sales ~ CPI + (Price = Pimin), x) predict(result, x) residuals(result, x) model_response(result, x) @test nobs(result) == 1380 @test_approx_eq vcov(result)[1] 3.5384578251636785 show(reg(Sales ~ Price |> pState, x)) show(reg(Sales ~ CPI + (Price = Pimin) |> pState, x)) result = reg(Sales ~ Price, x) @test maxabs(residuals(result, x)[1:10] .- [-39.2637, -37.48801, -34.38801, -36.09743, -36.97446, -43.15547, -41.22573, -40.83648, -34.52427, -28.91617]) <= 1e-4 result = reg(Sales ~ Price |> pState, x, save = true) @test maxabs(result.augmentdf[:residuals][1:10] .- [-22.08499, -20.33318, -17.23318, -18.97645, -19.85547, -26.1161, -24.20627, -23.87674, -17.62624, -12.01018]) <= 1e-4
[ 3500, 371, 27354, 292, 1039, 11, 6060, 35439, 11, 10832, 18610, 5841, 1424, 11, 7308, 13, 14402, 198, 198, 87, 796, 27039, 7203, 489, 76, 1600, 366, 34, 328, 283, 4943, 198, 87, 58, 25, 79, 9012, 60, 796, 5933, 7, 87, 58, 25, 9012, 12962, 198, 87, 58, 25, 79, 17688, 60, 796, 5933, 7, 87, 58, 25, 17688, 12962, 628, 198, 20274, 796, 842, 7, 44490, 5299, 399, 17931, 11, 2124, 8, 198, 12860, 7, 20274, 8, 198, 79, 17407, 7, 20274, 11, 2124, 8, 198, 411, 312, 723, 82, 7, 20274, 11, 2124, 8, 628, 198, 198, 2301, 7, 44490, 5299, 42103, 1343, 357, 18124, 796, 350, 320, 259, 828, 2124, 8, 198, 198, 20274, 796, 842, 7, 44490, 5299, 42103, 1343, 357, 18124, 796, 350, 320, 259, 828, 2124, 8, 198, 79, 17407, 7, 20274, 11, 2124, 8, 198, 411, 312, 723, 82, 7, 20274, 11, 2124, 8, 198, 19849, 62, 26209, 7, 20274, 11, 2124, 8, 198, 31, 9288, 220, 645, 1443, 7, 20274, 8, 6624, 1511, 1795, 198, 31, 9288, 62, 1324, 13907, 62, 27363, 220, 410, 66, 709, 7, 20274, 38381, 16, 60, 220, 513, 13, 49561, 2231, 3695, 1495, 1433, 2623, 41172, 628, 198, 12860, 7, 2301, 7, 44490, 5299, 7886, 930, 29, 279, 9012, 11, 2124, 4008, 198, 12860, 7, 2301, 7, 44490, 5299, 42103, 1343, 357, 18124, 796, 350, 320, 259, 8, 930, 29, 279, 9012, 11, 2124, 4008, 628, 628, 198, 198, 20274, 796, 842, 7, 44490, 5299, 7886, 11, 2124, 8, 198, 31, 9288, 3509, 8937, 7, 411, 312, 723, 82, 7, 20274, 11, 2124, 38381, 16, 25, 940, 60, 764, 12, 25915, 2670, 13, 2075, 2718, 11, 532, 2718, 13, 33646, 486, 11, 532, 2682, 13, 30460, 486, 11, 532, 2623, 13, 2931, 22, 3559, 11, 532, 2623, 13, 5607, 27260, 11, 532, 3559, 13, 18742, 2857, 11, 532, 3901, 13, 18182, 4790, 11, 532, 1821, 13, 5999, 34287, 11, 532, 2682, 13, 48057, 1983, 11, 532, 2078, 13, 48894, 1558, 12962, 19841, 352, 68, 12, 19, 198, 198, 20274, 796, 842, 7, 44490, 5299, 7886, 930, 29, 279, 9012, 11, 2124, 11, 3613, 796, 2081, 8, 198, 31, 9288, 3509, 8937, 7, 20274, 13, 559, 5154, 7568, 58, 25, 411, 312, 723, 82, 7131, 16, 25, 940, 60, 764, 12, 25915, 1828, 13, 2919, 28324, 11, 532, 1238, 13, 20370, 1507, 11, 532, 1558, 13, 25429, 1507, 11, 532, 1507, 13, 24, 4304, 2231, 11, 532, 1129, 13, 45432, 2857, 11, 532, 2075, 13, 1157, 5333, 11, 532, 1731, 13, 22136, 1983, 11, 532, 1954, 13, 5774, 45385, 11, 532, 1558, 13, 45191, 1731, 11, 532, 1065, 13, 486, 29159, 12962, 19841, 352, 68, 12, 19, 628, 628 ]
2.174779
452
using CosmoParticles using FillArrays using LazyArrays using LinearAlgebra using Rotations using SortingAlgorithms using StatsBase using Test using Unitful const CP = CosmoParticles @testset "CosmoParticles.jl" begin @testset "Particles" begin p = Particles(:dm) p.id = sample(1:1000, 100; replace=false) p.pos = rand(3, 100) # different id and pos for copied Particles pcid = rand(100) pcpos = rand(3, 100) # Particle specific pc = Particles(:dm, :id => p.id, :pos => p.pos) @test pc == p pc = copy(p) @test pc == p @test pc !== p @test pc.props == p.props @test pc.props !== p.props pc = empty(p) @test pc.type === :dm @test isempty(pc.props) @test isempty(pc) @test CP.particle_name(p) == "Particles" @test issetequal(propertynames(p), [:type, :id, :pos]) @test issetequal(propertynames(p; private=true), [:type, :props, :id, :pos]) io = IOBuffer() show(io, "text/plain", p) @test String(take!(io)) == "dm: 100 Particles\n id pos" # test AbstractParticles with basic implementation Particles @test CP.get_props(p) === p.props @test getproperty(p, :id) === p.props[:id] @test getproperty(p, :type) === p.type === :dm @test getproperty(p, :props) === p.props @test p.id === p.props[:id] pc = copy(p) setproperty!(p, :pos, pcpos) @test p.pos === pcpos pc.id = pcid @test pc.id === pcid @test p.id !== pcid @test_throws ErrorException(""" setfield!: immutable struct of type Particles cannot be changed""") p.type = :gas @test p[:id] === p.props[:id] pc = copy(p) p[:id] = pcid @test p.id === pcid @test keys(p) == keys(p.props) @test haskey(p, :id) @test !haskey(p, :vel) @test !haskey(p, :type) @test values(p) == values(p.props) @test issetequal(propertynames(p), [:type, :id, :pos]) # test default implementations for AbstractParticles @test issetequal(Base.@invoke(propertynames(p::AbstractParticles)), [:id, :pos]) pc = deepcopy(p) empty!(pc) @test isempty(pc.props) @test isempty(pc) @test !isempty(p) copy!(pc, p) @test pc !== p && pc == p && !isempty(pc) @test CP.particle_number(p) == 100 @test CP.particle_number(Particles(:gas)) == 0 @test CP.particle_number(Particles(:gas, Dict{Symbol,Any}(:mass => 3))) == 0 @test isnothing(Base.@invoke(CP.particle_name(p::AbstractParticles))) io = IOBuffer() CP.show_properties(io, "text/plain", p) @test String(take!(io)) == "100 Particles\n id pos" end @testset "AllParticles" begin dm = Particles(:dm) dm.id = sample(1:1000, 100; replace=false) dm.pos = rand(3, 100) dm.mass = rand() dm.test = rand() gas = Particles(:gas) gas.id = sample(1001:2000, 100; replace=false) gas.pos = rand(3, 100) gas.mass = rand(100) gas.temp = rand(100) gas.zs = rand(2, 100) gas.test = rand(2, 100) pcoll = ParticleCollection(dm, gas) p = AllParticles(pcoll) @test CP.particle_collection(p) === pcoll # @test get_props(p) === p.props # not part of the API if p.id[1] == dm.id[1] @test p.id == vcat(dm.id, gas.id) @test p.pos == hcat(dm.pos, gas.pos) @test p.mass == vcat(fill(dm.mass, length(dm.id)), gas.mass) @test isequal.(p.temp, vcat(fill(missing, length(dm.id)), gas.temp)) |> all @test isequal.(p.zs, hcat(fill(missing, 2, length(dm.id)), gas.zs)) |> all @test p.test == hcat(fill(dm.test, 2, length(dm.id)), gas.test) else @test p.id == vcat(gas.id, dm.id) @test p.pos == hcat(gas.pos, dm.pos) @test p.mass == vcat(gas.mass, fill(dm.mass, length(dm.id))) @test isequal.(p.temp, vcat(gas.temp, fill(missing, length(dm.id)))) |> all @test isequal.(p.zs, hcat(gas.zs, fill(missing, 2, length(dm.id)))) |> all @test p.test == hcat(gas.test, fill(dm.test, 2, length(dm.id))) end @test_throws ErrorException p.id = rand(100) @test_throws KeyError p.vel @test issetequal(keys(p), [:id, :mass, :pos, :temp, :zs, :test]) @test keys(p) == keys(AllParticles(pcoll)) @test haskey(p, :id) && haskey(AllParticles(pcoll), :id) @test !haskey(p, :vel) && !haskey(AllParticles(pcoll), :vel) @test all(val === p[key] for (key, val) in zip(keys(p), values(p))) @test all(val === p[key] for (key, val) in pairs(p)) @test_throws ErrorException copy(p) @test_throws ErrorException copy!(p, AllParticles(pcoll)) @test_throws ErrorException copy!(p, dm) pc = Particles(:all) copy!(pc, p) collect(values(p)) # materializes properties in Dict @test pc.id == p.id @test pc.mass == p.mass @test pc.pos == p.pos @test all(isequal.(pc.temp, p.temp)) @test all(isequal.(pc.zs, p.zs)) @test pc.test == p.test copy!(pc, p, [:id, :mass, :temp]) @test haskey.((pc,), [:id, :mass, :temp]) |> all @test !haskey(pc, :pos) @test isa.([pc.id, pc.mass, pc.temp], Array) |> all @test Particles(p, [:id, :mass, :temp]) == pc @test_throws ErrorException empty(p) @test_throws ErrorException empty!(p) @test !isempty(p) @test isempty(ParticleCollection() |> AllParticles) @test isempty(ParticleCollection(Particles(:dm), Particles(:gas)) |> AllParticles) @test p == AllParticles(pcoll) @test CP.particle_name(p) == "Particles" @test CP.particle_number(p) == 200 list = [:id, :mass, :pos, :temp, :zs, :test] @test issetequal(propertynames(p), list) @test issetequal(propertynames(p; private=true), [fieldnames(AllParticles) |> collect; list]) io = IOBuffer() show(io, "text/plain", p) @test String(take!(io)) == "all: 200 Particles\n id mass pos temp test zs" @test CP.particle_number(AllParticles(ParticleCollection())) == 0 mask = isodd.(p.id) ind = findall(mask) @test_throws ErrorException p[mask] @test_throws ErrorException p[ind] # cover case where the dimension is not found from a vector or matrix # and where only one particle subtype exists pos = rand(3, 100) mass = rand() pc = ParticleCollection(Particles(:dm, :pos => pos, :mass => mass)) ap = pc.all @test ap.pos == pos @test ap.mass == fill(mass, 100) end @testset "Particle Collection" begin dm = Particles(:dm) dm.id = sample(1:1000, 100; replace=false) dm.pos = rand(3, 100) gas = Particles(:gas) gas.id = sample(1001:2000, 100; replace=false) gas.pos = rand(3, 100) @testset "ParticleCollection" begin pc = ParticleCollection() @test pc isa ParticleCollection{Particles} @test pc.particles == Dict{Symbol,Particles}() @test ParticleCollection(Particles) == pc pc = ParticleCollection(:dm => dm, :gas => gas) @test pc isa ParticleCollection{Particles} @test pc.particles == Dict{Symbol,Particles}(:dm => dm, :gas => gas) @test ParticleCollection(dm, gas) == pc @test redshift(pc) == 0 pc = ParticleCollection(dm) pcc = copy(pc) @test pcc.particles[:dm] === pc.particles[:dm] pcc.particles[:dm] = gas @test pcc.particles[:dm] !== pc.particles[:dm] @test empty(pc) == ParticleCollection() pc = ParticleCollection(dm, gas) io = IOBuffer() show(io, "text/plain", pc) @test String(take!(io)) == "ParticleCollection\ndm: 100 Particles\n id pos\ngas: 100 Particles\n id pos" end @testset "RedshiftParticleCollection" begin z = 0.5 pc = RedshiftParticleCollection(0.5) @test pc isa RedshiftParticleCollection{Particles} @test pc.particles == Dict{Symbol,Particles}() @test pc.z == z @test RedshiftParticleCollection(Particles, z) == pc pc = RedshiftParticleCollection(z, :dm => dm, :gas => gas) @test pc isa RedshiftParticleCollection{Particles} @test pc.particles == Dict{Symbol,Particles}(:dm => dm, :gas => gas) @test RedshiftParticleCollection(z, dm, gas) == pc @test redshift(pc) == z pc = RedshiftParticleCollection(z, dm) pcc = copy(pc) @test pcc.particles[:dm] === pc.particles[:dm] pcc.particles[:dm] = gas @test pcc.particles[:dm] !== pc.particles[:dm] @test empty(pc) == RedshiftParticleCollection(z) pc = RedshiftParticleCollection(z, dm, gas) io = IOBuffer() show(io, "text/plain", pc) @test String(take!(io)) == "ParticleCollection at z = $z\ndm: 100 Particles\n id pos\ngas: 100 Particles\n id pos" @test issetequal(propertynames(pc), [:z, :all, :dm, :gas]) @test issetequal(propertynames(pc; private=true), [:z, :all, :particles, :dm, :gas]) rpc = RedshiftParticleCollection(0, dm, gas) pc = ParticleCollection(dm, gas) @test rpc == pc && pc == rpc rpc = RedshiftParticleCollection(z, dm, gas) @test rpc != pc && pc != rpc end @testset "AbstractParticleCollection" begin pc = ParticleCollection(dm, gas) @test CP.get_particles(pc) === pc.particles @test getproperty(pc, :dm) === pc.particles[:dm] @test getproperty(pc, :particles) === pc.particles @test pc.dm === pc.particles[:dm] @test pc[:dm] === pc.particles[:dm] @test_throws ErrorException( "setfield!: immutable struct of type ParticleCollection cannot be changed", ) pc.particles = Dict{Symbol,Particles}() pc.dm = gas @test pc[:dm] === gas pc[:dm] = dm @test pc.dm === dm @test pc.all == AllParticles(pc) @test_throws ErrorException pc.all = dm @test_throws KeyError pc[:all] @test keys(pc) == keys(pc.particles) @test haskey(pc, :dm) @test !haskey(pc, :stars) @test !haskey(pc, :particles) @test values(pc) == values(pc.particles) @test issetequal(propertynames(pc), [:all, :dm, :gas]) pcc = deepcopy(pc) empty!(pcc) @test isempty(pcc.particles) @test isempty(pcc) @test !isempty(pc) copy!(pcc, pc) @test pcc !== pc && pcc == pc && !isempty(pcc) io = IOBuffer() CP.show_properties(io, "text/plain", pc) @test String(take!(io)) == "dm: 100 Particles\n id pos\ngas: 100 Particles\n id pos" end end @testset "Utils" begin @testset "Index particles" begin p = Particles(:dm) p.id = sample(1:1000, 100; replace=false) p.pos = rand(3, 100) p.mass = 4u"kg" mask = rand(100) .> 0.5 ind = findall(mask) @test CP._applyind(3, mask) == 3 @test CP._applyind(p.mass, mask) == p.mass @test CP._applyind(p.id, mask) == p.id[mask] @test CP._applyind(p.pos, mask) == p.pos[:, mask] @test CP._applyind(3, ind) == 3 @test CP._applyind(p.mass, ind) == p.mass @test CP._applyind(p.id, ind) == p.id[ind] @test CP._applyind(p.pos, ind) == p.pos[:, ind] a = rand(45) b = rand(55) c = ApplyArray(vcat, a, b) @test CP._applyind(c, mask) == Array(c)[mask] @test CP._applyind(c, ind) == Array(c)[ind] a = rand(3, 45) b = rand(3, 55) c = ApplyArray(hcat, a, b) @test CP._applyind(c, mask) == Array(c)[:, mask] @test CP._applyind(c, ind) == Array(c)[:, ind] pc = CP.applyind(p, mask) @test pc.id == p.id[mask] @test pc.pos == p.pos[:, mask] @test pc.mass == p.mass @test CP.applyind(p, ind) == pc @test p[ind] == pc @test p[mask] == pc pcc = deepcopy(p) CP.applyind!(pcc, mask) @test pcc == pc pcc = deepcopy(p) CP.applyind!(pcc, ind) @test pcc == pc pc = CP.applyind(p, mask; affect=[:pos, :mass, :foo]) @test !haskey(pc, :id) @test !haskey(pc, :foo) @test pc.pos == p.pos[:, mask] @test pc.mass == p.mass pc = ParticleCollection(p) ap = pc.all @test_throws ErrorException CP.applyind(ap, ind) @test_throws ErrorException CP.applyind!(ap, ind) @test_throws ErrorException CP.applyind(ap, mask) @test_throws ErrorException CP.applyind!(ap, mask) end @testset "Remove particles" begin p = Particles(:dm) p.id = sample(1:1000, 100; replace=false) p.pos = rand(3, 100) p.mass = 4u"kg" mask = rand(100) .> 0.5 ind = findall(mask) @test CP._removeind(3, ind) == 3 @test CP._removeind(p.mass, ind) == p.mass @test CP._removeind(p.id, ind) == deleteat!(copy(p.id), ind) posremoved = CP._removeind(p.pos, ind) @test posremoved[1, :] == deleteat!(p.pos[1, :], ind) @test posremoved[2, :] == deleteat!(p.pos[2, :], ind) @test posremoved[3, :] == deleteat!(p.pos[3, :], ind) a = rand(45) b = rand(55) c = ApplyArray(vcat, a, b) @test CP._removeind(c, ind) == deleteat!(Array(c), ind) a = rand(3, 45) b = rand(3, 55) c = ApplyArray(hcat, a, b) cremoved = CP._removeind(c, ind) carray = Array(c) @test cremoved[1, :] == deleteat!(carray[1, :], ind) @test cremoved[2, :] == deleteat!(carray[2, :], ind) @test cremoved[3, :] == deleteat!(carray[3, :], ind) pc = CP.applyind(p, .~mask) @test CP.removeind(p, ind) == pc pcc = deepcopy(p) CP.removeind!(pcc, ind) @test pcc == pc affect = [:pos, :mass, :foo] pc = CP.removeind(p, ind; affect) @test pc == CP.applyind(p, .~mask; affect) @test CP.deleteat(p, ind) == CP.removeind(p, ind) pc = deepcopy(p) @test CP.deleteat!(pc, ind) == CP.removeind(p, ind) pc = ParticleCollection(p) ap = pc.all @test_throws Exception CP.removeind(ap, ind) @test_throws Exception CP.removeind!(ap, ind) end @testset "Find all in" begin a = sample(1:10000, 6000; replace=false) set = sample(1:10000, 100; replace=false) inboth = intersect(a, set) ind = CP.findall_in(a, set) @test length(ind) == length(inboth) @test issetequal(a[ind], inboth) @test CP.findall_in(a, Set(set)) == ind sort!(a) sort!(set) ind = CP.findall_in(a, set) @test length(ind) == length(inboth) @test issetequal(a[ind], inboth) @test CP.findall_in(a, Set(set)) == ind @test CP.findall_in_sorted(a, set) == ind alarge = collect(1:1_200_000) alarge2 = collect(200_000:1_600_000) setlarge = sample(1:1_200_000, 100_000; replace=false) |> sort! inboth = intersect(alarge, setlarge) inboth2 = intersect(alarge2, setlarge) ind = CP.findall_in(alarge, setlarge) @test length(ind) == length(inboth) @test issetequal(alarge[ind], inboth) @test CP.findall_in(alarge, Set(setlarge)) == ind ind = CP.findall_in(alarge2, setlarge) @test length(ind) == length(inboth2) @test issetequal(alarge2[ind], inboth2) @test CP.findall_in(alarge2, Set(setlarge)) == ind # test empty arrays @test CP.findall_in_sorted([], []) |> isempty @test CP.findall_in_sorted(a, []) |> isempty @test CP.findall_in_sorted([], set) |> isempty @test CP.findall_in([], Set([])) |> isempty @test CP.findall_in(a, Set([])) |> isempty @test CP.findall_in([], Set(set)) |> isempty end @testset "Unitful operations" begin a = rand(100) au = a * u"m" af = convert(Vector{Float32}, a) afu = af * u"m" b = rand() @test CP.product_preserve_type(a, b) == a .* b @test CP.product_preserve_type(au, b) == au .* b @test CP.product_preserve_type(af, b) == af .* convert(Float32, b) @test CP.product_preserve_type(afu, b) == afu .* convert(Float32, b) ac = copy(a) CP.product_preserve_type!(ac, b) @test ac == a .* b auc = copy(au) CP.product_preserve_type!(auc, b) @test auc == au .* b afc = copy(af) CP.product_preserve_type!(afc, b) @test afc == af .* convert(Float32, b) afuc = copy(afu) CP.product_preserve_type!(afuc, b) @test afuc == afu .* convert(Float32, b) end @testset "Lazy ustrip" begin @test CP.ustrip_lazy(3) == 3 a = rand(4) b = rand(3) au = a * u"m" bu = b * u"m" @test CP.ustrip_lazy(a) === a @test CP.ustrip_lazy(au) == a @test CP.ustrip_lazy(Diagonal(au)) == Diagonal(a) @test CP.ustrip_lazy(Bidiagonal(au, bu, :U)) == Bidiagonal(a, b, :U) @test CP.ustrip_lazy(Tridiagonal(bu, au, bu)) == Tridiagonal(b, a, b) @test CP.ustrip_lazy(SymTridiagonal(au, bu)) == SymTridiagonal(a, b) auview = @view au[1:3] @test CP.ustrip_lazy(auview) == a[1:3] c = vcat(a, b) cu = ApplyArray(vcat, au, bu) @test CP.ustrip_lazy(cu) == c c = fill(2.5, 4) cu = Fill(2.5u"m", 4) @test CP.ustrip_lazy(cu) == c auf = rand(Float32, 4) * u"m" au_strip = CP.ustrip_lazy(u"km", au) auf_strip = CP.ustrip_lazy(u"km", auf) @test au_strip ≈ ustrip(au ./ 1000) @test eltype(au_strip) === Float64 @test auf_strip ≈ ustrip(auf ./ 1000) @test eltype(auf_strip) === Float32 auc = copy(au) aufc = copy(auf) auc_strip = CP.ustrip_lazy!(u"km", auc) aufc_strip = CP.ustrip_lazy!(u"km", aufc) @test auc_strip == au_strip @test aufc_strip == auf_strip @test CP.ustrip_lazy(auc) == au_strip @test CP.ustrip_lazy(aufc) == auf_strip auc = copy(au) aufc = copy(auf) auc_conv = CP.uconvert_lazy!(u"km", auc) aufc_conv = CP.uconvert_lazy!(u"km", aufc) @test auc_conv ≈ uconvert.(u"km", au) @test aufc_conv ≈ uconvert.(u"km", auf) @test CP.ustrip_lazy(auc) == CP.ustrip_lazy(auc_conv) @test CP.ustrip_lazy(aufc) == CP.ustrip_lazy(aufc_conv) auc = copy(au) aufc = copy(auf) auc_conv = CP.uconvert_lazy!(u"m", auc) aufc_conv = CP.uconvert_lazy!(u"m", aufc) @test auc_conv ≈ uconvert.(u"m", au) @test aufc_conv ≈ uconvert.(u"m", auf) @test CP.ustrip_lazy(auc) == CP.ustrip_lazy(auc_conv) @test CP.ustrip_lazy(aufc) == CP.ustrip_lazy(aufc_conv) au = rand(4) * u"°C" auf = rand(Float32, 4) * u"°C" auc = copy(au) aufc = copy(auf) auc_conv = CP.uconvert_lazy!(u"K", auc) aufc_conv = CP.uconvert_lazy!(u"K", aufc) @test auc_conv ≈ uconvert.(u"K", au) @test aufc_conv ≈ uconvert.(u"K", auf) @test CP.ustrip_lazy(auc) == CP.ustrip_lazy(auc_conv) @test CP.ustrip_lazy(aufc) == CP.ustrip_lazy(aufc_conv) end end @testset "Transformations" begin @testset "Rotation" begin rotmat = rand(RotMatrix{3}) a = rand(3, 100) au = a * u"m" arot = rotmat * a aurot = rotmat * au @test CP.matrix_rotate(a, rotmat) == arot @test CP.matrix_rotate(au, rotmat) == aurot ac = copy(a) CP.matrix_rotate!(ac, rotmat) @test ac == arot auc = copy(au) CP.matrix_rotate!(auc, rotmat) @test auc == aurot ac = similar(a) CP.matrix_rotate!(ac, a, rotmat) @test ac == arot auc = similar(au) CP.matrix_rotate!(auc, au, rotmat) @test auc == aurot @testset "Particle Rotation" begin p = Particles(:dm) p.pos = copy(au) p.vel = copy(a) pc = rotate(p, rotmat, :pos) @test p.pos == au @test pc.pos == aurot @test p.vel === pc.vel == a pc = rotate(p, rotmat) @test p.pos == au @test pc.pos == aurot @test p.vel == a @test pc.vel == arot pc = deepcopy(p) rotate!(pc, rotmat, :vel) @test pc.pos == au @test pc.vel == arot pc = deepcopy(p) rotate!(pc, rotmat) @test pc.pos == aurot @test pc.vel == arot end @testset "Particle Collection Rotation" begin dm = Particles(:dm) dm.pos = copy(au) dm.vel = copy(a) gas = Particles(:gas) gas.pos = copy(au) gas.vel = copy(a) pc = ParticleCollection(dm, gas) pcc = rotate(pc, rotmat, :pos) @test pc.dm.pos == pc.gas.pos == au @test pcc.dm.pos == pcc.gas.pos == aurot @test pc.dm.vel === pcc.dm.vel == a pcc = rotate(pc, rotmat) @test pc.dm.pos == pc.gas.pos == au @test pcc.dm.pos == pcc.gas.pos == aurot @test pc.dm.vel == pc.gas.vel == a @test pcc.dm.vel == pcc.gas.vel == arot pcc = deepcopy(pc) rotate!(pcc, rotmat, :vel) @test pcc.dm.pos == pcc.gas.pos == au @test pcc.dm.vel == pcc.gas.vel == arot pcc = deepcopy(pc) rotate!(pcc, rotmat) @test pcc.dm.pos == pcc.gas.pos == aurot @test pcc.dm.vel == pcc.gas.vel == arot pccc = deepcopy(pc) ap = pccc.all @test_throws ErrorException rotate(ap, rotmat) rotate!(ap, rotmat) @test pccc == pcc end end @testset "Translations" begin da = rand(3) dau = rand(3) * u"m" a = rand(3, 100) au = a * u"m" atrans = a .+ da autrans = au .+ dau @testset "Particle Translations" begin p = Particles(:dm) p.pos = copy(au) p.vel = copy(a) pc = translate(p, dau) @test p.pos == au @test pc.pos == autrans @test p.vel === pc.vel == a pc = translate(p, da, :vel) @test p.pos === pc.pos == au @test p.vel == a @test pc.vel == atrans pc = deepcopy(p) translate!(pc, dau) @test pc.pos == autrans @test pc.vel == a pc = deepcopy(p) translate!(pc, da, :vel) @test pc.pos == au @test pc.vel == atrans # periodic translations period, period_half = 10, 5 CP._translate_periodic(1, 2, period) == 1 CP._translate_periodic(8, 2, period, period_half) == -2 CP._translate_periodic(2, 8, period, period_half) == 12 o = oneunit(eltype(dau)) pc = translate_periodic(p, dau, o) @test all(dau .- 0.5o .≤ minimum(pc.pos; dims=2)) && all(maximum(pc.pos; dims=2) .≤ dau .+ 0.5o) pc = deepcopy(p) translate_periodic!(pc, dau, o) @test all(dau .- 0.5o .≤ minimum(pc.pos; dims=2)) && all(maximum(pc.pos; dims=2) .≤ dau .+ 0.5o) pcc = translate_periodic_to_center(p, dau, o) @test pcc == translate(pc, -dau) pcc = deepcopy(p) translate_periodic_to_center!(pcc, dau, o) @test pcc == translate(pc, -dau) end @testset "Particle Collection Translations" begin dm = Particles(:dm) dm.pos = copy(au) dm.vel = copy(a) gas = Particles(:gas) gas.pos = copy(au) gas.vel = copy(a) pc = ParticleCollection(dm, gas) pcc = translate(pc, dau) @test pc.dm.pos == pc.gas.pos == au @test pcc.dm.pos == pcc.gas.pos == autrans @test pc.dm.vel === pcc.dm.vel == a pcc = translate(pc, da, :vel) @test pc.dm.pos === pcc.dm.pos == au @test pc.dm.vel == pc.gas.vel == a @test pcc.dm.vel == pcc.gas.vel == atrans pcc = deepcopy(pc) translate!(pcc, dau) @test pcc.dm.pos == pcc.gas.pos == autrans @test pcc.dm.vel == pcc.gas.vel == a pcc = deepcopy(pc) translate!(pcc, da, :vel) @test pcc.dm.pos == pcc.gas.pos == au @test pcc.dm.vel == pcc.dm.vel == atrans pccc = deepcopy(pc) ap = pccc.all @test_throws ErrorException translate(ap, da) translate!(ap, dau) @test pccc == translate(pc, dau) pccc = deepcopy(pc) ap = pccc.all translate!(ap, da, :vel) @test pccc == pcc o = oneunit(eltype(dau)) pcc = translate_periodic(pc, dau, o) @test pcc.dm == translate_periodic(pc.dm, dau, o) @test pcc.gas == translate_periodic(pc.gas, dau, o) pccc = deepcopy(pc) translate_periodic!(pccc, dau, o) @test pccc == pcc pcc = translate_periodic_to_center(pc, dau, o) @test pcc.dm == translate_periodic_to_center(pc.dm, dau, o) @test pcc.gas == translate_periodic_to_center(pc.gas, dau, o) pccc = deepcopy(pc) translate_periodic_to_center!(pccc, dau, o) @test pccc == pcc end end @testset "Comoving" begin z = 1.5 a = rand(Float32, 3, 100) au = a * u"m" n = rand(Float32, 100) nu = n * u"m^-3" m = copy(n) propexp = [(:pos, 1), (:vel, 1), (:n, -3)] acom = a .* (1 + z) aucom = au .* (1 + z) ncom = n .* (1 + z)^-3 nucom = nu .* (1 + z)^-3 aphys = a ./ (1 + z) auphys = au ./ (1 + z) nphys = n ./ (1 + z)^-3 nuphys = nu ./ (1 + z)^-3 @testset "Particle Comoving" begin p = Particles(:dm) p.pos = a p.n = n p.mass = m @test a .* CP.factor_to_comoving(z, 1) ≈ acom @test n .* CP.factor_to_comoving(z, -3) ≈ ncom @test a .* CP.factor_to_physical(z, 1) ≈ aphys @test n .* CP.factor_to_physical(z, -3) ≈ nphys pc = to_comoving(p, z; propexp) @test pc.pos ≈ acom @test pc.n ≈ ncom @test pc.mass ≈ m pcc = deepcopy(p) to_comoving!(pcc, z; propexp) @test pcc == pc pc = to_physical(p, z; propexp) @test pc.pos ≈ aphys @test pc.n ≈ nphys @test pc.mass ≈ m pcc = deepcopy(p) to_physical!(pcc, z; propexp) @test pcc == pc p = Particles(:dm) p.pos = au p.n = nu p.mass = m pc = to_comoving(p, z; propexp) @test pc.pos ≈ aucom @test pc.n ≈ nucom @test pc.mass ≈ m pcc = deepcopy(p) to_comoving!(pcc, z; propexp) @test pcc == pc pc = to_physical(p, z; propexp) @test pc.pos ≈ auphys @test pc.n ≈ nuphys @test pc.mass ≈ m pcc = deepcopy(p) to_physical!(pcc, z; propexp) @test pcc == pc end @testset "Particle Collection Comoving" begin dm = Particles(:dm) dm.pos = copy(au) dm.n = copy(n) dm.mass = copy(m) gas = Particles(:gas) gas.pos = copy(a) gas.n = copy(nu) gas.mass = copy(m) pc = RedshiftParticleCollection(z, dm, gas) pcc = to_comoving(pc; propexp) @test pcc.dm == to_comoving(dm, z; propexp) @test pcc.gas == to_comoving(gas, z; propexp) pccc = deepcopy(pc) to_comoving!(pccc; propexp) @test pccc == pcc pcc = to_physical(pc; propexp) @test pcc.dm == to_physical(dm, z; propexp) @test pcc.gas == to_physical(gas, z; propexp) pccc = deepcopy(pc) to_physical!(pccc; propexp) @test pccc == pcc pccc = deepcopy(pc) ap = pccc.all @test_throws ErrorException to_comoving(ap, z; propexp) @test_throws ErrorException to_physical(ap, z; propexp) to_comoving!(ap, z; propexp) @test pccc == to_comoving(pc; propexp) pccc = deepcopy(pc) ap = pccc.all to_physical!(ap, z; propexp) @test pccc == to_physical(pc; propexp) end end end @testset "Misc Operations" begin ids = sample(1:1000, 100; replace=false) a = rand(3, 100) bu = rand(100) * u"kg" p = Particles(:dm) p.id = ids p.pos = copy(a) p.mass = copy(bu) @testset "Particle Sorting" begin pc = sort(p, :id) @test issorted(pc.id) @test p.id == ids ind = searchsortedfirst(pc.id, p.id[1]) @test pc.pos[:, ind] == p.pos[:, 1] @test pc.mass[ind] == p.mass[1] pc = sort(p, :mass; affect=[:mass, :pos], alg=RadixSort) @test issorted(pc.mass) @test haskey(pc, :pos) @test !haskey(pc, :id) pc = sort(p, :mass; affect=[:pos], alg=RadixSort) @test !haskey(pc, :mass) pc = deepcopy(p) sort!(pc, :id; alg=RadixSort) @test issorted(pc.id) ind = searchsortedfirst(pc.id, p.id[1]) @test pc.pos[:, ind] == p.pos[:, 1] @test pc.mass[ind] == p.mass[1] end @testset "Particle Collection Sorting" begin dm = p gas = Particles(:gas, deepcopy(p.props)) pc = ParticleCollection(dm, gas) pcc = sort(pc, :id) @test pc != pcc @test pcc.dm == sort(dm, :id) @test pcc.gas == sort(gas, :id) affect = [:mass, :pos] pcc = sort(pc, :mass; affect, alg=RadixSort) @test pcc.dm == sort(dm, :mass; affect) @test pcc.gas == sort(gas, :mass; affect) affect = [(:dm, [:mass, :pos]), (:gas, [:mass])] pcc = sort(pc, :mass; affect, alg=QuickSort) @test pcc.dm == sort(dm, :mass; affect=[:mass, :pos]) @test pcc.gas == sort(gas, :mass; affect=[:mass]) pcc = deepcopy(pc) sort!(pcc, :id; alg=RadixSort) @test pcc == sort(pc, :id) ap = pc.all @test_throws ErrorException sort(ap, :id; affect) @test_throws ErrorException sort!(ap, :id; alg=RadixSort) end @testset "Particle Filtering" begin massmin = 0.5u"kg" pc = filter(p -> p.mass .> massmin, p) @test all(pc.mass .> massmin) @test p.mass == bu ind = findfirst(>(massmin), p.mass) @test pc.pos[:, 1] == p.pos[:, ind] @test pc.id[1] == p.id[ind] @test filter(p -> findall(p.mass .> massmin), p) == pc pc = filter(p -> p.mass .> massmin, p; affect=[:id, :mass]) @test all(pc.mass .> massmin) @test haskey(pc, :id) @test !haskey(pc, :pos) pc = deepcopy(p) filter!(p -> p.mass .> massmin, pc) @test all(pc.mass .> massmin) @test p.mass == bu ind = findfirst(>(massmin), p.mass) @test pc.pos[:, 1] == p.pos[:, ind] @test pc.id[1] == p.id[ind] ids_wanted = sample(1:1000, 100; replace=false) pc = filter(p; ids=ids_wanted) @test all(in.(pc.id, (ids_wanted,))) @test !any(in.(setdiff(ids, pc.id), (ids_wanted,))) ind = findfirst(in(ids_wanted), p.id) @test pc.pos[:, 1] == p.pos[:, ind] @test pc.mass[1] == p.mass[ind] @test filter(p; ids=Set(ids_wanted)) == pc pc = filter(p; ids=ids_wanted, affect=[:id, :mass]) @test all(in.(pc.id, (ids_wanted,))) @test !any(in.(setdiff(ids, pc.id), (ids_wanted,))) @test haskey(pc, :mass) @test !haskey(pc, :pos) pc = deepcopy(p) filter!(pc; ids=ids_wanted) @test all(in.(pc.id, (ids_wanted,))) @test !any(in.(setdiff(ids, pc.id), (ids_wanted,))) ind = findfirst(in(ids_wanted), p.id) @test pc.pos[:, 1] == p.pos[:, ind] @test pc.mass[1] == p.mass[ind] @test filter!(deepcopy(p); ids=Set(ids_wanted)) == pc end @testset "Particle Collection Filtering" begin dm = p gas = Particles(:gas, deepcopy(p.props)) pc = ParticleCollection(dm, gas) massmin = 0.5u"kg" f = p -> p.mass .> massmin pcc = filter(f, pc) @test pcc.dm == filter(f, dm) @test filter(p -> findall(p.mass .> massmin), pc) == pcc affect = [:id, :mass] pcc = filter(f, pc; affect) @test pcc.dm == filter(f, dm; affect) affect = [(:dm, [:id, :mass])] pcc = filter(f, pc; affect) @test pcc.dm == filter(f, dm; affect=[:id, :mass]) @test !haskey(pcc, :gas) pcc = deepcopy(pc) filter!(f, pcc) @test pcc == filter(f, pc) ids_wanted = sample(1:1000, 100; replace=false) pcc = filter(pc; ids=ids_wanted) @test pcc.dm == filter(dm; ids=ids_wanted) @test filter(pc; ids=Set(ids_wanted)) == pcc affect = [:id, :mass] pcc = filter(pc; ids=ids_wanted, affect) @test pcc.dm == filter(dm; ids=ids_wanted, affect) affect = [(:gas, [:id])] pcc = filter(pc; ids=ids_wanted, affect) @test !haskey(pcc, :dm) @test pcc.gas == filter(gas; ids=ids_wanted, affect=[:id]) pcc = deepcopy(pc) filter!(pcc; ids=ids_wanted) @test pcc == filter(pcc; ids=ids_wanted) @test filter!(deepcopy(pc); ids=Set(ids_wanted)) == pcc ap = pc.all @test_throws ErrorException filter(f, ap; affect) @test_throws ErrorException filter!(f, ap) @test_throws ErrorException filter(ap; ids=ids_wanted) @test_throws ErrorException filter!(ap; ids=ids_wanted) end @testset "Particle Removing" begin ids_remove = sample(1:1000, 100; replace=false) ids_keep = setdiff(1:1000, ids_remove) pc_check = filter(p; ids=ids_keep) @test delete(p; ids=ids_remove) == pc_check @test delete(p; ids=Set(ids_remove)) == pc_check pc = delete(p; ids=ids_remove, affect=[:id, :mass]) @test pc == filter(p; ids=ids_keep, affect=[:id, :mass]) pc = deepcopy(p) delete!(pc; ids=ids_remove) @test pc == pc_check @test delete!(deepcopy(p); ids=Set(ids_remove)) == pc_check end @testset "Particle Collection Removing" begin dm = p gas = Particles(:gas, deepcopy(p.props)) pc = ParticleCollection(dm, gas) ids_remove = sample(1:1000, 100; replace=false) pcc = delete(pc; ids=ids_remove) @test pcc.dm == delete(dm; ids=ids_remove) @test delete(pc; ids=Set(ids_remove)) == pcc affect = [:id, :mass] pcc = delete(pc; ids=ids_remove, affect) @test pcc.dm == delete(dm; ids=ids_remove, affect) affect = [(:gas, [:id])] pcc = delete(pc; ids=ids_remove, affect) @test !haskey(pcc, :dm) @test pcc.gas == delete(gas; ids=ids_remove, affect=[:id]) pcc = deepcopy(pc) delete!(pcc; ids=ids_remove) @test pcc == delete(pcc; ids=ids_remove) @test delete!(deepcopy(pc); ids=Set(ids_remove)) == pcc ap = pc.all @test_throws Exception delete(ap; ids=ids_remove) @test_throws Exception delete!(ap; ids=ids_remove) end end @testset "Geometry" begin # create square/cube/hypercube of positions between 0 and 1 pos2 = reshape(Iterators.product(0:0.1:1, 0:0.1:1) |> collect, :) pos2 = reduce(hcat, getindex.(pos2, i) for i in eachindex(pos2[1]))' pos3 = reshape(Iterators.product(0:0.1:1, 0:0.1:1, 0:0.1:1) |> collect, :) pos3 = reduce(hcat, getindex.(pos3, i) for i in eachindex(pos3[1]))' pos4 = reshape(Iterators.product(0:0.1:1, 0:0.1:1, 0:0.1:1, 0:0.1:1) |> collect, :) pos4 = reduce(hcat, getindex.(pos4, i) for i in eachindex(pos4[1]))' @testset "Hyperrectangle" begin hrect = CosmoHyperrectangle(0.5rand(4), 0.5(1 .+ rand(4))) @test hrect isa CosmoHyperrectangle{Float64,4} hrect = CosmoHyperrectangle([0, 0, 0] .// 100, [15, 25, 20] .// 100) @test hrect isa CosmoHyperrectangle{Float64,3} @test hrect isa CosmoCuboid{Float64} # construct hyperrectangles from center and side lengths @test CosmoHyperrectangle([75, 125, 100] .// 1000, ([15, 25, 20] .// 100)...) == hrect @test CosmoCuboid([75, 125, 100] .// 1000, ([15, 25, 20] .// 100)...) == hrect @test CosmoRectangle([75, 125] .// 1000, ([15, 25] .// 100)...) == CosmoRectangle([0, 0] .// 100, [15, 25] .// 100) # test constructors @test CosmoHyperrectangle([0, 0, 0], [0.15, 0.25, 0.20]) isa CosmoCuboid{Float64} @test CosmoHyperrectangle{Float64,3}([0, 0, 0.0], [0.15, 0.25, 0.20]) isa CosmoCuboid{Float64} @test CosmoHyperrectangle{Float64,3}([0, 0, 0], [0.15, 0.25, 1 // 10]) isa CosmoCuboid{Float64} @test_throws AssertionError CosmoHyperrectangle{Float64,4}([0, 0, 0.0], [0.15, 0.25, 0.20]) @test CosmoCuboid([0, 0, 0], [0.15, 0.25, 0.20]) isa CosmoCuboid{Float64} @test_throws AssertionError CosmoCuboid([0, 0], [0.15, 0.25]) @test CosmoRectangle([0, 0], [0.25, 0.20]) isa CosmoRectangle{Float64} @test_throws AssertionError CosmoRectangle([0, 0, 0], [0.15, 0.25, 0.20]) @test_throws AssertionError CosmoRectangle([0, 0], [0.15, 0.25, 0.20]) @test CosmoCuboid{Float64}([0, 0, 0.0], [0.15, 0.25, 0.20]) isa CosmoCuboid{Float64} @test CosmoCuboid{Float32}([0, 0, 0], [0.15, 0.25, 1 // 10]) isa CosmoCuboid{Float32} @test CosmoRectangle{Float64}([0, 0.0], [0.25, 0.20]) isa CosmoRectangle{Float64} @test CosmoRectangle{Float64}([0, 0], [0.25, 0.20]) isa CosmoRectangle{Float64} @test CosmoHyperrectangle([0, 0], 0.15, 0.25) isa CosmoRectangle{Float64} @test CosmoHyperrectangle([0, 0, 0], 0.15, 0.25, 0.20) isa CosmoCuboid{Float64} @test CosmoHyperrectangle([0, 0, 0, 0], 0.15, 0.25, 0.20, 0.54) isa CosmoHyperrectangle{Float64,4} @test_throws Exception CosmoHyperrectangle([0, 0], 0.15, 0.25, 0.54) r = 5 // 2 @test CosmoHypercube([0, 0, 0, 0], r) == CosmoHyperrectangle([-r, -r, -r, -r], [r, r, r, r]) @test CosmoCube([0, 0, 0], r) == CosmoCuboid([-r, -r, -r], [r, r, r]) @test CosmoSquare([0, 0], r) == CosmoRectangle([-r, -r], [r, r]) cuboid = CosmoCuboid([0, 0, 0] .// 100, [15, 25, 19] .// 100) @test CP.geometry_enclosing_center(cuboid) ≈ [15, 25, 19] .// 200 |> float @test CP.geometry_enclosing_center(CosmoCube(zeros(Int, 3), 4 // 1)) == zeros(3) @test all(CP.geometry_enclosing_corners(cuboid) .≈ (zeros(3), [15, 25, 19] .// 100 |> float)) pos3in = pos3[:, CP.mask_in(pos3, cuboid)] @test all(0 .≤ pos3in[1, :] .≤ 0.15) && all(0 .≤ pos3in[2, :] .≤ 0.25) && all(0 .≤ pos3in[3, :] .≤ 0.19) rect = CosmoRectangle([0, 0] .// 100, [25, 19] .// 100) pos2in = pos2[:, CP.mask_in(pos2, rect)] @test all(0 .≤ pos2in[1, :] .≤ 0.25) && all(0 .≤ pos2in[2, :] .≤ 0.19) hrect = CosmoHyperrectangle([0, 0, 0, 0] .// 100, [15, 25, 19, 35] .// 100) pos4in = pos4[:, CP.mask_in(pos4, hrect)] @test all(0 .≤ pos4in[1, :] .≤ 0.15) && all(0 .≤ pos4in[2, :] .≤ 0.25) && all(0 .≤ pos4in[3, :] .≤ 0.19) && all(0 .≤ pos4in[4, :] .≤ 0.35) @test_throws AssertionError CP.mask_in(pos3, hrect) end @testset "Hypersphere" begin hsphere = CosmoHypersphere(0.5rand(4), 0.5) @test hsphere isa CosmoHypersphere{Float64,4} hsphere = CosmoHypersphere([0, 0, 0] .// 100, 15 // 100) @test hsphere isa CosmoHypersphere{Float64,3} @test hsphere isa CosmoSphere{Float64} @test hsphere == CosmoHypersphere([0, 0, 0], 15 // 100) # test constructors @test CosmoHypersphere([0.15, 0.25, 0.20], 2) isa CosmoSphere{Float64} @test CosmoHypersphere{Float64,3}([0.15, 0.25, 0.20], 0.2) isa CosmoSphere{Float64} @test CosmoHypersphere{Float32,3}([0.15, 0.25, 0.20], 0.2) isa CosmoSphere{Float32} @test_throws AssertionError CosmoHypersphere{Float64,4}([0.15, 0.25, 0.20], 0.2) @test CosmoSphere([0.15, 0.25, 0.20], 0.2) isa CosmoSphere{Float64} @test_throws AssertionError CosmoSphere([0.15, 0.25], 0.3) @test CosmoCircle([0.25, 0.20], 0.2) isa CosmoCircle{Float64} @test_throws AssertionError CosmoCircle([0.15, 0.25, 0.20], 0.2) @test CosmoSphere{Float64}([0.15, 0.25, 0.20], 0.2) isa CosmoSphere{Float64} @test CosmoSphere{Float32}([0.15, 0.25, 0.20], 1) isa CosmoSphere{Float32} @test CosmoCircle{Float64}([0.25, 0.20], 0.2) isa CosmoCircle{Float64} r = 12 // 100 center = [10, 20, 30] .// 100 sphere = CosmoSphere(center, r) @test CP.geometry_enclosing_center(sphere) ≈ center |> float @test all( CP.geometry_enclosing_corners(sphere) .≈ ([-2, 8, 18] .// 100 |> float, [22, 32, 42] .// 100 |> float), ) pos3in = pos3[:, CP.mask_in(pos3, sphere)] @test all(sum(abs2, pos3in .- center; dims=1) .≤ r^2) pos3notin = pos3[:, .~CP.mask_in(pos3, sphere)] @test all(sum(abs2, pos3notin .- center; dims=1) .> r^2) center = [20, 30] .// 100 circle = CosmoCircle(center, r) pos2in = pos2[:, CP.mask_in(pos2, circle)] @test all(sum(abs2, pos2in .- center; dims=1) .≤ r^2) center = [10, 20, 30, 40] .// 100 hsphere = CosmoHypersphere(center, r) pos4in = pos4[:, CP.mask_in(pos4, hsphere)] @test all(sum(abs2, pos4in .- center; dims=1) .≤ r^2) sphere = CosmoSphere(zeros(3), r) @test CosmoSphere(r) == sphere pos3in = pos3[:, CP.mask_in(pos3, sphere)] @test all(sum(abs2, pos3in; dims=1) .≤ r^2) circle = CosmoCircle(zeros(2), r) @test CosmoCircle(r) == circle pos2in = pos2[:, CP.mask_in(pos2, circle)] @test all(sum(abs2, pos2in; dims=1) .≤ r^2) hsphere = CosmoHypersphere(zeros(4), r) @test CosmoHypersphere(4, r) == hsphere pos4in = pos4[:, CP.mask_in(pos4, hsphere)] @test all(sum(abs2, pos4in; dims=1) .≤ r^2) @test_throws AssertionError CP.mask_in(pos3, hsphere) end @testset "Cylinder" begin scyl = CosmoStandingCylinder(0.5rand(3), 0.5, 0.5) @test scyl isa CosmoStandingCylinder{Float64} scyl = CosmoStandingCylinder([1, 2, 3] .// 10, 2 // 10, 1 // 10) @test scyl isa CosmoStandingCylinder{Float64} @test CosmoStandingCylinder(rand(3), 1, 1 // 10) isa CosmoStandingCylinder{Float64} @test CosmoStandingCylinder{Float32}(rand(3), 1, 1 // 10) isa CosmoStandingCylinder{Float32} @test_throws AssertionError CosmoStandingCylinder(rand(4), 1, 1 // 10) center = [1, 2, 3] .// 10 h = 24 // 100 r = 15 // 100 scyl = CosmoStandingCylinder(center, h, r) @test CP.geometry_enclosing_center(scyl) ≈ center |> float @test all( CP.geometry_enclosing_corners(scyl) .≈ ([-5, 5, 18] .// 100 |> float, [25, 35, 42] .// 100 |> float), ) pos3in = pos3[:, CP.mask_in(pos3, scyl)] @test @views all(sum(abs2, pos3in[1:2, :] .- center[1:2]; dims=1) .≤ r^2) @test @views all(18 // 100 .≤ pos3in[3, :] .≤ 42 // 100) pos3notin = pos3[:, .~CP.mask_in(pos3, scyl)] @test @views all( vec(sum(abs2, pos3notin[1:2, :] .- center[1:2]; dims=1) .> r^2) .| (18 // 100 .> pos3notin[3, :]) .| (pos3notin[3, :] .> 42 // 100), ) @test_throws AssertionError CP.mask_in(pos2, scyl) cyl = CosmoCylinder(0.5rand(3), 0.5rand(3), 0.5) @test cyl isa CosmoCylinder{Float64} cyl = CosmoCylinder([1, 2, 3] .// 10, [2, 3, 4] .// 10, 1 // 10) @test cyl isa CosmoCylinder{Float64} @test CosmoCylinder(rand(3), rand(3), 1 // 10) isa CosmoCylinder{Float64} @test CosmoCylinder(rand(3), [0, 0, 0], 1 // 10) isa CosmoCylinder{Float64} @test CosmoCylinder{Float32}(rand(3), [0, 0, 0], 1 // 10) isa CosmoCylinder{Float32} @test_throws AssertionError CosmoCylinder(rand(4), rand(3), 0.1) @test_throws AssertionError CosmoCylinder(rand(3), rand(2), 0.1) center = center startpos = [10, 20, 18] .// 100 endpos = [10, 20, 42] .// 100 r = r cyl = CosmoCylinder(startpos, endpos, r) @test CP.geometry_enclosing_center(cyl) ≈ center |> float @test all(CP.geometry_enclosing_corners(cyl) .≈ ([-5, 5, 18] .// 100, [25, 35, 42] .// 100)) # right mask for standing cylinder @test scyl == cyl @test CP.mask_in(pos3, scyl) == CP.mask_in(pos3, cyl) @test_throws AssertionError CP.mask_in(pos2, cyl) @test CosmoStandingCylinder(cyl) == scyl @test CosmoCylinder(scyl) == cyl # same result switching random start and end points of the cylinder p1 = rand(3) p2 = rand(3) r = 0.15 c1 = CosmoCylinder(p1, p2, r) c2 = CosmoCylinder(p2, p1, r) @test CP.geometry_enclosing_center(c1) ≈ CP.geometry_enclosing_center(c2) @test all(CP.geometry_enclosing_corners(c1) .≈ CP.geometry_enclosing_corners(c2)) @test CP.mask_in(pos3, c1) == CP.mask_in(pos3, c2) @test_throws AssertionError CosmoStandingCylinder(c1) scyl = CosmoStandingCylinder([1, 2, 3] .// 10, 2 // 10, 1 // 10) @test scyl == CosmoStandingCylinder([1, 2, 3] .// 10, 2 // 10, 1 // 10) @test scyl ≈ CosmoCylinder([1, 2, 2] .// 10, [1, 2, 4] .// 10, 1 // 10) @test CosmoCylinder([1, 2, 2] .// 10, [1, 2, 4] .// 10, 1 // 10) ≈ scyl end @testset "Filtering" begin p = Particles(:dm) p.pos = pos3 p.mass = rand(size(pos3, 2)) pu = Particles(:dm) pu.pos = pos3 .* u"m" pu.mass = rand(size(pos3, 2)) center = rand(3) sph = CosmoSphere(center, 0.2) sphu = CosmoSphere(center * u"m", 0.2u"m") mask = CP.mask_in(pos3, sph) @test filter(p, sph) == p[mask] @test filter(pu, sphu) == pu[mask] pc = filter(p, sph; affect=[:pos]) @test pc.pos == p.pos[:, mask] @test !haskey(pc, :mass) pc = deepcopy(p) filter!(pc, sph) @test pc == p[mask] # Particle collection dm = p gas = Particles(:gas, deepcopy(p.props)) pc = ParticleCollection(dm, gas) pcc = filter(pc, sph) @test pcc.dm == dm[mask] pcc = filter(pc, sph; affect=[:pos]) @test pcc.dm == filter(dm, sph; affect=[:pos]) pcc = filter(pc, sph; affect=[(:dm, [:pos, :mass])]) @test pcc.dm == filter(dm, sph; affect=[:pos, :mass]) @test !haskey(pcc, :gas) pcc = deepcopy(pc) filter!(pcc, sph) @test pcc == filter(pc, sph) ap = pc.all @test_throws ErrorException filter(ap, sph) @test_throws ErrorException filter!(ap, sph) end end @testset "Properties" begin @testset "Norm" begin a2 = rand(2, 100) a3 = rand(3, 100) a4 = rand(4, 100) n2 = norm.(eachcol(a2)) n3 = norm.(eachcol(a3)) n4 = norm.(eachcol(a4)) @test colnorm(a2) ≈ n2 @test colnorm(a3) ≈ n3 @test colnorm(a4) ≈ n4 @test colnorm(a2 * u"m") ≈ n2 * u"m" @test colnorm(a3 * u"m") ≈ n3 * u"m" @test colnorm(a4 * u"m") ≈ n4 * u"m" @test colnorm2(a2) ≈ n2 .^ 2 @test colnorm2(a3) ≈ n3 .^ 2 @test colnorm2(a4) ≈ n4 .^ 2 @test colnorm2(a2 * u"m") ≈ (n2 * u"m") .^ 2 @test colnorm2(a3 * u"m") ≈ (n3 * u"m") .^ 2 @test colnorm2(a4 * u"m") ≈ (n4 * u"m") .^ 2 am2 = similar(a2, Union{Float64,Missing}) am3 = similar(a3, Union{Float64,Missing}) am4 = similar(a4, Union{Float64,Missing}) am2 .= a2 am3 .= a3 am4 .= a4 am2[:, 1] .= missing am3[:, 1] .= missing am4[:, 1] .= missing @test all(colnorm(am2) .≈ n2) |> ismissing @test all(colnorm(am3) .≈ n3) |> ismissing @test all(colnorm(am4) .≈ n4) |> ismissing @test all(colnorm(am2 * u"m") .≈ n2 * u"m") |> ismissing @test all(colnorm(am3 * u"m") .≈ n3 * u"m") |> ismissing @test all(colnorm(am4 * u"m") .≈ n4 * u"m") |> ismissing @test all(colnorm2(am2) .≈ n2 .^ 2) |> ismissing @test all(colnorm2(am3) .≈ n3 .^ 2) |> ismissing @test all(colnorm2(am4) .≈ n4 .^ 2) |> ismissing @test all(colnorm2(am2 * u"m") .≈ (n2 * u"m") .^ 2) |> ismissing @test all(colnorm2(am3 * u"m") .≈ (n3 * u"m") .^ 2) |> ismissing @test all(colnorm2(am4 * u"m") .≈ (n4 * u"m") .^ 2) |> ismissing end @testset "Norm around Origin" begin a2 = rand(2, 100) a3 = rand(3, 100) a4 = rand(4, 100) o2 = rand(2) o3 = rand(3) o4 = rand(4) n2 = norm.(eachcol(a2 .- o2)) n3 = norm.(eachcol(a3 .- o3)) n4 = norm.(eachcol(a4 .- o4)) @test colnorm(a2, o2) ≈ n2 @test colnorm(a3, o3) ≈ n3 @test colnorm(a4, o4) ≈ n4 @test colnorm(a2 * u"m", o2 * u"m") ≈ n2 * u"m" @test colnorm(a3 * u"m", o3 * u"m") ≈ n3 * u"m" @test colnorm(a4 * u"m", o4 * u"m") ≈ n4 * u"m" @test colnorm2(a2, o2) ≈ n2 .^ 2 @test colnorm2(a3, o3) ≈ n3 .^ 2 @test colnorm2(a4, o4) ≈ n4 .^ 2 @test colnorm2(a2 * u"m", o2 * u"m") ≈ (n2 * u"m") .^ 2 @test colnorm2(a3 * u"m", o3 * u"m") ≈ (n3 * u"m") .^ 2 @test colnorm2(a4 * u"m", o4 * u"m") ≈ (n4 * u"m") .^ 2 am2 = similar(a2, Union{Float64,Missing}) am3 = similar(a3, Union{Float64,Missing}) am4 = similar(a4, Union{Float64,Missing}) am2 .= a2 am3 .= a3 am4 .= a4 am2[:, 1] .= missing am3[:, 1] .= missing am4[:, 1] .= missing @test all(colnorm(am2, o2) .≈ n2) |> ismissing @test all(colnorm(am3, o3) .≈ n3) |> ismissing @test all(colnorm(am4, o4) .≈ n4) |> ismissing @test all(colnorm(am2 * u"m", o2 * u"m") .≈ n2 * u"m") |> ismissing @test all(colnorm(am3 * u"m", o3 * u"m") .≈ n3 * u"m") |> ismissing @test all(colnorm(am4 * u"m", o4 * u"m") .≈ n4 * u"m") |> ismissing @test all(colnorm2(am2, o2) .≈ n2 .^ 2) |> ismissing @test all(colnorm2(am3, o3) .≈ n3 .^ 2) |> ismissing @test all(colnorm2(am4, o4) .≈ n4 .^ 2) |> ismissing @test all(colnorm2(am2 * u"m", o2 * u"m") .≈ (n2 * u"m") .^ 2) |> ismissing @test all(colnorm2(am3 * u"m", o3 * u"m") .≈ (n3 * u"m") .^ 2) |> ismissing @test all(colnorm2(am4 * u"m", o4 * u"m") .≈ (n4 * u"m") .^ 2) |> ismissing end @testset "Dot Product" begin a2 = rand(2, 100) a3 = rand(3, 100) a4 = rand(4, 100) b2 = rand(2, 100) b3 = rand(3, 100) b4 = rand(4, 100) c2 = reduce(hcat, [dot(ai, bi) for (ai, bi) in zip(eachcol(a2), eachcol(b2))]) |> vec c3 = reduce(hcat, [dot(ai, bi) for (ai, bi) in zip(eachcol(a3), eachcol(b3))]) |> vec c4 = reduce(hcat, [dot(ai, bi) for (ai, bi) in zip(eachcol(a4), eachcol(b4))]) |> vec for (a, b, c) in zip([a2, a3, a4], [b2, b3, b4], [c2, c3, c4]) @test coldot(a, b) ≈ c @test coldot(a * u"m", b) ≈ c * u"m" @test coldot(a, b * u"m") ≈ c * u"m" @test coldot(a * u"m", b * u"m") ≈ c * u"m^2" am = similar(a, Union{Float64,Missing}) am .= a am[:, 1] .= missing bm = similar(b, Union{Float64,Missing}) bm .= b bm[:, 1] .= missing @test all(coldot(am, b) .≈ c) |> ismissing @test all(coldot(a * u"m", bm) .≈ c * u"m") |> ismissing @test all(coldot(a, bm * u"m") .≈ c * u"m") |> ismissing @test all(coldot(am * u"m", bm) .≈ c * u"m") |> ismissing @test all(coldot(am * u"m", bm * u"m") .≈ c * u"m^2") |> ismissing end am = similar(a3, Union{Float64,Nothing}) am .= a3 @test coldot(am, b3) ≈ c3 end @testset "Cross Product" begin a = rand(3, 100) b = rand(3, 100) au = a * u"m" bu = b * u"m" c = reduce(hcat, [cross(ai, bi) for (ai, bi) in zip(eachcol(a), eachcol(b))]) @test colcross(a, b) ≈ c @test colcross(au, b) ≈ c * u"m" @test colcross(a, bu) ≈ c * u"m" @test colcross(au, bu) ≈ c * u"m^2" am = similar(a, Union{Float64,Missing}) am .= a am[:, 1] .= missing bm = similar(b, Union{Float64,Missing}) bm .= b bm[:, 1] .= missing @test all(colcross(am, b) .≈ c) |> ismissing @test all(colcross(au, bm) .≈ c * u"m") |> ismissing @test all(colcross(a, bm * u"m") .≈ c * u"m") |> ismissing @test all(colcross(am * u"m", bm) .≈ c * u"m") |> ismissing @test all(colcross(am * u"m", bm * u"m") .≈ c * u"m^2") |> ismissing am = similar(a, Union{Float64,Nothing}) am .= a @test colcross(am, b) ≈ c end @testset "Angular momentum" begin a = rand(3, 100) b = rand(3, 100) au = a * u"m" bu = b * u"m" for m in [rand(), rand(100)] mu = m * u"kg" j = m' .* colcross(a, b) @test angmom(a, b, m) ≈ j @test angmom(au, b, m) ≈ j * u"m" @test angmom(a, bu, m) ≈ j * u"m" @test angmom(au, bu, m) ≈ j * u"m^2" @test angmom(a, b, mu) ≈ j * u"kg" @test angmom(au, b, mu) ≈ j * u"m*kg" @test angmom(a, bu, mu) ≈ j * u"m*kg" @test angmom(au, bu, mu) ≈ j * u"m^2*kg" for func in [angmomtot, angmomtot_stable] @test func(a, b, m) ≈ sum(j; dims=2) @test func(au, b, m) ≈ sum(j * u"m"; dims=2) @test func(a, bu, m) ≈ sum(j * u"m"; dims=2) @test func(au, bu, m) ≈ sum(j * u"m^2"; dims=2) @test func(a, b, mu) ≈ sum(j * u"kg"; dims=2) @test func(au, b, mu) ≈ sum(j * u"m*kg"; dims=2) @test func(a, bu, mu) ≈ sum(j * u"m*kg"; dims=2) @test func(au, bu, mu) ≈ sum(j * u"m^2*kg"; dims=2) end origin = rand(3) velorigin = rand(3) jorigin = m' .* colcross(a .- origin, b) @test angmom(au, bu, mu; origin=origin * u"m") ≈ jorigin * u"m^2*kg" @test angmomtot(au, bu, mu; origin=origin * u"m") ≈ sum(jorigin * u"m^2*kg"; dims=2) jorigin = m' .* colcross(a, b .- velorigin) @test angmom(au, bu, mu; velorigin=velorigin * u"m") ≈ jorigin * u"m^2*kg" @test angmomtot(au, bu, mu; velorigin=velorigin * u"m") ≈ sum(jorigin * u"m^2*kg"; dims=2) @test angmomtot_stable(au, bu, mu; velorigin=velorigin * u"m") ≈ sum(jorigin * u"m^2*kg"; dims=2) jorigin = m' .* colcross(a .- origin, b .- velorigin) @test angmom(au, bu, mu; origin=origin * u"m", velorigin=velorigin * u"m") ≈ jorigin * u"m^2*kg" @test angmomtot(au, bu, mu; origin=origin * u"m", velorigin=velorigin * u"m") ≈ sum(jorigin * u"m^2*kg"; dims=2) @test angmomtot_stable(au, bu, mu; origin=origin * u"m", velorigin=velorigin * u"m") ≈ sum(jorigin * u"m^2*kg"; dims=2) am = similar(a, Union{Float64,Missing}) am .= a am[:, 1] .= missing bm = similar(b, Union{Float64,Missing}) bm .= b bm[:, 1] .= missing @test all(angmom(am, b, m) .≈ j) |> ismissing @test all(angmom(au, bm, m) .≈ j * u"m") |> ismissing @test all(angmom(a, bm * u"m", m) .≈ j * u"m") |> ismissing @test all(angmom(am * u"m", bm, m) .≈ j * u"m") |> ismissing @test all(angmom(am * u"m", bm * u"m", m) .≈ j * u"m^2") |> ismissing @test all(angmom(am, b, mu) .≈ j * u"kg") |> ismissing @test all(angmom(au, bm, mu) .≈ j * u"m*kg") |> ismissing @test all(angmom(a, bm * u"m", mu) .≈ j * u"m*kg") |> ismissing @test all(angmom(am * u"m", bm, mu) .≈ j * u"m*kg") |> ismissing @test all(angmom(am * u"m", bm * u"m", mu) .≈ j * u"m^2*kg") |> ismissing am = similar(a, Union{Float64,Nothing}) am .= a @test angmom(am, b, m) ≈ j end end @testset "Particles properties" begin dm = Particles(:dm, :pos => rand(3, 100), :vel => rand(Float32, 3, 100), :mass => 2) gas = Particles( :gas, :pos => rand(3, 100), :vel => rand(Float32, 3, 100), :mass => rand(100), :temp => rand(100), :test => 1, :mass2 => Fill(2, 100), ) dmu = deepcopy(dm) gasu = deepcopy(gas) dmu.pos *= u"m" dmu.vel *= u"km/s" dmu.mass *= u"kg" gasu.pos *= u"m" gasu.vel *= u"km/s" gasu.mass *= u"kg" gasu.mass2 *= u"kg" gasu.temp *= u"K" for (dm, gas) in zip([dm, dmu], [gas, gasu]) cp = ParticleCollection(dm, gas) ap = cp.all p = Particles(ap) @test meanpos(dm) == mean(dm.pos; dims=2) @test meanpos(dm; massweighted=false) == mean(dm.pos; dims=2) @test meanpos(gas) ≈ sum(gas.pos .* gas.mass'; dims=2) / sum(gas.mass) @test meanpos(gas; massweighted=false) == mean(gas.pos; dims=2) @test meanpos(ap) ≈ meanpos(p) @test meanprop(dm, :pos) == mean(dm.pos; dims=2) @test meanprop(gas, :pos; massprop=:mass2) == mean(gas.pos; dims=2) @test meanprop(gas, :temp) ≈ sum(gas.temp .* gas.mass) / sum(gas.mass) @test meanprop(gas, :temp; massweighted=false) == mean(gas.temp) @test meanprop(gas, :temp; massprop=:mass2) == mean(gas.temp) @test meanprop(dm, :mass) == dm.mass @test meanprop(dm, :mass; massweighted=false) == dm.mass @test meanprop(gas, :test) == gas.test @test meanprop(gas, :mass2) == gas.mass2[1] @test meanprop(gas, :mass2; massweighted=false) == gas.mass2[1] @test meanprop(gas, :mass2; massprop=:mass2) == gas.mass2[1] @test meanprop(ap, :mass) ≈ meanvel(p, :mass) @test meanvel(dm) == mean(dm.vel; dims=2) @test meanvel(dm; massweighted=false) == mean(dm.vel; dims=2) @test meanvel(gas) ≈ sum(gas.vel .* gas.mass'; dims=2) / sum(gas.mass) @test meanvel(gas; massweighted=false) == mean(gas.vel; dims=2) @test meanvel(ap) ≈ meanvel(p) @test sumprop(dm, :pos) == sum(dm.pos; dims=2) @test sumprop(gas, :pos) == sum(gas.pos; dims=2) @test sumprop(dm, :mass) == CP.particle_number(dm) * dm.mass @test sumprop(gas, :mass2) == sum(gas.mass2) @test sumprop(ap, :pos) == sumprop(p, :pos) @test angmom(dm; angmomprop=:j) == angmom(dm.pos, dm.vel, dm.mass) @test angmomtot(dm; angmomprop=:j) == angmomtot(dm.pos, dm.vel, dm.mass) @test angmomtot_stable(dm; angmomprop=:j) == angmomtot_stable(dm.pos, dm.vel, dm.mass) dm.j = angmom(dm) @test angmom(dm; angmomprop=:j) ≈ angmom(dm.pos, dm.vel, dm.mass) @test angmomtot(dm; angmomprop=:j) ≈ angmomtot(dm.pos, dm.vel, dm.mass) @test angmomtot_stable(dm; angmomprop=:j) ≈ angmomtot_stable(dm.pos, dm.vel, dm.mass) @test angmom(gas; angmomprop=:j) == angmom(gas.pos, gas.vel, gas.mass) @test angmomtot(gas; angmomprop=:j) == angmomtot(gas.pos, gas.vel, gas.mass) @test angmomtot_stable(gas; angmomprop=:j) == angmomtot_stable(gas.pos, gas.vel, gas.mass) origin = 2 * dm.pos[:, 1] velorigin = 2 * dm.vel[:, 1] for func in [angmom, angmomtot, angmomtot_stable] @test func(gas; origin) == func(gas.pos, gas.vel, gas.mass; origin) @test func(gas; velorigin) == func(gas.pos, gas.vel, gas.mass; velorigin) @test func(gas; origin, velorigin) == func(gas.pos, gas.vel, gas.mass; origin, velorigin) end end end end end
[ 3500, 10437, 5908, 7841, 2983, 198, 3500, 27845, 3163, 20477, 198, 3500, 406, 12582, 3163, 20477, 198, 3500, 44800, 2348, 29230, 198, 3500, 18481, 602, 198, 3500, 311, 24707, 2348, 7727, 907, 198, 3500, 20595, 14881, 198, 3500, 6208, 198, 3500, 11801, 913, 198, 198, 9979, 16932, 796, 10437, 5908, 7841, 2983, 198, 198, 31, 9288, 2617, 366, 36734, 5908, 7841, 2983, 13, 20362, 1, 2221, 628, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 2983, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 628, 220, 220, 220, 220, 220, 220, 220, 279, 13, 312, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 1180, 4686, 290, 1426, 329, 18984, 2142, 2983, 198, 220, 220, 220, 220, 220, 220, 220, 40653, 312, 796, 43720, 7, 3064, 8, 198, 220, 220, 220, 220, 220, 220, 220, 40653, 1930, 796, 43720, 7, 18, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 2142, 1548, 2176, 198, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 2983, 7, 25, 36020, 11, 1058, 312, 5218, 279, 13, 312, 11, 1058, 1930, 5218, 279, 13, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 6624, 279, 628, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 4866, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 6624, 279, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 5145, 855, 279, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1676, 862, 6624, 279, 13, 1676, 862, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1676, 862, 5145, 855, 279, 13, 1676, 862, 628, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 6565, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 4906, 24844, 1058, 36020, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 14751, 13, 1676, 862, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 14751, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 3672, 7, 79, 8, 6624, 366, 7841, 2983, 1, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 79, 828, 685, 25, 4906, 11, 1058, 312, 11, 1058, 1930, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 79, 26, 2839, 28, 7942, 828, 685, 25, 4906, 11, 1058, 1676, 862, 11, 1058, 312, 11, 1058, 1930, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 905, 7, 952, 11, 366, 5239, 14, 25638, 1600, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10903, 7, 20657, 0, 7, 952, 4008, 6624, 366, 36020, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 1, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 1332, 27741, 7841, 2983, 351, 4096, 7822, 2142, 2983, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 1136, 62, 1676, 862, 7, 79, 8, 24844, 279, 13, 1676, 862, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 651, 26745, 7, 79, 11, 1058, 312, 8, 24844, 279, 13, 1676, 862, 58, 25, 312, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 651, 26745, 7, 79, 11, 1058, 4906, 8, 24844, 279, 13, 4906, 24844, 1058, 36020, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 651, 26745, 7, 79, 11, 1058, 1676, 862, 8, 24844, 279, 13, 1676, 862, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 312, 24844, 279, 13, 1676, 862, 58, 25, 312, 60, 628, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 4866, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 900, 26745, 0, 7, 79, 11, 1058, 1930, 11, 40653, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 24844, 40653, 1930, 198, 220, 220, 220, 220, 220, 220, 220, 40653, 13, 312, 796, 40653, 312, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 312, 24844, 40653, 312, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 312, 5145, 855, 40653, 312, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 7203, 15931, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 900, 3245, 48725, 40139, 2878, 286, 2099, 2142, 2983, 2314, 307, 3421, 15931, 4943, 279, 13, 4906, 796, 1058, 22649, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 58, 25, 312, 60, 24844, 279, 13, 1676, 862, 58, 25, 312, 60, 628, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 4866, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 279, 58, 25, 312, 60, 796, 40653, 312, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 312, 24844, 40653, 312, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8251, 7, 79, 8, 6624, 8251, 7, 79, 13, 1676, 862, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 7, 79, 11, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 11, 1058, 4906, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3815, 7, 79, 8, 6624, 3815, 7, 79, 13, 1676, 862, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 79, 828, 685, 25, 4906, 11, 1058, 312, 11, 1058, 1930, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 1303, 1332, 4277, 25504, 329, 27741, 7841, 2983, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 14881, 13, 31, 37669, 7, 26745, 14933, 7, 79, 3712, 23839, 7841, 2983, 36911, 685, 25, 312, 11, 1058, 1930, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 6565, 0, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 14751, 13, 1676, 862, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 14751, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 271, 28920, 7, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 4866, 0, 7, 14751, 11, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 5145, 855, 279, 11405, 40653, 6624, 279, 11405, 5145, 271, 28920, 7, 14751, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 17618, 7, 79, 8, 6624, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 17618, 7, 7841, 2983, 7, 25, 22649, 4008, 6624, 657, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 17618, 7, 7841, 2983, 7, 25, 22649, 11, 360, 713, 90, 13940, 23650, 11, 7149, 92, 7, 25, 22208, 5218, 513, 22305, 6624, 657, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 22366, 7, 14881, 13, 31, 37669, 7, 8697, 13, 3911, 1548, 62, 3672, 7, 79, 3712, 23839, 7841, 2983, 22305, 628, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 12860, 62, 48310, 7, 952, 11, 366, 5239, 14, 25638, 1600, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10903, 7, 20657, 0, 7, 952, 4008, 6624, 366, 3064, 2142, 2983, 59, 77, 4686, 1426, 1, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 3237, 7841, 2983, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 312, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 22208, 796, 43720, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 9288, 796, 43720, 3419, 628, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 312, 796, 6291, 7, 47705, 25, 11024, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 22208, 796, 43720, 7, 3064, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 29510, 796, 43720, 7, 3064, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 89, 82, 796, 43720, 7, 17, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 9288, 796, 43720, 7, 17, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 279, 26000, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 279, 796, 1439, 7841, 2983, 7, 14751, 692, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 43681, 7, 79, 8, 24844, 279, 26000, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 2488, 9288, 651, 62, 1676, 862, 7, 79, 8, 24844, 279, 13, 1676, 862, 1303, 407, 636, 286, 262, 7824, 628, 220, 220, 220, 220, 220, 220, 220, 611, 279, 13, 312, 58, 16, 60, 6624, 288, 76, 13, 312, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 312, 6624, 410, 9246, 7, 36020, 13, 312, 11, 3623, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 6624, 289, 9246, 7, 36020, 13, 1930, 11, 3623, 13, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 22208, 6624, 410, 9246, 7, 20797, 7, 36020, 13, 22208, 11, 4129, 7, 36020, 13, 312, 36911, 3623, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 12195, 79, 13, 29510, 11, 410, 9246, 7, 20797, 7, 45688, 11, 4129, 7, 36020, 13, 312, 36911, 3623, 13, 29510, 4008, 930, 29, 477, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 12195, 79, 13, 89, 82, 11, 289, 9246, 7, 20797, 7, 45688, 11, 362, 11, 4129, 7, 36020, 13, 312, 36911, 3623, 13, 89, 82, 4008, 930, 29, 477, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 9288, 6624, 289, 9246, 7, 20797, 7, 36020, 13, 9288, 11, 362, 11, 4129, 7, 36020, 13, 312, 36911, 3623, 13, 9288, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2073, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 312, 6624, 410, 9246, 7, 22649, 13, 312, 11, 288, 76, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 6624, 289, 9246, 7, 22649, 13, 1930, 11, 288, 76, 13, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 22208, 6624, 410, 9246, 7, 22649, 13, 22208, 11, 6070, 7, 36020, 13, 22208, 11, 4129, 7, 36020, 13, 312, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 12195, 79, 13, 29510, 11, 410, 9246, 7, 22649, 13, 29510, 11, 6070, 7, 45688, 11, 4129, 7, 36020, 13, 312, 35514, 930, 29, 477, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 40496, 12195, 79, 13, 89, 82, 11, 289, 9246, 7, 22649, 13, 89, 82, 11, 6070, 7, 45688, 11, 362, 11, 4129, 7, 36020, 13, 312, 35514, 930, 29, 477, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 9288, 6624, 289, 9246, 7, 22649, 13, 9288, 11, 6070, 7, 36020, 13, 9288, 11, 362, 11, 4129, 7, 36020, 13, 312, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 279, 13, 312, 796, 43720, 7, 3064, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 7383, 12331, 279, 13, 626, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 13083, 7, 79, 828, 685, 25, 312, 11, 1058, 22208, 11, 1058, 1930, 11, 1058, 29510, 11, 1058, 89, 82, 11, 1058, 9288, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8251, 7, 79, 8, 6624, 8251, 7, 3237, 7841, 2983, 7, 14751, 692, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 7, 79, 11, 1058, 312, 8, 11405, 468, 2539, 7, 3237, 7841, 2983, 7, 14751, 692, 828, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 11, 1058, 626, 8, 11405, 5145, 10134, 2539, 7, 3237, 7841, 2983, 7, 14751, 692, 828, 1058, 626, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 2100, 24844, 279, 58, 2539, 60, 329, 357, 2539, 11, 1188, 8, 287, 19974, 7, 13083, 7, 79, 828, 3815, 7, 79, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 2100, 24844, 279, 58, 2539, 60, 329, 357, 2539, 11, 1188, 8, 287, 14729, 7, 79, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 4866, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 4866, 0, 7, 79, 11, 1439, 7841, 2983, 7, 14751, 692, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 4866, 0, 7, 79, 11, 288, 76, 8, 628, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 2983, 7, 25, 439, 8, 198, 220, 220, 220, 220, 220, 220, 220, 4866, 0, 7, 14751, 11, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2824, 7, 27160, 7, 79, 4008, 1303, 2587, 4340, 6608, 287, 360, 713, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 312, 6624, 279, 13, 312, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 6624, 279, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 279, 13, 1930, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 786, 13255, 12195, 14751, 13, 29510, 11, 279, 13, 29510, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 786, 13255, 12195, 14751, 13, 89, 82, 11, 279, 13, 89, 82, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 9288, 6624, 279, 13, 9288, 628, 220, 220, 220, 220, 220, 220, 220, 4866, 0, 7, 14751, 11, 279, 11, 685, 25, 312, 11, 1058, 22208, 11, 1058, 29510, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 12195, 7, 14751, 11, 828, 685, 25, 312, 11, 1058, 22208, 11, 1058, 29510, 12962, 930, 29, 477, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 64, 12195, 58, 14751, 13, 312, 11, 40653, 13, 22208, 11, 40653, 13, 29510, 4357, 15690, 8, 930, 29, 477, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2142, 2983, 7, 79, 11, 685, 25, 312, 11, 1058, 22208, 11, 1058, 29510, 12962, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 6565, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 6565, 0, 7, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 271, 28920, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 7841, 1548, 36307, 3419, 930, 29, 1439, 7841, 2983, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 7841, 1548, 36307, 7, 7841, 2983, 7, 25, 36020, 828, 2142, 2983, 7, 25, 22649, 4008, 930, 29, 1439, 7841, 2983, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 6624, 1439, 7841, 2983, 7, 14751, 692, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 3672, 7, 79, 8, 6624, 366, 7841, 2983, 1, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 17618, 7, 79, 8, 6624, 939, 628, 220, 220, 220, 220, 220, 220, 220, 1351, 796, 685, 25, 312, 11, 1058, 22208, 11, 1058, 1930, 11, 1058, 29510, 11, 1058, 89, 82, 11, 1058, 9288, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 79, 828, 1351, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 79, 26, 2839, 28, 7942, 828, 685, 3245, 14933, 7, 3237, 7841, 2983, 8, 930, 29, 2824, 26, 1351, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 905, 7, 952, 11, 366, 5239, 14, 25638, 1600, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10903, 7, 20657, 0, 7, 952, 4008, 6624, 366, 439, 25, 939, 2142, 2983, 59, 77, 4686, 2347, 1426, 20218, 1332, 1976, 82, 1, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 3911, 1548, 62, 17618, 7, 3237, 7841, 2983, 7, 7841, 1548, 36307, 3419, 4008, 6624, 657, 628, 198, 220, 220, 220, 220, 220, 220, 220, 9335, 796, 318, 5088, 12195, 79, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 439, 7, 27932, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 279, 58, 27932, 60, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 279, 58, 521, 60, 628, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 3002, 1339, 810, 262, 15793, 318, 407, 1043, 422, 257, 15879, 393, 17593, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 290, 810, 691, 530, 18758, 850, 4906, 7160, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 2347, 796, 43720, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 7841, 2983, 7, 25, 36020, 11, 1058, 1930, 5218, 1426, 11, 1058, 22208, 5218, 2347, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2471, 13, 1930, 6624, 1426, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2471, 13, 22208, 6624, 6070, 7, 22208, 11, 1802, 8, 198, 220, 220, 220, 886, 628, 198, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 312, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 312, 796, 6291, 7, 47705, 25, 11024, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 36307, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 318, 64, 2142, 1548, 36307, 90, 7841, 2983, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 3911, 2983, 6624, 360, 713, 90, 13940, 23650, 11, 7841, 2983, 92, 3419, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2142, 1548, 36307, 7, 7841, 2983, 8, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 25, 36020, 5218, 288, 76, 11, 1058, 22649, 5218, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 318, 64, 2142, 1548, 36307, 90, 7841, 2983, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 3911, 2983, 6624, 360, 713, 90, 13940, 23650, 11, 7841, 2983, 92, 7, 25, 36020, 5218, 288, 76, 11, 1058, 22649, 5218, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2266, 30846, 7, 14751, 8, 6624, 657, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 4866, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 3911, 2983, 58, 25, 36020, 60, 24844, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 13, 3911, 2983, 58, 25, 36020, 60, 796, 3623, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 3911, 2983, 58, 25, 36020, 60, 5145, 855, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 6565, 7, 14751, 8, 6624, 2142, 1548, 36307, 3419, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 905, 7, 952, 11, 366, 5239, 14, 25638, 1600, 40653, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10903, 7, 20657, 0, 7, 952, 4008, 6624, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 7841, 1548, 36307, 59, 358, 76, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 59, 782, 292, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 1, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7738, 30846, 7841, 1548, 36307, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1976, 796, 657, 13, 20, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2297, 30846, 7841, 1548, 36307, 7, 15, 13, 20, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 318, 64, 2297, 30846, 7841, 1548, 36307, 90, 7841, 2983, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 3911, 2983, 6624, 360, 713, 90, 13940, 23650, 11, 7841, 2983, 92, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 89, 6624, 1976, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2297, 30846, 7841, 1548, 36307, 7, 7841, 2983, 11, 1976, 8, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2297, 30846, 7841, 1548, 36307, 7, 89, 11, 1058, 36020, 5218, 288, 76, 11, 1058, 22649, 5218, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 318, 64, 2297, 30846, 7841, 1548, 36307, 90, 7841, 2983, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 3911, 2983, 6624, 360, 713, 90, 13940, 23650, 11, 7841, 2983, 92, 7, 25, 36020, 5218, 288, 76, 11, 1058, 22649, 5218, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2297, 30846, 7841, 1548, 36307, 7, 89, 11, 288, 76, 11, 3623, 8, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2266, 30846, 7, 14751, 8, 6624, 1976, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2297, 30846, 7841, 1548, 36307, 7, 89, 11, 288, 76, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 4866, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 3911, 2983, 58, 25, 36020, 60, 24844, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 13, 3911, 2983, 58, 25, 36020, 60, 796, 3623, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 3911, 2983, 58, 25, 36020, 60, 5145, 855, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 6565, 7, 14751, 8, 6624, 2297, 30846, 7841, 1548, 36307, 7, 89, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2297, 30846, 7841, 1548, 36307, 7, 89, 11, 288, 76, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 905, 7, 952, 11, 366, 5239, 14, 25638, 1600, 40653, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10903, 7, 20657, 0, 7, 952, 4008, 6624, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 7841, 1548, 36307, 379, 1976, 796, 720, 89, 59, 358, 76, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 59, 782, 292, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 14751, 828, 685, 25, 89, 11, 1058, 439, 11, 1058, 36020, 11, 1058, 22649, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 14751, 26, 2839, 28, 7942, 828, 685, 25, 89, 11, 1058, 439, 11, 1058, 3911, 2983, 11, 1058, 36020, 11, 1058, 22649, 12962, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 14751, 796, 2297, 30846, 7841, 1548, 36307, 7, 15, 11, 288, 76, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 374, 14751, 6624, 40653, 11405, 40653, 6624, 374, 14751, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 14751, 796, 2297, 30846, 7841, 1548, 36307, 7, 89, 11, 288, 76, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 374, 14751, 14512, 40653, 11405, 40653, 14512, 374, 14751, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 23839, 7841, 1548, 36307, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 1136, 62, 3911, 2983, 7, 14751, 8, 24844, 40653, 13, 3911, 2983, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 651, 26745, 7, 14751, 11, 1058, 36020, 8, 24844, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 651, 26745, 7, 14751, 11, 1058, 3911, 2983, 8, 24844, 40653, 13, 3911, 2983, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 24844, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 58, 25, 36020, 60, 24844, 40653, 13, 3911, 2983, 58, 25, 36020, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 2617, 3245, 48725, 40139, 2878, 286, 2099, 2142, 1548, 36307, 2314, 307, 3421, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 40653, 13, 3911, 2983, 796, 360, 713, 90, 13940, 23650, 11, 7841, 2983, 92, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 13, 36020, 796, 3623, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 58, 25, 36020, 60, 24844, 3623, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 58, 25, 36020, 60, 796, 288, 76, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 24844, 288, 76, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 439, 6624, 1439, 7841, 2983, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 40653, 13, 439, 796, 288, 76, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 7383, 12331, 40653, 58, 25, 439, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8251, 7, 14751, 8, 6624, 8251, 7, 14751, 13, 3911, 2983, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 7, 14751, 11, 1058, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 30783, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 3911, 2983, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3815, 7, 14751, 8, 6624, 3815, 7, 14751, 13, 3911, 2983, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 26745, 14933, 7, 14751, 828, 685, 25, 439, 11, 1058, 36020, 11, 1058, 22649, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6565, 0, 7, 79, 535, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 79, 535, 13, 3911, 2983, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 318, 28920, 7, 79, 535, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 271, 28920, 7, 14751, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 4866, 0, 7, 79, 535, 11, 40653, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 5145, 855, 40653, 11405, 279, 535, 6624, 40653, 11405, 5145, 271, 28920, 7, 79, 535, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 33245, 796, 314, 9864, 13712, 3419, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 12860, 62, 48310, 7, 952, 11, 366, 5239, 14, 25638, 1600, 40653, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10903, 7, 20657, 0, 7, 952, 4008, 6624, 366, 36020, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 59, 782, 292, 25, 1802, 2142, 2983, 59, 77, 4686, 1426, 1, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 198, 220, 220, 220, 2488, 9288, 2617, 366, 18274, 4487, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 15732, 13166, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 312, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 22208, 796, 604, 84, 1, 10025, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9335, 796, 43720, 7, 3064, 8, 764, 29, 657, 13, 20, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 439, 7, 27932, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 18, 11, 9335, 8, 6624, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 79, 13, 22208, 11, 9335, 8, 6624, 279, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 79, 13, 312, 11, 9335, 8, 6624, 279, 13, 312, 58, 27932, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 79, 13, 1930, 11, 9335, 8, 6624, 279, 13, 1930, 58, 45299, 9335, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 18, 11, 773, 8, 6624, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 79, 13, 22208, 11, 773, 8, 6624, 279, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 79, 13, 312, 11, 773, 8, 6624, 279, 13, 312, 58, 521, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 79, 13, 1930, 11, 773, 8, 6624, 279, 13, 1930, 58, 45299, 773, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 2231, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 2816, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 27967, 19182, 7, 85, 9246, 11, 257, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 66, 11, 9335, 8, 6624, 15690, 7, 66, 38381, 27932, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 66, 11, 773, 8, 6624, 15690, 7, 66, 38381, 521, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 4153, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 18, 11, 5996, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 27967, 19182, 7, 71, 9246, 11, 257, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 66, 11, 9335, 8, 6624, 15690, 7, 66, 38381, 45299, 9335, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 39014, 521, 7, 66, 11, 773, 8, 6624, 15690, 7, 66, 38381, 45299, 773, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 16932, 13, 39014, 521, 7, 79, 11, 9335, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 312, 6624, 279, 13, 312, 58, 27932, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 279, 13, 1930, 58, 45299, 9335, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 6624, 279, 13, 22208, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 39014, 521, 7, 79, 11, 773, 8, 6624, 40653, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 58, 521, 60, 6624, 40653, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 58, 27932, 60, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 39014, 521, 0, 7, 79, 535, 11, 9335, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 39014, 521, 0, 7, 79, 535, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 16932, 13, 39014, 521, 7, 79, 11, 9335, 26, 2689, 41888, 25, 1930, 11, 1058, 22208, 11, 1058, 21943, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 21943, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 279, 13, 1930, 58, 45299, 9335, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 6624, 279, 13, 22208, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 16932, 13, 39014, 521, 7, 499, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 16932, 13, 39014, 521, 0, 7, 499, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 16932, 13, 39014, 521, 7, 499, 11, 9335, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 16932, 13, 39014, 521, 0, 7, 499, 11, 9335, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 27914, 13166, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 312, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 22208, 796, 604, 84, 1, 10025, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9335, 796, 43720, 7, 3064, 8, 764, 29, 657, 13, 20, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 439, 7, 27932, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 28956, 521, 7, 18, 11, 773, 8, 6624, 513, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 28956, 521, 7, 79, 13, 22208, 11, 773, 8, 6624, 279, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 28956, 521, 7, 79, 13, 312, 11, 773, 8, 6624, 12233, 265, 0, 7, 30073, 7, 79, 13, 312, 828, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 2787, 2668, 796, 16932, 13557, 28956, 521, 7, 79, 13, 1930, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1426, 2787, 2668, 58, 16, 11, 1058, 60, 6624, 12233, 265, 0, 7, 79, 13, 1930, 58, 16, 11, 1058, 4357, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1426, 2787, 2668, 58, 17, 11, 1058, 60, 6624, 12233, 265, 0, 7, 79, 13, 1930, 58, 17, 11, 1058, 4357, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1426, 2787, 2668, 58, 18, 11, 1058, 60, 6624, 12233, 265, 0, 7, 79, 13, 1930, 58, 18, 11, 1058, 4357, 773, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 2231, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 2816, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 27967, 19182, 7, 85, 9246, 11, 257, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13557, 28956, 521, 7, 66, 11, 773, 8, 6624, 12233, 265, 0, 7, 19182, 7, 66, 828, 773, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 4153, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 18, 11, 5996, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 27967, 19182, 7, 71, 9246, 11, 257, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 36559, 2668, 796, 16932, 13557, 28956, 521, 7, 66, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1097, 2433, 796, 15690, 7, 66, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 36559, 2668, 58, 16, 11, 1058, 60, 6624, 12233, 265, 0, 7, 7718, 2433, 58, 16, 11, 1058, 4357, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 36559, 2668, 58, 17, 11, 1058, 60, 6624, 12233, 265, 0, 7, 7718, 2433, 58, 17, 11, 1058, 4357, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 36559, 2668, 58, 18, 11, 1058, 60, 6624, 12233, 265, 0, 7, 7718, 2433, 58, 18, 11, 1058, 4357, 773, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 16932, 13, 39014, 521, 7, 79, 11, 764, 93, 27932, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 28956, 521, 7, 79, 11, 773, 8, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 28956, 521, 0, 7, 79, 535, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 685, 25, 1930, 11, 1058, 22208, 11, 1058, 21943, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 16932, 13, 28956, 521, 7, 79, 11, 773, 26, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 6624, 16932, 13, 39014, 521, 7, 79, 11, 764, 93, 27932, 26, 2689, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 33678, 265, 7, 79, 11, 773, 8, 6624, 16932, 13, 28956, 521, 7, 79, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 33678, 265, 0, 7, 14751, 11, 773, 8, 6624, 16932, 13, 28956, 521, 7, 79, 11, 773, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 35528, 16932, 13, 28956, 521, 7, 499, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 35528, 16932, 13, 28956, 521, 0, 7, 499, 11, 773, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 16742, 477, 287, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 6291, 7, 16, 25, 49388, 11, 39064, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 900, 796, 6291, 7, 16, 25, 49388, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 287, 16885, 796, 36177, 7, 64, 11, 900, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 16932, 13, 19796, 439, 62, 259, 7, 64, 11, 900, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 521, 8, 6624, 4129, 7, 259, 16885, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 64, 58, 521, 4357, 287, 16885, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 7, 64, 11, 5345, 7, 2617, 4008, 6624, 773, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3297, 0, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3297, 0, 7, 2617, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 16932, 13, 19796, 439, 62, 259, 7, 64, 11, 900, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 521, 8, 6624, 4129, 7, 259, 16885, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 64, 58, 521, 4357, 287, 16885, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 7, 64, 11, 5345, 7, 2617, 4008, 6624, 773, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 62, 82, 9741, 7, 64, 11, 900, 8, 6624, 773, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 435, 1376, 796, 2824, 7, 16, 25, 16, 62, 2167, 62, 830, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 435, 1376, 17, 796, 2824, 7, 2167, 62, 830, 25, 16, 62, 8054, 62, 830, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 900, 11664, 796, 6291, 7, 16, 25, 16, 62, 2167, 62, 830, 11, 1802, 62, 830, 26, 6330, 28, 9562, 8, 930, 29, 3297, 0, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 287, 16885, 796, 36177, 7, 282, 1376, 11, 900, 11664, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 287, 16885, 17, 796, 36177, 7, 282, 1376, 17, 11, 900, 11664, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 16932, 13, 19796, 439, 62, 259, 7, 282, 1376, 11, 900, 11664, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 521, 8, 6624, 4129, 7, 259, 16885, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 282, 1376, 58, 521, 4357, 287, 16885, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 7, 282, 1376, 11, 5345, 7, 2617, 11664, 4008, 6624, 773, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 16932, 13, 19796, 439, 62, 259, 7, 282, 1376, 17, 11, 900, 11664, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4129, 7, 521, 8, 6624, 4129, 7, 259, 16885, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 316, 40496, 7, 282, 1376, 17, 58, 521, 4357, 287, 16885, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 7, 282, 1376, 17, 11, 5345, 7, 2617, 11664, 4008, 6624, 773, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1332, 6565, 26515, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 62, 82, 9741, 26933, 4357, 685, 12962, 930, 29, 318, 28920, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 62, 82, 9741, 7, 64, 11, 685, 12962, 930, 29, 318, 28920, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 62, 82, 9741, 26933, 4357, 900, 8, 930, 29, 318, 28920, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 26933, 4357, 5345, 7, 21737, 4008, 930, 29, 318, 28920, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 7, 64, 11, 5345, 7, 21737, 4008, 930, 29, 318, 28920, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 19796, 439, 62, 259, 26933, 4357, 5345, 7, 2617, 4008, 930, 29, 318, 28920, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 26453, 913, 4560, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 3064, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6580, 796, 10385, 7, 38469, 90, 43879, 2624, 5512, 257, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6580, 84, 796, 6580, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 3419, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 7, 64, 11, 275, 8, 6624, 257, 764, 9, 275, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 7, 559, 11, 275, 8, 6624, 35851, 764, 9, 275, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 7, 1878, 11, 275, 8, 6624, 6580, 764, 9, 10385, 7, 43879, 2624, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 7, 1878, 84, 11, 275, 8, 6624, 6580, 84, 764, 9, 10385, 7, 43879, 2624, 11, 275, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 936, 796, 4866, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 0, 7, 330, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 936, 6624, 257, 764, 9, 275, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 0, 7, 14272, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 6624, 35851, 764, 9, 275, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6580, 66, 796, 4866, 7, 1878, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 0, 7, 1878, 66, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 6580, 66, 6624, 6580, 764, 9, 10385, 7, 43879, 2624, 11, 275, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6580, 1229, 796, 4866, 7, 1878, 84, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 11167, 62, 18302, 3760, 62, 4906, 0, 7, 1878, 1229, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 6580, 1229, 6624, 6580, 84, 764, 9, 10385, 7, 43879, 2624, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 43, 12582, 334, 36311, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 18, 8, 6624, 513, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 19, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 809, 796, 275, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 64, 8, 24844, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 8, 6624, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 18683, 27923, 7, 559, 4008, 6624, 6031, 27923, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 33, 19830, 27923, 7, 559, 11, 809, 11, 1058, 52, 4008, 6624, 347, 19830, 27923, 7, 64, 11, 275, 11, 1058, 52, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 2898, 19830, 27923, 7, 11110, 11, 35851, 11, 809, 4008, 6624, 833, 19830, 27923, 7, 65, 11, 257, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 43094, 2898, 19830, 27923, 7, 559, 11, 809, 4008, 6624, 15845, 2898, 19830, 27923, 7, 64, 11, 275, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 1177, 796, 2488, 1177, 35851, 58, 16, 25, 18, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 1177, 8, 6624, 257, 58, 16, 25, 18, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 410, 9246, 7, 64, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18912, 796, 27967, 19182, 7, 85, 9246, 11, 35851, 11, 809, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 27399, 8, 6624, 269, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 6070, 7, 17, 13, 20, 11, 604, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 18912, 796, 27845, 7, 17, 13, 20, 84, 1, 76, 1600, 604, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 27399, 8, 6624, 269, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 796, 43720, 7, 43879, 2624, 11, 604, 8, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 62, 36311, 796, 16932, 13, 436, 5528, 62, 75, 12582, 7, 84, 1, 13276, 1600, 35851, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 62, 36311, 796, 16932, 13, 436, 5528, 62, 75, 12582, 7, 84, 1, 13276, 1600, 257, 3046, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 35851, 62, 36311, 15139, 230, 334, 36311, 7, 559, 24457, 8576, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1288, 4906, 7, 559, 62, 36311, 8, 24844, 48436, 2414, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 3046, 62, 36311, 15139, 230, 334, 36311, 7, 559, 69, 24457, 8576, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1288, 4906, 7, 559, 69, 62, 36311, 8, 24844, 48436, 2624, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 796, 4866, 7, 559, 69, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 62, 36311, 796, 16932, 13, 436, 5528, 62, 75, 12582, 0, 7, 84, 1, 13276, 1600, 257, 1229, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 62, 36311, 796, 16932, 13, 436, 5528, 62, 75, 12582, 0, 7, 84, 1, 13276, 1600, 257, 3046, 66, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 62, 36311, 6624, 35851, 62, 36311, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 3046, 66, 62, 36311, 6624, 257, 3046, 62, 36311, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 8, 6624, 35851, 62, 36311, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 8, 6624, 257, 3046, 62, 36311, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 796, 4866, 7, 559, 69, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 62, 42946, 796, 16932, 13, 84, 1102, 1851, 62, 75, 12582, 0, 7, 84, 1, 13276, 1600, 257, 1229, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 62, 42946, 796, 16932, 13, 84, 1102, 1851, 62, 75, 12582, 0, 7, 84, 1, 13276, 1600, 257, 3046, 66, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 62, 42946, 15139, 230, 334, 1102, 1851, 12195, 84, 1, 13276, 1600, 35851, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 3046, 66, 62, 42946, 15139, 230, 334, 1102, 1851, 12195, 84, 1, 13276, 1600, 257, 3046, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 8, 6624, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 62, 42946, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 8, 6624, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 62, 42946, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 796, 4866, 7, 559, 69, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 62, 42946, 796, 16932, 13, 84, 1102, 1851, 62, 75, 12582, 0, 7, 84, 1, 76, 1600, 257, 1229, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 62, 42946, 796, 16932, 13, 84, 1102, 1851, 62, 75, 12582, 0, 7, 84, 1, 76, 1600, 257, 3046, 66, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 62, 42946, 15139, 230, 334, 1102, 1851, 12195, 84, 1, 76, 1600, 35851, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 3046, 66, 62, 42946, 15139, 230, 334, 1102, 1851, 12195, 84, 1, 76, 1600, 257, 3046, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 8, 6624, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 62, 42946, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 8, 6624, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 62, 42946, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 43720, 7, 19, 8, 1635, 334, 1, 7200, 34, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 796, 43720, 7, 43879, 2624, 11, 604, 8, 1635, 334, 1, 7200, 34, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 796, 4866, 7, 559, 69, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 62, 42946, 796, 16932, 13, 84, 1102, 1851, 62, 75, 12582, 0, 7, 84, 1, 42, 1600, 257, 1229, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 3046, 66, 62, 42946, 796, 16932, 13, 84, 1102, 1851, 62, 75, 12582, 0, 7, 84, 1, 42, 1600, 257, 3046, 66, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 62, 42946, 15139, 230, 334, 1102, 1851, 12195, 84, 1, 42, 1600, 35851, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 3046, 66, 62, 42946, 15139, 230, 334, 1102, 1851, 12195, 84, 1, 42, 1600, 257, 3046, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 8, 6624, 16932, 13, 436, 5528, 62, 75, 12582, 7, 14272, 62, 42946, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 8, 6624, 16932, 13, 436, 5528, 62, 75, 12582, 7, 559, 16072, 62, 42946, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 198, 220, 220, 220, 2488, 9288, 2617, 366, 41762, 602, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 49, 14221, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 5724, 6759, 796, 43720, 7, 24864, 46912, 90, 18, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 10599, 796, 5724, 6759, 1635, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1434, 83, 796, 5724, 6759, 1635, 35851, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 6759, 8609, 62, 10599, 378, 7, 64, 11, 5724, 6759, 8, 6624, 257, 10599, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 6759, 8609, 62, 10599, 378, 7, 559, 11, 5724, 6759, 8, 6624, 257, 1434, 83, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 936, 796, 4866, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 6759, 8609, 62, 10599, 378, 0, 7, 330, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 936, 6624, 257, 10599, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 6759, 8609, 62, 10599, 378, 0, 7, 14272, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 6624, 257, 1434, 83, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 936, 796, 2092, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 6759, 8609, 62, 10599, 378, 0, 7, 330, 11, 257, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 936, 6624, 257, 10599, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 1229, 796, 2092, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 6759, 8609, 62, 10599, 378, 0, 7, 14272, 11, 35851, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 1229, 6624, 257, 1434, 83, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 371, 14221, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 626, 796, 4866, 7, 64, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 23064, 7, 79, 11, 5724, 6759, 11, 1058, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 257, 1434, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 626, 24844, 40653, 13, 626, 6624, 257, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 23064, 7, 79, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 257, 1434, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 626, 6624, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 626, 6624, 257, 10599, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23064, 0, 7, 14751, 11, 5724, 6759, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 626, 6624, 257, 10599, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23064, 0, 7, 14751, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 257, 1434, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 626, 6624, 257, 10599, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 371, 14221, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 626, 796, 4866, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 626, 796, 4866, 7, 64, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 23064, 7, 14751, 11, 5724, 6759, 11, 1058, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 1930, 6624, 40653, 13, 22649, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 257, 1434, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 626, 24844, 279, 535, 13, 36020, 13, 626, 6624, 257, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 23064, 7, 14751, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 1930, 6624, 40653, 13, 22649, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 257, 1434, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 626, 6624, 40653, 13, 22649, 13, 626, 6624, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 626, 6624, 279, 535, 13, 22649, 13, 626, 6624, 257, 10599, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23064, 0, 7, 79, 535, 11, 5724, 6759, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 626, 6624, 279, 535, 13, 22649, 13, 626, 6624, 257, 10599, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23064, 0, 7, 79, 535, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 257, 1434, 83, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 626, 6624, 279, 535, 13, 22649, 13, 626, 6624, 257, 10599, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 279, 535, 66, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 23064, 7, 499, 11, 5724, 6759, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23064, 0, 7, 499, 11, 5724, 6759, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 279, 535, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 8291, 49905, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 12379, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 559, 796, 43720, 7, 18, 8, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 379, 26084, 796, 257, 764, 10, 12379, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1960, 26084, 796, 35851, 764, 10, 288, 559, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 3602, 49905, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 626, 796, 4866, 7, 64, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 15772, 7, 79, 11, 288, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 1960, 26084, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 626, 24844, 40653, 13, 626, 6624, 257, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 15772, 7, 79, 11, 12379, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 1930, 24844, 40653, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 626, 6624, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 626, 6624, 379, 26084, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 0, 7, 14751, 11, 288, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 1960, 26084, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 626, 6624, 257, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 0, 7, 14751, 11, 12379, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 626, 6624, 379, 26084, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 27458, 25231, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2278, 11, 2278, 62, 13959, 796, 838, 11, 642, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13557, 7645, 17660, 62, 41007, 291, 7, 16, 11, 362, 11, 2278, 8, 6624, 352, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13557, 7645, 17660, 62, 41007, 291, 7, 23, 11, 362, 11, 2278, 11, 2278, 62, 13959, 8, 6624, 532, 17, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13557, 7645, 17660, 62, 41007, 291, 7, 17, 11, 807, 11, 2278, 11, 2278, 62, 13959, 8, 6624, 1105, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 267, 796, 530, 20850, 7, 417, 4906, 7, 67, 559, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 15772, 62, 41007, 291, 7, 79, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 67, 559, 764, 12, 657, 13, 20, 78, 764, 35705, 97, 5288, 7, 14751, 13, 1930, 26, 5391, 82, 28, 17, 4008, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 47033, 7, 14751, 13, 1930, 26, 5391, 82, 28, 17, 8, 764, 35705, 97, 288, 559, 764, 10, 657, 13, 20, 78, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 62, 41007, 291, 0, 7, 14751, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 67, 559, 764, 12, 657, 13, 20, 78, 764, 35705, 97, 5288, 7, 14751, 13, 1930, 26, 5391, 82, 28, 17, 4008, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 47033, 7, 14751, 13, 1930, 26, 5391, 82, 28, 17, 8, 764, 35705, 97, 288, 559, 764, 10, 657, 13, 20, 78, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 15772, 62, 41007, 291, 62, 1462, 62, 16159, 7, 79, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 15772, 7, 14751, 11, 532, 67, 559, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 62, 41007, 291, 62, 1462, 62, 16159, 0, 7, 79, 535, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 15772, 7, 14751, 11, 532, 67, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 3602, 49905, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 626, 796, 4866, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 626, 796, 4866, 7, 64, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 15772, 7, 14751, 11, 288, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 1930, 6624, 40653, 13, 22649, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 1960, 26084, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 626, 24844, 279, 535, 13, 36020, 13, 626, 6624, 257, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 15772, 7, 14751, 11, 12379, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 1930, 24844, 279, 535, 13, 36020, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 36020, 13, 626, 6624, 40653, 13, 22649, 13, 626, 6624, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 626, 6624, 279, 535, 13, 22649, 13, 626, 6624, 379, 26084, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 0, 7, 79, 535, 11, 288, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 1960, 26084, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 626, 6624, 279, 535, 13, 22649, 13, 626, 6624, 257, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 0, 7, 79, 535, 11, 12379, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 1930, 6624, 279, 535, 13, 22649, 13, 1930, 6624, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 13, 626, 6624, 279, 535, 13, 36020, 13, 626, 6624, 379, 26084, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 279, 535, 66, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 15772, 7, 499, 11, 12379, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 0, 7, 499, 11, 288, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 15772, 7, 14751, 11, 288, 559, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 279, 535, 66, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 0, 7, 499, 11, 12379, 11, 1058, 626, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 279, 535, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 267, 796, 530, 20850, 7, 417, 4906, 7, 67, 559, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 15772, 62, 41007, 291, 7, 14751, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 15772, 62, 41007, 291, 7, 14751, 13, 36020, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 15772, 62, 41007, 291, 7, 14751, 13, 22649, 11, 288, 559, 11, 267, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 62, 41007, 291, 0, 7, 79, 535, 66, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 279, 535, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 15772, 62, 41007, 291, 62, 1462, 62, 16159, 7, 14751, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 15772, 62, 41007, 291, 62, 1462, 62, 16159, 7, 14751, 13, 36020, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 15772, 62, 41007, 291, 62, 1462, 62, 16159, 7, 14751, 13, 22649, 11, 288, 559, 11, 267, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 15772, 62, 41007, 291, 62, 1462, 62, 16159, 0, 7, 79, 535, 66, 11, 288, 559, 11, 267, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 279, 535, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 5377, 5165, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1976, 796, 352, 13, 20, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 43879, 2624, 11, 513, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 796, 43720, 7, 43879, 2624, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 14364, 796, 299, 1635, 334, 1, 76, 61, 12, 18, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 285, 796, 4866, 7, 77, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 386, 24900, 79, 796, 47527, 25, 1930, 11, 352, 828, 357, 25, 626, 11, 352, 828, 357, 25, 77, 11, 532, 18, 15437, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 785, 796, 257, 764, 9, 357, 16, 1343, 1976, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 785, 796, 35851, 764, 9, 357, 16, 1343, 1976, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 785, 796, 299, 764, 9, 357, 16, 1343, 1976, 8, 61, 12, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 14364, 785, 796, 14364, 764, 9, 357, 16, 1343, 1976, 8, 61, 12, 18, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 34411, 796, 257, 24457, 357, 16, 1343, 1976, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 25689, 893, 796, 35851, 24457, 357, 16, 1343, 1976, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 34411, 796, 299, 24457, 357, 16, 1343, 1976, 8, 61, 12, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 14364, 34411, 796, 14364, 24457, 357, 16, 1343, 1976, 8, 61, 12, 18, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 955, 5165, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 77, 796, 299, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 22208, 796, 285, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 764, 9, 16932, 13, 31412, 62, 1462, 62, 785, 5165, 7, 89, 11, 352, 8, 15139, 230, 257, 785, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 299, 764, 9, 16932, 13, 31412, 62, 1462, 62, 785, 5165, 7, 89, 11, 532, 18, 8, 15139, 230, 299, 785, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 257, 764, 9, 16932, 13, 31412, 62, 1462, 62, 42854, 7, 89, 11, 352, 8, 15139, 230, 257, 34411, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 299, 764, 9, 16932, 13, 31412, 62, 1462, 62, 42854, 7, 89, 11, 532, 18, 8, 15139, 230, 299, 34411, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 284, 62, 785, 5165, 7, 79, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 15139, 230, 257, 785, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 77, 15139, 230, 299, 785, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 15139, 230, 285, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 785, 5165, 0, 7, 79, 535, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 284, 62, 42854, 7, 79, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 15139, 230, 257, 34411, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 77, 15139, 230, 299, 34411, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 15139, 230, 285, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 42854, 0, 7, 79, 535, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 35851, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 77, 796, 14364, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 22208, 796, 285, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 284, 62, 785, 5165, 7, 79, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 15139, 230, 35851, 785, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 77, 15139, 230, 14364, 785, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 15139, 230, 285, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 785, 5165, 0, 7, 79, 535, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 284, 62, 42854, 7, 79, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 15139, 230, 257, 25689, 893, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 77, 15139, 230, 14364, 34411, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 15139, 230, 285, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 42854, 0, 7, 79, 535, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 40653, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 955, 5165, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 1930, 796, 4866, 7, 559, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 77, 796, 4866, 7, 77, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 22208, 796, 4866, 7, 76, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 1930, 796, 4866, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 77, 796, 4866, 7, 28803, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 13, 22208, 796, 4866, 7, 76, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2297, 30846, 7841, 1548, 36307, 7, 89, 11, 288, 76, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 284, 62, 785, 5165, 7, 14751, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 284, 62, 785, 5165, 7, 36020, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 284, 62, 785, 5165, 7, 22649, 11, 1976, 26, 386, 24900, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 785, 5165, 0, 7, 79, 535, 66, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 279, 535, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 284, 62, 42854, 7, 14751, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 284, 62, 42854, 7, 36020, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 284, 62, 42854, 7, 22649, 11, 1976, 26, 386, 24900, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 42854, 0, 7, 79, 535, 66, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 279, 535, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 279, 535, 66, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 284, 62, 785, 5165, 7, 499, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 284, 62, 42854, 7, 499, 11, 1976, 26, 386, 24900, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 785, 5165, 0, 7, 499, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 284, 62, 785, 5165, 7, 14751, 26, 386, 24900, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 66, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 279, 535, 66, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 284, 62, 42854, 0, 7, 499, 11, 1976, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 66, 6624, 284, 62, 42854, 7, 14751, 26, 386, 24900, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 198, 220, 220, 220, 2488, 9288, 2617, 366, 44, 2304, 16205, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 2340, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 809, 796, 43720, 7, 3064, 8, 1635, 334, 1, 10025, 1, 628, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 279, 13, 312, 796, 220, 2340, 198, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 4866, 7, 64, 8, 198, 220, 220, 220, 220, 220, 220, 220, 279, 13, 22208, 796, 4866, 7, 11110, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 311, 24707, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 3297, 7, 79, 11, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 9741, 7, 14751, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 312, 6624, 220, 2340, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 2989, 82, 9741, 11085, 7, 14751, 13, 312, 11, 279, 13, 312, 58, 16, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 58, 45299, 773, 60, 6624, 279, 13, 1930, 58, 45299, 352, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 58, 521, 60, 6624, 279, 13, 22208, 58, 16, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 3297, 7, 79, 11, 1058, 22208, 26, 2689, 41888, 25, 22208, 11, 1058, 1930, 4357, 435, 70, 28, 15546, 844, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 9741, 7, 14751, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 7, 14751, 11, 1058, 1930, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 312, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 3297, 7, 79, 11, 1058, 22208, 26, 2689, 41888, 25, 1930, 4357, 435, 70, 28, 15546, 844, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 22208, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3297, 0, 7, 14751, 11, 1058, 312, 26, 435, 70, 28, 15546, 844, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1189, 9741, 7, 14751, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 2989, 82, 9741, 11085, 7, 14751, 13, 312, 11, 279, 13, 312, 58, 16, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 58, 45299, 773, 60, 6624, 279, 13, 1930, 58, 45299, 352, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 58, 521, 60, 6624, 279, 13, 22208, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 311, 24707, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 279, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 11, 2769, 30073, 7, 79, 13, 1676, 862, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 3297, 7, 14751, 11, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 14512, 279, 535, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 3297, 7, 36020, 11, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 3297, 7, 22649, 11, 1058, 312, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 685, 25, 22208, 11, 1058, 1930, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 3297, 7, 14751, 11, 1058, 22208, 26, 2689, 11, 435, 70, 28, 15546, 844, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 3297, 7, 36020, 11, 1058, 22208, 26, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 3297, 7, 22649, 11, 1058, 22208, 26, 2689, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 47527, 25, 36020, 11, 685, 25, 22208, 11, 1058, 1930, 46570, 357, 25, 22649, 11, 685, 25, 22208, 12962, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 3297, 7, 14751, 11, 1058, 22208, 26, 2689, 11, 435, 70, 28, 21063, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 3297, 7, 36020, 11, 1058, 22208, 26, 2689, 41888, 25, 22208, 11, 1058, 1930, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 3297, 7, 22649, 11, 1058, 22208, 26, 2689, 41888, 25, 22208, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3297, 0, 7, 79, 535, 11, 1058, 312, 26, 435, 70, 28, 15546, 844, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 3297, 7, 14751, 11, 1058, 312, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 3297, 7, 499, 11, 1058, 312, 26, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 3297, 0, 7, 499, 11, 1058, 312, 26, 435, 70, 28, 15546, 844, 42758, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 7066, 20212, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2347, 1084, 796, 657, 13, 20, 84, 1, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 8106, 7, 79, 4613, 279, 13, 22208, 764, 29, 2347, 1084, 11, 279, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 14751, 13, 22208, 764, 29, 2347, 1084, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 22208, 6624, 809, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 11085, 7, 33994, 22208, 1084, 828, 279, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 58, 45299, 352, 60, 6624, 279, 13, 1930, 58, 45299, 773, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 312, 58, 16, 60, 6624, 279, 13, 312, 58, 521, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 7, 79, 4613, 1064, 439, 7, 79, 13, 22208, 764, 29, 2347, 1084, 828, 279, 8, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 8106, 7, 79, 4613, 279, 13, 22208, 764, 29, 2347, 1084, 11, 279, 26, 2689, 41888, 25, 312, 11, 1058, 22208, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 14751, 13, 22208, 764, 29, 2347, 1084, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 7, 14751, 11, 1058, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 1930, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8106, 0, 7, 79, 4613, 279, 13, 22208, 764, 29, 2347, 1084, 11, 40653, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 14751, 13, 22208, 764, 29, 2347, 1084, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 13, 22208, 6624, 809, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 11085, 7, 33994, 22208, 1084, 828, 279, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 58, 45299, 352, 60, 6624, 279, 13, 1930, 58, 45299, 773, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 312, 58, 16, 60, 6624, 279, 13, 312, 58, 521, 60, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2340, 62, 86, 4126, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 8106, 7, 79, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 259, 12195, 14751, 13, 312, 11, 357, 2340, 62, 86, 4126, 11, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 1092, 7, 259, 12195, 2617, 26069, 7, 2340, 11, 40653, 13, 312, 828, 357, 2340, 62, 86, 4126, 11, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 11085, 7, 259, 7, 2340, 62, 86, 4126, 828, 279, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 58, 45299, 352, 60, 6624, 279, 13, 1930, 58, 45299, 773, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 58, 16, 60, 6624, 279, 13, 22208, 58, 521, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 7, 79, 26, 220, 2340, 28, 7248, 7, 2340, 62, 86, 4126, 4008, 6624, 40653, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 8106, 7, 79, 26, 220, 2340, 28, 2340, 62, 86, 4126, 11, 2689, 41888, 25, 312, 11, 1058, 22208, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 259, 12195, 14751, 13, 312, 11, 357, 2340, 62, 86, 4126, 11, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 1092, 7, 259, 12195, 2617, 26069, 7, 2340, 11, 40653, 13, 312, 828, 357, 2340, 62, 86, 4126, 11, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 468, 2539, 7, 14751, 11, 1058, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 1930, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8106, 0, 7, 14751, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 259, 12195, 14751, 13, 312, 11, 357, 2340, 62, 86, 4126, 11, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 1092, 7, 259, 12195, 2617, 26069, 7, 2340, 11, 40653, 13, 312, 828, 357, 2340, 62, 86, 4126, 11, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 773, 796, 1064, 11085, 7, 259, 7, 2340, 62, 86, 4126, 828, 279, 13, 312, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 58, 45299, 352, 60, 6624, 279, 13, 1930, 58, 45299, 773, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 22208, 58, 16, 60, 6624, 279, 13, 22208, 58, 521, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 0, 7, 22089, 30073, 7, 79, 1776, 220, 2340, 28, 7248, 7, 2340, 62, 86, 4126, 4008, 6624, 40653, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 7066, 20212, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 279, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 11, 2769, 30073, 7, 79, 13, 1676, 862, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2347, 1084, 796, 657, 13, 20, 84, 1, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 277, 796, 279, 4613, 279, 13, 22208, 764, 29, 2347, 1084, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 69, 11, 40653, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 69, 11, 288, 76, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 7, 79, 4613, 1064, 439, 7, 79, 13, 22208, 764, 29, 2347, 1084, 828, 40653, 8, 6624, 279, 535, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 685, 25, 312, 11, 1058, 22208, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 69, 11, 40653, 26, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 69, 11, 288, 76, 26, 2689, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 47527, 25, 36020, 11, 685, 25, 312, 11, 1058, 22208, 12962, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 69, 11, 40653, 26, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 69, 11, 288, 76, 26, 2689, 41888, 25, 312, 11, 1058, 22208, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 535, 11, 1058, 22649, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8106, 0, 7, 69, 11, 279, 535, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 8106, 7, 69, 11, 40653, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2340, 62, 86, 4126, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 14751, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 36020, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 7, 14751, 26, 220, 2340, 28, 7248, 7, 2340, 62, 86, 4126, 4008, 6624, 279, 535, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 685, 25, 312, 11, 1058, 22208, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 14751, 26, 220, 2340, 28, 2340, 62, 86, 4126, 11, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 36020, 26, 220, 2340, 28, 2340, 62, 86, 4126, 11, 2689, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 47527, 25, 22649, 11, 685, 25, 312, 12962, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 14751, 26, 220, 2340, 28, 2340, 62, 86, 4126, 11, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 535, 11, 1058, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 8106, 7, 22649, 26, 220, 2340, 28, 2340, 62, 86, 4126, 11, 2689, 41888, 25, 312, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8106, 0, 7, 79, 535, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 8106, 7, 79, 535, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 0, 7, 22089, 30073, 7, 14751, 1776, 220, 2340, 28, 7248, 7, 2340, 62, 86, 4126, 4008, 6624, 279, 535, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 8106, 7, 69, 11, 2471, 26, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 8106, 0, 7, 69, 11, 2471, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 8106, 7, 499, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 8106, 0, 7, 499, 26, 220, 2340, 28, 2340, 62, 86, 4126, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 3982, 5165, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2340, 62, 28956, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2340, 62, 14894, 796, 900, 26069, 7, 16, 25, 12825, 11, 220, 2340, 62, 28956, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 62, 9122, 796, 8106, 7, 79, 26, 220, 2340, 28, 2340, 62, 14894, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 12233, 7, 79, 26, 220, 2340, 28, 2340, 62, 28956, 8, 6624, 40653, 62, 9122, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 12233, 7, 79, 26, 220, 2340, 28, 7248, 7, 2340, 62, 28956, 4008, 6624, 40653, 62, 9122, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 12233, 7, 79, 26, 220, 2340, 28, 2340, 62, 28956, 11, 2689, 41888, 25, 312, 11, 1058, 22208, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 6624, 8106, 7, 79, 26, 220, 2340, 28, 2340, 62, 14894, 11, 2689, 41888, 25, 312, 11, 1058, 22208, 12962, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 12233, 0, 7, 14751, 26, 220, 2340, 28, 2340, 62, 28956, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 6624, 40653, 62, 9122, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 12233, 0, 7, 22089, 30073, 7, 79, 1776, 220, 2340, 28, 7248, 7, 2340, 62, 28956, 4008, 6624, 40653, 62, 9122, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 1548, 12251, 3982, 5165, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 279, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 11, 2769, 30073, 7, 79, 13, 1676, 862, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2340, 62, 28956, 796, 6291, 7, 16, 25, 12825, 11, 1802, 26, 6330, 28, 9562, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 12233, 7, 14751, 26, 220, 2340, 28, 2340, 62, 28956, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 12233, 7, 36020, 26, 220, 2340, 28, 2340, 62, 28956, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 12233, 7, 14751, 26, 220, 2340, 28, 7248, 7, 2340, 62, 28956, 4008, 6624, 279, 535, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 685, 25, 312, 11, 1058, 22208, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 12233, 7, 14751, 26, 220, 2340, 28, 2340, 62, 28956, 11, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 12233, 7, 36020, 26, 220, 2340, 28, 2340, 62, 28956, 11, 2689, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2689, 796, 47527, 25, 22649, 11, 685, 25, 312, 12962, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 12233, 7, 14751, 26, 220, 2340, 28, 2340, 62, 28956, 11, 2689, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 535, 11, 1058, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 22649, 6624, 12233, 7, 22649, 26, 220, 2340, 28, 2340, 62, 28956, 11, 2689, 41888, 25, 312, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 12233, 0, 7, 79, 535, 26, 220, 2340, 28, 2340, 62, 28956, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 12233, 7, 79, 535, 26, 220, 2340, 28, 2340, 62, 28956, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 12233, 0, 7, 22089, 30073, 7, 14751, 1776, 220, 2340, 28, 7248, 7, 2340, 62, 28956, 4008, 6624, 279, 535, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 35528, 12233, 7, 499, 26, 220, 2340, 28, 2340, 62, 28956, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 35528, 12233, 0, 7, 499, 26, 220, 2340, 28, 2340, 62, 28956, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 220, 220, 220, 2488, 9288, 2617, 366, 10082, 15748, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 1303, 2251, 6616, 14, 40296, 14, 49229, 40296, 286, 6116, 1022, 657, 290, 352, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 17, 796, 27179, 1758, 7, 29993, 2024, 13, 11167, 7, 15, 25, 15, 13, 16, 25, 16, 11, 657, 25, 15, 13, 16, 25, 16, 8, 930, 29, 2824, 11, 14373, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 17, 796, 4646, 7, 71, 9246, 11, 651, 9630, 12195, 1930, 17, 11, 1312, 8, 329, 1312, 287, 1123, 9630, 7, 1930, 17, 58, 16, 60, 4008, 6, 628, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 796, 27179, 1758, 7, 29993, 2024, 13, 11167, 7, 15, 25, 15, 13, 16, 25, 16, 11, 657, 25, 15, 13, 16, 25, 16, 11, 657, 25, 15, 13, 16, 25, 16, 8, 930, 29, 2824, 11, 14373, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 796, 4646, 7, 71, 9246, 11, 651, 9630, 12195, 1930, 18, 11, 1312, 8, 329, 1312, 287, 1123, 9630, 7, 1930, 18, 58, 16, 60, 4008, 6, 628, 220, 220, 220, 220, 220, 220, 220, 1426, 19, 796, 27179, 1758, 7, 29993, 2024, 13, 11167, 7, 15, 25, 15, 13, 16, 25, 16, 11, 657, 25, 15, 13, 16, 25, 16, 11, 657, 25, 15, 13, 16, 25, 16, 11, 657, 25, 15, 13, 16, 25, 16, 8, 930, 29, 2824, 11, 14373, 198, 220, 220, 220, 220, 220, 220, 220, 1426, 19, 796, 4646, 7, 71, 9246, 11, 651, 9630, 12195, 1930, 19, 11, 1312, 8, 329, 1312, 287, 1123, 9630, 7, 1930, 19, 58, 16, 60, 4008, 6, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 38197, 2554, 9248, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2554, 796, 10437, 5908, 38197, 2554, 9248, 7, 15, 13, 20, 25192, 7, 19, 828, 657, 13, 20, 7, 16, 764, 10, 43720, 7, 19, 22305, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2554, 318, 64, 10437, 5908, 38197, 2554, 9248, 90, 43879, 2414, 11, 19, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2554, 796, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 11, 657, 60, 764, 1003, 1802, 11, 685, 1314, 11, 1679, 11, 1160, 60, 764, 1003, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2554, 318, 64, 10437, 5908, 38197, 2554, 9248, 90, 43879, 2414, 11, 18, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2554, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 5678, 8718, 2554, 27787, 422, 3641, 290, 1735, 20428, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 26933, 2425, 11, 13151, 11, 1802, 60, 764, 1003, 8576, 11, 29565, 1314, 11, 1679, 11, 1160, 60, 764, 1003, 1802, 8, 23029, 6624, 289, 2554, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 43632, 1868, 26933, 2425, 11, 13151, 11, 1802, 60, 764, 1003, 8576, 11, 29565, 1314, 11, 1679, 11, 1160, 60, 764, 1003, 1802, 8, 23029, 6624, 289, 2554, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 45474, 9248, 26933, 2425, 11, 13151, 60, 764, 1003, 8576, 11, 29565, 1314, 11, 1679, 60, 764, 1003, 1802, 8, 23029, 6624, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 10437, 5908, 45474, 9248, 26933, 15, 11, 657, 60, 764, 1003, 1802, 11, 685, 1314, 11, 1679, 60, 764, 1003, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1332, 5678, 669, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 90, 43879, 2414, 11, 18, 92, 26933, 15, 11, 657, 11, 657, 13, 15, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 90, 43879, 2414, 11, 18, 92, 26933, 15, 11, 657, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 352, 3373, 838, 12962, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 38197, 2554, 9248, 90, 43879, 2414, 11, 19, 92, 26933, 15, 11, 657, 11, 657, 13, 15, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 43632, 1868, 26933, 15, 11, 657, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 43632, 1868, 26933, 15, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 45474, 9248, 26933, 15, 11, 657, 4357, 685, 15, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 45474, 9248, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 45474, 9248, 26933, 15, 11, 657, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 45474, 9248, 26933, 15, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 26933, 15, 11, 657, 11, 657, 13, 15, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 43632, 1868, 90, 43879, 2624, 92, 26933, 15, 11, 657, 11, 657, 4357, 685, 15, 13, 1314, 11, 657, 13, 1495, 11, 352, 3373, 838, 12962, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2624, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 45474, 9248, 90, 43879, 2414, 92, 26933, 15, 11, 657, 13, 15, 4357, 685, 15, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 45474, 9248, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 45474, 9248, 90, 43879, 2414, 92, 26933, 15, 11, 657, 4357, 685, 15, 13, 1495, 11, 657, 13, 1238, 12962, 318, 64, 10437, 5908, 45474, 9248, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 4357, 657, 13, 1314, 11, 657, 13, 1495, 8, 318, 64, 10437, 5908, 45474, 9248, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 11, 657, 4357, 657, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 8, 318, 64, 10437, 5908, 43632, 1868, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 11, 657, 11, 657, 4357, 657, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 11, 657, 13, 4051, 8, 318, 64, 10437, 5908, 38197, 2554, 9248, 90, 43879, 2414, 11, 19, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 35528, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 4357, 657, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 4051, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 796, 642, 3373, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38197, 40296, 26933, 15, 11, 657, 11, 657, 11, 657, 4357, 374, 8, 6624, 10437, 5908, 38197, 2554, 9248, 26933, 12, 81, 11, 532, 81, 11, 532, 81, 11, 532, 81, 4357, 685, 81, 11, 374, 11, 374, 11, 374, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 29071, 26933, 15, 11, 657, 11, 657, 4357, 374, 8, 6624, 10437, 5908, 43632, 1868, 26933, 12, 81, 11, 532, 81, 11, 532, 81, 4357, 685, 81, 11, 374, 11, 374, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 48011, 26933, 15, 11, 657, 4357, 374, 8, 6624, 10437, 5908, 45474, 9248, 26933, 12, 81, 11, 532, 81, 4357, 685, 81, 11, 374, 12962, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 13617, 1868, 796, 10437, 5908, 43632, 1868, 26933, 15, 11, 657, 11, 657, 60, 764, 1003, 1802, 11, 685, 1314, 11, 1679, 11, 678, 60, 764, 1003, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 66, 549, 1868, 8, 15139, 230, 685, 1314, 11, 1679, 11, 678, 60, 764, 1003, 939, 930, 29, 12178, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 36734, 5908, 29071, 7, 9107, 418, 7, 5317, 11, 513, 828, 604, 3373, 352, 4008, 6624, 1976, 27498, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 8697, 13, 469, 15748, 62, 268, 565, 2752, 62, 20772, 364, 7, 66, 549, 1868, 8, 764, 35705, 230, 357, 9107, 418, 7, 18, 828, 685, 1314, 11, 1679, 11, 678, 60, 764, 1003, 1802, 930, 29, 12178, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 259, 796, 1426, 18, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 13617, 1868, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 15, 764, 35705, 97, 1426, 18, 259, 58, 16, 11, 1058, 60, 764, 35705, 97, 657, 13, 1314, 8, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 15, 764, 35705, 97, 1426, 18, 259, 58, 17, 11, 1058, 60, 764, 35705, 97, 657, 13, 1495, 8, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 15, 764, 35705, 97, 1426, 18, 259, 58, 18, 11, 1058, 60, 764, 35705, 97, 657, 13, 1129, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 13621, 796, 10437, 5908, 45474, 9248, 26933, 15, 11, 657, 60, 764, 1003, 1802, 11, 685, 1495, 11, 678, 60, 764, 1003, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 17, 259, 796, 1426, 17, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 17, 11, 13621, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 15, 764, 35705, 97, 1426, 17, 259, 58, 16, 11, 1058, 60, 764, 35705, 97, 657, 13, 1495, 8, 11405, 477, 7, 15, 764, 35705, 97, 1426, 17, 259, 58, 17, 11, 1058, 60, 764, 35705, 97, 657, 13, 1129, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2554, 796, 10437, 5908, 38197, 2554, 9248, 26933, 15, 11, 657, 11, 657, 11, 657, 60, 764, 1003, 1802, 11, 685, 1314, 11, 1679, 11, 678, 11, 3439, 60, 764, 1003, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 19, 259, 796, 1426, 19, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 19, 11, 289, 2554, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 15, 764, 35705, 97, 1426, 19, 259, 58, 16, 11, 1058, 60, 764, 35705, 97, 657, 13, 1314, 8, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 15, 764, 35705, 97, 1426, 19, 259, 58, 17, 11, 1058, 60, 764, 35705, 97, 657, 13, 1495, 8, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 15, 764, 35705, 97, 1426, 19, 259, 58, 18, 11, 1058, 60, 764, 35705, 97, 657, 13, 1129, 8, 11405, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 477, 7, 15, 764, 35705, 97, 1426, 19, 259, 58, 19, 11, 1058, 60, 764, 35705, 97, 657, 13, 2327, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 289, 2554, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 49926, 364, 79, 1456, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2777, 1456, 796, 10437, 5908, 49926, 364, 79, 1456, 7, 15, 13, 20, 25192, 7, 19, 828, 657, 13, 20, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2777, 1456, 318, 64, 10437, 5908, 49926, 364, 79, 1456, 90, 43879, 2414, 11, 19, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2777, 1456, 796, 10437, 5908, 49926, 364, 79, 1456, 26933, 15, 11, 657, 11, 657, 60, 764, 1003, 1802, 11, 1315, 3373, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2777, 1456, 318, 64, 10437, 5908, 49926, 364, 79, 1456, 90, 43879, 2414, 11, 18, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2777, 1456, 318, 64, 10437, 5908, 38882, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 289, 2777, 1456, 6624, 10437, 5908, 49926, 364, 79, 1456, 26933, 15, 11, 657, 11, 657, 4357, 1315, 3373, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 1332, 5678, 669, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 49926, 364, 79, 1456, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 362, 8, 318, 64, 10437, 5908, 38882, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 49926, 364, 79, 1456, 90, 43879, 2414, 11, 18, 92, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 318, 64, 10437, 5908, 38882, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 49926, 364, 79, 1456, 90, 43879, 2624, 11, 18, 92, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 318, 64, 10437, 5908, 38882, 90, 43879, 2624, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 49926, 364, 79, 1456, 90, 43879, 2414, 11, 19, 92, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38882, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 318, 64, 10437, 5908, 38882, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 38882, 26933, 15, 13, 1314, 11, 657, 13, 1495, 4357, 657, 13, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 31560, 293, 26933, 15, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 318, 64, 10437, 5908, 31560, 293, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 31560, 293, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38882, 90, 43879, 2414, 92, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 318, 64, 10437, 5908, 38882, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38882, 90, 43879, 2624, 92, 26933, 15, 13, 1314, 11, 657, 13, 1495, 11, 657, 13, 1238, 4357, 352, 8, 318, 64, 10437, 5908, 38882, 90, 43879, 2624, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 31560, 293, 90, 43879, 2414, 92, 26933, 15, 13, 1495, 11, 657, 13, 1238, 4357, 657, 13, 17, 8, 318, 64, 10437, 5908, 31560, 293, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 796, 1105, 3373, 1802, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3641, 796, 685, 940, 11, 1160, 11, 1542, 60, 764, 1003, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16558, 796, 10437, 5908, 38882, 7, 16159, 11, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 2777, 1456, 8, 15139, 230, 3641, 930, 29, 12178, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 20772, 364, 7, 2777, 1456, 8, 764, 35705, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29565, 12, 17, 11, 807, 11, 1248, 60, 764, 1003, 1802, 930, 29, 12178, 11, 685, 1828, 11, 3933, 11, 5433, 60, 764, 1003, 1802, 930, 29, 12178, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 259, 796, 1426, 18, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 16558, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 18, 259, 764, 12, 3641, 26, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 1662, 259, 796, 1426, 18, 58, 45299, 764, 93, 8697, 13, 27932, 62, 259, 7, 1930, 18, 11, 16558, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 18, 1662, 259, 764, 12, 3641, 26, 5391, 82, 28, 16, 8, 764, 29, 374, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3641, 796, 685, 1238, 11, 1542, 60, 764, 1003, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9197, 796, 10437, 5908, 31560, 293, 7, 16159, 11, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 17, 259, 796, 1426, 17, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 17, 11, 9197, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 17, 259, 764, 12, 3641, 26, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3641, 796, 685, 940, 11, 1160, 11, 1542, 11, 2319, 60, 764, 1003, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2777, 1456, 796, 10437, 5908, 49926, 364, 79, 1456, 7, 16159, 11, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 19, 259, 796, 1426, 19, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 19, 11, 289, 2777, 1456, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 19, 259, 764, 12, 3641, 26, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16558, 796, 10437, 5908, 38882, 7, 9107, 418, 7, 18, 828, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 38882, 7, 81, 8, 6624, 16558, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 259, 796, 1426, 18, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 16558, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 18, 259, 26, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9197, 796, 10437, 5908, 31560, 293, 7, 9107, 418, 7, 17, 828, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 31560, 293, 7, 81, 8, 6624, 9197, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 17, 259, 796, 1426, 17, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 17, 11, 9197, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 17, 259, 26, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 2777, 1456, 796, 10437, 5908, 49926, 364, 79, 1456, 7, 9107, 418, 7, 19, 828, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 49926, 364, 79, 1456, 7, 19, 11, 374, 8, 6624, 289, 2777, 1456, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 19, 259, 796, 1426, 19, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 19, 11, 289, 2777, 1456, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 16345, 7, 8937, 17, 11, 1426, 19, 259, 26, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 289, 2777, 1456, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 34, 2645, 5540, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 629, 2645, 796, 10437, 5908, 44196, 34, 2645, 5540, 7, 15, 13, 20, 25192, 7, 18, 828, 657, 13, 20, 11, 657, 13, 20, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 629, 2645, 318, 64, 10437, 5908, 44196, 34, 2645, 5540, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 629, 2645, 796, 10437, 5908, 44196, 34, 2645, 5540, 26933, 16, 11, 362, 11, 513, 60, 764, 1003, 838, 11, 362, 3373, 838, 11, 352, 3373, 838, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 629, 2645, 318, 64, 10437, 5908, 44196, 34, 2645, 5540, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 44196, 34, 2645, 5540, 7, 25192, 7, 18, 828, 352, 11, 352, 3373, 838, 8, 318, 64, 10437, 5908, 44196, 34, 2645, 5540, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 44196, 34, 2645, 5540, 90, 43879, 2624, 92, 7, 25192, 7, 18, 828, 352, 11, 352, 3373, 838, 8, 318, 64, 10437, 5908, 44196, 34, 2645, 5540, 90, 43879, 2624, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 44196, 34, 2645, 5540, 7, 25192, 7, 19, 828, 352, 11, 352, 3373, 838, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3641, 796, 685, 16, 11, 362, 11, 513, 60, 764, 1003, 838, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 289, 796, 1987, 3373, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 796, 1315, 3373, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 629, 2645, 796, 10437, 5908, 44196, 34, 2645, 5540, 7, 16159, 11, 289, 11, 374, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 82, 38801, 8, 15139, 230, 3641, 930, 29, 12178, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 20772, 364, 7, 82, 38801, 8, 764, 35705, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 29565, 12, 20, 11, 642, 11, 1248, 60, 764, 1003, 1802, 930, 29, 12178, 11, 685, 1495, 11, 3439, 11, 5433, 60, 764, 1003, 1802, 930, 29, 12178, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 259, 796, 1426, 18, 58, 45299, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 629, 2645, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2488, 33571, 477, 7, 16345, 7, 8937, 17, 11, 1426, 18, 259, 58, 16, 25, 17, 11, 1058, 60, 764, 12, 3641, 58, 16, 25, 17, 11208, 5391, 82, 28, 16, 8, 764, 35705, 97, 374, 61, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2488, 33571, 477, 7, 1507, 3373, 1802, 764, 35705, 97, 1426, 18, 259, 58, 18, 11, 1058, 60, 764, 35705, 97, 5433, 3373, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1426, 18, 1662, 259, 796, 1426, 18, 58, 45299, 764, 93, 8697, 13, 27932, 62, 259, 7, 1930, 18, 11, 629, 2645, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2488, 33571, 477, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 43030, 7, 16345, 7, 8937, 17, 11, 1426, 18, 1662, 259, 58, 16, 25, 17, 11, 1058, 60, 764, 12, 3641, 58, 16, 25, 17, 11208, 5391, 82, 28, 16, 8, 764, 29, 374, 61, 17, 8, 764, 91, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 1507, 3373, 1802, 764, 29, 1426, 18, 1662, 259, 58, 18, 11, 1058, 12962, 764, 91, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 357, 1930, 18, 1662, 259, 58, 18, 11, 1058, 60, 764, 29, 5433, 3373, 1802, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 16932, 13, 27932, 62, 259, 7, 1930, 17, 11, 629, 2645, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 17327, 796, 10437, 5908, 34, 2645, 5540, 7, 15, 13, 20, 25192, 7, 18, 828, 657, 13, 20, 25192, 7, 18, 828, 657, 13, 20, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 17327, 318, 64, 10437, 5908, 34, 2645, 5540, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 17327, 796, 10437, 5908, 34, 2645, 5540, 26933, 16, 11, 362, 11, 513, 60, 764, 1003, 838, 11, 685, 17, 11, 513, 11, 604, 60, 764, 1003, 838, 11, 352, 3373, 838, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 17327, 318, 64, 10437, 5908, 34, 2645, 5540, 90, 43879, 2414, 92, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 34, 2645, 5540, 7, 25192, 7, 18, 828, 43720, 7, 18, 828, 352, 3373, 838, 8, 318, 64, 10437, 5908, 34, 2645, 5540, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 34, 2645, 5540, 7, 25192, 7, 18, 828, 685, 15, 11, 657, 11, 657, 4357, 352, 3373, 838, 8, 318, 64, 10437, 5908, 34, 2645, 5540, 90, 43879, 2414, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 34, 2645, 5540, 90, 43879, 2624, 92, 7, 25192, 7, 18, 828, 685, 15, 11, 657, 11, 657, 4357, 352, 3373, 838, 8, 318, 64, 10437, 5908, 34, 2645, 5540, 90, 43879, 2624, 92, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 34, 2645, 5540, 7, 25192, 7, 19, 828, 43720, 7, 18, 828, 657, 13, 16, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 34, 2645, 5540, 7, 25192, 7, 18, 828, 43720, 7, 17, 828, 657, 13, 16, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3641, 796, 3641, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 923, 1930, 796, 685, 940, 11, 1160, 11, 1248, 60, 764, 1003, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 1930, 796, 685, 940, 11, 1160, 11, 5433, 60, 764, 1003, 1802, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 796, 374, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 17327, 796, 10437, 5908, 34, 2645, 5540, 7, 9688, 1930, 11, 886, 1930, 11, 374, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 38801, 8, 15139, 230, 3641, 930, 29, 12178, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 8697, 13, 469, 15748, 62, 268, 565, 2752, 62, 20772, 364, 7, 38801, 8, 764, 35705, 230, 29565, 12, 20, 11, 642, 11, 1248, 60, 764, 1003, 1802, 11, 685, 1495, 11, 3439, 11, 5433, 60, 764, 1003, 1802, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 826, 9335, 329, 5055, 24911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 629, 2645, 6624, 17327, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 629, 2645, 8, 6624, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 17327, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 16932, 13, 27932, 62, 259, 7, 1930, 17, 11, 17327, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 44196, 34, 2645, 5540, 7, 38801, 8, 6624, 629, 2645, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 34, 2645, 5540, 7, 82, 38801, 8, 6624, 17327, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 976, 1255, 15430, 4738, 923, 290, 886, 2173, 286, 262, 24911, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 16, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 17, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 374, 796, 657, 13, 1314, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 16, 796, 10437, 5908, 34, 2645, 5540, 7, 79, 16, 11, 279, 17, 11, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 17, 796, 10437, 5908, 34, 2645, 5540, 7, 79, 17, 11, 279, 16, 11, 374, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 66, 16, 8, 15139, 230, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 16159, 7, 66, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 8697, 13, 469, 15748, 62, 268, 565, 2752, 62, 20772, 364, 7, 66, 16, 8, 764, 35705, 230, 16932, 13, 469, 15748, 62, 268, 565, 2752, 62, 20772, 364, 7, 66, 17, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 269, 16, 8, 6624, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 269, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 2195, 861, 295, 12331, 10437, 5908, 44196, 34, 2645, 5540, 7, 66, 16, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 629, 2645, 796, 10437, 5908, 44196, 34, 2645, 5540, 26933, 16, 11, 362, 11, 513, 60, 764, 1003, 838, 11, 362, 3373, 838, 11, 352, 3373, 838, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 629, 2645, 6624, 10437, 5908, 44196, 34, 2645, 5540, 26933, 16, 11, 362, 11, 513, 60, 764, 1003, 838, 11, 362, 3373, 838, 11, 352, 3373, 838, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 629, 2645, 15139, 230, 10437, 5908, 34, 2645, 5540, 26933, 16, 11, 362, 11, 362, 60, 764, 1003, 838, 11, 685, 16, 11, 362, 11, 604, 60, 764, 1003, 838, 11, 352, 3373, 838, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 10437, 5908, 34, 2645, 5540, 26933, 16, 11, 362, 11, 362, 60, 764, 1003, 838, 11, 685, 16, 11, 362, 11, 604, 60, 764, 1003, 838, 11, 352, 3373, 838, 8, 15139, 230, 629, 2645, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 11928, 20212, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 1930, 796, 1426, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 13, 22208, 796, 43720, 7, 7857, 7, 1930, 18, 11, 362, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 47574, 796, 2142, 2983, 7, 25, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 47574, 13, 1930, 796, 1426, 18, 764, 9, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 47574, 13, 22208, 796, 43720, 7, 7857, 7, 1930, 18, 11, 362, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3641, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 599, 71, 796, 10437, 5908, 38882, 7, 16159, 11, 657, 13, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 599, 13415, 796, 10437, 5908, 38882, 7, 16159, 1635, 334, 1, 76, 1600, 657, 13, 17, 84, 1, 76, 4943, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 9335, 796, 16932, 13, 27932, 62, 259, 7, 1930, 18, 11, 599, 71, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 7, 79, 11, 599, 71, 8, 6624, 279, 58, 27932, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 8106, 7, 19944, 11, 599, 13415, 8, 6624, 47574, 58, 27932, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 8106, 7, 79, 11, 599, 71, 26, 2689, 41888, 25, 1930, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 13, 1930, 6624, 279, 13, 1930, 58, 45299, 9335, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 14751, 11, 1058, 22208, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2769, 30073, 7, 79, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8106, 0, 7, 14751, 11, 599, 71, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 40653, 6624, 279, 58, 27932, 60, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1303, 2142, 1548, 4947, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 279, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 25, 22649, 11, 2769, 30073, 7, 79, 13, 1676, 862, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 40653, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 14751, 11, 599, 71, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 288, 76, 58, 27932, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 14751, 11, 599, 71, 26, 2689, 41888, 25, 1930, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 36020, 11, 599, 71, 26, 2689, 41888, 25, 1930, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 8106, 7, 14751, 11, 599, 71, 26, 2689, 41888, 7, 25, 36020, 11, 685, 25, 1930, 11, 1058, 22208, 12962, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 13, 36020, 6624, 8106, 7, 36020, 11, 599, 71, 26, 2689, 41888, 25, 1930, 11, 1058, 22208, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 5145, 10134, 2539, 7, 79, 535, 11, 1058, 22649, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 535, 796, 2769, 30073, 7, 14751, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8106, 0, 7, 79, 535, 11, 599, 71, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 279, 535, 6624, 8106, 7, 14751, 11, 599, 71, 8, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 40653, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 8106, 7, 499, 11, 599, 71, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 62, 400, 8516, 13047, 16922, 8106, 0, 7, 499, 11, 599, 71, 8, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 628, 198, 220, 220, 220, 2488, 9288, 2617, 366, 2964, 18200, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 35393, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 17, 796, 43720, 7, 17, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 18, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 19, 796, 43720, 7, 19, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 17, 796, 2593, 12195, 27379, 4033, 7, 64, 17, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 18, 796, 2593, 12195, 27379, 4033, 7, 64, 18, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 19, 796, 2593, 12195, 27379, 4033, 7, 64, 19, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 17, 8, 15139, 230, 299, 17, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 18, 8, 15139, 230, 299, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 19, 8, 15139, 230, 299, 19, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 17, 1635, 334, 1, 76, 4943, 15139, 230, 299, 17, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 18, 1635, 334, 1, 76, 4943, 15139, 230, 299, 18, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 19, 1635, 334, 1, 76, 4943, 15139, 230, 299, 19, 1635, 334, 1, 76, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 17, 8, 15139, 230, 299, 17, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 18, 8, 15139, 230, 299, 18, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 19, 8, 15139, 230, 299, 19, 764, 61, 362, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 17, 1635, 334, 1, 76, 4943, 15139, 230, 357, 77, 17, 1635, 334, 1, 76, 4943, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 18, 1635, 334, 1, 76, 4943, 15139, 230, 357, 77, 18, 1635, 334, 1, 76, 4943, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 19, 1635, 334, 1, 76, 4943, 15139, 230, 357, 77, 19, 1635, 334, 1, 76, 4943, 764, 61, 362, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 17, 796, 2092, 7, 64, 17, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 18, 796, 2092, 7, 64, 18, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 19, 796, 2092, 7, 64, 19, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 17, 764, 28, 257, 17, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 18, 764, 28, 257, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 19, 764, 28, 257, 19, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 17, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 18, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 19, 58, 45299, 352, 60, 764, 28, 4814, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 17, 8, 764, 35705, 230, 299, 17, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 18, 8, 764, 35705, 230, 299, 18, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 19, 8, 764, 35705, 230, 299, 19, 8, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 17, 1635, 334, 1, 76, 4943, 764, 35705, 230, 299, 17, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 18, 1635, 334, 1, 76, 4943, 764, 35705, 230, 299, 18, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 19, 1635, 334, 1, 76, 4943, 764, 35705, 230, 299, 19, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 17, 8, 764, 35705, 230, 299, 17, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 18, 8, 764, 35705, 230, 299, 18, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 19, 8, 764, 35705, 230, 299, 19, 764, 61, 362, 8, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 17, 1635, 334, 1, 76, 4943, 764, 35705, 230, 357, 77, 17, 1635, 334, 1, 76, 4943, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 18, 1635, 334, 1, 76, 4943, 764, 35705, 230, 357, 77, 18, 1635, 334, 1, 76, 4943, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 19, 1635, 334, 1, 76, 4943, 764, 35705, 230, 357, 77, 19, 1635, 334, 1, 76, 4943, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 35393, 1088, 19349, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 17, 796, 43720, 7, 17, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 18, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 19, 796, 43720, 7, 19, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 267, 17, 796, 43720, 7, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 267, 18, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 267, 19, 796, 43720, 7, 19, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 17, 796, 2593, 12195, 27379, 4033, 7, 64, 17, 764, 12, 267, 17, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 18, 796, 2593, 12195, 27379, 4033, 7, 64, 18, 764, 12, 267, 18, 4008, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 299, 19, 796, 2593, 12195, 27379, 4033, 7, 64, 19, 764, 12, 267, 19, 4008, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 17, 11, 267, 17, 8, 15139, 230, 299, 17, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 18, 11, 267, 18, 8, 15139, 230, 299, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 19, 11, 267, 19, 8, 15139, 230, 299, 19, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 17, 1635, 334, 1, 76, 1600, 267, 17, 1635, 334, 1, 76, 4943, 15139, 230, 299, 17, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 18, 1635, 334, 1, 76, 1600, 267, 18, 1635, 334, 1, 76, 4943, 15139, 230, 299, 18, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 7, 64, 19, 1635, 334, 1, 76, 1600, 267, 19, 1635, 334, 1, 76, 4943, 15139, 230, 299, 19, 1635, 334, 1, 76, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 17, 11, 267, 17, 8, 15139, 230, 299, 17, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 18, 11, 267, 18, 8, 15139, 230, 299, 18, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 19, 11, 267, 19, 8, 15139, 230, 299, 19, 764, 61, 362, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 17, 1635, 334, 1, 76, 1600, 267, 17, 1635, 334, 1, 76, 4943, 15139, 230, 357, 77, 17, 1635, 334, 1, 76, 4943, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 18, 1635, 334, 1, 76, 1600, 267, 18, 1635, 334, 1, 76, 4943, 15139, 230, 357, 77, 18, 1635, 334, 1, 76, 4943, 764, 61, 362, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 27237, 17, 7, 64, 19, 1635, 334, 1, 76, 1600, 267, 19, 1635, 334, 1, 76, 4943, 15139, 230, 357, 77, 19, 1635, 334, 1, 76, 4943, 764, 61, 362, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 17, 796, 2092, 7, 64, 17, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 18, 796, 2092, 7, 64, 18, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 19, 796, 2092, 7, 64, 19, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 17, 764, 28, 257, 17, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 18, 764, 28, 257, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 19, 764, 28, 257, 19, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 17, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 18, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 19, 58, 45299, 352, 60, 764, 28, 4814, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 17, 11, 267, 17, 8, 764, 35705, 230, 299, 17, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 18, 11, 267, 18, 8, 764, 35705, 230, 299, 18, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 19, 11, 267, 19, 8, 764, 35705, 230, 299, 19, 8, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 17, 1635, 334, 1, 76, 1600, 267, 17, 1635, 334, 1, 76, 4943, 764, 35705, 230, 299, 17, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 18, 1635, 334, 1, 76, 1600, 267, 18, 1635, 334, 1, 76, 4943, 764, 35705, 230, 299, 18, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 7, 321, 19, 1635, 334, 1, 76, 1600, 267, 19, 1635, 334, 1, 76, 4943, 764, 35705, 230, 299, 19, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 17, 11, 267, 17, 8, 764, 35705, 230, 299, 17, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 18, 11, 267, 18, 8, 764, 35705, 230, 299, 18, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 19, 11, 267, 19, 8, 764, 35705, 230, 299, 19, 764, 61, 362, 8, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 17, 1635, 334, 1, 76, 1600, 267, 17, 1635, 334, 1, 76, 4943, 764, 35705, 230, 357, 77, 17, 1635, 334, 1, 76, 4943, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 18, 1635, 334, 1, 76, 1600, 267, 18, 1635, 334, 1, 76, 4943, 764, 35705, 230, 357, 77, 18, 1635, 334, 1, 76, 4943, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 27237, 17, 7, 321, 19, 1635, 334, 1, 76, 1600, 267, 19, 1635, 334, 1, 76, 4943, 764, 35705, 230, 357, 77, 19, 1635, 334, 1, 76, 4943, 764, 61, 362, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 35, 313, 8721, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 17, 796, 43720, 7, 17, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 18, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 19, 796, 43720, 7, 19, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 17, 796, 43720, 7, 17, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 18, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 19, 796, 43720, 7, 19, 11, 1802, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 17, 796, 4646, 7, 71, 9246, 11, 685, 26518, 7, 1872, 11, 3182, 8, 329, 357, 1872, 11, 3182, 8, 287, 19974, 7, 27379, 4033, 7, 64, 17, 828, 1123, 4033, 7, 65, 17, 4008, 12962, 930, 29, 43030, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 18, 796, 4646, 7, 71, 9246, 11, 685, 26518, 7, 1872, 11, 3182, 8, 329, 357, 1872, 11, 3182, 8, 287, 19974, 7, 27379, 4033, 7, 64, 18, 828, 1123, 4033, 7, 65, 18, 4008, 12962, 930, 29, 43030, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 19, 796, 4646, 7, 71, 9246, 11, 685, 26518, 7, 1872, 11, 3182, 8, 329, 357, 1872, 11, 3182, 8, 287, 19974, 7, 27379, 4033, 7, 64, 19, 828, 1123, 4033, 7, 65, 19, 4008, 12962, 930, 29, 43030, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 357, 64, 11, 275, 11, 269, 8, 287, 19974, 26933, 64, 17, 11, 257, 18, 11, 257, 19, 4357, 685, 65, 17, 11, 275, 18, 11, 275, 19, 4357, 685, 66, 17, 11, 269, 18, 11, 269, 19, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4692, 313, 7, 64, 11, 275, 8, 15139, 230, 269, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4692, 313, 7, 64, 1635, 334, 1, 76, 1600, 275, 8, 15139, 230, 269, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4692, 313, 7, 64, 11, 275, 1635, 334, 1, 76, 4943, 15139, 230, 269, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4692, 313, 7, 64, 1635, 334, 1, 76, 1600, 275, 1635, 334, 1, 76, 4943, 15139, 230, 269, 1635, 334, 1, 76, 61, 17, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 796, 2092, 7, 64, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 764, 28, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 796, 2092, 7, 65, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 764, 28, 275, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 58, 45299, 352, 60, 764, 28, 4814, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 36673, 313, 7, 321, 11, 275, 8, 764, 35705, 230, 269, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 36673, 313, 7, 64, 1635, 334, 1, 76, 1600, 275, 76, 8, 764, 35705, 230, 269, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 36673, 313, 7, 64, 11, 275, 76, 1635, 334, 1, 76, 4943, 764, 35705, 230, 269, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 36673, 313, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 8, 764, 35705, 230, 269, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 36673, 313, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 1635, 334, 1, 76, 4943, 764, 35705, 230, 269, 1635, 334, 1, 76, 61, 17, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 796, 2092, 7, 64, 18, 11, 4479, 90, 43879, 2414, 11, 18465, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 764, 28, 257, 18, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 4692, 313, 7, 321, 11, 275, 18, 8, 15139, 230, 269, 18, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 21544, 8721, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 809, 796, 275, 1635, 334, 1, 76, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 269, 796, 4646, 7, 71, 9246, 11, 685, 19692, 7, 1872, 11, 3182, 8, 329, 357, 1872, 11, 3182, 8, 287, 19974, 7, 27379, 4033, 7, 64, 828, 1123, 4033, 7, 65, 4008, 12962, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 19692, 7, 64, 11, 275, 8, 15139, 230, 269, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 19692, 7, 559, 11, 275, 8, 15139, 230, 269, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 19692, 7, 64, 11, 809, 8, 15139, 230, 269, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 19692, 7, 559, 11, 809, 8, 15139, 230, 269, 1635, 334, 1, 76, 61, 17, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 796, 2092, 7, 64, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 764, 28, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 796, 2092, 7, 65, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 764, 28, 275, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 58, 45299, 352, 60, 764, 28, 4814, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 19692, 7, 321, 11, 275, 8, 764, 35705, 230, 269, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 19692, 7, 559, 11, 275, 76, 8, 764, 35705, 230, 269, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 19692, 7, 64, 11, 275, 76, 1635, 334, 1, 76, 4943, 764, 35705, 230, 269, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 19692, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 8, 764, 35705, 230, 269, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 4033, 19692, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 1635, 334, 1, 76, 4943, 764, 35705, 230, 269, 1635, 334, 1, 76, 61, 17, 4943, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 796, 2092, 7, 64, 11, 4479, 90, 43879, 2414, 11, 18465, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 764, 28, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 951, 19692, 7, 321, 11, 275, 8, 15139, 230, 269, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 13450, 934, 12858, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 257, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 796, 43720, 7, 18, 11, 1802, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 35851, 796, 257, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 809, 796, 275, 1635, 334, 1, 76, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 285, 287, 685, 25192, 22784, 43720, 7, 3064, 15437, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 38779, 796, 285, 1635, 334, 1, 10025, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 474, 796, 285, 6, 764, 9, 951, 19692, 7, 64, 11, 275, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 64, 11, 275, 11, 285, 8, 15139, 230, 474, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 275, 11, 285, 8, 15139, 230, 474, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 64, 11, 809, 11, 285, 8, 15139, 230, 474, 1635, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 809, 11, 285, 8, 15139, 230, 474, 1635, 334, 1, 76, 61, 17, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 64, 11, 275, 11, 38779, 8, 15139, 230, 474, 1635, 334, 1, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 275, 11, 38779, 8, 15139, 230, 474, 1635, 334, 1, 76, 9, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 64, 11, 809, 11, 38779, 8, 15139, 230, 474, 1635, 334, 1, 76, 9, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 809, 11, 38779, 8, 15139, 230, 474, 1635, 334, 1, 76, 61, 17, 9, 10025, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 25439, 287, 685, 648, 32542, 83, 313, 11, 3550, 32542, 83, 313, 62, 31284, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 64, 11, 275, 11, 285, 8, 15139, 230, 2160, 7, 73, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 559, 11, 275, 11, 285, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 76, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 64, 11, 809, 11, 285, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 76, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 559, 11, 809, 11, 285, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 76, 61, 17, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 64, 11, 275, 11, 38779, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 559, 11, 275, 11, 38779, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 76, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 64, 11, 809, 11, 38779, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 76, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 559, 11, 809, 11, 38779, 8, 15139, 230, 2160, 7, 73, 1635, 334, 1, 76, 61, 17, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8159, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 11555, 47103, 796, 43720, 7, 18, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 474, 47103, 796, 285, 6, 764, 9, 951, 19692, 7, 64, 764, 12, 8159, 11, 275, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 809, 11, 38779, 26, 8159, 28, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 474, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 7, 559, 11, 809, 11, 38779, 26, 8159, 28, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 2160, 7, 73, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 474, 47103, 796, 285, 6, 764, 9, 951, 19692, 7, 64, 11, 275, 764, 12, 11555, 47103, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 809, 11, 38779, 26, 11555, 47103, 28, 626, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 474, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 7, 559, 11, 809, 11, 38779, 26, 11555, 47103, 28, 626, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 2160, 7, 73, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 62, 31284, 7, 559, 11, 809, 11, 38779, 26, 11555, 47103, 28, 626, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2160, 7, 73, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 474, 47103, 796, 285, 6, 764, 9, 951, 19692, 7, 64, 764, 12, 8159, 11, 275, 764, 12, 11555, 47103, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 559, 11, 809, 11, 38779, 26, 8159, 28, 47103, 1635, 334, 1, 76, 1600, 11555, 47103, 28, 626, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 474, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 7, 559, 11, 809, 11, 38779, 26, 8159, 28, 47103, 1635, 334, 1, 76, 1600, 11555, 47103, 28, 626, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2160, 7, 73, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 8172, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 62, 31284, 7, 559, 11, 809, 11, 38779, 26, 8159, 28, 47103, 1635, 334, 1, 76, 1600, 11555, 47103, 28, 626, 47103, 1635, 334, 1, 76, 4943, 15139, 230, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2160, 7, 73, 47103, 1635, 334, 1, 76, 61, 17, 9, 10025, 8172, 5391, 82, 28, 17, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 796, 2092, 7, 64, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 764, 28, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 58, 45299, 352, 60, 764, 28, 4814, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 796, 2092, 7, 65, 11, 4479, 90, 43879, 2414, 11, 43730, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 764, 28, 275, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 275, 76, 58, 45299, 352, 60, 764, 28, 4814, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 321, 11, 275, 11, 285, 8, 764, 35705, 230, 474, 8, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 559, 11, 275, 76, 11, 285, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 64, 11, 275, 76, 1635, 334, 1, 76, 1600, 285, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 11, 285, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 1635, 334, 1, 76, 1600, 285, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 61, 17, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 321, 11, 275, 11, 38779, 8, 764, 35705, 230, 474, 1635, 334, 1, 10025, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 559, 11, 275, 76, 11, 38779, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 9, 10025, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 64, 11, 275, 76, 1635, 334, 1, 76, 1600, 38779, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 9, 10025, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 11, 38779, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 9, 10025, 4943, 930, 29, 318, 45688, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 477, 7, 648, 32542, 7, 321, 1635, 334, 1, 76, 1600, 275, 76, 1635, 334, 1, 76, 1600, 38779, 8, 764, 35705, 230, 474, 1635, 334, 1, 76, 61, 17, 9, 10025, 4943, 930, 29, 318, 45688, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 796, 2092, 7, 64, 11, 4479, 90, 43879, 2414, 11, 18465, 30072, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 716, 764, 28, 257, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 321, 11, 275, 11, 285, 8, 15139, 230, 474, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 628, 198, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 2617, 366, 7841, 2983, 6608, 1, 2221, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 796, 2142, 2983, 7, 25, 36020, 11, 1058, 1930, 5218, 43720, 7, 18, 11, 1802, 828, 1058, 626, 5218, 43720, 7, 43879, 2624, 11, 513, 11, 1802, 828, 1058, 22208, 5218, 362, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 796, 2142, 2983, 7, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 22649, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 1930, 5218, 43720, 7, 18, 11, 1802, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 626, 5218, 43720, 7, 43879, 2624, 11, 513, 11, 1802, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 22208, 5218, 43720, 7, 3064, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 29510, 5218, 43720, 7, 3064, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 9288, 5218, 352, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1058, 22208, 17, 5218, 27845, 7, 17, 11, 1802, 828, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1267, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 30300, 796, 2769, 30073, 7, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 84, 796, 2769, 30073, 7, 22649, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 30300, 13, 1930, 1635, 28, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 30300, 13, 626, 1635, 28, 334, 1, 13276, 14, 82, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 30300, 13, 22208, 1635, 28, 334, 1, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 84, 13, 1930, 1635, 28, 334, 1, 76, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 84, 13, 626, 1635, 28, 334, 1, 13276, 14, 82, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 84, 13, 22208, 1635, 28, 334, 1, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 84, 13, 22208, 17, 1635, 28, 334, 1, 10025, 1, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 3623, 84, 13, 29510, 1635, 28, 334, 1, 42, 1, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 357, 36020, 11, 3623, 8, 287, 19974, 26933, 36020, 11, 288, 30300, 4357, 685, 22649, 11, 3623, 84, 12962, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 31396, 796, 2142, 1548, 36307, 7, 36020, 11, 3623, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2471, 796, 31396, 13, 439, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 279, 796, 2142, 2983, 7, 499, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 1930, 7, 36020, 8, 6624, 1612, 7, 36020, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 1930, 7, 36020, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 1612, 7, 36020, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 1930, 7, 22649, 8, 15139, 230, 2160, 7, 22649, 13, 1930, 764, 9, 3623, 13, 22208, 17020, 5391, 82, 28, 17, 8, 1220, 2160, 7, 22649, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 1930, 7, 22649, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 1612, 7, 22649, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 1930, 7, 499, 8, 15139, 230, 1612, 1930, 7, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 36020, 11, 1058, 1930, 8, 6624, 1612, 7, 36020, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 1930, 26, 2347, 22930, 28, 25, 22208, 17, 8, 6624, 1612, 7, 22649, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 29510, 8, 15139, 230, 2160, 7, 22649, 13, 29510, 764, 9, 3623, 13, 22208, 8, 1220, 2160, 7, 22649, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 29510, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 1612, 7, 22649, 13, 29510, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 29510, 26, 2347, 22930, 28, 25, 22208, 17, 8, 6624, 1612, 7, 22649, 13, 29510, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 36020, 11, 1058, 22208, 8, 6624, 288, 76, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 36020, 11, 1058, 22208, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 288, 76, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 9288, 8, 6624, 3623, 13, 9288, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 22208, 17, 8, 6624, 3623, 13, 22208, 17, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 22208, 17, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 3623, 13, 22208, 17, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 22649, 11, 1058, 22208, 17, 26, 2347, 22930, 28, 25, 22208, 17, 8, 6624, 3623, 13, 22208, 17, 58, 16, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 22930, 7, 499, 11, 1058, 22208, 8, 15139, 230, 1612, 626, 7, 79, 11, 1058, 22208, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 626, 7, 36020, 8, 6624, 1612, 7, 36020, 13, 626, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 626, 7, 36020, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 1612, 7, 36020, 13, 626, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 626, 7, 22649, 8, 15139, 230, 2160, 7, 22649, 13, 626, 764, 9, 3623, 13, 22208, 17020, 5391, 82, 28, 17, 8, 1220, 2160, 7, 22649, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 626, 7, 22649, 26, 2347, 6551, 276, 28, 9562, 8, 6624, 1612, 7, 22649, 13, 626, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 1612, 626, 7, 499, 8, 15139, 230, 1612, 626, 7, 79, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 264, 931, 1773, 7, 36020, 11, 1058, 1930, 8, 6624, 2160, 7, 36020, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 264, 931, 1773, 7, 22649, 11, 1058, 1930, 8, 6624, 2160, 7, 22649, 13, 1930, 26, 5391, 82, 28, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 264, 931, 1773, 7, 36020, 11, 1058, 22208, 8, 6624, 16932, 13, 3911, 1548, 62, 17618, 7, 36020, 8, 1635, 288, 76, 13, 22208, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 264, 931, 1773, 7, 22649, 11, 1058, 22208, 17, 8, 6624, 2160, 7, 22649, 13, 22208, 17, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 264, 931, 1773, 7, 499, 11, 1058, 1930, 8, 6624, 264, 931, 1773, 7, 79, 11, 1058, 1930, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 36020, 26, 3550, 32542, 22930, 28, 25, 73, 8, 6624, 3550, 32542, 7, 36020, 13, 1930, 11, 288, 76, 13, 626, 11, 288, 76, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 7, 36020, 26, 3550, 32542, 22930, 28, 25, 73, 8, 6624, 3550, 32542, 83, 313, 7, 36020, 13, 1930, 11, 288, 76, 13, 626, 11, 288, 76, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 62, 31284, 7, 36020, 26, 3550, 32542, 22930, 28, 25, 73, 8, 6624, 3550, 32542, 83, 313, 62, 31284, 7, 36020, 13, 1930, 11, 288, 76, 13, 626, 11, 288, 76, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 288, 76, 13, 73, 796, 3550, 32542, 7, 36020, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 36020, 26, 3550, 32542, 22930, 28, 25, 73, 8, 15139, 230, 3550, 32542, 7, 36020, 13, 1930, 11, 288, 76, 13, 626, 11, 288, 76, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 7, 36020, 26, 3550, 32542, 22930, 28, 25, 73, 8, 15139, 230, 3550, 32542, 83, 313, 7, 36020, 13, 1930, 11, 288, 76, 13, 626, 11, 288, 76, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 62, 31284, 7, 36020, 26, 3550, 32542, 22930, 28, 25, 73, 8, 15139, 230, 3550, 32542, 83, 313, 62, 31284, 7, 36020, 13, 1930, 11, 288, 76, 13, 626, 11, 288, 76, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 7, 22649, 26, 3550, 32542, 22930, 28, 25, 73, 8, 6624, 3550, 32542, 7, 22649, 13, 1930, 11, 3623, 13, 626, 11, 3623, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 7, 22649, 26, 3550, 32542, 22930, 28, 25, 73, 8, 6624, 3550, 32542, 83, 313, 7, 22649, 13, 1930, 11, 3623, 13, 626, 11, 3623, 13, 22208, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 3550, 32542, 83, 313, 62, 31284, 7, 22649, 26, 3550, 32542, 22930, 28, 25, 73, 8, 6624, 3550, 32542, 83, 313, 62, 31284, 7, 22649, 13, 1930, 11, 3623, 13, 626, 11, 3623, 13, 22208, 8, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 8159, 796, 362, 1635, 288, 76, 13, 1930, 58, 45299, 352, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 11555, 47103, 796, 362, 1635, 288, 76, 13, 626, 58, 45299, 352, 60, 628, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 329, 25439, 287, 685, 648, 32542, 11, 3550, 32542, 83, 313, 11, 3550, 32542, 83, 313, 62, 31284, 60, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 22649, 26, 8159, 8, 6624, 25439, 7, 22649, 13, 1930, 11, 3623, 13, 626, 11, 3623, 13, 22208, 26, 8159, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 22649, 26, 11555, 47103, 8, 6624, 25439, 7, 22649, 13, 1930, 11, 3623, 13, 626, 11, 3623, 13, 22208, 26, 11555, 47103, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 2488, 9288, 25439, 7, 22649, 26, 8159, 11, 11555, 47103, 8, 6624, 25439, 7, 22649, 13, 1930, 11, 3623, 13, 626, 11, 3623, 13, 22208, 26, 8159, 11, 11555, 47103, 8, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 220, 220, 220, 220, 886, 198, 220, 220, 220, 886, 198, 437, 198 ]
1.752604
38,117
# # Instructions for Assignment06 # # ## Introduction # # Note: this file is runnable in its current state, # but is incomplete. # You can run the file from the command line, # or use the VS Code julia extension to run individual lines. ## To view additional instructions for this assignment, #jl ## see https://wellesley-bisc195.github.io/BISC195.jl/stable/Assignments/assignment06 #jl ## To view a rendered version of this document, #jl ## see https://wellesley-bisc195.github.io/BISC195.jl/stable/Assignments/assignment06_code #jl # ## Question 1 - Reading FASTA files # # A common way to interact with biological sequence data # is in a format called [`FASTA`](https://en.wikipedia.org/wiki/FASTA_format). # This is a very simple format, where each "record" (sequence) contains: # # 1. A "header" line, always starting with `>`, that contains a description of the sequence # 2. The sequence, which can be split across multiple lines # # For example, in the `data/` directory of this assignment, # there is a file called `cov2_genomes.fasta`, # which contains some genome sequences of Sars-CoV2 # isolated from humans early in the pandemic. # Use the shell to take a look at the first 10 lines (`head`) # of the file. # # Now, let's work on building a julia function # to help us use this file. """ count_records(path) Given a path to a `fasta` file, counts and returns the number of records it contains. Example ≡≡≡≡≡≡≡≡≡ julia> count_records("data/cov2_genomes.fasta") 10 """ function count_records(path) ## Your code here. end # Hint - If you're having trouble, the easiest thing to do # is probably to count lines that start with `>`. # ## Question 2 - Split the headers # # It's nice to know the number of records the file contains, # but it's more useful to actually be able to read and store # those records. # # Let's look again at the headers for these sequences. # This can be accomplished from the terminal using `grep`. # The simplest way to use `grep` is with 2 arguments - # the first argument specifies a pattern to look for, # and the second is the path to a file (or group of files). # # `grep` will then print to the screen all of the lines # from the file that match that pattern. # To see all of the header lines, for example, # # ```sh # $ grep '>' data/cov2_genomes.fasta # ``` # # Each header has 3 components, separated by `|` # Write a function that divides the header # into these 3 components, and returns them as a tuple. """ fasta_header(header) Divides a fasta header into its component parts, removing any leading or trailing spaces. Example ≡≡≡≡≡≡≡≡≡ julia> fasta_header(">M0002 |China|Homo sapiens") ("M0002", "China", "Homo sapiens") julia> fasta_header("AAATTC") Error: Invalid header (headers must start with '>') julia> fasta_header(">Another sequence") ("Another sequence",) julia> fasta_header(">headers| can | have| any number | of | info blocks") ("headers", "can", "have", "any number", "of", "info blocks") """ function fasta_header(header) startswith(header, '>') || error("Invalid header (headers must start with '>')") ## Your code here end # A couple of things to note about this function if you're strugling: # # 1. Notice that, even though each header must start with a `>`, # the first item in the returned Tuple should not # 2. The return item should always be a Tuple, even if there's only 1 item # 3. The `split()` function can divide a `String` by a delimeter. # 4. You may need to do some searching on the internet. # ## Question 3 - parse the file # # Alright - let's actually parse the file. # For now, the easiest thing to do # is to return two vectors, # one containing the parsed identifiers as tuples, # and one containing the sequences as strings. # # One thing to keep in mind # is that the sequences in a fasta file # can be spread out over multiple lines, # but they'll be much easier to work with as a single string, # so your function should have a way to join multiple lines # (remember the `join()` function?). # # I've included a few example files in the "data" directory # with some example files to test your functions on. # The examples in the docstring below # assume that your working directory is the assignment directory. """ function parse_fasta(path) Reads a fasta-formated file and returns 2 vectors, one containing parsed headers, the other containing the entire sequence as a `String`. Note: function does not validate DNA sequences for correctness. Example ≡≡≡≡≡≡≡≡≡ julia> ex1 = parse_fasta("data/ex1.fasta"); julia> ex1 isa Tuple true julia> ex1[1] 2-element Array{Tuple{String,String},1}: ("ex1.1", "easy") ("ex1.2", "multiline") julia> ex1[2] 2-element Array{String,1}: "AATTATAGC" "CGCCCCCCAGTCGGATT" julia> ex2 = parse_fasta("data/ex2.fasta"); julia> ex2[1] 4-element Array{Tuple{String,String},1}: ("ex2.1", "oneper") ("ex2.2", "wrong") ("ex2.3", "wronger") ("ex2.4", "wrongest") julia> ex2[2] 4-element Array{String,1}: "ATCCGT" "ATCGTGGaact" "ATCGTGGaact" "this isn't a dna string,but parse it anyway" """ function parse_fasta(path) ## Think through the components you need ## Does it make sense to define any containers at the beginning? ## How will you loop through the file? ## What do you need to get from each line? end # Tips: # # 1. Build the function in parts # - first, see if you can build the vector of headers, # ignoring the sequences # - next, see if you can collect the sequences, # even if they're not joined together properly # 2. Work on pieces of the function in the REPL. # Make sure each expression does what you think it does. # # For example, if you make a `for` loop to go through each line of the file, # add `@info` statements to check the value of each variable # in each loop. # ## Question 4 - Sequence Statistics # # We now have most of the pieces necessary to get some summary statistics # of CoV2 genomes. # Note: You may want to grab some code from previous assignments. # # Calculate the mean sequence length and standard deviation # of the CoV2 geneomes in `data/cov2_genomes.fasta`. ## helper code goes here mean_cov2_length = 0.0 std_cov2_length = 0.0 # Calculate the mean and standard deviation of GC content # of the CoV2 genomes in `data/cov2_genomes.fasta`. # GC content should be a number between 0 and 1. # Note: if you already parsed the fasta file above # and assigned the results to variables, # there's no need to re-parse it. ## helper code goes here mean_cov2_gc = 0.0 std_cov2_gc = 0.0 # ## Bonus Question # # Write a function that will read any proper fasta file # and returns a tuple with the mean and standard deviation # of the sequence length and gc content.
[ 2, 1303, 27759, 329, 50144, 3312, 198, 2, 198, 2, 22492, 22395, 198, 2, 220, 198, 2, 5740, 25, 428, 2393, 318, 1057, 77, 540, 287, 663, 1459, 1181, 11, 198, 2, 475, 318, 17503, 13, 198, 2, 921, 460, 1057, 262, 2393, 422, 262, 3141, 1627, 11, 198, 2, 393, 779, 262, 22269, 6127, 474, 43640, 7552, 284, 1057, 1981, 3951, 13, 198, 198, 2235, 1675, 1570, 3224, 7729, 329, 428, 16237, 11, 1303, 20362, 198, 2235, 766, 3740, 1378, 4053, 49048, 12, 65, 2304, 22186, 13, 12567, 13, 952, 14, 33, 37719, 22186, 13, 20362, 14, 31284, 14, 8021, 570, 902, 14, 562, 16747, 3312, 1303, 20362, 198, 198, 2235, 1675, 1570, 257, 15111, 2196, 286, 428, 3188, 11, 1303, 20362, 198, 2235, 766, 3740, 1378, 4053, 49048, 12, 65, 2304, 22186, 13, 12567, 13, 952, 14, 33, 37719, 22186, 13, 20362, 14, 31284, 14, 8021, 570, 902, 14, 562, 16747, 3312, 62, 8189, 1303, 20362, 198, 198, 2, 22492, 18233, 352, 532, 11725, 376, 1921, 5603, 3696, 198, 2, 220, 198, 2, 317, 2219, 835, 284, 9427, 351, 10685, 8379, 1366, 198, 2, 318, 287, 257, 5794, 1444, 685, 63, 37, 1921, 5603, 63, 16151, 5450, 1378, 268, 13, 31266, 13, 2398, 14, 15466, 14, 37, 1921, 5603, 62, 18982, 737, 198, 2, 770, 318, 257, 845, 2829, 5794, 11, 810, 1123, 366, 22105, 1, 357, 43167, 8, 4909, 25, 198, 2, 220, 198, 2, 352, 13, 317, 366, 25677, 1, 1627, 11, 1464, 3599, 351, 4600, 29, 47671, 326, 4909, 257, 6764, 286, 262, 8379, 198, 2, 362, 13, 383, 8379, 11, 543, 460, 307, 6626, 1973, 3294, 3951, 198, 2, 220, 198, 2, 1114, 1672, 11, 287, 262, 4600, 7890, 14, 63, 8619, 286, 428, 16237, 11, 198, 2, 612, 318, 257, 2393, 1444, 4600, 66, 709, 17, 62, 5235, 2586, 13, 7217, 64, 47671, 198, 2, 543, 4909, 617, 19270, 16311, 286, 311, 945, 12, 7222, 53, 17, 198, 2, 11557, 422, 5384, 1903, 287, 262, 19798, 5314, 13, 198, 2, 5765, 262, 7582, 284, 1011, 257, 804, 379, 262, 717, 838, 3951, 357, 63, 2256, 63, 8, 198, 2, 286, 262, 2393, 13, 198, 2, 220, 198, 2, 2735, 11, 1309, 338, 670, 319, 2615, 257, 474, 43640, 2163, 198, 2, 284, 1037, 514, 779, 428, 2393, 13, 198, 198, 37811, 198, 220, 220, 220, 954, 62, 8344, 3669, 7, 6978, 8, 198, 198, 15056, 257, 3108, 284, 257, 4600, 7217, 64, 63, 2393, 11, 198, 9127, 82, 290, 5860, 262, 1271, 286, 4406, 340, 4909, 13, 198, 198, 16281, 198, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 198, 220, 220, 220, 474, 43640, 29, 954, 62, 8344, 3669, 7203, 7890, 14, 66, 709, 17, 62, 5235, 2586, 13, 7217, 64, 4943, 198, 220, 220, 220, 838, 198, 37811, 198, 8818, 954, 62, 8344, 3669, 7, 6978, 8, 198, 220, 220, 220, 22492, 3406, 2438, 994, 13, 198, 437, 198, 198, 2, 367, 600, 532, 1002, 345, 821, 1719, 5876, 11, 262, 16638, 1517, 284, 466, 198, 2, 318, 2192, 284, 954, 3951, 326, 923, 351, 4600, 29, 44646, 198, 198, 2, 22492, 18233, 362, 532, 27758, 262, 24697, 198, 2, 220, 198, 2, 632, 338, 3621, 284, 760, 262, 1271, 286, 4406, 262, 2393, 4909, 11, 198, 2, 475, 340, 338, 517, 4465, 284, 1682, 307, 1498, 284, 1100, 290, 3650, 198, 2, 883, 4406, 13, 198, 2, 220, 198, 2, 3914, 338, 804, 757, 379, 262, 24697, 329, 777, 16311, 13, 198, 2, 770, 460, 307, 13013, 422, 262, 12094, 1262, 4600, 70, 7856, 44646, 198, 2, 383, 24043, 835, 284, 779, 4600, 70, 7856, 63, 318, 351, 362, 7159, 532, 198, 2, 262, 717, 4578, 26052, 257, 3912, 284, 804, 329, 11, 198, 2, 290, 262, 1218, 318, 262, 3108, 284, 257, 2393, 357, 273, 1448, 286, 3696, 737, 198, 2, 220, 198, 2, 4600, 70, 7856, 63, 481, 788, 3601, 284, 262, 3159, 477, 286, 262, 3951, 198, 2, 422, 262, 2393, 326, 2872, 326, 3912, 13, 198, 2, 1675, 766, 477, 286, 262, 13639, 3951, 11, 329, 1672, 11, 198, 2, 220, 198, 2, 7559, 63, 1477, 198, 2, 720, 42717, 705, 29, 6, 1366, 14, 66, 709, 17, 62, 5235, 2586, 13, 7217, 64, 198, 2, 7559, 63, 198, 2, 220, 198, 2, 5501, 13639, 468, 513, 6805, 11, 11266, 416, 4600, 91, 63, 198, 2, 19430, 257, 2163, 326, 36319, 262, 13639, 198, 2, 656, 777, 513, 6805, 11, 290, 5860, 606, 355, 257, 46545, 13, 198, 198, 37811, 198, 220, 220, 220, 3049, 64, 62, 25677, 7, 25677, 8, 198, 198, 24095, 1460, 257, 3049, 64, 13639, 656, 663, 7515, 3354, 11, 198, 2787, 5165, 597, 3756, 393, 25462, 9029, 13, 198, 198, 16281, 198, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 198, 220, 220, 220, 474, 43640, 29, 3049, 64, 62, 25677, 7, 5320, 44, 34215, 930, 14581, 91, 39, 17902, 31841, 10465, 4943, 198, 220, 220, 220, 5855, 44, 34215, 1600, 366, 14581, 1600, 366, 39, 17902, 31841, 10465, 4943, 628, 220, 220, 220, 474, 43640, 29, 3049, 64, 62, 25677, 7203, 3838, 1404, 4825, 4943, 198, 220, 220, 220, 13047, 25, 17665, 13639, 357, 50145, 1276, 923, 351, 705, 29, 11537, 628, 220, 220, 220, 474, 43640, 29, 3049, 64, 62, 25677, 7, 5320, 6610, 8379, 4943, 198, 220, 220, 220, 5855, 6610, 8379, 1600, 8, 628, 220, 220, 220, 474, 43640, 29, 3049, 64, 62, 25677, 7, 5320, 50145, 91, 460, 930, 423, 91, 597, 1271, 930, 286, 930, 7508, 7021, 4943, 198, 220, 220, 220, 5855, 50145, 1600, 366, 5171, 1600, 366, 14150, 1600, 366, 1092, 1271, 1600, 366, 1659, 1600, 366, 10951, 7021, 4943, 198, 37811, 198, 8818, 3049, 64, 62, 25677, 7, 25677, 8, 198, 220, 220, 220, 923, 2032, 342, 7, 25677, 11, 705, 29, 11537, 8614, 4049, 7203, 44651, 13639, 357, 50145, 1276, 923, 351, 705, 29, 11537, 4943, 628, 220, 220, 220, 22492, 3406, 2438, 994, 198, 437, 198, 198, 2, 317, 3155, 286, 1243, 284, 3465, 546, 428, 2163, 611, 345, 821, 336, 2143, 1359, 25, 198, 2, 220, 198, 2, 352, 13, 17641, 326, 11, 772, 996, 1123, 13639, 1276, 923, 351, 257, 4600, 29, 47671, 198, 2, 220, 220, 220, 262, 717, 2378, 287, 262, 4504, 309, 29291, 815, 407, 198, 2, 362, 13, 383, 1441, 2378, 815, 1464, 307, 257, 309, 29291, 11, 772, 611, 612, 338, 691, 352, 2378, 198, 2, 513, 13, 383, 4600, 35312, 3419, 63, 2163, 460, 14083, 257, 4600, 10100, 63, 416, 257, 1619, 16912, 13, 198, 2, 604, 13, 921, 743, 761, 284, 466, 617, 10342, 319, 262, 5230, 13, 198, 198, 2, 22492, 18233, 513, 532, 21136, 262, 2393, 198, 2, 220, 198, 2, 40967, 532, 1309, 338, 1682, 21136, 262, 2393, 13, 198, 2, 1114, 783, 11, 262, 16638, 1517, 284, 466, 198, 2, 318, 284, 1441, 734, 30104, 11, 220, 198, 2, 530, 7268, 262, 44267, 42814, 355, 12777, 2374, 11, 198, 2, 290, 530, 7268, 262, 16311, 355, 13042, 13, 198, 2, 220, 198, 2, 1881, 1517, 284, 1394, 287, 2000, 198, 2, 318, 326, 262, 16311, 287, 257, 3049, 64, 2393, 198, 2, 460, 307, 4104, 503, 625, 3294, 3951, 11, 198, 2, 475, 484, 1183, 307, 881, 4577, 284, 670, 351, 355, 257, 2060, 4731, 11, 198, 2, 523, 534, 2163, 815, 423, 257, 835, 284, 4654, 3294, 3951, 198, 2, 357, 38947, 262, 4600, 22179, 3419, 63, 2163, 29865, 198, 2, 220, 198, 2, 314, 1053, 3017, 257, 1178, 1672, 3696, 287, 262, 366, 7890, 1, 8619, 198, 2, 351, 617, 1672, 3696, 284, 1332, 534, 5499, 319, 13, 198, 2, 383, 6096, 287, 262, 2205, 8841, 2174, 198, 2, 7048, 326, 534, 1762, 8619, 318, 262, 16237, 8619, 13, 198, 198, 37811, 198, 220, 220, 220, 2163, 21136, 62, 7217, 64, 7, 6978, 8, 198, 198, 5569, 82, 257, 3049, 64, 12, 687, 515, 2393, 290, 5860, 362, 30104, 11, 198, 505, 7268, 44267, 24697, 11, 198, 1169, 584, 7268, 262, 2104, 8379, 355, 257, 4600, 10100, 44646, 198, 198, 6425, 25, 2163, 857, 407, 26571, 7446, 16311, 329, 29409, 13, 198, 198, 16281, 198, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 35705, 94, 198, 220, 220, 220, 474, 43640, 29, 409, 16, 796, 21136, 62, 7217, 64, 7203, 7890, 14, 1069, 16, 13, 7217, 64, 15341, 628, 220, 220, 220, 474, 43640, 29, 409, 16, 318, 64, 309, 29291, 198, 220, 220, 220, 2081, 628, 220, 220, 220, 474, 43640, 29, 409, 16, 58, 16, 60, 198, 220, 220, 220, 362, 12, 30854, 15690, 90, 51, 29291, 90, 10100, 11, 10100, 5512, 16, 38362, 198, 220, 220, 220, 220, 220, 5855, 1069, 16, 13, 16, 1600, 366, 38171, 4943, 198, 220, 220, 220, 220, 220, 5855, 1069, 16, 13, 17, 1600, 366, 16680, 346, 500, 4943, 628, 220, 220, 220, 474, 43640, 29, 409, 16, 58, 17, 60, 198, 220, 220, 220, 362, 12, 30854, 15690, 90, 10100, 11, 16, 38362, 198, 220, 220, 220, 366, 32, 17139, 1404, 4760, 34, 1, 198, 220, 220, 220, 366, 39816, 4093, 4093, 4093, 4760, 4825, 11190, 17139, 1, 628, 220, 220, 220, 474, 43640, 29, 409, 17, 796, 21136, 62, 7217, 64, 7203, 7890, 14, 1069, 17, 13, 7217, 64, 15341, 628, 220, 220, 220, 474, 43640, 29, 409, 17, 58, 16, 60, 198, 220, 220, 220, 604, 12, 30854, 15690, 90, 51, 29291, 90, 10100, 11, 10100, 5512, 16, 38362, 198, 220, 220, 220, 220, 220, 5855, 1069, 17, 13, 16, 1600, 366, 505, 525, 4943, 198, 220, 220, 220, 220, 220, 5855, 1069, 17, 13, 17, 1600, 366, 36460, 4943, 198, 220, 220, 220, 220, 220, 5855, 1069, 17, 13, 18, 1600, 366, 36460, 263, 4943, 198, 220, 220, 220, 220, 220, 5855, 1069, 17, 13, 19, 1600, 366, 36460, 395, 4943, 198, 220, 220, 220, 220, 198, 220, 220, 220, 474, 43640, 29, 409, 17, 58, 17, 60, 198, 220, 220, 220, 604, 12, 30854, 15690, 90, 10100, 11, 16, 38362, 198, 220, 220, 220, 220, 220, 366, 1404, 4093, 19555, 1, 198, 220, 220, 220, 220, 220, 366, 1404, 34, 19555, 11190, 64, 529, 1, 198, 220, 220, 220, 220, 220, 366, 1404, 34, 19555, 11190, 64, 529, 1, 198, 220, 220, 220, 220, 220, 366, 5661, 2125, 470, 257, 288, 2616, 4731, 11, 4360, 21136, 340, 6949, 1, 198, 37811, 198, 8818, 21136, 62, 7217, 64, 7, 6978, 8, 198, 220, 220, 220, 22492, 11382, 832, 262, 6805, 345, 761, 198, 220, 220, 220, 22492, 8314, 340, 787, 2565, 284, 8160, 597, 16472, 379, 262, 3726, 30, 198, 220, 220, 220, 22492, 1374, 481, 345, 9052, 832, 262, 2393, 30, 198, 220, 220, 220, 22492, 1867, 466, 345, 761, 284, 651, 422, 1123, 1627, 30, 198, 437, 198, 198, 2, 27558, 25, 198, 2, 220, 198, 2, 352, 13, 10934, 262, 2163, 287, 3354, 198, 2, 220, 220, 220, 532, 717, 11, 766, 611, 345, 460, 1382, 262, 15879, 286, 24697, 11, 198, 2, 220, 220, 220, 220, 220, 15482, 262, 16311, 198, 2, 220, 220, 220, 532, 1306, 11, 766, 611, 345, 460, 2824, 262, 16311, 11, 198, 2, 220, 220, 220, 220, 220, 772, 611, 484, 821, 407, 5399, 1978, 6105, 198, 2, 362, 13, 5521, 319, 5207, 286, 262, 2163, 287, 262, 45285, 13, 198, 2, 220, 220, 220, 6889, 1654, 1123, 5408, 857, 644, 345, 892, 340, 857, 13, 198, 2, 220, 220, 220, 220, 198, 2, 220, 220, 220, 1114, 1672, 11, 611, 345, 787, 257, 4600, 1640, 63, 9052, 284, 467, 832, 1123, 1627, 286, 262, 2393, 11, 198, 2, 220, 220, 220, 751, 4600, 31, 10951, 63, 6299, 284, 2198, 262, 1988, 286, 1123, 7885, 198, 2, 220, 220, 220, 287, 1123, 9052, 13, 198, 198, 2, 22492, 18233, 604, 532, 45835, 14370, 198, 2, 220, 198, 2, 775, 783, 423, 749, 286, 262, 5207, 3306, 284, 651, 617, 10638, 7869, 198, 2, 286, 1766, 53, 17, 42136, 13, 198, 2, 5740, 25, 921, 743, 765, 284, 5552, 617, 2438, 422, 2180, 25815, 13, 198, 2, 198, 2, 27131, 378, 262, 1612, 8379, 4129, 290, 3210, 28833, 198, 2, 286, 262, 1766, 53, 17, 9779, 2586, 287, 4600, 7890, 14, 66, 709, 17, 62, 5235, 2586, 13, 7217, 64, 44646, 198, 198, 2235, 31904, 2438, 2925, 994, 198, 198, 32604, 62, 66, 709, 17, 62, 13664, 796, 657, 13, 15, 198, 19282, 62, 66, 709, 17, 62, 13664, 796, 657, 13, 15, 198, 198, 2, 27131, 378, 262, 1612, 290, 3210, 28833, 286, 20145, 2695, 198, 2, 286, 262, 1766, 53, 17, 42136, 287, 4600, 7890, 14, 66, 709, 17, 62, 5235, 2586, 13, 7217, 64, 44646, 198, 2, 20145, 2695, 815, 307, 257, 1271, 1022, 657, 290, 352, 13, 198, 2, 5740, 25, 611, 345, 1541, 44267, 262, 3049, 64, 2393, 2029, 198, 2, 290, 8686, 262, 2482, 284, 9633, 11, 198, 2, 612, 338, 645, 761, 284, 302, 12, 29572, 340, 13, 198, 198, 2235, 31904, 2438, 2925, 994, 198, 198, 32604, 62, 66, 709, 17, 62, 36484, 796, 657, 13, 15, 198, 19282, 62, 66, 709, 17, 62, 36484, 796, 657, 13, 15, 198, 198, 2, 22492, 18770, 18233, 198, 2, 220, 198, 2, 19430, 257, 2163, 326, 481, 1100, 597, 1774, 3049, 64, 2393, 198, 2, 290, 5860, 257, 46545, 351, 262, 1612, 290, 3210, 28833, 198, 2, 286, 262, 8379, 4129, 290, 308, 66, 2695, 13, 198 ]
3.042347
2,267
<gh_stars>0 using Test, Pkg using MPI if haskey(Pkg.installed(), "CuArrays") using CuArrays ArrayType = CuArray else ArrayType = Array end MPI.Init() comm = MPI.COMM_WORLD size = MPI.Comm_size(comm) rank = MPI.Comm_rank(comm) for T in Base.uniontypes(MPI.MPIDatatype) # Allocating version a = ArrayType(fill(T(rank), size)) b = MPI.Alltoall(a, 1, comm) @test b isa ArrayType{T} @test b == ArrayType{T}(0:size-1) # Non Allocating version a = ArrayType(fill(T(rank),size)) b = ArrayType{T}(undef, size*1) MPI.Alltoall!(a, b, 1, comm) @test b == ArrayType{T}(0:size-1) # IN_PLACE version a = ArrayType{T}(fill(T(rank),size)) MPI.Alltoall!(MPI.IN_PLACE, a, 1, comm) @test a == ArrayType{T}(0:size-1) end MPI.Finalize() @test MPI.Finalized()
[ 27, 456, 62, 30783, 29, 15, 198, 3500, 6208, 11, 350, 10025, 198, 3500, 4904, 40, 198, 198, 361, 468, 2539, 7, 47, 10025, 13, 37050, 22784, 366, 46141, 3163, 20477, 4943, 198, 220, 220, 220, 1262, 14496, 3163, 20477, 198, 220, 220, 220, 15690, 6030, 796, 14496, 19182, 198, 17772, 198, 220, 220, 220, 15690, 6030, 796, 15690, 198, 437, 198, 198, 7378, 40, 13, 31768, 3419, 198, 198, 9503, 796, 4904, 40, 13, 9858, 44, 62, 45359, 11163, 198, 7857, 796, 4904, 40, 13, 6935, 62, 7857, 7, 9503, 8, 198, 43027, 796, 4904, 40, 13, 6935, 62, 43027, 7, 9503, 8, 198, 198, 1640, 309, 287, 7308, 13, 24592, 19199, 7, 7378, 40, 13, 7378, 2389, 265, 265, 2981, 8, 628, 220, 220, 220, 1303, 1439, 27123, 2196, 198, 220, 220, 220, 257, 796, 15690, 6030, 7, 20797, 7, 51, 7, 43027, 828, 2546, 4008, 198, 220, 220, 220, 275, 796, 4904, 40, 13, 3237, 1462, 439, 7, 64, 11, 352, 11, 725, 8, 198, 220, 220, 220, 2488, 9288, 275, 318, 64, 15690, 6030, 90, 51, 92, 198, 220, 220, 220, 2488, 9288, 275, 6624, 15690, 6030, 90, 51, 92, 7, 15, 25, 7857, 12, 16, 8, 628, 220, 220, 220, 1303, 8504, 1439, 27123, 2196, 198, 220, 220, 220, 257, 796, 15690, 6030, 7, 20797, 7, 51, 7, 43027, 828, 7857, 4008, 198, 220, 220, 220, 275, 796, 15690, 6030, 90, 51, 92, 7, 917, 891, 11, 2546, 9, 16, 8, 198, 220, 220, 220, 4904, 40, 13, 3237, 1462, 439, 0, 7, 64, 11, 275, 11, 352, 11, 725, 8, 198, 220, 220, 220, 2488, 9288, 275, 6624, 15690, 6030, 90, 51, 92, 7, 15, 25, 7857, 12, 16, 8, 628, 220, 220, 220, 1303, 3268, 62, 6489, 11598, 2196, 198, 220, 220, 220, 257, 796, 15690, 6030, 90, 51, 92, 7, 20797, 7, 51, 7, 43027, 828, 7857, 4008, 198, 220, 220, 220, 4904, 40, 13, 3237, 1462, 439, 0, 7, 7378, 40, 13, 1268, 62, 6489, 11598, 11, 257, 11, 352, 11, 725, 8, 198, 220, 220, 220, 2488, 9288, 257, 6624, 15690, 6030, 90, 51, 92, 7, 15, 25, 7857, 12, 16, 8, 198, 437, 198, 198, 7378, 40, 13, 19006, 1096, 3419, 198, 31, 9288, 4904, 40, 13, 19006, 1143, 3419, 198 ]
2.128272
382
<reponame>rcalxrc08/FinancialFFT.jl #TODO: CHANGE NAME function pricer(mcProcess::FinancialMonteCarlo.BaseProcess, zero_rate::FinancialMonteCarlo.AbstractZeroRateCurve, method::LewisMethod, abstractPayoff::FinancialMonteCarlo.EuropeanOption, ::FinancialMonteCarlo.CudaMode) T = abstractPayoff.T K = abstractPayoff.K A = method.A N = method.N S0 = mcProcess.underlying.S0 r = FinancialMonteCarlo.integral(zero_rate.r, T) / T d = FinancialMonteCarlo.integral(FinancialMonteCarlo.dividend(mcProcess), T) / T cf = FinancialFFT.CharactheristicFunction(mcProcess, T) corr = FinancialFFT.CharactheristicExponent(-1im, mcProcess, T) CharFunc(v) = cf(v) * exp(-v * 1im * corr) x__ = log(S0 / K) + (r - d) * T func_(z) = real_mod(exp(-z * 1im * x__) * CharFunc(-z - 1im * 0.5) / (z^2 + 0.25)) int_1 = midpoint_definite_integral_cu(func_, -A, A, N) price = S0 * (1 - exp(-x__ / 2) * int_1 / (2 * pi)) * exp(-d * T) return call_to_put(price, mcProcess.underlying, zero_rate, abstractPayoff) end
[ 27, 7856, 261, 480, 29, 6015, 282, 87, 6015, 2919, 14, 43621, 5777, 51, 13, 20362, 198, 2, 51, 3727, 46, 25, 5870, 27746, 36751, 198, 8818, 778, 16647, 7, 23209, 18709, 3712, 43621, 9069, 660, 9914, 5439, 13, 14881, 18709, 11, 6632, 62, 4873, 3712, 43621, 9069, 660, 9914, 5439, 13, 23839, 28667, 32184, 26628, 303, 11, 2446, 3712, 40330, 17410, 11, 12531, 19197, 2364, 3712, 43621, 9069, 660, 9914, 5439, 13, 22030, 19722, 11, 7904, 43621, 9069, 660, 9914, 5439, 13, 34, 15339, 19076, 8, 198, 220, 220, 220, 309, 796, 12531, 19197, 2364, 13, 51, 198, 220, 220, 220, 509, 796, 12531, 19197, 2364, 13, 42, 198, 220, 220, 220, 317, 796, 2446, 13, 32, 198, 220, 220, 220, 399, 796, 2446, 13, 45, 198, 220, 220, 220, 311, 15, 796, 36650, 18709, 13, 4625, 3157, 13, 50, 15, 198, 220, 220, 220, 374, 796, 11302, 9069, 660, 9914, 5439, 13, 18908, 1373, 7, 22570, 62, 4873, 13, 81, 11, 309, 8, 1220, 309, 198, 220, 220, 220, 288, 796, 11302, 9069, 660, 9914, 5439, 13, 18908, 1373, 7, 43621, 9069, 660, 9914, 5439, 13, 67, 1699, 437, 7, 23209, 18709, 828, 309, 8, 1220, 309, 198, 220, 220, 220, 30218, 796, 11302, 5777, 51, 13, 12441, 529, 372, 2569, 22203, 7, 23209, 18709, 11, 309, 8, 198, 220, 220, 220, 1162, 81, 796, 11302, 5777, 51, 13, 12441, 529, 372, 2569, 16870, 3471, 32590, 16, 320, 11, 36650, 18709, 11, 309, 8, 198, 220, 220, 220, 3178, 37, 19524, 7, 85, 8, 796, 30218, 7, 85, 8, 1635, 1033, 32590, 85, 1635, 352, 320, 1635, 1162, 81, 8, 198, 220, 220, 220, 2124, 834, 796, 2604, 7, 50, 15, 1220, 509, 8, 1343, 357, 81, 532, 288, 8, 1635, 309, 198, 220, 220, 220, 25439, 41052, 89, 8, 796, 1103, 62, 4666, 7, 11201, 32590, 89, 1635, 352, 320, 1635, 2124, 834, 8, 1635, 3178, 37, 19524, 32590, 89, 532, 352, 320, 1635, 657, 13, 20, 8, 1220, 357, 89, 61, 17, 1343, 657, 13, 1495, 4008, 198, 220, 220, 220, 493, 62, 16, 796, 3095, 4122, 62, 4299, 9504, 62, 18908, 1373, 62, 27399, 7, 20786, 62, 11, 532, 32, 11, 317, 11, 399, 8, 198, 220, 220, 220, 2756, 796, 311, 15, 1635, 357, 16, 532, 1033, 32590, 87, 834, 1220, 362, 8, 1635, 493, 62, 16, 1220, 357, 17, 1635, 31028, 4008, 1635, 1033, 32590, 67, 1635, 309, 8, 198, 220, 220, 220, 1441, 869, 62, 1462, 62, 1996, 7, 20888, 11, 36650, 18709, 13, 4625, 3157, 11, 6632, 62, 4873, 11, 12531, 19197, 2364, 8, 198, 437 ]
2.395402
435
<filename>src/dnn/compat.jl<gh_stars>100-1000 # Compatibility shims until users upgrade to new NNlib format function conv!(y::CuArray{T}, x::CuArray{T}, w::CuArray{T}; pad=0, stride=1, flipkernel=0, dilation=1, kwargs...) where {T<:CUDNNFloat} cdims = DenseConvDims(x, w; padding=pad, stride=stride, flipkernel=flipkernel, dilation=dilation) return conv!(y, x, w, cdims; kwargs...) end function ∇conv_filter!(dw::CuArray{T}, dy::CuArray{T}, x::CuArray{T}; pad=0, stride=1, flipkernel=0, dilation=1, kwargs...) where {T<:CUDNNFloat} cdims = DenseConvDims(x, dw; padding=pad, stride=stride, flipkernel=flipkernel, dilation=dilation) # NOTE!!! This compat shim re-arranges the argument order! return ∇conv_filter!(dw, x, dy, cdims; kwargs...) end function maxpool!(y::CuArray{T}, x::CuArray{T}, k; pad=map(_->0,k), stride=k) where {T<:CUDNNFloat} pdims = PoolDims(x, k; padding=pad, stride=stride) return maxpool!(y, x, pdims) end function meanpool!(y::CuArray{T}, x::CuArray{T}, k; pad=map(_->0,k), stride=k) where {T<:CUDNNFloat} pdims = PoolDims(x, k; padding=pad, stride=stride) return meanpool!(y, x, pdims) end
[ 27, 34345, 29, 10677, 14, 67, 20471, 14, 5589, 265, 13, 20362, 27, 456, 62, 30783, 29, 3064, 12, 12825, 198, 2, 46021, 427, 12078, 1566, 2985, 8515, 284, 649, 399, 45, 8019, 5794, 198, 8818, 3063, 0, 7, 88, 3712, 46141, 19182, 90, 51, 5512, 2124, 3712, 46141, 19182, 90, 51, 5512, 266, 3712, 46141, 19182, 90, 51, 19629, 14841, 28, 15, 11, 33769, 28, 16, 11, 14283, 33885, 28, 15, 11, 288, 10520, 28, 16, 11, 479, 86, 22046, 23029, 810, 1391, 51, 27, 25, 34, 8322, 6144, 43879, 92, 198, 220, 220, 220, 22927, 12078, 796, 360, 1072, 3103, 85, 35, 12078, 7, 87, 11, 266, 26, 24511, 28, 15636, 11, 33769, 28, 2536, 485, 11, 14283, 33885, 28, 2704, 541, 33885, 11, 288, 10520, 28, 67, 10520, 8, 198, 220, 220, 220, 1441, 3063, 0, 7, 88, 11, 2124, 11, 266, 11, 22927, 12078, 26, 479, 86, 22046, 23029, 198, 437, 198, 198, 8818, 18872, 229, 42946, 62, 24455, 0, 7, 67, 86, 3712, 46141, 19182, 90, 51, 5512, 20268, 3712, 46141, 19182, 90, 51, 5512, 2124, 3712, 46141, 19182, 90, 51, 19629, 14841, 28, 15, 11, 33769, 28, 16, 11, 14283, 33885, 28, 15, 11, 288, 10520, 28, 16, 11, 479, 86, 22046, 23029, 810, 1391, 51, 27, 25, 34, 8322, 6144, 43879, 92, 198, 220, 220, 220, 22927, 12078, 796, 360, 1072, 3103, 85, 35, 12078, 7, 87, 11, 43756, 26, 24511, 28, 15636, 11, 33769, 28, 2536, 485, 11, 14283, 33885, 28, 2704, 541, 33885, 11, 288, 10520, 28, 67, 10520, 8, 198, 220, 220, 220, 1303, 24550, 10185, 220, 770, 8330, 427, 320, 302, 12, 3258, 6231, 262, 4578, 1502, 0, 198, 220, 220, 220, 1441, 18872, 229, 42946, 62, 24455, 0, 7, 67, 86, 11, 2124, 11, 20268, 11, 22927, 12078, 26, 479, 86, 22046, 23029, 198, 437, 198, 198, 8818, 3509, 7742, 0, 7, 88, 3712, 46141, 19182, 90, 51, 5512, 2124, 3712, 46141, 19182, 90, 51, 5512, 479, 26, 14841, 28, 8899, 28264, 3784, 15, 11, 74, 828, 33769, 28, 74, 8, 810, 1391, 51, 27, 25, 34, 8322, 6144, 43879, 92, 198, 220, 220, 220, 279, 67, 12078, 796, 19850, 35, 12078, 7, 87, 11, 479, 26, 24511, 28, 15636, 11, 33769, 28, 2536, 485, 8, 198, 220, 220, 220, 1441, 3509, 7742, 0, 7, 88, 11, 2124, 11, 279, 67, 12078, 8, 198, 437, 198, 198, 8818, 1612, 7742, 0, 7, 88, 3712, 46141, 19182, 90, 51, 5512, 2124, 3712, 46141, 19182, 90, 51, 5512, 479, 26, 14841, 28, 8899, 28264, 3784, 15, 11, 74, 828, 33769, 28, 74, 8, 810, 1391, 51, 27, 25, 34, 8322, 6144, 43879, 92, 198, 220, 220, 220, 279, 67, 12078, 796, 19850, 35, 12078, 7, 87, 11, 479, 26, 24511, 28, 15636, 11, 33769, 28, 2536, 485, 8, 198, 220, 220, 220, 1441, 1612, 7742, 0, 7, 88, 11, 2124, 11, 279, 67, 12078, 8, 198, 437, 198 ]
2.364754
488