1
0
mirror of https://github.com/kalmarek/PropertyT.jl.git synced 2024-11-23 00:10:28 +01:00

sparsify both on the forward and backward transform

This commit is contained in:
kalmar 2017-07-26 12:15:31 +02:00
parent 3ff649683a
commit 66f860bac1
2 changed files with 2 additions and 2 deletions

View File

@ -83,7 +83,7 @@ function init_orbit_data(logger, sett::Settings; radius=2)
return 0
end
function transform(U::AbstractArray, V::AbstractArray; sparse=false)
function transform(U::AbstractArray, V::AbstractArray; sparse=true)
if sparse
return sparsify(U'*V*U)
else

View File

@ -123,7 +123,7 @@ function reconstruct_sol{T<:GroupElem, S<:AbstractArray}(mreps::Dict{T, S},
for g in keys(mreps)
A, B = mreps[g], mreps[inv(g)]
for π in 1:length(Us)
recP .+= dims[π].* (A * Us[π]*Ps[π]*Ust[π] * B)
recP .+= sparsify(dims[π].* (A * Us[π]*Ps[π]*Ust[π] * B))
end
end
recP .*= 1/length(keys(mreps))