Commit ca993272 authored by Mian Asbat ahmad's avatar Mian Asbat ahmad

Issue #16: pivot-calibration function updated to return the remaining three values

parent 42b41344
Pipeline #2144 passed with stages
in 10 minutes and 55 seconds
......@@ -105,4 +105,5 @@ def pivot_calibration(matrices4x4):
, x_values[4, 0], ",", x_values[5, 0],
"),residual=", residual_error)
return residual_error, x_values[0, 0], x_values[1, 0], x_values[2, 0]
return residual_error, x_values[0, 0], x_values[1, 0], x_values[2, 0], \
x_values[0, 0], x_values[1, 0], x_values[2, 0]
......@@ -43,7 +43,8 @@ def test_return_value():
matrices = np.concatenate(arrays)
numberOf4x4Matrices = int(matrices.size/16)
matrices4x4 = matrices.reshape(numberOf4x4Matrices, 4, 4)
residual_error, x_value_1, x_value_2, x_value_3 = p.pivot_calibration(matrices4x4)
residual_error, x_value_1, x_value_2, x_value_3, p_value_1, p_value_2, \
p_value_3 = p.pivot_calibration(matrices4x4)
assert 1.838 == round(residual_error, 3)
assert -14.476 == round(x_value_1, 3)
assert 395.143 == round(x_value_2, 3)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment