parameters: (nest)
docstring: :alias_main: paddle.flatten
  	:alias: paddle.flatten,paddle.tensor.flatten,paddle.tensor.manipulation.flatten
  	:old_api: paddle.fluid.layers.flatten
  
      Traverse all entries in the nested structure and put them into an list.
docstring_summary: :alias_main: paddle.flatten
  	:alias: paddle.flatten,paddle.tensor.flatten,paddle.tensor.manipulation.flatten
  	:old_api: paddle.fluid.layers.flatten
docstring_tokens: : alias_main : paddle . flatten : alias : paddle . flatten paddle . tensor . flatten paddle . tensor . manipulation . flatten : old_api : paddle . fluid . layers . flatten
function: def flatten(nest):
      """
  	:alias_main: paddle.flatten
  	:alias: paddle.flatten,paddle.tensor.flatten,paddle.tensor.manipulation.flatten
  	:old_api: paddle.fluid.layers.flatten
  
      Traverse all entries in the nested structure and put them into an list.
      """
      if is_sequence(nest):
          return list(_yield_flat_nest(nest))
      else:
          return [nest]
function_tokens: def flatten ( nest ) : if is_sequence ( nest ) : return list ( _yield_flat_nest ( nest ) ) else : return [ nest ]