Skip to content

Adding a new CI leg for netcoreapp 3.0 - #1700

Merged
Anipik merged 9 commits into
dotnet:masterfrom
Anipik:newci
Nov 28, 2018
Merged

Anipik merged 9 commits into
dotnet:masterfrom
Anipik:newci

Conversation

@Anipik

@Anipik Anipik commented Nov 21, 2018 •

Copy link
Copy Markdown
Contributor

Fixes #1711

@safern
safern self-requested a review November 21, 2018 21:08
Comment thread build/ci/phase-template.yml Outdated
Comment thread init-tools.cmd Outdated
@Anipik Anipik changed the title [WIP] Adding a new CI leg for netcoreapp 3.0 Adding a new CI leg for netcoreapp 3.0 Nov 22, 2018
Comment thread .vsts-dotnet-ci.yml Outdated
@Anipik

Anipik commented Nov 26, 2018

Copy link
Copy Markdown
Contributor Author

@danmosemsft @safern @Ivanidzo4ka @shauheen @tannergooding can please take a look at this pr ?


public static unsafe void MatMul(ReadOnlySpan<float> mat, ReadOnlySpan<float> src, Span<float> dst, int crow, int ccol)
{
Contracts.Assert(crow % 4 == 0);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are these asserts being removed as part of enabling CI?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These asserts are wrong, they were not being tested earlier because contracts.Assert was being removed.

Comment thread test/Microsoft.ML.Core.Tests/UnitTests/TestCSharpApi.cs Outdated
Comment thread test/Microsoft.ML.TestFramework/BaseTestBaseline.cs Outdated

@safern safern left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for the yml changes and script changes.

Comment thread test/Microsoft.ML.Core.Tests/UnitTests/TestCSharpApi.cs Outdated
Comment thread test/Microsoft.ML.TestFramework/BaseTestBaseline.cs Outdated
Comment thread init-tools.cmd Outdated
/// Multiclass Logistic Regression test.
/// </summary>
[Fact]
[ConditionalFact(typeof(BaseTestBaseline), nameof(BaseTestBaseline.NotNetCore30))] // netcore3.0 output differs from Baseline

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Disabling these tests on netcoreapp3.0 feels wrong. What happens when we completely move to .NET Core 3.0? We will then have to spend effort on re-enabling these tests for 3.0.

Is there a way we can investigate why the baselines differ? Rather than just shutting the tests off?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am working on investigating the failures on netcoreapp3.0
I was able to fix some more tests in the aligned Array PR,
I have an issue open with the list of those tests. but we may require some more people to work on it.

Comment thread DotnetCLIVersion.netcoreapp.txt
@Anipik

Anipik commented Nov 27, 2018

Copy link
Copy Markdown
Contributor Author

@eerhardt can you take another look ?

}

[Fact]
[ConditionalFact(typeof(BaseTestBaseline), nameof(BaseTestBaseline.LessThanNetCore30OrNotNetCore))] // netcore3.0 output differs from Baseline

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are we doing to track getting these tests enabled on .net core 3?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i have opened the issue for it #1096

It contains the list of tests that we fixed and ones still remaining

@eerhardt

Copy link
Copy Markdown
Member

Release build is still failing

@Anipik

Anipik commented Nov 27, 2018

Copy link
Copy Markdown
Contributor Author

Release build is still failing

it is due to this change #1724

Comment thread init-tools.cmd

public static unsafe void ScaleSrcU(float scale, ReadOnlySpan<float> src, Span<float> dst, int count)
{
Contracts.Assert(src.Length == dst.Length);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think asserts here are still valuable, aren't they?

Contracts.Assert(count <= src.Length && src.Length <= dst.Length);

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will add the more appropiate asserts with the documentation pr.
I am thinking of an another approach of slicing the span to the required length before passing to these functions and adding the contracts.Assert(src.Length == dst.Length) . Is this approach worth doing ?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO - no I don't think that approach is worth doing. That's why the count parameter is passed to these functions - so the spans don't need to be the same length, and one of the spans isn't chosen as "the one with the right length". It's unnecessary logic to ensure the spans are the same length.

Slicing spans is cheap, but it isn't free. You still have bounds checks to ensure the sliced values are less than the span length.

@eerhardt eerhardt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thanks for doing this work, @Anipik !

@Anipik
Anipik merged commit 3d33e20 into dotnet:master Nov 28, 2018
@Anipik
Anipik deleted the newci branch November 28, 2018 20:59
@ghost ghost locked as resolved and limited conversation to collaborators Mar 26, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants