1. 23 2月, 2021 1 次提交
  2. 08 1月, 2021 1 次提交
    • L
      [cherry-pick] [Dy2Stat] Don't convert to paddle.shape if var_x.shape is not... · 2ba9bdd7
      liym27 提交于
      [cherry-pick] [Dy2Stat] Don't convert to paddle.shape if var_x.shape is not negetive #29965 (#30235)
      
      * [Cherry-Pick 2.0] [Dy2Stat] Don't convert to paddle.shape if var_x.shape is not negetive (#29965)
      
      1. When x is Variable, call nn.shape(x) only in following cases:
       1)The shape of x is used in control flow condition.
       2)The dim to be used is negetive
      2. When x is Variable, but x.shape or x.shape[idx] doesn't contain negetive value, don't convert to paddle.shape()
      
      * [Cherry-Pick 2.0] [Dy2Stat] Use Paddle2.0 api paddle.tensor.array_* (#30156)
      2ba9bdd7
  3. 03 12月, 2020 1 次提交
  4. 25 11月, 2020 1 次提交
  5. 24 11月, 2020 1 次提交
    • L
      [Dynamic-to-Static] Fix bug of convert_logical_and/convert_logical_or: the... · 85292e0b
      liym27 提交于
      [Dynamic-to-Static] Fix bug of convert_logical_and/convert_logical_or: the operands are executed sequentially(#28993)
      
        
        1) The operands are executed sequentially according to the running logic of Python.
        
        2) If the left hand operand is True(for convert_logical_or)/False(for convert_logical_and), the right hand operand should be executed.
      85292e0b
  6. 11 11月, 2020 1 次提交
  7. 21 7月, 2020 1 次提交
  8. 16 7月, 2020 1 次提交
  9. 05 7月, 2020 1 次提交
  10. 11 6月, 2020 1 次提交
    • L
      [Dy2Static]Convert var.shape stmt and Convert the return variables of... · f16e2778
      liym27 提交于
      [Dy2Static]Convert var.shape stmt and Convert the return variables of Tensor-dependent 'if' staments to Tensor if it not  (#24911)
      
      * Support int and long: int or long -> six.integer_types. 
      
      * Modify test_tensor_shape: fix bug and modify comment. 
      
      * Support convert_var_shape to convert var.shape stmt
      
      * Modify code in ifelse_simple_func.py because don't support return non-Tensor in Tensor-dependent 'if' stament currently. 
      
      * Convert the return variables of Tensor-dependent 'if' staments to Tensor if it not. test=develop
      f16e2778
  11. 09 6月, 2020 1 次提交
  12. 05 6月, 2020 1 次提交
    • L
      [Dy2Static] Add convert_ifelse to run the transformed code dynamically (#24866) · a9dca580
      liym27 提交于
      * cast var in convert_logical_XX. 
      
      * Add convert_ifelse function in convert_operators.py  
      
      * Add logical_transformer. Remove LogicalTransformer from loop_transformer.py 
      
      * Revert modified tests in PR24799(convert_while_stmt). 
      
      * Comment and modify code that doesn't support `return` statement. 
      
      * Remove unnecessary class: MergeAssignTransformer, NodeTestTransformer and IfConditionVisitor in ifelse_transformer. 
      a9dca580
  13. 03 6月, 2020 1 次提交
    • L
      [Dy2Static]Convert while stmt and convert logical_XX (#24799) · 001c9fcc
      liym27 提交于
      * Support convert_while_loop. 
      
      * Comment code that not supported 'if' in test_break_continue. 
      
      * Convert int into tensor to support 'if' stmt in for/while loop. 
      
      * Add unittest to test all cases of convert_logical_XX. 
      
      * Add unittest to test all cases of convert_while_loop. 
      
      * Fix bug in LogicalOpTransformer. test=develop
      001c9fcc