Skip to content

Commit

Permalink
Fix tests and such
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewdalpino committed May 6, 2024
1 parent 4033a9d commit 19aecd1
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 297 deletions.
6 changes: 3 additions & 3 deletions src/Classifiers/LogisticRegression.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,9 @@ class LogisticRegression implements Estimator, Learner, Online, Probabilistic, R
/**
* The underlying neural network instance.
*
* @var \Rubix\ML\NeuralNet\Network|null
* @var Network|null
*/
protected ?\Rubix\ML\NeuralNet\Network $network = null;
protected ?Network $network = null;

/**
* The unique class labels.
Expand Down Expand Up @@ -267,7 +267,7 @@ public function losses() : ?array
/**
* Return the underlying neural network instance or null if not trained.
*
* @return \Rubix\ML\NeuralNet\Network|null
* @return Network|null
*/
public function network() : ?Network
{
Expand Down
11 changes: 3 additions & 8 deletions src/Classifiers/MultilayerPerceptron.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,9 @@ class MultilayerPerceptron implements Estimator, Learner, Online, Probabilistic,
/**
* The underlying neural network instance.
*
* @var \Rubix\ML\NeuralNet\Network|null
* @var Network|null
*/
protected ?\Rubix\ML\NeuralNet\Network $network = null;
protected ?Network $network = null;

/**
* The unique class labels.
Expand All @@ -167,12 +167,7 @@ class MultilayerPerceptron implements Estimator, Learner, Online, Probabilistic,
/**
* @param \Rubix\ML\NeuralNet\Layers\Hidden[] $hiddenLayers
* @param int $batchSize
<<<<<<< HEAD
* @param \Rubix\ML\NeuralNet\Optimizers\Optimizer|null $optimizer
=======
* @param Optimizer|null $optimizer
* @param float $l2Penalty
>>>>>>> 2.5
* @param int $epochs
* @param float $minChange
* @param int $evalInterval
Expand Down Expand Up @@ -349,7 +344,7 @@ public function losses() : ?array
/**
* Return the underlying neural network instance or null if not trained.
*
* @return \Rubix\ML\NeuralNet\Network|null
* @return Network|null
*/
public function network() : ?Network
{
Expand Down
6 changes: 3 additions & 3 deletions src/Classifiers/SoftmaxClassifier.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ class SoftmaxClassifier implements Estimator, Learner, Online, Probabilistic, Ve
/**
* The underlying neural network instance.
*
* @var \Rubix\ML\NeuralNet\Network|null
* @var Network|null
*/
protected ?\Rubix\ML\NeuralNet\Network $network = null;
protected ?Network $network = null;

/**
* The unique class labels.
Expand Down Expand Up @@ -263,7 +263,7 @@ public function losses() : ?array
/**
* Return the underlying neural network instance or null if not trained.
*
* @return \Rubix\ML\NeuralNet\Network|null
* @return Network|null
*/
public function network() : ?Network
{
Expand Down
271 changes: 0 additions & 271 deletions src/NeuralNet/FeedForward.php

This file was deleted.

6 changes: 3 additions & 3 deletions src/NeuralNet/Network.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class Network
*
* @var Input
*/
protected \Rubix\ML\NeuralNet\Layers\Input $input;
protected Input $input;

/**
* The hidden layers of the network.
Expand All @@ -59,14 +59,14 @@ class Network
*
* @var Output
*/
protected \Rubix\ML\NeuralNet\Layers\Output $output;
protected Output $output;

/**
* The gradient descent optimizer used to train the network.
*
* @var Optimizer
*/
protected \Rubix\ML\NeuralNet\Optimizers\Optimizer $optimizer;
protected Optimizer $optimizer;

/**
* @param Input $input
Expand Down
6 changes: 3 additions & 3 deletions src/Regressors/Adaline.php
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,9 @@ class Adaline implements Estimator, Learner, Online, RanksFeatures, Verbose, Per
/**
* The underlying neural network instance.
*
* @var \Rubix\ML\NeuralNet\Network|null
* @var Network|null
*/
protected ?\Rubix\ML\NeuralNet\Network $network = null;
protected ?Network $network = null;

/**
* The loss at each epoch from the last training session.
Expand Down Expand Up @@ -261,7 +261,7 @@ public function losses() : ?array
/**
* Return the underlying neural network instance or null if not trained.
*
* @return \Rubix\ML\NeuralNet\Network|null
* @return Network|null
*/
public function network() : ?Network
{
Expand Down
Loading

0 comments on commit 19aecd1

Please sign in to comment.