Somnibyte / MLKit

A simple machine learning framework written in Swift 🤖
MIT License
152 stars 14 forks source link

What should initial weights be? #7

Open junaidxabd opened 3 years ago

junaidxabd commented 3 years ago

I left the initial weights as the default values but it doesn't set the weights after that

        let initial_weights = Matrix<Float>(rows: 3, columns: 1, elements: [-100000.0, 1.0, 1.0])

        let weights = try! polynomialModel.train([timestamp,weekday], output: output_data, initialWeights: initial_weights, stepSize: Float(4e-12), tolerance: Float(1e9))

I've got 2 features like the Polynomial Regression Usage guide.