Node.js 服务器没有在 Heroku 上启动/在 He​​roku 上使用 tensorflow.js 的问题?

问题描述

在我的本地它运行良好 - 对于推送到 Heroku,我已经确保:

1 - 服务器的名称index.js

2 - 我的 config.js 变量被推送到构建中(这是一个私有存储库,所以没有问题)。

3 - 我的 package.json 列出了 "start": "node index.js"

当我在命令行上部署时,构建成功。当我打开 Heroku 的日志时,会发生以下情况:

2021-05-31T22:51:42.529122+00:00 app[web.1]:     at Object.<anonymous> (/app/node_modules/@tensorflow/tfjs-core/dist/io/weights_loader.js:97:48)
2021-05-31T22:51:42.529123+00:00 app[web.1]:     at step (/app/node_modules/@tensorflow/tfjs-core/dist/io/weights_loader.js:48:23)
2021-05-31T22:51:42.529123+00:00 app[web.1]:     at Object.next (/app/node_modules/@tensorflow/tfjs-core/dist/io/weights_loader.js:29:53)
2021-05-31T22:51:42.529124+00:00 app[web.1]:     at fulfilled (/app/node_modules/@tensorflow/tfjs-core/dist/io/weights_loader.js:20:58)
2021-05-31T22:51:42.529125+00:00 app[web.1]:     at runMicrotasks (<anonymous>)
2021-05-31T22:51:42.529125+00:00 app[web.1]:     at processticksAndRejections (internal/process/task_queues.js:95:5)
2021-05-31T23:02:02.262851+00:00 heroku[router]: at=info method=GET path="/" host=debord-meme.herokuapp.com request_id=f3ae7d61-e748-485a-bd9d-40cdc322fe4c fwd="3.227.8.29" dyno=web.1 connect=0ms service=2ms status=404 bytes=360 protocol=http
2021-05-31T23:31:35.687687+00:00 heroku[router]: at=info method=GET path="/" host=debord-meme.herokuapp.com request_id=1a4e15e3-7f2b-4c43-9924-e1616eb8bb2e fwd="3.238.176.110" dyno=web.1 connect=1ms service=2ms status=404 bytes=360 protocol=http
2021-06-01T00:09:11.001376+00:00 heroku[router]: at=info method=GET path="/" host=debord-meme.herokuapp.com request_id=3f13ee0f-600b-403b-89b8-180ec16d5a31 fwd="3.215.77.49" dyno=web.1 connect=1ms service=1ms status=404 bytes=360 protocol=http
2021-06-01T00:31:49.911593+00:00 heroku[router]: at=info method=GET path="/" host=debord-meme.herokuapp.com request_id=77efc241-83e0-47b1-83da-0befdd57fafe fwd="54.172.172.75" dyno=web.1 connect=1ms service=20ms status=404 bytes=360 protocol=http 

好像已经部署了包?还是 tensorflow.js 的问题?我真的不确定。谢谢你帮我。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)