dotnet / machinelearning

ML.NET is an open source and cross-platform machine learning framework for .NET.
https://dot.net/ml
MIT License
9.05k stars 1.88k forks source link

Use new System.Numerics.Tensors library for DataFrame arithmetic operations (.net8) #7179

Closed asmirnov82 closed 4 months ago

asmirnov82 commented 5 months ago

Use new System.Numerics.Tensors library for DataFrame arithmetic operations (.net8)

Fixes #7178

The aim of this PR to use new library for DataFrame arithmetic operations instead of custom implemtation. At the same time provide backward compatibility for pre-.Net8.0 versions of the package. To achive this, all .,net version specific code is localised in nested private classes of static class Arithmetic that implements IArithmetic<T> interface and are not used directly by any other DataFrame classes

codecov[bot] commented 5 months ago

Codecov Report

Attention: Patch coverage is 0% with 3 lines in your changes missing coverage. Please review.

Project coverage is 68.80%. Comparing base (579fe03) to head (da20f4d). Report is 1 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #7179 +/- ## ========================================== - Coverage 69.06% 68.80% -0.27% ========================================== Files 1401 1267 -134 Lines 268516 259501 -9015 Branches 27812 26910 -902 ========================================== - Hits 185451 178546 -6905 + Misses 75902 74083 -1819 + Partials 7163 6872 -291 ``` | [Flag](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet) | Coverage Δ | | |---|---|---| | [Debug](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet) | `68.80% <0.00%> (-0.27%)` | :arrow_down: | | [production](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet) | `63.07% <0.00%> (-0.58%)` | :arrow_down: | | [test](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet) | `88.96% <ø> (ø)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet) | Coverage Δ | | |---|---|---| | [...ta.Analysis/Computations/Arithmetic.netstandard.cs](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179?src=pr&el=tree&filepath=src%2FMicrosoft.Data.Analysis%2FComputations%2FArithmetic.netstandard.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet#diff-c3JjL01pY3Jvc29mdC5EYXRhLkFuYWx5c2lzL0NvbXB1dGF0aW9ucy9Bcml0aG1ldGljLm5ldHN0YW5kYXJkLmNz) | `45.64% <ø> (ø)` | | | [....Analysis.Tests/DataFrameTests.BinaryOperations.cs](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179?src=pr&el=tree&filepath=test%2FMicrosoft.Data.Analysis.Tests%2FDataFrameTests.BinaryOperations.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet#diff-dGVzdC9NaWNyb3NvZnQuRGF0YS5BbmFseXNpcy5UZXN0cy9EYXRhRnJhbWVUZXN0cy5CaW5hcnlPcGVyYXRpb25zLmNz) | `100.00% <ø> (ø)` | | | [...Microsoft.Data.Analysis/Computations/Arithmetic.cs](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179?src=pr&el=tree&filepath=src%2FMicrosoft.Data.Analysis%2FComputations%2FArithmetic.cs&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet#diff-c3JjL01pY3Jvc29mdC5EYXRhLkFuYWx5c2lzL0NvbXB1dGF0aW9ucy9Bcml0aG1ldGljLmNz) | `57.74% <0.00%> (-6.63%)` | :arrow_down: | ... and [137 files with indirect coverage changes](https://app.codecov.io/gh/dotnet/machinelearning/pull/7179/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dotnet)
ericstj commented 5 months ago

cc @michaelgsharp @tannergooding

JakeRadMSFT commented 4 months ago

/azp run

azure-pipelines[bot] commented 4 months ago
Azure Pipelines successfully started running 2 pipeline(s).