Open ev-br opened 10 months ago
I suppose the contract_path
for optimize=False
is a bit ill-defined. The options would be:
path = [range(num_inputs)]
, which would allow contract_path
to be called with the same args as contract
always - probably preferable.What about contract_path=True, should this be equivalent to "auto"?
I would agree contract_path=True
should be equivalent to auto
. It would seem natively to me that contract_path=False
is equivalent to ensue or path = [range(num_inputs)]
.
contract_path
'soptimize
argument is documented asstr, list or bool
, but using bool arguments raises a TypeError:IIUC this is due to https://github.com/dgasmith/opt_einsum/blob/master/opt_einsum/contract.py#L305C1-L307C25:
Granted, this is an edge case and maybe just a documentation issue of not allowing bools in the first place.