Skip to content

Commit

Permalink
up
Browse files Browse the repository at this point in the history
  • Loading branch information
xieyuheng committed May 30, 2024
1 parent 03e0cdc commit f97f624
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
9 changes: 7 additions & 2 deletions src/system-a/models/iris/irisModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,12 @@ import { samplingObjective } from "../../tensor/samplingObjective.js"
import { model } from "../model.js"
import { irisTrainXs, irisTrainYs } from "./irisDataset.js"

export const irisNetwork = blockStack([denseBlock(4, 6), denseBlock(6, 3)])
export const irisNetwork = blockStack([
denseBlock(4, 6),
denseBlock(6, 4),
denseBlock(4, 3),
denseBlock(3, 3),
])

export function irisTrainParameters(): Array<Tensor> {
const objective = samplingObjective(
Expand All @@ -29,7 +34,7 @@ export function irisTrainParameters(): Array<Tensor> {
// })

const gradientDescentFn = gradientDescentAdam({
learningRate: 0.002,
learningRate: 0.006,
decayRate: 0.9,
relayFactor: 0.85,
})
Expand Down
2 changes: 1 addition & 1 deletion src/system-a/tensor/zeroTensor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import assert from "node:assert"
import { test } from "node:test"
import { zeroTensor } from "./zeroTensor.js"

test("tensorZeros", () => {
test("zeroTensor", () => {
assert.deepStrictEqual(zeroTensor([2, 3]), [
[0, 0, 0],
[0, 0, 0],
Expand Down

0 comments on commit f97f624

Please sign in to comment.