mirror of
https://github.com/kalmarek/PropertyT.jl.git
synced 2024-11-19 15:25:29 +01:00
sparsify both on the forward and backward transform
This commit is contained in:
parent
3ff649683a
commit
66f860bac1
@ -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
|
||||
|
@ -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))
|
||||
|
Loading…
Reference in New Issue
Block a user