parameters: (columns_to_tensors,
                                  feature_columns,
                                  weight_collections,
                                  trainable,
                                  scope,
                                  output_rank,
                                  default_name)
docstring: Implementation of `input_from(_sequence)_feature_columns`.
docstring_summary: Implementation of `input_from(_sequence)_feature_columns`.
docstring_tokens: Implementation of input_from ( _sequence ) _feature_columns .
function: def _input_from_feature_columns(columns_to_tensors,
                                  feature_columns,
                                  weight_collections,
                                  trainable,
                                  scope,
                                  output_rank,
                                  default_name):
    """Implementation of `input_from(_sequence)_feature_columns`."""
    columns_to_tensors = columns_to_tensors.copy()
    check_feature_columns(feature_columns)
    with variable_scope.variable_scope(scope,
                                       default_name=default_name,
                                       values=columns_to_tensors.values()):
      output_tensors = []
      transformer = _Transformer(columns_to_tensors)
      if weight_collections:
        weight_collections = list(set(list(weight_collections) +
                                      [ops.GraphKeys.GLOBAL_VARIABLES]))
  
      for column in sorted(set(feature_columns), key=lambda x: x.key):
        with variable_scope.variable_scope(None,
                                           default_name=column.name,
                                           values=columns_to_tensors.values()):
          transformed_tensor = transformer.transform(column)
          if output_rank == 3:
            transformed_tensor = nest.map_structure(
                functools.partial(
                    _maybe_reshape_input_tensor,
                    column_name=column.name,
                    output_rank=output_rank), transformed_tensor)
          try:
            # pylint: disable=protected-access
            arguments = column._deep_embedding_lookup_arguments(
                transformed_tensor)
            output_tensors.append(
                fc._embeddings_from_arguments(  # pylint: disable=protected-access
                    column,
                    arguments,
                    weight_collections,
                    trainable,
                    output_rank=output_rank))
  
          except NotImplementedError as ee:
            try:
              # pylint: disable=protected-access
              output_tensors.append(column._to_dnn_input_layer(
                  transformed_tensor,
                  weight_collections,
                  trainable,
                  output_rank=output_rank))
            except ValueError as e:
              raise ValueError('Error creating input layer for column: {}.\n'
                               '{}, {}'.format(column.name, e, ee))
      return array_ops.concat(output_tensors, output_rank - 1)
function_tokens: def _input_from_feature_columns ( columns_to_tensors , feature_columns , weight_collections , trainable , scope , output_rank , default_name ) : columns_to_tensors = columns_to_tensors . copy ( ) check_feature_columns ( feature_columns ) with variable_scope . variable_scope ( scope , default_name = default_name , values = columns_to_tensors . values ( ) ) : output_tensors = [ ] transformer = _Transformer ( columns_to_tensors ) if weight_collections : weight_collections = list ( set ( list ( weight_collections ) + [ ops . GraphKeys . GLOBAL_VARIABLES ] ) ) for column in sorted ( set ( feature_columns ) , key = lambda x : x . key ) : with variable_scope . variable_scope ( None , default_name = column . name , values = columns_to_tensors . values ( ) ) : transformed_tensor = transformer . transform ( column ) if output_rank == 3 : transformed_tensor = nest . map_structure ( functools . partial ( _maybe_reshape_input_tensor , column_name = column . name , output_rank = output_rank ) , transformed_tensor ) try : # pylint: disable=protected-access arguments = column . _deep_embedding_lookup_arguments ( transformed_tensor ) output_tensors . append ( fc . _embeddings_from_arguments ( # pylint: disable=protected-access column , arguments , weight_collections , trainable , output_rank = output_rank ) ) except NotImplementedError as ee : try : # pylint: disable=protected-access output_tensors . append ( column . _to_dnn_input_layer ( transformed_tensor , weight_collections , trainable , output_rank = output_rank ) ) except ValueError as e : raise ValueError ( 'Error creating input layer for column: {}.\n' '{}, {}' . format ( column . name , e , ee ) ) return array_ops . concat ( output_tensors , output_rank - 1 )