Weihang Chen
Weihang Chen
您好,感谢您提出问题,这里有几个问题跟您确认下: 1. 您用的是v2版本吗?这个paddle.init在新的fluid版本中已经不再使用了,新版本只要更改以下图片所示的参数即可。现在我们的首页README没有及时更新,对此表示非常抱歉,待会会更新一下。  2. 这里为什么需要运行两遍?错误原因也是说Log工具被初始化了两遍所以出错了,运行一遍的话应该不会有问题。
了解了,确实有必要判断一下,不过这里可能有点困难,我追溯了一下这个错误,这个不是目前paddle里面的机制导致的,而是google的glog里面不允许这个二次Init操作。 现在paddle用了glog这个开源日志工具,使用这个日志工具需要调用Google提供的外部接口: `InitGoogleLogging` paddle也是这样使用的,包括现在的新版本fluid,paddle只能追溯到这一步了。 因此我追溯了glog的代码,触发这个错误的过程是这样的:   这里的CHECK导致了这个问题,但是这里不是我们的代码,这可能需要给google提下issues了。 建议暂时还是尽量提醒用户正确使用吧。
@cheradam 可以,抱歉是我考虑不周全。我考虑有三种解决的方向: 1. 可以在我们paddle v2代码初始化的时候加一个静态的状态记录变量,避免被二次调用 2. 改下Google glog的源码 3. 换用fluid版本,fluid版本里init这个操作用户是不能调用的,不会被二次使用 我先按第一种方向改一下
@weiexcelpro 您好,关于这个问题我后来找别的研发老师商量了一下,我之前考虑的解决方向可能带来隐患,不太合适。比较好的做法是在上层程序里用标志变量约束一下,比如假设init()背后是一个按钮,用户可能会点两次,那么就约束一下这个逻辑,避免用户点击两次。
@Silv3S @piotrekobi Our kernel migration work will be released in Paddle v2.4, and the `release/2.4` branch bas been created at 9.9, so the PRs merged into develop after 9.9 need...
> @PaulinaGacek the problem of PR-CI-Windows may be caused by the `Copy` difference
Could you help to review this PR and evaluate these changes on your internal system? After this PR is merged, we can start the migration of remaining kernels @jczaja @Silv3S
@Silv3S Hello, are the tests finished?
您是指预测部署的问题吗?您看下下面的文档能否满足您需求? https://www.paddlepaddle.org.cn/documentation/docs/zh/advanced_usage/deploy/index_cn.html 
您是要保存模型还是要部署模型,我看您同时使用了do_save_inference_model和init_from_params,是要用已经训练好的参数,继续训练,然后保存吗