code: def encode_architecture(architecture, problem_type):
      """Encodes the architecture of strings into the np.array.
  
      Args:
        architecture: A list of strings of the architecture.
        problem_type: The phoenix_spec.ProblemType.
  
      Returns:
        The np.array of the encoded architecture.
      """
  
      architecture = [block_builder.BlockType[b] for b in architecture]
      return np.array(
          architecture_utils.fix_architecture_order(
              architecture, problem_type
          )
      )
  
file_path: model_search/model_search/search/common.py
imports: import os
  from model_search import block_builder
  from model_search.architecture import architecture_utils
  import numpy
  import tensorflow.compat.v2
label_desc: Use image node_id 3 for calling a global function with example usage: encode_architecture(architecture, problem_type) and returns: np