code: def test_copy_nest():
      nest = {
          "a": [ivy.array([0]), ivy.array([1])],
          "b": {"c": [ivy.array([[2], [4]]), ivy.array([[6], [8]])]},
      }
      nest_copy = ivy.copy_nest(nest)
  
      # copied nests
      assert nest["a"] is not nest_copy["a"]
      assert nest["b"] is not nest_copy["b"]
      assert nest["b"]["c"] is not nest_copy["b"]["c"]
  
      # non-copied arrays
      assert nest["a"][0] is nest_copy["a"][0]
      assert nest["a"][1] is nest_copy["a"][1]
      assert nest["b"]["c"][0] is nest_copy["b"]["c"][0]
      assert nest["b"]["c"][1] is nest_copy["b"]["c"][1]
  
      from collections import namedtuple
  
      NAMEDTUPLE = namedtuple("OutNamedTuple", ["x", "y"])
      nest = NAMEDTUPLE(x=ivy.array([1.0]), y=ivy.array([2.0]))
      copied_nest = ivy.copy_nest(nest, include_derived=True)
      assert isinstance(copied_nest, NAMEDTUPLE)
  
imports: import copy
  import warnings
  import pytest
  import numpy
  import ivy
label_desc: Use image node_id 8 for calling a global function with example usage: test_copy_nest() without return types