feat_operator_hardmax
Context
Issue : aidge_export_cpp#27 (closed)
Commits
1 : adding hardmax operator
- Hardmax.hpp/cpp
- pybind_Hardmax.hpp
- Test_Hardmax_Op.cpp
2 : enhance main_compare.jinja
Now returns 1 if there is a computation error
Now outputs 1 if there is a difference detected between expected and actual values.
I have accordingly modified the test_export in export_cpp to check the return code of the command : aidge_export_cpp!41 (a881a088)
This implied modification of the run_command()
fctn that now outputs the return code of the bash command.
Upgraded output : now in for of table instead of simply a list
Previous output :
Value : VAL <=> Expected : VAL
Value : VAL <=> Expected : VAL
Value : VAL <=> Expected : VAL
Value : VAL <=> Expected : VAL
Enhanced output
(last column outputs a X when there is a difference between expected & predicted
---------------------------------------------------------------------------------
| Idx | Expected | Predicted | ERROR ? |
|-------------------------------------------------------------------------------|
| 0 | 1.000000 | 1.000000 | |
| 1 | 1.000000 | 1.000000 | |
| 2 | 0.000000 | 0.000000 | |
| 3 | 0.000000 | 0.000000 | |
| 4 | 1.000000 | 1.000000 | |
| 5 | 0.000000 | 0.000000 | |
| 6 | 1.000000 | 1.000000 | |
.....
| 209 | 1.000000 | 1.000000 | |
---------------------------------
| | TOTAL |
|-------------------------------|
| CORRECT | 210 |
| ERROR | 0 |
---------------------------------
Edited by Grégoire Kubler