This PR addresses an issue caused by the deprecation of np.product in NumPy version 1.25 and later. In the current codebase, np.product is only used to calculate the total number of possible combinations of factors, so the required modifications are minute.
As of NumPy 1.25.0, np.product has been deprecated, which leads to compatibility issues for projects requiring numpy>=1.22.0. For instance, the tests are not run successfully.
Changes made:
Replaced instances of np.product with np.prod, which is the recommended alternative in NumPy.
Tests:
The existing tests have been executed and pass successfully. No new tests were needed, as this is a straightforward replacement that maintains the same functionality.
This PR addresses an issue caused by the deprecation of
np.product
in NumPy version 1.25 and later. In the current codebase,np.product
is only used to calculate the total number of possible combinations of factors, so the required modifications are minute.As of NumPy 1.25.0,
np.product
has been deprecated, which leads to compatibility issues for projects requiringnumpy>=1.22.0
. For instance, the tests are not run successfully.Changes made:
np.product
withnp.prod
, which is the recommended alternative in NumPy.Tests:
References:
Please review the changes and let me know if any additional modifications are required :)