1. 14 4月, 2023 1 次提交
    • F
      1. modify set_value op, use Scalars to represent attr `values`, instead of a... · dd2a749a
      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.
      dd2a749a
  2. 28 3月, 2023 1 次提交
    • F
      Add basic functionalities to support Scalar & Scalars in op attr (#51984) · 2e9fd5e4
      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.
      2e9fd5e4
  3. 25 9月, 2022 1 次提交
  4. 05 7月, 2022 1 次提交
  5. 28 6月, 2022 1 次提交
    • R
      Remove boost::variant (#43100) · b3cf28f8
      Ruibiao Chen 提交于
      * boost::variant -> paddle::variant
      
      * boost::variant.apply_visit -> paddle::visit
      
      * Update pybind_boost_hraders.h
      
      * Fix CINN compilation errors
      
      * Revert FetchResultType
      b3cf28f8
  6. 26 6月, 2022 1 次提交
  7. 17 8月, 2021 1 次提交
    • C
      Copy boost optional to Paddle (#34780) · 9be41447
      chentianyu03 提交于
      * copy boost optional.hpp to paddle
      
      * copy boost optional.hpp to paddle
      
      * move directions
      
      * del fluid/utils
      
      * modify .hpp to .h
      
      * move directions
      
      * modify to paddle::optional
      
      * add modification description
      
      * format code stype for the files in paddle/utils
      
      * format code stype
      9be41447
  8. 26 3月, 2021 1 次提交
  9. 04 2月, 2021 1 次提交
  10. 06 1月, 2021 1 次提交
  11. 04 1月, 2021 1 次提交
  12. 18 12月, 2020 1 次提交
  13. 12 11月, 2020 1 次提交
  14. 05 11月, 2020 1 次提交
  15. 04 11月, 2020 1 次提交
    • enhance the op_version_registry, test=develop (#28347) · 21a63f6f
      石晓伟 提交于
      * enhance the op_version_registry, test=develop
      
      * add unittests, test=develop
      
      * enhance the op_version_registry, test=develop
      
      * fix bugs, test=develop
      
      * revert pybind_boost_headers.h, test=develop
      
      * fix a attribute bug, test=develop
      21a63f6f
  16. 10 10月, 2020 1 次提交
  17. 15 9月, 2020 1 次提交
  18. 03 9月, 2020 1 次提交
  19. 27 8月, 2020 1 次提交
  20. 25 8月, 2020 1 次提交
  21. 24 8月, 2020 2 次提交