- 🏫 I’m currently an autonomous driving software engineer.
- 🌱 I’m currently learning everything to be an DeepLearninger !
- 🔭 I’m currently working on computer vision !
- 🏃 I love diversified sports, such as swimming, running, skiing...
- ⚡ Fun fact: I love Jayzhou's music. I also love JJ!
- 📧 How to reach me: [email protected]
- 📖: How to read my repository: you can learn main popular deepLearning framworks
- 🏷️: My csdn blog: you can visit my csdn blog to get something you need !
- 🛠️: I am a PaddlePaddle and Pytorch Developer, you can visit my asistudio here
- 🛠️: I use python and C++.
humanposebl-paddle's Introduction
humanposebl-paddle's People
humanposebl-paddle's Issues
能否在aistudio提供下数据下载方式
关于0维Tensor的代码修改请求
Hi,开发者你好,由于飞桨API之前对0维Tensor的支持不完善,通过shape为[1]的1D Tensor来替代shape为[]的0D Tensor,因此在很多本应输出0维tensor的场景中,实际输出的是1维tensor(如:loss)。目前飞桨计划全面支持0维tensor,在大多数情况下不会有不兼容问题,但也发现少量情况可能会报错。
目前发现 会报错 的代码是:loss.numpy()[0]
。原因是此前loss为1D Tensor(错误的语义),运行loss.numpy()[0]可以将其转化为python float数据。在修改为0D Tensor(正确的语义)后,此操作会报错。需要将所有 loss.numpy()[0]
修改为 float(loss)
,以避免后续版本的代码错误。
因此请麻烦修改:
- 对于shape为[1]的1维Tensor:
Tensor.numpy()[0]
修改为float(Tensor)
,对当前不会有影响,亦可适应未来变化。感谢贡献代码。
Hi, Developer, Due to the poor support for the 0D tensor in Paddle API. In many case, the output 1D tensor which shoulde be 0D Tensor (such as loss) are used by mistake. Paddle is plan to support 0D tensor fully, which will not cause incompatibility in most cases. However, it is also found that some code will report error.
This code is: loss.numpy()[0]
。 The reason is that the loss was 1D Tensor (wrong) before, it can be used as loss.numpy()[0]
. After the loss is modified to 0D Tensor (correct), the operation will result in an error. Therefore, it is needed to modify loss.numpy()[0]
to float(loss)
, to avoid errors in future paddle version.
Therefore, please modify:
- As for shape[1] Tensor: modify
Tensor.numpy()[0]
tofloat (Tensor)
, It will not affect the current situation, but also adapt to future. Thank you for contributing code.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.