Skip to content

Commit

Permalink
Sort namespaces as per stylecop rules/.net convention and remove unus…
Browse files Browse the repository at this point in the history
…ed namespaces from source files. (#1963)

* Sort namespaces as stylecop rules/.net convention and remove unused namespaces from source files.
  • Loading branch information
codemzs authored Dec 25, 2018
1 parent 80f5720 commit a570da1
Show file tree
Hide file tree
Showing 682 changed files with 1,354 additions and 1,898 deletions.
5 changes: 5 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
root = true

[*.cs]
# Sort using directives with System.* appearing first
dotnet_sort_system_directives_first = true
7 changes: 3 additions & 4 deletions docs/samples/Microsoft.ML.Samples/Dynamic/Calibrator.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
using Microsoft.ML.Calibrator;
using Microsoft.ML;
using Microsoft.ML.Data;
using System;
using System;
using System.Linq;
using Microsoft.ML.Calibrator;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
6 changes: 3 additions & 3 deletions docs/samples/Microsoft.ML.Samples/Dynamic/ConcatTransform.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using Microsoft.ML.Data;
using Microsoft.ML.Transforms;
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.ML.Data;
using Microsoft.ML.Transforms;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using Microsoft.ML.Data;
using System;
using System;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using Microsoft.ML.Data;
using System;
using System;
using Microsoft.ML.Data;
namespace Microsoft.ML.Samples.Dynamic
{
public class FFM_BinaryClassificationExample
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Linq;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
// See the LICENSE file in the project root for more information.

using System;
using System.Linq;
using System.Collections.Generic;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeriesProcessing;
using System.IO;
using System.Linq;
using Microsoft.ML.Core.Data;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeries;
using System.IO;
using Microsoft.ML.TimeSeriesProcessing;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Collections.Generic;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeriesProcessing;
using Microsoft.ML.Core.Data;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeries;
using Microsoft.ML.TimeSeriesProcessing;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
4 changes: 2 additions & 2 deletions docs/samples/Microsoft.ML.Samples/Dynamic/KMeans.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using Microsoft.ML.Data;
using System;
using System;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
6 changes: 3 additions & 3 deletions docs/samples/Microsoft.ML.Samples/Dynamic/KeyToValue_Term.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using Microsoft.ML.Data;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;
using Microsoft.ML.Transforms.Conversions;
using Microsoft.ML.Transforms.Text;
using System;
using System.Collections.Generic;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
4 changes: 2 additions & 2 deletions docs/samples/Microsoft.ML.Samples/Dynamic/LdaTransform.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
4 changes: 2 additions & 2 deletions docs/samples/Microsoft.ML.Samples/Dynamic/NgramExtraction.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
6 changes: 3 additions & 3 deletions docs/samples/Microsoft.ML.Samples/Dynamic/Normalizer.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using Microsoft.ML.Data;
using Microsoft.ML.Transforms.Normalizers;
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.ML.Data;
using Microsoft.ML.Transforms.Normalizers;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
4 changes: 2 additions & 2 deletions docs/samples/Microsoft.ML.Samples/Dynamic/OnnxTransform.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using System;
using System.Linq;
using Microsoft.ML.Data;
using Microsoft.ML.OnnxRuntime;
using Microsoft.ML.Transforms;
using System;
using System.Linq;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using Microsoft.ML.Data;
using System;
using System.Linq;
using Microsoft.ML.Data;
using Microsoft.ML.Learners;
using Microsoft.ML.Trainers.HalLearners;
using System;
using System.Linq;

namespace Microsoft.ML.Samples.Dynamic.PermutationFeatureImportance
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Learners;
using System;
using System;
using System.Linq;
using Microsoft.ML.Learners;

namespace Microsoft.ML.Samples.Dynamic.PermutationFeatureImportance
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
4 changes: 2 additions & 2 deletions docs/samples/Microsoft.ML.Samples/Dynamic/SDCA.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Linq;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
4 changes: 2 additions & 2 deletions docs/samples/Microsoft.ML.Samples/Dynamic/SDCARegression.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System;
using System.Linq;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
using Microsoft.ML.Core.Data;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeriesProcessing;
using Microsoft.ML.TimeSeries;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using Microsoft.ML.Core.Data;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeries;
using Microsoft.ML.TimeSeriesProcessing;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
using Microsoft.ML.Core.Data;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeriesProcessing;
using Microsoft.ML.TimeSeries;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using Microsoft.ML.Core.Data;
using Microsoft.ML.Data;
using Microsoft.ML.TimeSeries;
using Microsoft.ML.TimeSeriesProcessing;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.ML.Data;
using System;
using System.Linq;
using Microsoft.ML.Data;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
6 changes: 3 additions & 3 deletions docs/samples/Microsoft.ML.Samples/Dynamic/TextTransform.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Microsoft.ML.Data;
using Microsoft.ML.Transforms.Text;
using System;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;
using Microsoft.ML.Transforms.Text;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
using Microsoft.ML.Data;
using System;
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;
using Microsoft.ML.Transforms;
using System;

namespace Microsoft.ML.Samples.Static
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
using Microsoft.ML.Data;
using System;
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;
using Microsoft.ML.Transforms;
using System;

namespace Microsoft.ML.Samples.Static
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
using Microsoft.ML.Data;
using Microsoft.ML.Trainers.FastTree;
using Microsoft.ML.StaticPipe;
using System;
using System;
using System.Linq;
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;
using Microsoft.ML.Trainers.FastTree;

namespace Microsoft.ML.Samples.Static
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;
using System;
using System;
using System.Collections.Generic;
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;

namespace Microsoft.ML.Samples.Dynamic
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
using System;
using Microsoft.ML.Data;
using Microsoft.ML.LightGBM.StaticPipe;
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;
using Microsoft.ML.Transforms;
using System;

namespace Microsoft.ML.Samples.Static
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
using Microsoft.ML.LightGBM.StaticPipe;
using Microsoft.ML.Data;
using Microsoft.ML.LightGBM;
using Microsoft.ML.StaticPipe;
using System;
using Microsoft.ML.Data;
using Microsoft.ML.LightGBM;
using Microsoft.ML.LightGBM.StaticPipe;

namespace Microsoft.ML.Samples.Static
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
using Microsoft.ML.Data;
using System;
using Microsoft.ML.Data;
using Microsoft.ML.StaticPipe;
using Microsoft.ML.Transforms;
using System;

namespace Microsoft.ML.Samples.Static
{
Expand Down
2 changes: 1 addition & 1 deletion docs/samples/Microsoft.ML.Samples/Static/SDCARegression.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using Microsoft.ML.Data;
using Microsoft.ML.Learners;
using Microsoft.ML.StaticPipe;
using System;

namespace Microsoft.ML.Samples.Static
{
Expand Down
6 changes: 6 additions & 0 deletions src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,10 @@
Include="StyleCop.Analyzers" Version="1.1.0-beta008" PrivateAssets="All" />
</ItemGroup>

<ItemGroup>
<AdditionalFiles Include="$(MSBuildThisFileDirectory)stylecop.json">
<Link>stylecop.json</Link>
</AdditionalFiles>
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using Microsoft.ML.Internal.Utilities;
using System;
using System.IO;
using System.IO.Compression;
using System.Reflection;
using Microsoft.ML.Internal.Utilities;

namespace Microsoft.ML
{
Expand Down
Loading

0 comments on commit a570da1

Please sign in to comment.