Bug Title
This bug may be an error/oversight but it might not be
Describe the Bug
There seems to be a shape mismatch issue with the coefficients in the MultiPenaltyLasso class. When fitting the model with non-zero penalties, the coefficients are returned in a shape (features x targets), but it is expected to be (targets x features). This mismatch could lead to confusion or errors when using the model and interpreting the results.
Steps to Reproduce
- Use the
MultiPenaltyLasso class and fit it with mock data where some alpha values are zero.
- Observe the shape of the
coef_ attribute after fitting the model.
- Compare the expected shape (targets x features) vs the actual shape (features x targets).
Expected Behavior
The coefficient matrix should ideally be returned in a shape of (targets x features), especially to align with common conventions in sklearn-like models.
Actual Behavior
The coefficient matrix is returned in a shape of (features x targets), which leads to a mismatch in the tests and may cause confusion when interpreting the model's output.
Environment
OS: Windows 10 Python version: 3.11.7 Dependencies: sklearn, numpy
Additional Context
This issue was discovered during testing when asserting the shape of the coef_ attribute. The tests expect (targets x features), but the model returns (features x targets).
There may need to be either a fix in the code to transpose the coefficients, or clear documentation explaining the output format.
Optional Labels
Bug Title
This bug may be an error/oversight but it might not be
Describe the Bug
There seems to be a shape mismatch issue with the coefficients in the
MultiPenaltyLassoclass. When fitting the model with non-zero penalties, the coefficients are returned in a shape (features x targets), but it is expected to be (targets x features). This mismatch could lead to confusion or errors when using the model and interpreting the results.Steps to Reproduce
MultiPenaltyLassoclass and fit it with mock data where some alpha values are zero.coef_attribute after fitting the model.Expected Behavior
The coefficient matrix should ideally be returned in a shape of (targets x features), especially to align with common conventions in sklearn-like models.
Actual Behavior
The coefficient matrix is returned in a shape of (features x targets), which leads to a mismatch in the tests and may cause confusion when interpreting the model's output.
Environment
OS: Windows 10 Python version: 3.11.7 Dependencies: sklearn, numpy
Additional Context
This issue was discovered during testing when asserting the shape of the
coef_attribute. The tests expect (targets x features), but the model returns (features x targets).There may need to be either a fix in the code to transpose the coefficients, or clear documentation explaining the output format.
Optional Labels