poly_deg_dtype in the default constructor for and an attribute of MultiIndexSet
Working on Issue #46 gives a good opportunity to clarify some of my own confusion about the code especially regarding its interfaces. Here's one:
The default constructor (__init__
) for a MultiIndexSet instance has the following signature:
def __init__(self, exponents: ARRAY, lp_degree=None, poly_deg_dtype=None)
Is there a particular reason why it may require poly_deg_dtype
(albeit optional)?
Furthermore, the exponents are also required (via np.require
) to be an INT_DTYPE
(btw, it would stealthily convert any non-integer floating arrays into an integer by cutting off the fraction; is this "safe"? I guess, if the input is wrong it should be caught than gracefully continue like this).
Finally, a MultiIndexSet instance also has an attribute of the same name (although it is always set to INT_DTYPE
).
I'm looking for a particular situation somewhere in the code where they are used, i.e., in which an instance constructed with other poly_deg_dtype
or in which the attribute is accessed and used. However, it seems I cannot find any (or?).
Perhaps @hernan68 can help me clarifying this? Thanks in advance!