@0x77/brain 中文文档教程

发布于 5年前 浏览 26 更新于 3年前

Brain.js CLI

@0x77/brain 是一个带有 brain.js 和 repl 的 Node.js 模块,它类似于带有 brain.js 的 repl 和一些额外的功能,如 loadFromJSON/readFromJSON file

How to install

安装:

  • Yarn
$ yarn global add @0x77/brain 
  • NPM
$ npm i -g @0x77/brain

Commands

  • REPL:
    • .break Sometimes you get stuck, this gets you out
    • .clear Break, and also clear the local context
    • .editor Enter editor mode
    • .exit Exit the repl
    • .help Print help message
    • .load Load JS from a file into the REPL session
    • .save Save all evaluated commands in this REPL session to a file
  • BRAIN:
    • net.loadFromJSON(path) - loads net from json file (<path to file>)
    • saveToJSON(path) - saves net to json file (<path to file>)
    • train(config) - starts training nn (<brain.js train config>)
    • run(data) - run's the nn (<data>)
    • loadTrainingData(path) - loads training data from json file (<path to file>)

Brain.js CLI

@0x77/brain is an Node.js module with brain.js and repl, its like repl with brain.js and some additionally features like loadFromJSON/readFromJSON file.

How to install

To install:

  • Yarn
$ yarn global add @0x77/brain 
  • NPM
$ npm i -g @0x77/brain

Commands

  • REPL:
    • .break Sometimes you get stuck, this gets you out
    • .clear Break, and also clear the local context
    • .editor Enter editor mode
    • .exit Exit the repl
    • .help Print help message
    • .load Load JS from a file into the REPL session
    • .save Save all evaluated commands in this REPL session to a file
  • BRAIN:
    • net.loadFromJSON(path) - loads net from json file (<path to file>)
    • saveToJSON(path) - saves net to json file (<path to file>)
    • train(config) - starts training nn (<brain.js train config>)
    • run(data) - run's the nn (<data>)
    • loadTrainingData(path) - loads training data from json file (<path to file>)
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文