| 1 | <?php |
||
| 12 | abstract class LayeredNetwork implements Network |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var Layer[] |
||
| 16 | */ |
||
| 17 | protected $layers; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * @param Layer $layer |
||
| 21 | */ |
||
| 22 | public function addLayer(Layer $layer) |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @return Layer[] |
||
| 29 | */ |
||
| 30 | public function getLayers(): array |
||
| 34 | |||
| 35 | /** |
||
| 36 | * @return Layer |
||
| 37 | */ |
||
| 38 | public function getOutputLayer(): Layer |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @return array |
||
| 45 | */ |
||
| 46 | public function getOutput(): array |
||
| 55 | |||
| 56 | /** |
||
| 57 | * @param mixed $input |
||
| 58 | * |
||
| 59 | * @return $this |
||
| 60 | */ |
||
| 61 | public function setInput($input) |
||
| 81 | } |
||
| 82 |