Skip to content

Commit

Permalink
improve codecov to nice_cov
Browse files Browse the repository at this point in the history
  • Loading branch information
odunbar committed Aug 6, 2024
1 parent 97075cd commit ff6b4d3
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/RandomFeature/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,12 @@ rng = Random.MersenneTwister(seed)
good_cov = shrinkage_cov(samples)
@test (cond(good_cov) < 1.1) && ((good_cov[1] < 1.2) && (good_cov[1] > 0.8))

# test NICE utility
samples = rand(MvNormal(zeros(100), I), 20)
# normal condition number should be huge around 10^18
# nice cov will have improved conditioning, does not perform as well at this task as shrinking so has looser bounds
good_cov = nice_cov(samples)
@test (cond(good_cov) < 100) && ((good_cov[1] < 1.5) && (good_cov[1] > 0.5))

end

Expand Down

0 comments on commit ff6b4d3

Please sign in to comment.