-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
python_builtins: follow python signature
our 'min' and 'max' didn't allow multiple arguments, while Python's does in general we were hesitating whether our min/max/sum should mimic Python's or NumPys. Now it was a mix in the middle... we were somewhat like Python but did np.max() inside (same for sum, messing up the return type); and we didnt yet get to implementing 'axis' like numpy either. With this pull request, I propose that the least confusing thing for people that do `from cpmpy import *` is to not break any existing python code... that is, follow the Python signature of min/max/sum (and fall back to that built-in when no decision variables are given).
- Loading branch information
Showing
1 changed file
with
32 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters