import torch
from torch._inductor.select_algorithm import extern_kernels
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid
from torch._C import _cuda_getCurrentRawStream as get_raw_stream
from torch._inductor.runtime import triton_helpers
import torch.nn as nn
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cuda = torch._C._dynamo.guards._empty_strided_cuda


@triton.jit
def triton_poi_fused_relu_0(in_ptr0, out_ptr0, out_ptr1, xnumel, XBLOCK: tl
    .constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + x0, None)
    tmp1 = tl.full([1], 0, tl.int32)
    tmp2 = triton_helpers.maximum(tmp1, tmp0)
    tl.store(out_ptr0 + x0, tmp2, None)
    tl.store(out_ptr1 + x0, tmp2, None)


@triton.jit
def triton_poi_fused_convolution_relu_1(in_out_ptr0, in_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 4096 % 64
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tl.full([1], 0, tl.int32)
    tmp4 = triton_helpers.maximum(tmp3, tmp2)
    tl.store(in_out_ptr0 + x3, tmp4, None)


@triton.jit
def triton_poi_fused_convolution_2(in_out_ptr0, in_ptr0, xnumel, XBLOCK: tl
    .constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 4096 % 64
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(in_out_ptr0 + x3, tmp2, None)


@triton.jit
def triton_poi_fused_max_pool2d_with_indices_relu_3(in_ptr0, out_ptr0,
    out_ptr1, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x0 = xindex % 32
    x1 = xindex // 32
    x2 = xindex
    tmp0 = tl.load(in_ptr0 + (2 * x0 + 128 * x1), None, eviction_policy=
        'evict_last')
    tmp1 = tl.load(in_ptr0 + (1 + 2 * x0 + 128 * x1), None, eviction_policy
        ='evict_last')
    tmp7 = tl.load(in_ptr0 + (64 + 2 * x0 + 128 * x1), None,
        eviction_policy='evict_last')
    tmp12 = tl.load(in_ptr0 + (65 + 2 * x0 + 128 * x1), None,
        eviction_policy='evict_last')
    tmp2 = tmp1 > tmp0
    tmp3 = tl.full([1], 1, tl.int8)
    tmp4 = tl.full([1], 0, tl.int8)
    tmp5 = tl.where(tmp2, tmp3, tmp4)
    tmp6 = triton_helpers.maximum(tmp1, tmp0)
    tmp8 = tmp7 > tmp6
    tmp9 = tl.full([1], 2, tl.int8)
    tmp10 = tl.where(tmp8, tmp9, tmp5)
    tmp11 = triton_helpers.maximum(tmp7, tmp6)
    tmp13 = tmp12 > tmp11
    tmp14 = tl.full([1], 3, tl.int8)
    tmp15 = tl.where(tmp13, tmp14, tmp10)
    tmp16 = triton_helpers.maximum(tmp12, tmp11)
    tmp17 = tl.full([1], 0, tl.int32)
    tmp18 = triton_helpers.maximum(tmp17, tmp16)
    tl.store(out_ptr0 + x2, tmp15, None)
    tl.store(out_ptr1 + x2, tmp18, None)


@triton.jit
def triton_poi_fused_convolution_relu_4(in_out_ptr0, in_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 1024 % 128
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tl.full([1], 0, tl.int32)
    tmp4 = triton_helpers.maximum(tmp3, tmp2)
    tl.store(in_out_ptr0 + x3, tmp4, None)


@triton.jit
def triton_poi_fused_convolution_5(in_out_ptr0, in_ptr0, xnumel, XBLOCK: tl
    .constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 1024 % 128
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(in_out_ptr0 + x3, tmp2, None)


@triton.jit
def triton_poi_fused_max_pool2d_with_indices_relu_6(in_ptr0, out_ptr0,
    out_ptr1, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x0 = xindex % 16
    x1 = xindex // 16
    x2 = xindex
    tmp0 = tl.load(in_ptr0 + (2 * x0 + 64 * x1), None, eviction_policy=
        'evict_last')
    tmp1 = tl.load(in_ptr0 + (1 + 2 * x0 + 64 * x1), None, eviction_policy=
        'evict_last')
    tmp7 = tl.load(in_ptr0 + (32 + 2 * x0 + 64 * x1), None, eviction_policy
        ='evict_last')
    tmp12 = tl.load(in_ptr0 + (33 + 2 * x0 + 64 * x1), None,
        eviction_policy='evict_last')
    tmp2 = tmp1 > tmp0
    tmp3 = tl.full([1], 1, tl.int8)
    tmp4 = tl.full([1], 0, tl.int8)
    tmp5 = tl.where(tmp2, tmp3, tmp4)
    tmp6 = triton_helpers.maximum(tmp1, tmp0)
    tmp8 = tmp7 > tmp6
    tmp9 = tl.full([1], 2, tl.int8)
    tmp10 = tl.where(tmp8, tmp9, tmp5)
    tmp11 = triton_helpers.maximum(tmp7, tmp6)
    tmp13 = tmp12 > tmp11
    tmp14 = tl.full([1], 3, tl.int8)
    tmp15 = tl.where(tmp13, tmp14, tmp10)
    tmp16 = triton_helpers.maximum(tmp12, tmp11)
    tmp17 = tl.full([1], 0, tl.int32)
    tmp18 = triton_helpers.maximum(tmp17, tmp16)
    tl.store(out_ptr0 + x2, tmp15, None)
    tl.store(out_ptr1 + x2, tmp18, None)


@triton.jit
def triton_poi_fused_convolution_relu_7(in_out_ptr0, in_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 256 % 256
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tl.full([1], 0, tl.int32)
    tmp4 = triton_helpers.maximum(tmp3, tmp2)
    tl.store(in_out_ptr0 + x3, tmp4, None)


@triton.jit
def triton_poi_fused_convolution_8(in_out_ptr0, in_ptr0, xnumel, XBLOCK: tl
    .constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 256 % 256
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(in_out_ptr0 + x3, tmp2, None)


@triton.jit
def triton_poi_fused_max_pool2d_with_indices_relu_9(in_ptr0, out_ptr0,
    out_ptr1, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x0 = xindex % 8
    x1 = xindex // 8
    x2 = xindex
    tmp0 = tl.load(in_ptr0 + (2 * x0 + 32 * x1), None, eviction_policy=
        'evict_last')
    tmp1 = tl.load(in_ptr0 + (1 + 2 * x0 + 32 * x1), None, eviction_policy=
        'evict_last')
    tmp7 = tl.load(in_ptr0 + (16 + 2 * x0 + 32 * x1), None, eviction_policy
        ='evict_last')
    tmp12 = tl.load(in_ptr0 + (17 + 2 * x0 + 32 * x1), None,
        eviction_policy='evict_last')
    tmp2 = tmp1 > tmp0
    tmp3 = tl.full([1], 1, tl.int8)
    tmp4 = tl.full([1], 0, tl.int8)
    tmp5 = tl.where(tmp2, tmp3, tmp4)
    tmp6 = triton_helpers.maximum(tmp1, tmp0)
    tmp8 = tmp7 > tmp6
    tmp9 = tl.full([1], 2, tl.int8)
    tmp10 = tl.where(tmp8, tmp9, tmp5)
    tmp11 = triton_helpers.maximum(tmp7, tmp6)
    tmp13 = tmp12 > tmp11
    tmp14 = tl.full([1], 3, tl.int8)
    tmp15 = tl.where(tmp13, tmp14, tmp10)
    tmp16 = triton_helpers.maximum(tmp12, tmp11)
    tmp17 = tl.full([1], 0, tl.int32)
    tmp18 = triton_helpers.maximum(tmp17, tmp16)
    tl.store(out_ptr0 + x2, tmp15, None)
    tl.store(out_ptr1 + x2, tmp18, None)


@triton.jit
def triton_poi_fused_convolution_relu_10(in_out_ptr0, in_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 64 % 512
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tl.full([1], 0, tl.int32)
    tmp4 = triton_helpers.maximum(tmp3, tmp2)
    tl.store(in_out_ptr0 + x3, tmp4, None)


@triton.jit
def triton_poi_fused_convolution_11(in_out_ptr0, in_ptr0, xnumel, XBLOCK:
    tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 64 % 512
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(in_out_ptr0 + x3, tmp2, None)


@triton.jit
def triton_poi_fused_max_pool2d_with_indices_relu_12(in_ptr0, out_ptr0,
    out_ptr1, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x0 = xindex % 4
    x1 = xindex // 4
    x2 = xindex
    tmp0 = tl.load(in_ptr0 + (2 * x0 + 16 * x1), None, eviction_policy=
        'evict_last')
    tmp1 = tl.load(in_ptr0 + (1 + 2 * x0 + 16 * x1), None, eviction_policy=
        'evict_last')
    tmp7 = tl.load(in_ptr0 + (8 + 2 * x0 + 16 * x1), None, eviction_policy=
        'evict_last')
    tmp12 = tl.load(in_ptr0 + (9 + 2 * x0 + 16 * x1), None, eviction_policy
        ='evict_last')
    tmp2 = tmp1 > tmp0
    tmp3 = tl.full([1], 1, tl.int8)
    tmp4 = tl.full([1], 0, tl.int8)
    tmp5 = tl.where(tmp2, tmp3, tmp4)
    tmp6 = triton_helpers.maximum(tmp1, tmp0)
    tmp8 = tmp7 > tmp6
    tmp9 = tl.full([1], 2, tl.int8)
    tmp10 = tl.where(tmp8, tmp9, tmp5)
    tmp11 = triton_helpers.maximum(tmp7, tmp6)
    tmp13 = tmp12 > tmp11
    tmp14 = tl.full([1], 3, tl.int8)
    tmp15 = tl.where(tmp13, tmp14, tmp10)
    tmp16 = triton_helpers.maximum(tmp12, tmp11)
    tmp17 = tl.full([1], 0, tl.int32)
    tmp18 = triton_helpers.maximum(tmp17, tmp16)
    tl.store(out_ptr0 + x2, tmp15, None)
    tl.store(out_ptr1 + x2, tmp18, None)


@triton.jit
def triton_poi_fused_convolution_relu_13(in_out_ptr0, in_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 16 % 1024
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tl.full([1], 0, tl.int32)
    tmp4 = triton_helpers.maximum(tmp3, tmp2)
    tl.store(in_out_ptr0 + x3, tmp4, None)


@triton.jit
def triton_poi_fused_convolution_14(in_out_ptr0, in_ptr0, xnumel, XBLOCK:
    tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x3 = xindex
    x1 = xindex // 16 % 1024
    tmp0 = tl.load(in_out_ptr0 + x3, None)
    tmp1 = tl.load(in_ptr0 + x1, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(in_out_ptr0 + x3, tmp2, None)


@triton.jit
def triton_poi_fused_cat_relu_15(in_ptr0, in_ptr1, in_ptr2, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x1 = xindex // 64 % 1024
    x0 = xindex % 64
    x2 = xindex // 65536
    x3 = xindex
    tmp0 = x1
    tl.full([1], 0, tl.int64)
    tmp3 = tl.full([1], 512, tl.int64)
    tmp4 = tmp0 < tmp3
    tmp5 = tl.load(in_ptr0 + (x0 + 64 * x1 + 32768 * x2), tmp4, other=0.0)
    tmp6 = tl.load(in_ptr1 + x1, tmp4, eviction_policy='evict_last', other=0.0)
    tmp7 = tmp5 + tmp6
    tmp8 = tl.full(tmp7.shape, 0.0, tmp7.dtype)
    tmp9 = tl.where(tmp4, tmp7, tmp8)
    tmp10 = tmp0 >= tmp3
    tl.full([1], 1024, tl.int64)
    tmp13 = tl.load(in_ptr2 + (x0 + 64 * (-512 + x1) + 32768 * x2), tmp10,
        other=0.0)
    tmp14 = tl.where(tmp4, tmp9, tmp13)
    tmp15 = tl.full([1], 0, tl.int32)
    tmp16 = triton_helpers.maximum(tmp15, tmp14)
    tl.store(out_ptr0 + x3, tmp16, None)


@triton.jit
def triton_poi_fused_cat_relu_16(in_ptr0, in_ptr1, in_ptr2, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x1 = xindex // 256 % 512
    x0 = xindex % 256
    x2 = xindex // 131072
    x3 = xindex
    tmp0 = x1
    tl.full([1], 0, tl.int64)
    tmp3 = tl.full([1], 256, tl.int64)
    tmp4 = tmp0 < tmp3
    tmp5 = tl.load(in_ptr0 + (x0 + 256 * x1 + 65536 * x2), tmp4, other=0.0)
    tmp6 = tl.load(in_ptr1 + x1, tmp4, eviction_policy='evict_last', other=0.0)
    tmp7 = tmp5 + tmp6
    tmp8 = tl.full(tmp7.shape, 0.0, tmp7.dtype)
    tmp9 = tl.where(tmp4, tmp7, tmp8)
    tmp10 = tmp0 >= tmp3
    tl.full([1], 512, tl.int64)
    tmp13 = tl.load(in_ptr2 + (x0 + 256 * (-256 + x1) + 65536 * x2), tmp10,
        other=0.0)
    tmp14 = tl.where(tmp4, tmp9, tmp13)
    tmp15 = tl.full([1], 0, tl.int32)
    tmp16 = triton_helpers.maximum(tmp15, tmp14)
    tl.store(out_ptr0 + x3, tmp16, None)


@triton.jit
def triton_poi_fused_cat_relu_17(in_ptr0, in_ptr1, in_ptr2, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x1 = xindex // 1024 % 256
    x0 = xindex % 1024
    x2 = xindex // 262144
    x3 = xindex
    tmp0 = x1
    tl.full([1], 0, tl.int64)
    tmp3 = tl.full([1], 128, tl.int64)
    tmp4 = tmp0 < tmp3
    tmp5 = tl.load(in_ptr0 + (x0 + 1024 * x1 + 131072 * x2), tmp4, other=0.0)
    tmp6 = tl.load(in_ptr1 + x1, tmp4, eviction_policy='evict_last', other=0.0)
    tmp7 = tmp5 + tmp6
    tmp8 = tl.full(tmp7.shape, 0.0, tmp7.dtype)
    tmp9 = tl.where(tmp4, tmp7, tmp8)
    tmp10 = tmp0 >= tmp3
    tl.full([1], 256, tl.int64)
    tmp13 = tl.load(in_ptr2 + (x0 + 1024 * (-128 + x1) + 131072 * x2),
        tmp10, other=0.0)
    tmp14 = tl.where(tmp4, tmp9, tmp13)
    tmp15 = tl.full([1], 0, tl.int32)
    tmp16 = triton_helpers.maximum(tmp15, tmp14)
    tl.store(out_ptr0 + x3, tmp16, None)


@triton.jit
def triton_poi_fused_cat_relu_18(in_ptr0, in_ptr1, in_ptr2, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x1 = xindex // 4096 % 128
    x0 = xindex % 4096
    x2 = xindex // 524288
    x3 = xindex
    tmp0 = x1
    tl.full([1], 0, tl.int64)
    tmp3 = tl.full([1], 64, tl.int64)
    tmp4 = tmp0 < tmp3
    tmp5 = tl.load(in_ptr0 + (x0 + 4096 * x1 + 262144 * x2), tmp4, other=0.0)
    tmp6 = tl.load(in_ptr1 + x1, tmp4, eviction_policy='evict_last', other=0.0)
    tmp7 = tmp5 + tmp6
    tmp8 = tl.full(tmp7.shape, 0.0, tmp7.dtype)
    tmp9 = tl.where(tmp4, tmp7, tmp8)
    tmp10 = tmp0 >= tmp3
    tl.full([1], 128, tl.int64)
    tmp13 = tl.load(in_ptr2 + (x0 + 4096 * (-64 + x1) + 262144 * x2), tmp10,
        other=0.0)
    tmp14 = tl.where(tmp4, tmp9, tmp13)
    tmp15 = tl.full([1], 0, tl.int32)
    tmp16 = triton_helpers.maximum(tmp15, tmp14)
    tl.store(out_ptr0 + x3, tmp16, None)


@triton.jit
def triton_poi_fused_convolution_19(in_out_ptr0, in_ptr0, xnumel, XBLOCK:
    tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x0 = xindex
    tmp0 = tl.load(in_out_ptr0 + x0, None)
    tmp1 = tl.load(in_ptr0 + 0)
    tmp2 = tl.broadcast_to(tmp1, [XBLOCK])
    tmp3 = tmp0 + tmp2
    tl.store(in_out_ptr0 + x0, tmp3, None)


def call(args):
    (primals_1, primals_2, primals_3, primals_4, primals_5, primals_6,
        primals_7, primals_8, primals_9, primals_10, primals_11, primals_12,
        primals_13, primals_14, primals_15, primals_16, primals_17,
        primals_18, primals_19, primals_20, primals_21, primals_22,
        primals_23, primals_24, primals_25, primals_26, primals_27,
        primals_28, primals_29, primals_30, primals_31, primals_32,
        primals_33, primals_34, primals_35, primals_36, primals_37,
        primals_38, primals_39, primals_40, primals_41, primals_42,
        primals_43, primals_44, primals_45, primals_46, primals_47) = args
    args.clear()
    assert_size_stride(primals_1, (4, 1, 64, 64), (4096, 4096, 64, 1))
    assert_size_stride(primals_2, (64, 1, 3, 3), (9, 9, 3, 1))
    assert_size_stride(primals_3, (64,), (1,))
    assert_size_stride(primals_4, (64, 64, 3, 3), (576, 9, 3, 1))
    assert_size_stride(primals_5, (64,), (1,))
    assert_size_stride(primals_6, (128, 64, 3, 3), (576, 9, 3, 1))
    assert_size_stride(primals_7, (128,), (1,))
    assert_size_stride(primals_8, (128, 128, 3, 3), (1152, 9, 3, 1))
    assert_size_stride(primals_9, (128,), (1,))
    assert_size_stride(primals_10, (256, 128, 3, 3), (1152, 9, 3, 1))
    assert_size_stride(primals_11, (256,), (1,))
    assert_size_stride(primals_12, (256, 256, 3, 3), (2304, 9, 3, 1))
    assert_size_stride(primals_13, (256,), (1,))
    assert_size_stride(primals_14, (512, 256, 3, 3), (2304, 9, 3, 1))
    assert_size_stride(primals_15, (512,), (1,))
    assert_size_stride(primals_16, (512, 512, 3, 3), (4608, 9, 3, 1))
    assert_size_stride(primals_17, (512,), (1,))
    assert_size_stride(primals_18, (1024, 512, 3, 3), (4608, 9, 3, 1))
    assert_size_stride(primals_19, (1024,), (1,))
    assert_size_stride(primals_20, (1024, 1024, 3, 3), (9216, 9, 3, 1))
    assert_size_stride(primals_21, (1024,), (1,))
    assert_size_stride(primals_22, (1024, 512, 2, 2), (2048, 4, 2, 1))
    assert_size_stride(primals_23, (512,), (1,))
    assert_size_stride(primals_24, (512, 1024, 3, 3), (9216, 9, 3, 1))
    assert_size_stride(primals_25, (512,), (1,))
    assert_size_stride(primals_26, (512, 512, 3, 3), (4608, 9, 3, 1))
    assert_size_stride(primals_27, (512,), (1,))
    assert_size_stride(primals_28, (512, 256, 2, 2), (1024, 4, 2, 1))
    assert_size_stride(primals_29, (256,), (1,))
    assert_size_stride(primals_30, (256, 512, 3, 3), (4608, 9, 3, 1))
    assert_size_stride(primals_31, (256,), (1,))
    assert_size_stride(primals_32, (256, 256, 3, 3), (2304, 9, 3, 1))
    assert_size_stride(primals_33, (256,), (1,))
    assert_size_stride(primals_34, (256, 128, 2, 2), (512, 4, 2, 1))
    assert_size_stride(primals_35, (128,), (1,))
    assert_size_stride(primals_36, (128, 256, 3, 3), (2304, 9, 3, 1))
    assert_size_stride(primals_37, (128,), (1,))
    assert_size_stride(primals_38, (128, 128, 3, 3), (1152, 9, 3, 1))
    assert_size_stride(primals_39, (128,), (1,))
    assert_size_stride(primals_40, (128, 64, 2, 2), (256, 4, 2, 1))
    assert_size_stride(primals_41, (64,), (1,))
    assert_size_stride(primals_42, (64, 128, 3, 3), (1152, 9, 3, 1))
    assert_size_stride(primals_43, (64,), (1,))
    assert_size_stride(primals_44, (64, 64, 3, 3), (576, 9, 3, 1))
    assert_size_stride(primals_45, (64,), (1,))
    assert_size_stride(primals_46, (1, 64, 1, 1), (64, 1, 1, 1))
    assert_size_stride(primals_47, (1,), (1,))
    with torch.cuda._DeviceGuard(0):
        torch.cuda.set_device(0)
        buf0 = empty_strided_cuda((4, 1, 64, 64), (4096, 4096, 64, 1),
            torch.float32)
        get_raw_stream(0)
        triton_poi_fused_relu_0[grid(16384)](primals_1, buf0, primals_1, 
            16384, XBLOCK=256, num_warps=4, num_stages=1)
        del primals_1
        buf1 = extern_kernels.convolution(buf0, primals_2, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf1, (4, 64, 64, 64), (262144, 4096, 64, 1))
        buf2 = buf1
        del buf1
        triton_poi_fused_convolution_relu_1[grid(1048576)](buf2, primals_3,
            1048576, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_3
        buf3 = extern_kernels.convolution(buf2, primals_4, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf3, (4, 64, 64, 64), (262144, 4096, 64, 1))
        buf4 = buf3
        del buf3
        triton_poi_fused_convolution_2[grid(1048576)](buf4, primals_5, 
            1048576, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_5
        buf5 = empty_strided_cuda((4, 64, 32, 32), (65536, 1024, 32, 1),
            torch.int8)
        buf6 = empty_strided_cuda((4, 64, 32, 32), (65536, 1024, 32, 1),
            torch.float32)
        triton_poi_fused_max_pool2d_with_indices_relu_3[grid(262144)](buf4,
            buf5, buf6, 262144, XBLOCK=512, num_warps=8, num_stages=1)
        buf7 = extern_kernels.convolution(buf6, primals_6, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf7, (4, 128, 32, 32), (131072, 1024, 32, 1))
        buf8 = buf7
        del buf7
        triton_poi_fused_convolution_relu_4[grid(524288)](buf8, primals_7, 
            524288, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_7
        buf9 = extern_kernels.convolution(buf8, primals_8, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf9, (4, 128, 32, 32), (131072, 1024, 32, 1))
        buf10 = buf9
        del buf9
        triton_poi_fused_convolution_5[grid(524288)](buf10, primals_9, 
            524288, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_9
        buf11 = empty_strided_cuda((4, 128, 16, 16), (32768, 256, 16, 1),
            torch.int8)
        buf12 = empty_strided_cuda((4, 128, 16, 16), (32768, 256, 16, 1),
            torch.float32)
        triton_poi_fused_max_pool2d_with_indices_relu_6[grid(131072)](buf10,
            buf11, buf12, 131072, XBLOCK=512, num_warps=8, num_stages=1)
        buf13 = extern_kernels.convolution(buf12, primals_10, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf13, (4, 256, 16, 16), (65536, 256, 16, 1))
        buf14 = buf13
        del buf13
        triton_poi_fused_convolution_relu_7[grid(262144)](buf14, primals_11,
            262144, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_11
        buf15 = extern_kernels.convolution(buf14, primals_12, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf15, (4, 256, 16, 16), (65536, 256, 16, 1))
        buf16 = buf15
        del buf15
        triton_poi_fused_convolution_8[grid(262144)](buf16, primals_13, 
            262144, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_13
        buf17 = empty_strided_cuda((4, 256, 8, 8), (16384, 64, 8, 1), torch
            .int8)
        buf18 = empty_strided_cuda((4, 256, 8, 8), (16384, 64, 8, 1), torch
            .float32)
        triton_poi_fused_max_pool2d_with_indices_relu_9[grid(65536)](buf16,
            buf17, buf18, 65536, XBLOCK=256, num_warps=4, num_stages=1)
        buf19 = extern_kernels.convolution(buf18, primals_14, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf19, (4, 512, 8, 8), (32768, 64, 8, 1))
        buf20 = buf19
        del buf19
        triton_poi_fused_convolution_relu_10[grid(131072)](buf20,
            primals_15, 131072, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_15
        buf21 = extern_kernels.convolution(buf20, primals_16, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf21, (4, 512, 8, 8), (32768, 64, 8, 1))
        buf22 = buf21
        del buf21
        triton_poi_fused_convolution_11[grid(131072)](buf22, primals_17, 
            131072, XBLOCK=512, num_warps=8, num_stages=1)
        del primals_17
        buf23 = empty_strided_cuda((4, 512, 4, 4), (8192, 16, 4, 1), torch.int8
            )
        buf24 = empty_strided_cuda((4, 512, 4, 4), (8192, 16, 4, 1), torch.
            float32)
        triton_poi_fused_max_pool2d_with_indices_relu_12[grid(32768)](buf22,
            buf23, buf24, 32768, XBLOCK=128, num_warps=4, num_stages=1)
        buf25 = extern_kernels.convolution(buf24, primals_18, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf25, (4, 1024, 4, 4), (16384, 16, 4, 1))
        buf26 = buf25
        del buf25
        triton_poi_fused_convolution_relu_13[grid(65536)](buf26, primals_19,
            65536, XBLOCK=256, num_warps=4, num_stages=1)
        del primals_19
        buf27 = extern_kernels.convolution(buf26, primals_20, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf27, (4, 1024, 4, 4), (16384, 16, 4, 1))
        buf28 = buf27
        del buf27
        triton_poi_fused_convolution_14[grid(65536)](buf28, primals_21, 
            65536, XBLOCK=256, num_warps=4, num_stages=1)
        del primals_21
        buf29 = extern_kernels.convolution(buf28, primals_22, stride=(2, 2),
            padding=(0, 0), dilation=(1, 1), transposed=True,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf29, (4, 512, 8, 8), (32768, 64, 8, 1))
        buf30 = empty_strided_cuda((4, 1024, 8, 8), (65536, 64, 8, 1),
            torch.float32)
        triton_poi_fused_cat_relu_15[grid(262144)](buf29, primals_23, buf22,
            buf30, 262144, XBLOCK=1024, num_warps=4, num_stages=1)
        del buf29
        del primals_23
        buf31 = extern_kernels.convolution(buf30, primals_24, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf31, (4, 512, 8, 8), (32768, 64, 8, 1))
        buf32 = buf31
        del buf31
        triton_poi_fused_convolution_relu_10[grid(131072)](buf32,
            primals_25, 131072, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_25
        buf33 = extern_kernels.convolution(buf32, primals_26, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf33, (4, 512, 8, 8), (32768, 64, 8, 1))
        buf34 = buf33
        del buf33
        triton_poi_fused_convolution_11[grid(131072)](buf34, primals_27, 
            131072, XBLOCK=512, num_warps=8, num_stages=1)
        del primals_27
        buf35 = extern_kernels.convolution(buf34, primals_28, stride=(2, 2),
            padding=(0, 0), dilation=(1, 1), transposed=True,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf35, (4, 256, 16, 16), (65536, 256, 16, 1))
        buf36 = empty_strided_cuda((4, 512, 16, 16), (131072, 256, 16, 1),
            torch.float32)
        triton_poi_fused_cat_relu_16[grid(524288)](buf35, primals_29, buf16,
            buf36, 524288, XBLOCK=512, num_warps=8, num_stages=1)
        del buf35
        del primals_29
        buf37 = extern_kernels.convolution(buf36, primals_30, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf37, (4, 256, 16, 16), (65536, 256, 16, 1))
        buf38 = buf37
        del buf37
        triton_poi_fused_convolution_relu_7[grid(262144)](buf38, primals_31,
            262144, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_31
        buf39 = extern_kernels.convolution(buf38, primals_32, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf39, (4, 256, 16, 16), (65536, 256, 16, 1))
        buf40 = buf39
        del buf39
        triton_poi_fused_convolution_8[grid(262144)](buf40, primals_33, 
            262144, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_33
        buf41 = extern_kernels.convolution(buf40, primals_34, stride=(2, 2),
            padding=(0, 0), dilation=(1, 1), transposed=True,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf41, (4, 128, 32, 32), (131072, 1024, 32, 1))
        buf42 = empty_strided_cuda((4, 256, 32, 32), (262144, 1024, 32, 1),
            torch.float32)
        triton_poi_fused_cat_relu_17[grid(1048576)](buf41, primals_35,
            buf10, buf42, 1048576, XBLOCK=1024, num_warps=4, num_stages=1)
        del buf41
        del primals_35
        buf43 = extern_kernels.convolution(buf42, primals_36, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf43, (4, 128, 32, 32), (131072, 1024, 32, 1))
        buf44 = buf43
        del buf43
        triton_poi_fused_convolution_relu_4[grid(524288)](buf44, primals_37,
            524288, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_37
        buf45 = extern_kernels.convolution(buf44, primals_38, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf45, (4, 128, 32, 32), (131072, 1024, 32, 1))
        buf46 = buf45
        del buf45
        triton_poi_fused_convolution_5[grid(524288)](buf46, primals_39, 
            524288, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_39
        buf47 = extern_kernels.convolution(buf46, primals_40, stride=(2, 2),
            padding=(0, 0), dilation=(1, 1), transposed=True,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf47, (4, 64, 64, 64), (262144, 4096, 64, 1))
        buf48 = empty_strided_cuda((4, 128, 64, 64), (524288, 4096, 64, 1),
            torch.float32)
        triton_poi_fused_cat_relu_18[grid(2097152)](buf47, primals_41, buf4,
            buf48, 2097152, XBLOCK=1024, num_warps=4, num_stages=1)
        del buf47
        del primals_41
        buf49 = extern_kernels.convolution(buf48, primals_42, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf49, (4, 64, 64, 64), (262144, 4096, 64, 1))
        buf50 = buf49
        del buf49
        triton_poi_fused_convolution_relu_1[grid(1048576)](buf50,
            primals_43, 1048576, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_43
        buf51 = extern_kernels.convolution(buf50, primals_44, stride=(1, 1),
            padding=(1, 1), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf51, (4, 64, 64, 64), (262144, 4096, 64, 1))
        buf52 = buf51
        del buf51
        triton_poi_fused_convolution_2[grid(1048576)](buf52, primals_45, 
            1048576, XBLOCK=1024, num_warps=4, num_stages=1)
        del primals_45
        buf53 = extern_kernels.convolution(buf52, primals_46, stride=(1, 1),
            padding=(0, 0), dilation=(1, 1), transposed=False,
            output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf53, (4, 1, 64, 64), (4096, 4096, 64, 1))
        buf54 = buf53
        del buf53
        triton_poi_fused_convolution_19[grid(16384)](buf54, primals_47, 
            16384, XBLOCK=256, num_warps=4, num_stages=1)
        del primals_47
    return (buf54, primals_2, primals_4, primals_6, primals_8, primals_10,
        primals_12, primals_14, primals_16, primals_18, primals_20,
        primals_22, primals_24, primals_26, primals_28, primals_30,
        primals_32, primals_34, primals_36, primals_38, primals_40,
        primals_42, primals_44, primals_46, buf0, buf2, buf4, buf5, buf6,
        buf8, buf10, buf11, buf12, buf14, buf16, buf17, buf18, buf20, buf22,
        buf23, buf24, buf26, buf28, buf30, buf32, buf34, buf36, buf38,
        buf40, buf42, buf44, buf46, buf48, buf50, buf52)


class double_conv(nn.Module):

    def __init__(self, input_channels, output_channels):
        super(double_conv, self).__init__()
        self.conv1 = nn.Conv2d(input_channels, output_channels, kernel_size
            =3, padding='same')
        self.conv2 = nn.Conv2d(output_channels, output_channels,
            kernel_size=3, padding='same')
        self.relu_activation = nn.ReLU(inplace=True)

    def forward(self, x):
        x = self.conv1(self.relu_activation(x))
        x = self.conv2(self.relu_activation(x))
        return x


class traspose_conv(nn.Module):

    def __init__(self, num_of_channels):
        super(traspose_conv, self).__init__()
        self.trasnpose_conv = nn.ConvTranspose2d(num_of_channels, int(
            num_of_channels / 2), kernel_size=2, stride=2)

    def forward(self, x):
        x = self.trasnpose_conv(x)
        return x


class double_decoder_conv(nn.Module):

    def __init__(self, input_channels1, output_channels1, output_channels2):
        super(double_decoder_conv, self).__init__()
        self.conv1 = nn.Conv2d(input_channels1, output_channels1,
            kernel_size=3, padding='same')
        self.conv2 = nn.Conv2d(output_channels1, output_channels2,
            kernel_size=3, padding='same')
        self.relu_activation = nn.ReLU(inplace=True)

    def forward(self, x):
        x = self.conv1(self.relu_activation(x))
        x = self.conv2(self.relu_activation(x))
        return x


class UNetNew(nn.Module):

    def __init__(self):
        super(UNetNew, self).__init__()
        self.double_conv1 = double_conv(1, 64)
        self.double_conv2 = double_conv(64, 128)
        self.double_conv3 = double_conv(128, 256)
        self.double_conv4 = double_conv(256, 512)
        self.double_conv5 = double_conv(512, 1024)
        self.maxpool = nn.MaxPool2d(kernel_size=2, stride=2)
        self.traspose_conv1 = traspose_conv(1024)
        self.traspose_conv2 = traspose_conv(512)
        self.traspose_conv3 = traspose_conv(256)
        self.traspose_conv4 = traspose_conv(128)
        self.double_decoder_conv1 = double_decoder_conv(1024, 512, 512)
        self.double_decoder_conv2 = double_decoder_conv(512, 256, 256)
        self.double_decoder_conv3 = double_decoder_conv(256, 128, 128)
        self.double_decoder_conv4 = double_decoder_conv(128, 64, 64)
        self.final_conv = nn.Conv2d(64, 1, kernel_size=1, padding='same')

    def forward(self, input_0):
        primals_2 = self.double_conv1.conv1.weight
        primals_3 = self.double_conv1.conv1.bias
        primals_4 = self.double_conv1.conv2.weight
        primals_5 = self.double_conv1.conv2.bias
        primals_6 = self.double_conv2.conv1.weight
        primals_7 = self.double_conv2.conv1.bias
        primals_8 = self.double_conv2.conv2.weight
        primals_9 = self.double_conv2.conv2.bias
        primals_10 = self.double_conv3.conv1.weight
        primals_11 = self.double_conv3.conv1.bias
        primals_12 = self.double_conv3.conv2.weight
        primals_13 = self.double_conv3.conv2.bias
        primals_14 = self.double_conv4.conv1.weight
        primals_15 = self.double_conv4.conv1.bias
        primals_16 = self.double_conv4.conv2.weight
        primals_17 = self.double_conv4.conv2.bias
        primals_18 = self.double_conv5.conv1.weight
        primals_19 = self.double_conv5.conv1.bias
        primals_20 = self.double_conv5.conv2.weight
        primals_21 = self.double_conv5.conv2.bias
        primals_22 = self.traspose_conv1.trasnpose_conv.weight
        primals_23 = self.traspose_conv1.trasnpose_conv.bias
        primals_28 = self.traspose_conv2.trasnpose_conv.weight
        primals_29 = self.traspose_conv2.trasnpose_conv.bias
        primals_34 = self.traspose_conv3.trasnpose_conv.weight
        primals_35 = self.traspose_conv3.trasnpose_conv.bias
        primals_40 = self.traspose_conv4.trasnpose_conv.weight
        primals_41 = self.traspose_conv4.trasnpose_conv.bias
        primals_24 = self.double_decoder_conv1.conv1.weight
        primals_25 = self.double_decoder_conv1.conv1.bias
        primals_26 = self.double_decoder_conv1.conv2.weight
        primals_27 = self.double_decoder_conv1.conv2.bias
        primals_30 = self.double_decoder_conv2.conv1.weight
        primals_31 = self.double_decoder_conv2.conv1.bias
        primals_32 = self.double_decoder_conv2.conv2.weight
        primals_33 = self.double_decoder_conv2.conv2.bias
        primals_36 = self.double_decoder_conv3.conv1.weight
        primals_37 = self.double_decoder_conv3.conv1.bias
        primals_38 = self.double_decoder_conv3.conv2.weight
        primals_39 = self.double_decoder_conv3.conv2.bias
        primals_42 = self.double_decoder_conv4.conv1.weight
        primals_43 = self.double_decoder_conv4.conv1.bias
        primals_44 = self.double_decoder_conv4.conv2.weight
        primals_45 = self.double_decoder_conv4.conv2.bias
        primals_46 = self.final_conv.weight
        primals_47 = self.final_conv.bias
        primals_1 = input_0
        output = call([primals_1, primals_2, primals_3, primals_4,
            primals_5, primals_6, primals_7, primals_8, primals_9,
            primals_10, primals_11, primals_12, primals_13, primals_14,
            primals_15, primals_16, primals_17, primals_18, primals_19,
            primals_20, primals_21, primals_22, primals_23, primals_24,
            primals_25, primals_26, primals_27, primals_28, primals_29,
            primals_30, primals_31, primals_32, primals_33, primals_34,
            primals_35, primals_36, primals_37, primals_38, primals_39,
            primals_40, primals_41, primals_42, primals_43, primals_44,
            primals_45, primals_46, primals_47])
        return output[0]


Measured latency_ms: 0.023209