ds4dm / ecole

Extensible Combinatorial Optimization Learning Environments
https://www.ecole.ai
BSD 3-Clause "New" or "Revised" License
325 stars 68 forks source link

NodeBipartite does not normalize row coefficients properly #263

Closed gasse closed 3 years ago

gasse commented 3 years ago

Describe the bug

In the rows Ax <= b returned by NodeBipartite, only b is normalized at the moment. https://github.com/ds4dm/ecole/blob/e9522ef138cd52de3859b15433b02e07cd43f2b2/libecole/src/observation/nodebipartite.cpp#L221 https://github.com/ds4dm/ecole/blob/e9522ef138cd52de3859b15433b02e07cd43f2b2/libecole/src/observation/nodebipartite.cpp#L227

Coefficients in A are returned as-is, without normalization: https://github.com/ds4dm/ecole/blob/e9522ef138cd52de3859b15433b02e07cd43f2b2/libecole/src/observation/nodebipartite.cpp#L324

Expected behavior

In the rows Ax <= b returned by NodeBipartite, both b and A should be normalized by each row's L2 norm.

Additional context

Problem identified here: https://github.com/ds4dm/ml4co-competition/discussions/86#discussioncomment-1451480