钟良堂 2021-10-13 00:03 采纳率: 42.9%
浏览 218
已结题

在Android上部署TensorFlowLite报错(官方的TensorFlowLite demo)

最近在Android Studio上面部署TensorFlowLite demo,使用的是这个教程:

https://www.jianshu.com/p/50f5c7d32575

我已经Gradle Files成功了:

img

img

但是点击运行的时候,要下载这些文件,却报了这个错误:

下载的时候:

img

我用了翻墙上网还是不能下载,还是会报这个错误:

Connection timed out: connect.If you are behind an HTTP proxy, please configure the proxy settings either in IDE or Gradle.

具体报错信息如下:

> Task :app:downloadModelFile
Download https://tfhub.dev/tensorflow/lite-model/ssd_mobilenet_v1/1/metadata/2?lite-format=tflite

> Task :app:downloadModelFile FAILED
Execution failed for task ':app:downloadModelFile'.
> de.undercouch.gradle.tasks.download.org.apache.http.conn.HttpHostConnectException: Connect to tfhub.dev:443 [tfhub.dev/142.251.42.238] failed: Connection timed out: connect

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

img

Execution failed for task ':app:downloadModelFile'.
> de.undercouch.gradle.tasks.download.org.apache.http.conn.HttpHostConnectException: Connect to tfhub.dev:443 [tfhub.dev/142.251.42.238] failed: Connection timed out: connect

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

img

感觉这个太难受了,只是一个官方dome,我都部署那么久,希望有做出来的同学可以帮我看看,谢谢!

  • 写回答

1条回答 默认 最新

  • IT人.阿标 移动开发领域优质创作者 2021-10-13 08:05
    关注

    你开墙只是电脑开墙吧? 是不是没有另外设置android studio的代理或者设置Gradle的代理,没设置的话还是访问不通的

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

问题事件

  • 系统已结题 10月21日
  • 已采纳回答 10月13日
  • 修改了问题 10月13日
  • 修改了问题 10月13日
  • 展开全部

悬赏问题

  • ¥30 Matlab打开默认名称带有/的光谱数据
  • ¥50 easyExcel模板 动态单元格合并列
  • ¥15 res.rows如何取值使用
  • ¥15 在odoo17开发环境中,怎么实现库存管理系统,或独立模块设计与AGV小车对接?开发方面应如何设计和开发?请详细解释MES或WMS在与AGV小车对接时需完成的设计和开发
  • ¥15 CSP算法实现EEG特征提取,哪一步错了?
  • ¥15 游戏盾如何溯源服务器真实ip?需要30个字。后面的字是凑数的
  • ¥15 vue3前端取消收藏的不会引用collectId
  • ¥15 delphi7 HMAC_SHA256方式加密
  • ¥15 关于#qt#的问题:我想实现qcustomplot完成坐标轴
  • ¥15 下列c语言代码为何输出了多余的空格