class_docstr: The skip optimization removes unnecessary nodes
  from expression tree.
  
  For example:
    The expression `(col_py (append frame_with_100_columns dummy_col dummy_name) 1)` can
    be simplified to `(col_py frame_with_100_columns 1)`
  
  Note: right now this is really specific version only
class_docstr_tok: ["The","skip","optimization","removes","unnecessary","nodes","from","expression","tree",".","For","example",":","The","expression","`","(","col_py","(","append","frame_with_100_columns","dummy_col","dummy_name",")","1",")","`","can","be","simplified","to","`","(","col_py","frame_with_100_columns","1",")","`","Note",":","right","now","this","is","really","specific","version","only"]
code: def is_applicable(self, expr):
      assert isinstance(expr, h2o.expr.ExprNode)
      if any(expr._children):
          append_expr = expr.arg(0)
          # Now only supports single 'cols_py' parameters, and composition with append
          # Also `append` dst argument needs to have properly filled cache
          if (
              expr.narg() == 2
              and append_expr._op == "append"
              and any(append_expr._children)
          ):
              append_dst = append_expr.arg(0)
              cols_py_select = expr.arg(1)
              return (
                  isinstance(cols_py_select, int)
                  and append_dst._cache.ncols_valid()
                  and cols_py_select < append_dst._cache.ncols
              )
  
      return False
  
file_path: h2o-3/h2o-py/h2o/expr_optimizer.py
imports: import h2o.expr
label_desc: Use image node_id 2 for calling the SkipExprOptimization obj's underlying member method code with example usage: obj.is_applicable(expr) and returns: False, unknown