Skip to content

Commit

Permalink
namespaces re-organisation & cleanup
Browse files Browse the repository at this point in the history
- move algorithms to `AI.Algorithms` instead of `AI.MachineLearning`
- move Machine to `AI.Machine` instead of repeating `AI.Machine.Machine`
- get rid of old `Regression.cs` file that's no longer needed, see #8 for updated notes
  • Loading branch information
radumg committed Feb 26, 2018
1 parent 396b9bf commit d545f71
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 64 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
using Accord.Math.Random;
using Accord.Statistics.Models.Regression.Linear;
using AI.Machine;
using Autodesk.DesignScript.Runtime;
using System;
using System.Collections.Generic;

namespace AI.MachineLearning.Regression
namespace AI.Algorithms.Regression
{
/// <summary>
/// In linear regression, the model specification is that the dependent variable, y is a linear combination of the parameters (but need not be linear in the independent variables).
/// </summary>
public class SimpleLinearRegression : IAlgorithm
{
#region Interface Properties
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
using Autodesk.DesignScript.Runtime;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace AI.Machine
namespace AI
{
[IsVisibleInDynamoLibrary(false)]
public interface IAlgorithm
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using Autodesk.DesignScript.Runtime;

namespace AI.Machine
namespace AI
{
/// <summary>
/// The generic capabilities of a machine, used for machine learning
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
using System;
using AI.Utilities;
using Autodesk.DesignScript.Runtime;
using AI.Machine;

namespace AI.Machine
namespace AI
{
/// <summary>
/// Machines are entities that can leverage different algorithms to learn from training data and then predict new values.
Expand Down
2 changes: 1 addition & 1 deletion src/DynAI/MachineLearning.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
using System.Text;
using System.Threading.Tasks;

namespace AI.MachineLearning
namespace AI.Algorithms
{
#region Linear Regression

Expand Down
10 changes: 4 additions & 6 deletions src/DynAI/MachineLearning.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,10 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="MachineLearning\Regression.cs" />
<Compile Include="MachineLearning\SimpleLinearRegression.cs" />
<Compile Include="Machine\IAlgorithm.cs" />
<Compile Include="Machine\IMachine.cs" />
<Compile Include="Machine\MachineBase.cs" />
<Compile Include="Machine\RegressionMachine.cs" />
<Compile Include="Algorithms\SimpleLinearRegression.cs" />
<Compile Include="Interfaces\IAlgorithm.cs" />
<Compile Include="Interfaces\IMachine.cs" />
<Compile Include="Machine\Machine.cs" />
<Compile Include="Utils\JSON.cs" />
<Compile Include="MachineLearning.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
Expand Down
47 changes: 0 additions & 47 deletions src/DynAI/MachineLearning/Regression.cs

This file was deleted.

0 comments on commit d545f71

Please sign in to comment.