diff --git a/com.unity.ml-agents/CHANGELOG.md b/com.unity.ml-agents/CHANGELOG.md index 0237b6c34e..3ad6d47a1c 100755 --- a/com.unity.ml-agents/CHANGELOG.md +++ b/com.unity.ml-agents/CHANGELOG.md @@ -20,6 +20,7 @@ and this project adheres to - Fixed a bug when using LSTM and SAC where the buffer might contain non-integer numbers of sequences. (#6301) - Fixed mixed CPU/GPU computation by ensuring tensors share a consistent device in the trainer; Updated training devices. (#6303) - Fix typing on optional strings (#6311) +- Tighten assertion bound for test_process_pixels_gray (#6312) #### Examples - Replace hardcoded value 200f by agentRotationSpeed in MoveAgent() (#6306) diff --git a/ml-agents-envs/tests/test_rpc_utils.py b/ml-agents-envs/tests/test_rpc_utils.py index 8440d6586a..85b75d5450 100644 --- a/ml-agents-envs/tests/test_rpc_utils.py +++ b/ml-agents-envs/tests/test_rpc_utils.py @@ -259,7 +259,7 @@ def test_process_pixels_gray(): byte_arr = generate_compressed_data(in_array) out_array = process_pixels(byte_arr, 1) assert out_array.shape == (1, 128, 64) - assert np.mean(in_array.mean(axis=0, keepdims=True) - out_array) < 0.01 + assert np.mean(in_array.mean(axis=0, keepdims=True) - out_array) < 0.002 assert np.allclose(in_array.mean(axis=0, keepdims=True), out_array, atol=0.01) diff --git a/ml-agents/mlagents/trainers/tests/test_rpc_utils.py b/ml-agents/mlagents/trainers/tests/test_rpc_utils.py index 6599c8948d..574da87714 100644 --- a/ml-agents/mlagents/trainers/tests/test_rpc_utils.py +++ b/ml-agents/mlagents/trainers/tests/test_rpc_utils.py @@ -259,7 +259,7 @@ def test_process_pixels_gray(): byte_arr = generate_compressed_data(in_array) out_array = process_pixels(byte_arr, 1) assert out_array.shape == (1, 128, 64) - assert np.mean(in_array.mean(axis=0, keepdims=True) - out_array) < 0.01 + assert np.mean(in_array.mean(axis=0, keepdims=True) - out_array) < 0.002 assert np.allclose(in_array.mean(axis=0, keepdims=True), out_array, atol=0.01)