Skip to content

Commit 242ce9b

Browse files
committed
Updated eps
1 parent f0f7909 commit 242ce9b

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/genplots.jl

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,21 @@ function runplotgen()
88
genplots(funcs, refs)
99
end
1010

11-
@doc """ results = genplots(funcs, refs; kwargs...)
11+
@doc """ results = genplots(funcs, refs; eps, kwargs...)
1212
Generate the plots needed for the tests in ControlSystems.jl
1313
""" ->
14-
function genplots(funcs, refs; eps=1e-3, kwargs...)
14+
function genplots(funcs, refs; eps=0.01*ones(length(refs)), kwargs...)
1515
gadfly()
1616
results = Array(VisualRegressionTests.VisualTestResult, length(refs))
1717
#Run/generate tests
1818
for (i,ref) in enumerate(refs)
1919
testf(fn) = png(funcs[i](), fn)
20-
results[i] = test_images(VisualTest(testf, ref); eps=eps, kwargs...)
20+
results[i] = test_images(VisualTest(testf, ref); eps=eps[i], kwargs...)
2121
end
2222
results
2323
end
2424

25-
@doc """funcs, refs = getexamples()
25+
@doc """funcs, refs, eps = getexamples()
2626
Get the example functions and locations of reference plots needed for the tests in ControlSystems.jl
2727
""" ->
2828
function getexamples()
@@ -60,5 +60,7 @@ function getexamples()
6060
"impulse.png", "lsim.png", "margin.png", "gangoffour.png", "pzmap.png"]
6161
funcs = [bodegen, nyquistgen, sigmagen, nicholsgen, stepgen,
6262
impulsegen, lsimgen, margingen, gangoffourgen, pzmapgen]
63-
funcs, map(s -> plotsdir*s, refs)
63+
eps = 0.01*ones(length(refs));
64+
eps[1] = 0.02; eps[9] = 0.03;
65+
funcs, map(s -> plotsdir*s, refs), eps
6466
end

0 commit comments

Comments
 (0)