Skip to content

Cannot create LSTM network in brain.js #23

@gao-uk

Description

@gao-uk

After installing brainjs on an Apple Mac using the Terminal command:

npm install brainjs

I find the following attempt in node.js to create an LSTM network results in an error:

const brain = require('brainjs');

const net = new brain.recurrent.LSTM();

The error message shown in Terminal is:

const net = new brain.recurrent.LSTM();
                                ^
TypeError: Cannot read properties of undefined (reading 'LSTM')

What am I doing wrong here?

I am following code example articles here and here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions