Skip to content

Commit

Permalink
changing matlab client test to use gaussian mixture: it provides grad…
Browse files Browse the repository at this point in the history
…ients and is it a wiser choice to test TT and SGMK clients
  • Loading branch information
Lorenzo Tamellini committed Nov 30, 2023
1 parent 172aea5 commit e2bac6e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/client-matlab.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:

services:
model:
image: linusseelinger/benchmark-analytic-funnel:latest
image: linusseelinger/benchmark-analytic-gaussian-mixture:latest
ports:
- 4243:4243

Expand Down
13 changes: 9 additions & 4 deletions testing/clients/TestMatlab.m
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ function testConnection(testCase)
model = HTTPModel(uri,'posterior');

httpValue = model.evaluate([1, 3])
exactValue = -5.147502395904501;
exactValue = -3.176886723809662;
testCase.verifyEqual(httpValue, exactValue, 'RelTol', 1e-14)

end
Expand All @@ -19,17 +19,22 @@ function testApplyJacobian(testCase)
model = HTTPModel(uri,'posterior');

httpValue = model.apply_jacobian([1.0,4.0], [1,3], 0, 0)
exactValue = -3.370206919896928;
exactValue = -6.877474014398787;
testCase.verifyEqual(httpValue, exactValue, 'RelTol', 1e-14)

end

function testBasicExample(testCase)
matlabClient;;
matlabClient;
end

function testTTExample(testCase)
ttClient;;
ttClient;
end

function testSGMKExample(testCase)
sgmkClient;
end

end
end

0 comments on commit e2bac6e

Please sign in to comment.