- 14 4月, 2023 1 次提交
-
-
由 Feiyu Chan 提交于
1. modify set_value op, use Scalars to represent attr `values`, instead of a bunch of attributs of various types; (#52408) 2. add program converter and set_value op as an example, which provides the functionality to convert `paddle::framework::ProgramDesc` between old and new formats(the differences are mainly some operators with incompatible updates in the definition); 3. program version and operator version map now are always saved when serializing `paddle::framework::ProgramDesc` to identify the version; 3. provide an option `legacy_format=false` in serialization of `paddle::framework::ProgramDesc`, it decided whether to convert ProgramDesc back to a legacy format, which is compatible for paddle 2.4.2 or earlier versions to load and execute; 4. deserialization of `paddle::framework::ProgramDesc` is now automatically detecting whether the bytes it receives is in legacy format(contains any of the operators that has been incompatibly updated and have any attribute of type `Scalar`) and convert it to new format. But if you want a faithful deserialization without the automatic conversion, you can use protobuf's deserialization instead. Though it is not recommended, it can be used for the purpose of testing.
-
- 28 3月, 2023 1 次提交
-
-
由 Feiyu Chan 提交于
Add basic functionalities to support Scalar & Scalars in operator attribute. 1. extend allowed types in operator's attribute type, add `paddle::experimental::Scalar`, add corresponding protobuf Message types; 2. Scalar enhancement, add formatting, equality; 3. add code to handle Scalar & Scalars in opmaker, conversion from paddle operator to phi kernel, opdesc construction and manipulation, tensorrt converter, tracer, operator construction, etc; 4. bind `paddle::experimental::Scalar` to python, as `libpaddle.Scalar`; 5. add functionality to canonicalize attribute map according to OpProto(if the op the attribute map used for has an OpProto); 6. add code to manipulate Scalar proto message via protobuffer python API; Add unittests. 1. add test cases for formatting, equality for Scalars, and WrapAsScalars; 2. add test cases for 'casting' between different morphs of attributes; 3. add test cases for extracting scalar & scalars from attribute; 4. add test cases for CanonicalizeScalarAttrs(and fix a bug in type index offset); 5. fix gmock's library filename on windows platform. 6. clean code: use canonicalize_attrs instead of inlining the function; 7. add test cases for libpaddle.Scalar in python code. 8. add test cases for `make_scalar_proto`, which manipulate proto message `Scalar` via protobuffer python API.
-
- 05 6月, 2022 1 次提交
-
-
由 Sing_chan 提交于
-
- 04 2月, 2021 1 次提交
-
-
由 wanghuancoder 提交于
* use iwyu clean include second time, test=develop
-
- 10 10月, 2020 1 次提交
-
-
由 石晓伟 提交于
-