def copy_tensor_attributes(dst, src):
    """
    Copy over all tensor attributes that need to be preserved
    """
    attrs = ["depth", "name", "nop", "is_output"]
    for attr in attrs:
        if attr in src._attrs:
            dst._attrs[attr] = src._attrs[attr]
Copy over all tensor attributes that need to be preserved
python/aitemplate/compiler/transform/transform_utils.py