# AOT ID: ['0_forward']
from ctypes import c_void_p, c_long, c_int
import torch
import math
import random
import os
import tempfile
from math import inf, nan
from torch._inductor.hooks import run_intermediate_hooks
from torch._inductor.utils import maybe_profile
from torch._inductor.codegen.memory_planning import _align as align
from torch import device, empty_strided
from torch._inductor.async_compile import AsyncCompile
from torch._inductor.select_algorithm import extern_kernels
from torch._inductor.codegen.multi_kernel import MultiKernelCall
import triton
import triton.language as tl
from torch._inductor.runtime.triton_heuristics import grid, split_scan_grid, grid_combo_kernels, start_graph, end_graph
from torch._C import _cuda_getCurrentRawStream as get_raw_stream

aten = torch.ops.aten
inductor_ops = torch.ops.inductor
_quantized = torch.ops._quantized
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cpu = torch._C._dynamo.guards._empty_strided_cpu
empty_strided_cuda = torch._C._dynamo.guards._empty_strided_cuda
empty_strided_xpu = torch._C._dynamo.guards._empty_strided_xpu
reinterpret_tensor = torch._C._dynamo.guards._reinterpret_tensor
alloc_from_pool = torch.ops.inductor._alloc_from_pool
async_compile = AsyncCompile()


# kernel path: runs/run_shard_7/inductor_cache/4n/c4nqo5grlrit5lmmzyvvr4b4jaxbu4da4u3recsuxjhj4z33ebee.py
# Unsorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
triton_poi_fused_0 = async_compile.triton('triton_poi_fused_0', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[65536, 32], tile_hint=TileHint.SQUARE,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: 'i32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_0', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_0(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK : tl.constexpr, XBLOCK : tl.constexpr):
    ynumel = 61440
    xnumel = 25
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = tl.full([XBLOCK, YBLOCK], True, tl.int1)
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 192
    y1 = (yindex // 192)
    tmp0 = tl.load(in_ptr0 + (x2 + (25*y3)), xmask, eviction_policy='evict_last')
    tl.store(out_ptr0 + (y0 + (192*x2) + (4800*y1)), tmp0, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/rs/crschneg3kvye3kuwch7myvnxivcwiau22prtweju442z2v6tr7s.py
# Unsorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
triton_poi_fused_1 = async_compile.triton('triton_poi_fused_1', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[2048, 16], tile_hint=TileHint.SQUARE,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: 'i32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_1', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_1(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK : tl.constexpr, XBLOCK : tl.constexpr):
    ynumel = 1280
    xnumel = 16
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = yindex < ynumel
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 320
    y1 = (yindex // 320)
    tmp0 = tl.load(in_ptr0 + (x2 + (16*y3)), xmask & ymask, eviction_policy='evict_last')
    tl.store(out_ptr0 + (y0 + (320*x2) + (5120*y1)), tmp0, xmask & ymask)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/ii/ciillaxyhgye3tvsrtkgjmpxnrkn67tpnzlawb2zuma4x3u5wdlo.py
# Unsorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
triton_poi_fused_2 = async_compile.triton('triton_poi_fused_2', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[65536, 32], tile_hint=TileHint.SQUARE,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: 'i32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_2', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_2(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK : tl.constexpr, XBLOCK : tl.constexpr):
    ynumel = 36864
    xnumel = 25
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = tl.full([XBLOCK, YBLOCK], True, tl.int1)
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 192
    y1 = (yindex // 192)
    tmp0 = tl.load(in_ptr0 + (x2 + (25*y3)), xmask, eviction_policy='evict_last')
    tl.store(out_ptr0 + (y0 + (192*x2) + (4800*y1)), tmp0, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/kd/ckd3zxo3eoxbqovhr35s3zxwuhhw3ndu4jrxzfm7775qyiuynzfo.py
# Unsorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
triton_poi_fused_3 = async_compile.triton('triton_poi_fused_3', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[1024, 32], tile_hint=TileHint.SQUARE,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: 'i32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_3', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_3(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK : tl.constexpr, XBLOCK : tl.constexpr):
    ynumel = 576
    xnumel = 25
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = yindex < ynumel
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 3
    y1 = (yindex // 3)
    tmp0 = tl.load(in_ptr0 + (x2 + (25*y3)), xmask & ymask, eviction_policy='evict_last')
    tl.store(out_ptr0 + (y0 + (3*x2) + (75*y1)), tmp0, xmask & ymask)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/k4/ck4v5mrrogvczni3qdwtiec3hzxl2msvobvw7cdbwfz2vw75wg7h.py
# Topologically Sorted Source Nodes: [conv_transpose2d, pow_3], Original ATen: [aten.convolution, aten.pow]
# Source node to ATen node mapping:
#   conv_transpose2d => convolution
#   pow_3 => pow_3
# Graph fragment:
#   %convolution : [num_users=3] = call_function[target=torch.ops.aten.convolution.default](args = (%primals_3, %primals_1, %primals_2, [2, 2], [2, 2], [1, 1], True, [1, 1], 1), kwargs = {})
#   %pow_3 : [num_users=2] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%convolution, 2), kwargs = {})
triton_poi_fused_convolution_pow_4 = async_compile.triton('triton_poi_fused_convolution_pow_4', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[65536], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_pow_4', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 2, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_pow_4(in_out_ptr0, in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 49152
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + (x2), None)
    tmp1 = tl.load(in_ptr0 + (x0), None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tmp2 * tmp2
    tl.store(in_out_ptr0 + (x2), tmp2, None)
    tl.store(out_ptr0 + (x2), tmp3, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/6g/c6gbex743ouacies5yjrzwvxv4d6uicjzoy47ao3vs5ue4iej5kk.py
# Topologically Sorted Source Nodes: [gamma, pow_2, gamma_1], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub]
# Source node to ATen node mapping:
#   gamma => full_default_1, maximum_1
#   gamma_1 => sub_1
#   pow_2 => pow_2
# Graph fragment:
#   %full_default_1 : [num_users=5] = call_function[target=torch.ops.aten.full.default](args = ([192, 192], 3.814697265625e-06), kwargs = {dtype: torch.float32, layout: torch.strided, device: cuda:0, pin_memory: False})
#   %maximum_1 : [num_users=1] = call_function[target=torch.ops.aten.maximum.default](args = (%primals_5, %full_default_1), kwargs = {})
#   %pow_2 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum_1, 2), kwargs = {})
#   %sub_1 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%pow_2, 1.4551915228366852e-11), kwargs = {})
triton_poi_fused_maximum_mul_pow_sub_5 = async_compile.triton('triton_poi_fused_maximum_mul_pow_sub_5', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[65536], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_maximum_mul_pow_sub_5', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_maximum_mul_pow_sub_5(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 36864
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (x0), None)
    tmp1 = 3.814697265625e-06
    tmp2 = triton_helpers.maximum(tmp0, tmp1)
    tmp3 = tmp2 * tmp2
    tmp4 = 1.4551915228366852e-11
    tmp5 = tmp3 - tmp4
    tl.store(out_ptr0 + (x0), tmp5, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/ma/cmaubmvm6x5ray2d4ualpba23p4vufvwun5ed5sp2ksk5bd35xlb.py
# Topologically Sorted Source Nodes: [beta, pow_1, beta_1, norm_, norm__1, outputs], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution, aten.sqrt]
# Source node to ATen node mapping:
#   beta => full_default, maximum
#   beta_1 => sub
#   norm_ => convolution_1
#   norm__1 => sqrt
#   outputs => mul_2
#   pow_1 => pow_1
# Graph fragment:
#   %full_default : [num_users=5] = call_function[target=torch.ops.aten.full.default](args = ([192], 0.0010000072652474046), kwargs = {dtype: torch.float32, layout: torch.strided, device: cuda:0, pin_memory: False})
#   %maximum : [num_users=1] = call_function[target=torch.ops.aten.maximum.default](args = (%primals_4, %full_default), kwargs = {})
#   %pow_1 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum, 2), kwargs = {})
#   %sub : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%pow_1, 1.4551915228366852e-11), kwargs = {})
#   %convolution_1 : [num_users=2] = call_function[target=torch.ops.aten.convolution.default](args = (%pow_3, %view, %sub, [1, 1], [0, 0], [1, 1], False, [0, 0], 1), kwargs = {})
#   %sqrt : [num_users=1] = call_function[target=torch.ops.aten.sqrt.default](args = (%convolution_1,), kwargs = {})
#   %mul_2 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%convolution, %sqrt), kwargs = {})
triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6 = async_compile.triton('triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[65536], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3, 4), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 3, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6(in_out_ptr0, in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 49152
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + (x2), None)
    tmp1 = tl.load(in_ptr0 + (x0), None, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr1 + (x2), None)
    tmp2 = 0.0010000072652474046
    tmp3 = triton_helpers.maximum(tmp1, tmp2)
    tmp4 = tmp3 * tmp3
    tmp5 = 1.4551915228366852e-11
    tmp6 = tmp4 - tmp5
    tmp7 = tmp0 + tmp6
    tmp9 = libdevice.sqrt(tmp7)
    tmp10 = tmp8 * tmp9
    tl.store(in_out_ptr0 + (x2), tmp7, None)
    tl.store(out_ptr0 + (x2), tmp10, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/x4/cx4ac643qojszmjtzwt6ozkxaamlordjcbqdqd6iouokmhwufttr.py
# Topologically Sorted Source Nodes: [conv_transpose2d_1, pow_6], Original ATen: [aten.convolution, aten.pow]
# Source node to ATen node mapping:
#   conv_transpose2d_1 => convolution_2
#   pow_6 => pow_6
# Graph fragment:
#   %convolution_2 : [num_users=3] = call_function[target=torch.ops.aten.convolution.default](args = (%mul_2, %primals_6, %primals_7, [2, 2], [2, 2], [1, 1], True, [1, 1], 1), kwargs = {})
#   %pow_6 : [num_users=2] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%convolution_2, 2), kwargs = {})
triton_poi_fused_convolution_pow_7 = async_compile.triton('triton_poi_fused_convolution_pow_7', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[262144], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_pow_7', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 2, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_pow_7(in_out_ptr0, in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 196608
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + (x2), None)
    tmp1 = tl.load(in_ptr0 + (x0), None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tmp2 * tmp2
    tl.store(in_out_ptr0 + (x2), tmp2, None)
    tl.store(out_ptr0 + (x2), tmp3, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/tb/ctb5lb7ljulmsfb6wsmeoaxme5qlnejo4wywpvrz76r4vl67djhz.py
# Topologically Sorted Source Nodes: [gamma, gamma_3, pow_5, gamma_4], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.ge]
# Source node to ATen node mapping:
#   gamma => full_default_1
#   gamma_3 => maximum_3
#   gamma_4 => sub_3
#   pow_5 => pow_5
# Graph fragment:
#   %full_default_1 : [num_users=5] = call_function[target=torch.ops.aten.full.default](args = ([192, 192], 3.814697265625e-06), kwargs = {dtype: torch.float32, layout: torch.strided, device: cuda:0, pin_memory: False})
#   %maximum_3 : [num_users=2] = call_function[target=torch.ops.aten.maximum.default](args = (%primals_9, %full_default_1), kwargs = {})
#   %pow_5 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum_3, 2), kwargs = {})
#   %sub_3 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%pow_5, 1.4551915228366852e-11), kwargs = {})
#   %pow_14 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum_3, 1.0), kwargs = {})
#   %mul_25 : [num_users=1] = call_function[target=torch.ops.aten.mul.Scalar](args = (%pow_14, 2.0), kwargs = {})
#   %ge_2 : [num_users=1] = call_function[target=torch.ops.aten.ge.Tensor](args = (%primals_9, %full_default_1), kwargs = {})
triton_poi_fused_ge_maximum_mul_pow_sub_8 = async_compile.triton('triton_poi_fused_ge_maximum_mul_pow_sub_8', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[65536], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*i1', 4: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3, 4), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_ge_maximum_mul_pow_sub_8', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_ge_maximum_mul_pow_sub_8(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK : tl.constexpr):
    xnumel = 36864
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (x0), None)
    tmp1 = 3.814697265625e-06
    tmp2 = triton_helpers.maximum(tmp0, tmp1)
    tmp3 = tmp2 * tmp2
    tmp4 = 1.4551915228366852e-11
    tmp5 = tmp3 - tmp4
    tmp6 = 2.0
    tmp7 = tmp2 * tmp6
    tmp8 = tmp0 >= tmp1
    tl.store(out_ptr0 + (x0), tmp5, None)
    tl.store(out_ptr1 + (x0), tmp7, None)
    tl.store(out_ptr2 + (x0), tmp8, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/sk/cskr6dg7zebx6ayzi6uxfz77bly2f4mgpujcytypuxkeer3rje5a.py
# Topologically Sorted Source Nodes: [beta, beta_2, pow_4, beta_3, norm__2, norm__3, outputs_1], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution, aten.sqrt]
# Source node to ATen node mapping:
#   beta => full_default
#   beta_2 => maximum_2
#   beta_3 => sub_2
#   norm__2 => convolution_3
#   norm__3 => sqrt_1
#   outputs_1 => mul_5
#   pow_4 => pow_4
# Graph fragment:
#   %full_default : [num_users=5] = call_function[target=torch.ops.aten.full.default](args = ([192], 0.0010000072652474046), kwargs = {dtype: torch.float32, layout: torch.strided, device: cuda:0, pin_memory: False})
#   %maximum_2 : [num_users=2] = call_function[target=torch.ops.aten.maximum.default](args = (%primals_8, %full_default), kwargs = {})
#   %pow_4 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum_2, 2), kwargs = {})
#   %sub_2 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%pow_4, 1.4551915228366852e-11), kwargs = {})
#   %convolution_3 : [num_users=2] = call_function[target=torch.ops.aten.convolution.default](args = (%pow_6, %view_1, %sub_2, [1, 1], [0, 0], [1, 1], False, [0, 0], 1), kwargs = {})
#   %sqrt_1 : [num_users=1] = call_function[target=torch.ops.aten.sqrt.default](args = (%convolution_3,), kwargs = {})
#   %mul_5 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%convolution_2, %sqrt_1), kwargs = {})
triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9 = async_compile.triton('triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[262144], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3, 4), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 3, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9(in_out_ptr0, in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 196608
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + (x2), None)
    tmp1 = tl.load(in_ptr0 + (x0), None, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr1 + (x2), None)
    tmp2 = 0.0010000072652474046
    tmp3 = triton_helpers.maximum(tmp1, tmp2)
    tmp4 = tmp3 * tmp3
    tmp5 = 1.4551915228366852e-11
    tmp6 = tmp4 - tmp5
    tmp7 = tmp0 + tmp6
    tmp9 = libdevice.sqrt(tmp7)
    tmp10 = tmp8 * tmp9
    tl.store(in_out_ptr0 + (x2), tmp7, None)
    tl.store(out_ptr0 + (x2), tmp10, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/yk/cykmdry7fdyxl4owrvajfjc2fcgy6hagpeat3wnqwvv53rcr2v6c.py
# Topologically Sorted Source Nodes: [conv_transpose2d_2, pow_9], Original ATen: [aten.convolution, aten.pow]
# Source node to ATen node mapping:
#   conv_transpose2d_2 => convolution_4
#   pow_9 => pow_9
# Graph fragment:
#   %convolution_4 : [num_users=3] = call_function[target=torch.ops.aten.convolution.default](args = (%mul_5, %primals_10, %primals_11, [2, 2], [2, 2], [1, 1], True, [1, 1], 1), kwargs = {})
#   %pow_9 : [num_users=2] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%convolution_4, 2), kwargs = {})
triton_poi_fused_convolution_pow_10 = async_compile.triton('triton_poi_fused_convolution_pow_10', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[1048576], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_pow_10', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 2, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_pow_10(in_out_ptr0, in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 786432
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + (x2), None)
    tmp1 = tl.load(in_ptr0 + (x0), None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tmp2 * tmp2
    tl.store(in_out_ptr0 + (x2), tmp2, None)
    tl.store(out_ptr0 + (x2), tmp3, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/3v/c3vv5mwzilryp2l3jqqicod2tskfjauwm3mst66y37vpfqw7b5pc.py
# Topologically Sorted Source Nodes: [beta, beta_4, pow_7, beta_5, norm__4, norm__5, outputs_2], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution, aten.sqrt]
# Source node to ATen node mapping:
#   beta => full_default
#   beta_4 => maximum_4
#   beta_5 => sub_4
#   norm__4 => convolution_5
#   norm__5 => sqrt_2
#   outputs_2 => mul_8
#   pow_7 => pow_7
# Graph fragment:
#   %full_default : [num_users=5] = call_function[target=torch.ops.aten.full.default](args = ([192], 0.0010000072652474046), kwargs = {dtype: torch.float32, layout: torch.strided, device: cuda:0, pin_memory: False})
#   %maximum_4 : [num_users=2] = call_function[target=torch.ops.aten.maximum.default](args = (%primals_12, %full_default), kwargs = {})
#   %pow_7 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum_4, 2), kwargs = {})
#   %sub_4 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%pow_7, 1.4551915228366852e-11), kwargs = {})
#   %convolution_5 : [num_users=2] = call_function[target=torch.ops.aten.convolution.default](args = (%pow_9, %view_2, %sub_4, [1, 1], [0, 0], [1, 1], False, [0, 0], 1), kwargs = {})
#   %sqrt_2 : [num_users=1] = call_function[target=torch.ops.aten.sqrt.default](args = (%convolution_5,), kwargs = {})
#   %mul_8 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%convolution_4, %sqrt_2), kwargs = {})
triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11 = async_compile.triton('triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[1048576], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3, 4), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 3, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11(in_out_ptr0, in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 786432
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + (x2), None)
    tmp1 = tl.load(in_ptr0 + (x0), None, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr1 + (x2), None)
    tmp2 = 0.0010000072652474046
    tmp3 = triton_helpers.maximum(tmp1, tmp2)
    tmp4 = tmp3 * tmp3
    tmp5 = 1.4551915228366852e-11
    tmp6 = tmp4 - tmp5
    tmp7 = tmp0 + tmp6
    tmp9 = libdevice.sqrt(tmp7)
    tmp10 = tmp8 * tmp9
    tl.store(in_out_ptr0 + (x2), tmp7, None)
    tl.store(out_ptr0 + (x2), tmp10, None)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/fg/cfgrlsu4faeplr4s3vhd7hx4eh6myzadnc4cayzvcnm2n5blp5wk.py
# Topologically Sorted Source Nodes: [x], Original ATen: [aten.convolution]
# Source node to ATen node mapping:
#   x => convolution_6
# Graph fragment:
#   %convolution_6 : [num_users=1] = call_function[target=torch.ops.aten.convolution.default](args = (%mul_8, %primals_14, %primals_15, [2, 2], [2, 2], [1, 1], True, [1, 1], 1), kwargs = {})
triton_poi_fused_convolution_12 = async_compile.triton('triton_poi_fused_convolution_12', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[16, 4096], tile_hint=TileHint.DEFAULT,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: 'i32', 4: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 4), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_convolution_12', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 2, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_convolution_12(in_ptr0, in_ptr1, out_ptr0, ynumel, xnumel, YBLOCK : tl.constexpr, XBLOCK : tl.constexpr):
    ynumel = 12
    xnumel = 4096
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = yindex < ynumel
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = tl.full([XBLOCK, YBLOCK], True, tl.int1)
    x2 = xindex
    y0 = yindex % 3
    y1 = (yindex // 3)
    y3 = yindex
    tmp0 = tl.load(in_ptr0 + (y0 + (3*x2) + (12288*y1)), ymask, eviction_policy='evict_last')
    tmp1 = tl.load(in_ptr1 + (y0), ymask, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(out_ptr0 + (x2 + (4096*y3)), tmp2, ymask)
''', device_str='cuda')


# kernel path: runs/run_shard_7/inductor_cache/qt/cqtikzj3dhv4hmlzfc4qpxybeeekea326e3s6dj4ojfaeizdpbed.py
# Topologically Sorted Source Nodes: [beta, beta_4], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.ge]
# Source node to ATen node mapping:
#   beta => full_default
#   beta_4 => maximum_4
# Graph fragment:
#   %full_default : [num_users=5] = call_function[target=torch.ops.aten.full.default](args = ([192], 0.0010000072652474046), kwargs = {dtype: torch.float32, layout: torch.strided, device: cuda:0, pin_memory: False})
#   %maximum_4 : [num_users=2] = call_function[target=torch.ops.aten.maximum.default](args = (%primals_12, %full_default), kwargs = {})
#   %pow_12 : [num_users=1] = call_function[target=torch.ops.aten.pow.Tensor_Scalar](args = (%maximum_4, 1.0), kwargs = {})
#   %mul_17 : [num_users=1] = call_function[target=torch.ops.aten.mul.Scalar](args = (%pow_12, 2.0), kwargs = {})
#   %ge_1 : [num_users=1] = call_function[target=torch.ops.aten.ge.Tensor](args = (%primals_12, %full_default), kwargs = {})
triton_poi_fused_ge_maximum_mul_pow_13 = async_compile.triton('triton_poi_fused_ge_maximum_mul_pow_13', '''
import triton
import triton.language as tl
from triton.compiler.compiler import AttrsDescriptor

from torch._inductor.runtime import triton_helpers, triton_heuristics
from torch._inductor.runtime.triton_helpers import libdevice, math as tl_math
from torch._inductor.runtime.hints import AutotuneHint, ReductionHint, TileHint, instance_descriptor, DeviceProperties

@triton_heuristics.pointwise(
    size_hints=[256], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*i1', 3: 'i32'}, 'device': DeviceProperties(type='cuda', index=0, cc=80, major=8, regs_per_multiprocessor=65536, max_threads_per_multi_processor=2048, multi_processor_count=108), 'constants': {}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_ge_maximum_mul_pow_13', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 0, 'backend_hash': 'A9C866B4A14FD3277824029365D703C2427B2E685E54EC9B3EF4ADC8D1EEAC1D', 'are_deterministic_algorithms_enabled': False, 'assert_indirect_indexing': True, 'autotune_local_cache': True, 'autotune_pointwise': True, 'autotune_remote_cache': None, 'force_disable_caches': False, 'dynamic_scale_rblock': True, 'max_autotune': False, 'max_autotune_pointwise': False, 'min_split_scan_rblock': 256, 'spill_threshold': 16, 'store_cubin': False},
    min_elem_per_thread=0
)
@triton.jit
def triton_poi_fused_ge_maximum_mul_pow_13(in_ptr0, out_ptr0, out_ptr1, xnumel, XBLOCK : tl.constexpr):
    xnumel = 192
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (x0), xmask)
    tmp1 = 0.0010000072652474046
    tmp2 = triton_helpers.maximum(tmp0, tmp1)
    tmp3 = 2.0
    tmp4 = tmp2 * tmp3
    tmp5 = tmp0 >= tmp1
    tl.store(out_ptr0 + (x0), tmp4, xmask)
    tl.store(out_ptr1 + (x0), tmp5, xmask)
''', device_str='cuda')


async_compile.wait(globals())
del async_compile

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 = args
    args.clear()
    assert_size_stride(primals_1, (320, 192, 5, 5), (4800, 25, 5, 1))
    assert_size_stride(primals_2, (192, ), (1, ))
    assert_size_stride(primals_3, (4, 320, 4, 4), (5120, 16, 4, 1))
    assert_size_stride(primals_4, (192, ), (1, ))
    assert_size_stride(primals_5, (192, 192), (192, 1))
    assert_size_stride(primals_6, (192, 192, 5, 5), (4800, 25, 5, 1))
    assert_size_stride(primals_7, (192, ), (1, ))
    assert_size_stride(primals_8, (192, ), (1, ))
    assert_size_stride(primals_9, (192, 192), (192, 1))
    assert_size_stride(primals_10, (192, 192, 5, 5), (4800, 25, 5, 1))
    assert_size_stride(primals_11, (192, ), (1, ))
    assert_size_stride(primals_12, (192, ), (1, ))
    assert_size_stride(primals_13, (192, 192), (192, 1))
    assert_size_stride(primals_14, (192, 3, 5, 5), (75, 25, 5, 1))
    assert_size_stride(primals_15, (3, ), (1, ))
    with torch.cuda._DeviceGuard(0):
        torch.cuda.set_device(0)
        buf0 = empty_strided_cuda((320, 192, 5, 5), (4800, 1, 960, 192), torch.float32)
        # Unsorted Source Nodes: [], Original ATen: []
        stream0 = get_raw_stream(0)
        triton_poi_fused_0.run(primals_1, buf0, 61440, 25, grid=grid(61440, 25), stream=stream0)
        del primals_1
        buf1 = empty_strided_cuda((4, 320, 4, 4), (5120, 1, 1280, 320), torch.float32)
        # Unsorted Source Nodes: [], Original ATen: []
        triton_poi_fused_1.run(primals_3, buf1, 1280, 16, grid=grid(1280, 16), stream=stream0)
        del primals_3
        buf2 = empty_strided_cuda((192, 192, 5, 5), (4800, 1, 960, 192), torch.float32)
        # Unsorted Source Nodes: [], Original ATen: []
        triton_poi_fused_2.run(primals_6, buf2, 36864, 25, grid=grid(36864, 25), stream=stream0)
        del primals_6
        buf3 = empty_strided_cuda((192, 192, 5, 5), (4800, 1, 960, 192), torch.float32)
        # Unsorted Source Nodes: [], Original ATen: []
        triton_poi_fused_2.run(primals_10, buf3, 36864, 25, grid=grid(36864, 25), stream=stream0)
        del primals_10
        buf4 = empty_strided_cuda((192, 3, 5, 5), (75, 1, 15, 3), torch.float32)
        # Unsorted Source Nodes: [], Original ATen: []
        triton_poi_fused_3.run(primals_14, buf4, 576, 25, grid=grid(576, 25), stream=stream0)
        del primals_14
        # Topologically Sorted Source Nodes: [conv_transpose2d], Original ATen: [aten.convolution]
        buf5 = extern_kernels.convolution(buf1, buf0, stride=(2, 2), padding=(2, 2), dilation=(1, 1), transposed=True, output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf5, (4, 192, 8, 8), (12288, 1, 1536, 192))
        buf6 = buf5; del buf5  # reuse
        buf8 = empty_strided_cuda((4, 192, 8, 8), (12288, 1, 1536, 192), torch.float32)
        # Topologically Sorted Source Nodes: [conv_transpose2d, pow_3], Original ATen: [aten.convolution, aten.pow]
        triton_poi_fused_convolution_pow_4.run(buf6, primals_2, buf8, 49152, grid=grid(49152), stream=stream0)
        del primals_2
        buf7 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        # Topologically Sorted Source Nodes: [gamma, pow_2, gamma_1], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub]
        triton_poi_fused_maximum_mul_pow_sub_5.run(primals_5, buf7, 36864, grid=grid(36864), stream=stream0)
        # Topologically Sorted Source Nodes: [beta, pow_1, beta_1, norm_], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution]
        buf9 = extern_kernels.convolution(buf8, reinterpret_tensor(buf7, (192, 192, 1, 1), (192, 1, 0, 0), 0), stride=(1, 1), padding=(0, 0), dilation=(1, 1), transposed=False, output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf9, (4, 192, 8, 8), (12288, 1, 1536, 192))
        buf10 = buf9; del buf9  # reuse
        buf11 = empty_strided_cuda((4, 192, 8, 8), (12288, 1, 1536, 192), torch.float32)
        # Topologically Sorted Source Nodes: [beta, pow_1, beta_1, norm_, norm__1, outputs], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution, aten.sqrt]
        triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6.run(buf10, primals_4, buf6, buf11, 49152, grid=grid(49152), stream=stream0)
        # Topologically Sorted Source Nodes: [conv_transpose2d_1], Original ATen: [aten.convolution]
        buf12 = extern_kernels.convolution(buf11, buf2, stride=(2, 2), padding=(2, 2), dilation=(1, 1), transposed=True, output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf12, (4, 192, 16, 16), (49152, 1, 3072, 192))
        buf13 = buf12; del buf12  # reuse
        buf15 = empty_strided_cuda((4, 192, 16, 16), (49152, 1, 3072, 192), torch.float32)
        # Topologically Sorted Source Nodes: [conv_transpose2d_1, pow_6], Original ATen: [aten.convolution, aten.pow]
        triton_poi_fused_convolution_pow_7.run(buf13, primals_7, buf15, 196608, grid=grid(196608), stream=stream0)
        del primals_7
        buf14 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf32 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf33 = empty_strided_cuda((192, 192), (192, 1), torch.bool)
        # Topologically Sorted Source Nodes: [gamma, gamma_3, pow_5, gamma_4], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.ge]
        triton_poi_fused_ge_maximum_mul_pow_sub_8.run(primals_9, buf14, buf32, buf33, 36864, grid=grid(36864), stream=stream0)
        del primals_9
        # Topologically Sorted Source Nodes: [beta, beta_2, pow_4, beta_3, norm__2], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution]
        buf16 = extern_kernels.convolution(buf15, reinterpret_tensor(buf14, (192, 192, 1, 1), (192, 1, 0, 0), 0), stride=(1, 1), padding=(0, 0), dilation=(1, 1), transposed=False, output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf16, (4, 192, 16, 16), (49152, 1, 3072, 192))
        buf17 = buf16; del buf16  # reuse
        buf18 = empty_strided_cuda((4, 192, 16, 16), (49152, 1, 3072, 192), torch.float32)
        # Topologically Sorted Source Nodes: [beta, beta_2, pow_4, beta_3, norm__2, norm__3, outputs_1], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution, aten.sqrt]
        triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9.run(buf17, primals_8, buf13, buf18, 196608, grid=grid(196608), stream=stream0)
        # Topologically Sorted Source Nodes: [conv_transpose2d_2], Original ATen: [aten.convolution]
        buf19 = extern_kernels.convolution(buf18, buf3, stride=(2, 2), padding=(2, 2), dilation=(1, 1), transposed=True, output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf19, (4, 192, 32, 32), (196608, 1, 6144, 192))
        buf20 = buf19; del buf19  # reuse
        buf22 = empty_strided_cuda((4, 192, 32, 32), (196608, 1, 6144, 192), torch.float32)
        # Topologically Sorted Source Nodes: [conv_transpose2d_2, pow_9], Original ATen: [aten.convolution, aten.pow]
        triton_poi_fused_convolution_pow_10.run(buf20, primals_11, buf22, 786432, grid=grid(786432), stream=stream0)
        del primals_11
        buf21 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf28 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf29 = empty_strided_cuda((192, 192), (192, 1), torch.bool)
        # Topologically Sorted Source Nodes: [gamma, gamma_6, pow_8, gamma_7], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.ge]
        triton_poi_fused_ge_maximum_mul_pow_sub_8.run(primals_13, buf21, buf28, buf29, 36864, grid=grid(36864), stream=stream0)
        del primals_13
        # Topologically Sorted Source Nodes: [beta, beta_4, pow_7, beta_5, norm__4], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution]
        buf23 = extern_kernels.convolution(buf22, reinterpret_tensor(buf21, (192, 192, 1, 1), (192, 1, 0, 0), 0), stride=(1, 1), padding=(0, 0), dilation=(1, 1), transposed=False, output_padding=(0, 0), groups=1, bias=None)
        assert_size_stride(buf23, (4, 192, 32, 32), (196608, 1, 6144, 192))
        buf24 = buf23; del buf23  # reuse
        buf25 = empty_strided_cuda((4, 192, 32, 32), (196608, 1, 6144, 192), torch.float32)
        # Topologically Sorted Source Nodes: [beta, beta_4, pow_7, beta_5, norm__4, norm__5, outputs_2], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.sub, aten.convolution, aten.sqrt]
        triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11.run(buf24, primals_12, buf20, buf25, 786432, grid=grid(786432), stream=stream0)
        # Topologically Sorted Source Nodes: [x], Original ATen: [aten.convolution]
        buf26 = extern_kernels.convolution(buf25, buf4, stride=(2, 2), padding=(2, 2), dilation=(1, 1), transposed=True, output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf26, (4, 3, 64, 64), (12288, 1, 192, 3))
        buf27 = empty_strided_cuda((4, 3, 64, 64), (12288, 4096, 64, 1), torch.float32)
        # Topologically Sorted Source Nodes: [x], Original ATen: [aten.convolution]
        triton_poi_fused_convolution_12.run(buf26, primals_15, buf27, 12, 4096, grid=grid(12, 4096), stream=stream0)
        del buf26
        del primals_15
        buf30 = empty_strided_cuda((192, ), (1, ), torch.float32)
        buf31 = empty_strided_cuda((192, ), (1, ), torch.bool)
        # Topologically Sorted Source Nodes: [beta, beta_4], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.ge]
        triton_poi_fused_ge_maximum_mul_pow_13.run(primals_12, buf30, buf31, 192, grid=grid(192), stream=stream0)
        del primals_12
        buf34 = empty_strided_cuda((192, ), (1, ), torch.float32)
        buf35 = empty_strided_cuda((192, ), (1, ), torch.bool)
        # Topologically Sorted Source Nodes: [beta, beta_2], Original ATen: [aten.mul, aten.maximum, aten.pow, aten.ge]
        triton_poi_fused_ge_maximum_mul_pow_13.run(primals_8, buf34, buf35, 192, grid=grid(192), stream=stream0)
        del primals_8
    return (buf27, buf0, buf1, primals_4, primals_5, buf2, buf3, buf4, buf6, reinterpret_tensor(buf7, (192, 192, 1, 1), (192, 1, 1, 1), 0), buf8, buf10, buf11, buf13, reinterpret_tensor(buf14, (192, 192, 1, 1), (192, 1, 1, 1), 0), buf15, buf17, buf18, buf20, reinterpret_tensor(buf21, (192, 192, 1, 1), (192, 1, 1, 1), 0), buf22, buf24, buf25, buf28, buf29, buf30, buf31, buf32, buf33, buf34, buf35, )


def benchmark_compiled_module(times=10, repeat=10):
    from torch._dynamo.testing import rand_strided
    from torch._inductor.utils import print_performance
    primals_1 = rand_strided((320, 192, 5, 5), (4800, 25, 5, 1), device='cuda:0', dtype=torch.float32)
    primals_2 = rand_strided((192, ), (1, ), device='cuda:0', dtype=torch.float32)
    primals_3 = rand_strided((4, 320, 4, 4), (5120, 16, 4, 1), device='cuda:0', dtype=torch.float32)
    primals_4 = rand_strided((192, ), (1, ), device='cuda:0', dtype=torch.float32)
    primals_5 = rand_strided((192, 192), (192, 1), device='cuda:0', dtype=torch.float32)
    primals_6 = rand_strided((192, 192, 5, 5), (4800, 25, 5, 1), device='cuda:0', dtype=torch.float32)
    primals_7 = rand_strided((192, ), (1, ), device='cuda:0', dtype=torch.float32)
    primals_8 = rand_strided((192, ), (1, ), device='cuda:0', dtype=torch.float32)
    primals_9 = rand_strided((192, 192), (192, 1), device='cuda:0', dtype=torch.float32)
    primals_10 = rand_strided((192, 192, 5, 5), (4800, 25, 5, 1), device='cuda:0', dtype=torch.float32)
    primals_11 = rand_strided((192, ), (1, ), device='cuda:0', dtype=torch.float32)
    primals_12 = rand_strided((192, ), (1, ), device='cuda:0', dtype=torch.float32)
    primals_13 = rand_strided((192, 192), (192, 1), device='cuda:0', dtype=torch.float32)
    primals_14 = rand_strided((192, 3, 5, 5), (75, 25, 5, 1), device='cuda:0', dtype=torch.float32)
    primals_15 = rand_strided((3, ), (1, ), device='cuda:0', dtype=torch.float32)
    fn = lambda: 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])
    return print_performance(fn, times=times, repeat=repeat)


if __name__ == "__main__":
    from torch._inductor.wrapper_benchmark import compiled_module_main
    compiled_module_main('None', benchmark_compiled_module)

from torch.autograd import Function
import math
import torch
import torch.nn as nn
import torch.utils.data


class LowerBound(Function):

    @staticmethod
    def forward(ctx, inputs, bound):
        b = torch.ones_like(inputs) * bound
        ctx.save_for_backward(inputs, b)
        return torch.max(inputs, b)

    @staticmethod
    def backward(ctx, grad_output):
        inputs, b = ctx.saved_tensors
        pass_through_1 = inputs >= b
        pass_through_2 = grad_output < 0
        pass_through = pass_through_1 | pass_through_2
        return pass_through.type(grad_output.dtype) * grad_output, None


class GDN(nn.Module):
    """Generalized divisive normalization layer.
    y[i] = x[i] / sqrt(beta[i] + sum_j(gamma[j, i] * x[j]))
    """

    def __init__(self, ch, inverse=False, beta_min=1e-06, gamma_init=0.1,
        reparam_offset=2 ** -18):
        super(GDN, self).__init__()
        self.inverse = inverse
        self.beta_min = beta_min
        self.gamma_init = gamma_init
        self.reparam_offset = reparam_offset
        self.build(ch)

    def build(self, ch):
        self.pedestal = self.reparam_offset ** 2
        self.beta_bound = (self.beta_min + self.reparam_offset ** 2) ** 0.5
        self.gamma_bound = self.reparam_offset
        beta = torch.sqrt(torch.ones(ch) + self.pedestal)
        self.beta = nn.Parameter(beta)
        eye = torch.eye(ch)
        g = self.gamma_init * eye
        g = g + self.pedestal
        gamma = torch.sqrt(g)
        self.gamma = nn.Parameter(gamma)
        self.pedestal = self.pedestal

    def forward(self, inputs):
        unfold = False
        if inputs.dim() == 5:
            unfold = True
            bs, ch, d, w, h = inputs.size()
            inputs = inputs.view(bs, ch, d * w, h)
        _, ch, _, _ = inputs.size()
        beta = LowerBound.apply(self.beta, self.beta_bound)
        beta = beta ** 2 - self.pedestal
        gamma = LowerBound.apply(self.gamma, self.gamma_bound)
        gamma = gamma ** 2 - self.pedestal
        gamma = gamma.view(ch, ch, 1, 1)
        norm_ = nn.functional.conv2d(inputs ** 2, gamma, beta)
        norm_ = torch.sqrt(norm_)
        if self.inverse:
            outputs = inputs * norm_
        else:
            outputs = inputs / norm_
        if unfold:
            outputs = outputs.view(bs, ch, d, w, h)
        return outputs


class Synthesis_net(nn.Module):
    """
    Decode synthesis
    """

    def __init__(self, out_channel_N=192, out_channel_M=320):
        super(Synthesis_net, self).__init__()
        self.deconv1 = nn.ConvTranspose2d(out_channel_M, out_channel_N, 5,
            stride=2, padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv1.weight.data, math.sqrt(2 *
            1 * (out_channel_M + out_channel_N) / (out_channel_M +
            out_channel_M)))
        torch.nn.init.constant_(self.deconv1.bias.data, 0.01)
        self.igdn1 = GDN(out_channel_N, inverse=True)
        self.deconv2 = nn.ConvTranspose2d(out_channel_N, out_channel_N, 5,
            stride=2, padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv2.weight.data, math.sqrt(2 * 1)
            )
        torch.nn.init.constant_(self.deconv2.bias.data, 0.01)
        self.igdn2 = GDN(out_channel_N, inverse=True)
        self.deconv3 = nn.ConvTranspose2d(out_channel_N, out_channel_N, 5,
            stride=2, padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv3.weight.data, math.sqrt(2 * 1)
            )
        torch.nn.init.constant_(self.deconv3.bias.data, 0.01)
        self.igdn3 = GDN(out_channel_N, inverse=True)
        self.deconv4 = nn.ConvTranspose2d(out_channel_N, 3, 5, stride=2,
            padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv4.weight.data, math.sqrt(2 *
            1 * (out_channel_N + 3) / (out_channel_N + out_channel_N)))
        torch.nn.init.constant_(self.deconv4.bias.data, 0.01)

    def forward(self, x):
        x = self.igdn1(self.deconv1(x))
        x = self.igdn2(self.deconv2(x))
        x = self.igdn3(self.deconv3(x))
        x = self.deconv4(x)
        return x


def get_inputs():
    return [torch.rand([4, 320, 4, 4])]


def get_init_inputs():
    return [[], {}]

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
from torch._inductor.runtime.triton_helpers import libdevice
from torch.autograd import Function
import math
import torch.nn as nn
import torch.utils.data
assert_size_stride = torch._C._dynamo.guards.assert_size_stride
empty_strided_cuda = torch._C._dynamo.guards._empty_strided_cuda
reinterpret_tensor = torch._C._dynamo.guards._reinterpret_tensor


@triton.jit
def triton_poi_fused_0(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK: tl.
    constexpr, XBLOCK: tl.constexpr):
    xnumel = 25
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    tl.full([XBLOCK, YBLOCK], True, tl.int1)
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 192
    y1 = yindex // 192
    tmp0 = tl.load(in_ptr0 + (x2 + 25 * y3), xmask, eviction_policy=
        'evict_last')
    tl.store(out_ptr0 + (y0 + 192 * x2 + 4800 * y1), tmp0, xmask)


@triton.jit
def triton_poi_fused_1(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK: tl.
    constexpr, XBLOCK: tl.constexpr):
    ynumel = 1280
    xnumel = 16
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = yindex < ynumel
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 320
    y1 = yindex // 320
    tmp0 = tl.load(in_ptr0 + (x2 + 16 * y3), xmask & ymask, eviction_policy
        ='evict_last')
    tl.store(out_ptr0 + (y0 + 320 * x2 + 5120 * y1), tmp0, xmask & ymask)


@triton.jit
def triton_poi_fused_2(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK: tl.
    constexpr, XBLOCK: tl.constexpr):
    xnumel = 25
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    tl.full([XBLOCK, YBLOCK], True, tl.int1)
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 192
    y1 = yindex // 192
    tmp0 = tl.load(in_ptr0 + (x2 + 25 * y3), xmask, eviction_policy=
        'evict_last')
    tl.store(out_ptr0 + (y0 + 192 * x2 + 4800 * y1), tmp0, xmask)


@triton.jit
def triton_poi_fused_3(in_ptr0, out_ptr0, ynumel, xnumel, YBLOCK: tl.
    constexpr, XBLOCK: tl.constexpr):
    ynumel = 576
    xnumel = 25
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = yindex < ynumel
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = xindex < xnumel
    x2 = xindex
    y3 = yindex
    y0 = yindex % 3
    y1 = yindex // 3
    tmp0 = tl.load(in_ptr0 + (x2 + 25 * y3), xmask & ymask, eviction_policy
        ='evict_last')
    tl.store(out_ptr0 + (y0 + 3 * x2 + 75 * y1), tmp0, xmask & ymask)


@triton.jit
def triton_poi_fused_convolution_pow_4(in_out_ptr0, in_ptr0, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + x2, None)
    tmp1 = tl.load(in_ptr0 + x0, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tmp2 * tmp2
    tl.store(in_out_ptr0 + x2, tmp2, None)
    tl.store(out_ptr0 + x2, tmp3, None)


@triton.jit
def triton_poi_fused_maximum_mul_pow_sub_5(in_ptr0, out_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_ptr0 + x0, None)
    tmp1 = 3.814697265625e-06
    tmp2 = triton_helpers.maximum(tmp0, tmp1)
    tmp3 = tmp2 * tmp2
    tmp4 = 1.4551915228366852e-11
    tmp5 = tmp3 - tmp4
    tl.store(out_ptr0 + x0, tmp5, None)


@triton.jit
def triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6(in_out_ptr0,
    in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + x2, None)
    tmp1 = tl.load(in_ptr0 + x0, None, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr1 + x2, None)
    tmp2 = 0.0010000072652474046
    tmp3 = triton_helpers.maximum(tmp1, tmp2)
    tmp4 = tmp3 * tmp3
    tmp5 = 1.4551915228366852e-11
    tmp6 = tmp4 - tmp5
    tmp7 = tmp0 + tmp6
    tmp9 = libdevice.sqrt(tmp7)
    tmp10 = tmp8 * tmp9
    tl.store(in_out_ptr0 + x2, tmp7, None)
    tl.store(out_ptr0 + x2, tmp10, None)


@triton.jit
def triton_poi_fused_convolution_pow_7(in_out_ptr0, in_ptr0, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + x2, None)
    tmp1 = tl.load(in_ptr0 + x0, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tmp2 * tmp2
    tl.store(in_out_ptr0 + x2, tmp2, None)
    tl.store(out_ptr0 + x2, tmp3, None)


@triton.jit
def triton_poi_fused_ge_maximum_mul_pow_sub_8(in_ptr0, out_ptr0, out_ptr1,
    out_ptr2, 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 = 3.814697265625e-06
    tmp2 = triton_helpers.maximum(tmp0, tmp1)
    tmp3 = tmp2 * tmp2
    tmp4 = 1.4551915228366852e-11
    tmp5 = tmp3 - tmp4
    tmp6 = 2.0
    tmp7 = tmp2 * tmp6
    tmp8 = tmp0 >= tmp1
    tl.store(out_ptr0 + x0, tmp5, None)
    tl.store(out_ptr1 + x0, tmp7, None)
    tl.store(out_ptr2 + x0, tmp8, None)


@triton.jit
def triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9(in_out_ptr0,
    in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + x2, None)
    tmp1 = tl.load(in_ptr0 + x0, None, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr1 + x2, None)
    tmp2 = 0.0010000072652474046
    tmp3 = triton_helpers.maximum(tmp1, tmp2)
    tmp4 = tmp3 * tmp3
    tmp5 = 1.4551915228366852e-11
    tmp6 = tmp4 - tmp5
    tmp7 = tmp0 + tmp6
    tmp9 = libdevice.sqrt(tmp7)
    tmp10 = tmp8 * tmp9
    tl.store(in_out_ptr0 + x2, tmp7, None)
    tl.store(out_ptr0 + x2, tmp10, None)


@triton.jit
def triton_poi_fused_convolution_pow_10(in_out_ptr0, in_ptr0, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + x2, None)
    tmp1 = tl.load(in_ptr0 + x0, None, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tmp3 = tmp2 * tmp2
    tl.store(in_out_ptr0 + x2, tmp2, None)
    tl.store(out_ptr0 + x2, tmp3, None)


@triton.jit
def triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11(in_out_ptr0,
    in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    tl.full([XBLOCK], True, tl.int1)
    x2 = xindex
    x0 = xindex % 192
    tmp0 = tl.load(in_out_ptr0 + x2, None)
    tmp1 = tl.load(in_ptr0 + x0, None, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr1 + x2, None)
    tmp2 = 0.0010000072652474046
    tmp3 = triton_helpers.maximum(tmp1, tmp2)
    tmp4 = tmp3 * tmp3
    tmp5 = 1.4551915228366852e-11
    tmp6 = tmp4 - tmp5
    tmp7 = tmp0 + tmp6
    tmp9 = libdevice.sqrt(tmp7)
    tmp10 = tmp8 * tmp9
    tl.store(in_out_ptr0 + x2, tmp7, None)
    tl.store(out_ptr0 + x2, tmp10, None)


@triton.jit
def triton_poi_fused_convolution_12(in_ptr0, in_ptr1, out_ptr0, ynumel,
    xnumel, YBLOCK: tl.constexpr, XBLOCK: tl.constexpr):
    ynumel = 12
    yoffset = tl.program_id(1) * YBLOCK
    yindex = yoffset + tl.arange(0, YBLOCK)[None, :]
    ymask = yindex < ynumel
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    tl.full([XBLOCK, YBLOCK], True, tl.int1)
    x2 = xindex
    y0 = yindex % 3
    y1 = yindex // 3
    y3 = yindex
    tmp0 = tl.load(in_ptr0 + (y0 + 3 * x2 + 12288 * y1), ymask,
        eviction_policy='evict_last')
    tmp1 = tl.load(in_ptr1 + y0, ymask, eviction_policy='evict_last')
    tmp2 = tmp0 + tmp1
    tl.store(out_ptr0 + (x2 + 4096 * y3), tmp2, ymask)


@triton.jit
def triton_poi_fused_ge_maximum_mul_pow_13(in_ptr0, out_ptr0, out_ptr1,
    xnumel, XBLOCK: tl.constexpr):
    xnumel = 192
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + x0, xmask)
    tmp1 = 0.0010000072652474046
    tmp2 = triton_helpers.maximum(tmp0, tmp1)
    tmp3 = 2.0
    tmp4 = tmp2 * tmp3
    tmp5 = tmp0 >= tmp1
    tl.store(out_ptr0 + x0, tmp4, xmask)
    tl.store(out_ptr1 + x0, tmp5, xmask)


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) = args
    args.clear()
    assert_size_stride(primals_1, (320, 192, 5, 5), (4800, 25, 5, 1))
    assert_size_stride(primals_2, (192,), (1,))
    assert_size_stride(primals_3, (4, 320, 4, 4), (5120, 16, 4, 1))
    assert_size_stride(primals_4, (192,), (1,))
    assert_size_stride(primals_5, (192, 192), (192, 1))
    assert_size_stride(primals_6, (192, 192, 5, 5), (4800, 25, 5, 1))
    assert_size_stride(primals_7, (192,), (1,))
    assert_size_stride(primals_8, (192,), (1,))
    assert_size_stride(primals_9, (192, 192), (192, 1))
    assert_size_stride(primals_10, (192, 192, 5, 5), (4800, 25, 5, 1))
    assert_size_stride(primals_11, (192,), (1,))
    assert_size_stride(primals_12, (192,), (1,))
    assert_size_stride(primals_13, (192, 192), (192, 1))
    assert_size_stride(primals_14, (192, 3, 5, 5), (75, 25, 5, 1))
    assert_size_stride(primals_15, (3,), (1,))
    with torch.cuda._DeviceGuard(0):
        torch.cuda.set_device(0)
        buf0 = empty_strided_cuda((320, 192, 5, 5), (4800, 1, 960, 192),
            torch.float32)
        get_raw_stream(0)
        triton_poi_fused_0[grid(61440, 25)](primals_1, buf0, 61440, 25,
            XBLOCK=32, YBLOCK=32, num_warps=4, num_stages=1)
        del primals_1
        buf1 = empty_strided_cuda((4, 320, 4, 4), (5120, 1, 1280, 320),
            torch.float32)
        triton_poi_fused_1[grid(1280, 16)](primals_3, buf1, 1280, 16,
            XBLOCK=16, YBLOCK=64, num_warps=4, num_stages=1)
        del primals_3
        buf2 = empty_strided_cuda((192, 192, 5, 5), (4800, 1, 960, 192),
            torch.float32)
        triton_poi_fused_2[grid(36864, 25)](primals_6, buf2, 36864, 25,
            XBLOCK=32, YBLOCK=32, num_warps=4, num_stages=1)
        del primals_6
        buf3 = empty_strided_cuda((192, 192, 5, 5), (4800, 1, 960, 192),
            torch.float32)
        triton_poi_fused_2[grid(36864, 25)](primals_10, buf3, 36864, 25,
            XBLOCK=32, YBLOCK=32, num_warps=4, num_stages=1)
        del primals_10
        buf4 = empty_strided_cuda((192, 3, 5, 5), (75, 1, 15, 3), torch.float32
            )
        triton_poi_fused_3[grid(576, 25)](primals_14, buf4, 576, 25, XBLOCK
            =32, YBLOCK=32, num_warps=4, num_stages=1)
        del primals_14
        buf5 = extern_kernels.convolution(buf1, buf0, stride=(2, 2),
            padding=(2, 2), dilation=(1, 1), transposed=True,
            output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf5, (4, 192, 8, 8), (12288, 1, 1536, 192))
        buf6 = buf5
        del buf5
        buf8 = empty_strided_cuda((4, 192, 8, 8), (12288, 1, 1536, 192),
            torch.float32)
        triton_poi_fused_convolution_pow_4[grid(49152)](buf6, primals_2,
            buf8, 49152, XBLOCK=256, num_warps=4, num_stages=1)
        del primals_2
        buf7 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        triton_poi_fused_maximum_mul_pow_sub_5[grid(36864)](primals_5, buf7,
            36864, XBLOCK=512, num_warps=4, num_stages=1)
        buf9 = extern_kernels.convolution(buf8, reinterpret_tensor(buf7, (
            192, 192, 1, 1), (192, 1, 0, 0), 0), stride=(1, 1), padding=(0,
            0), dilation=(1, 1), transposed=False, output_padding=(0, 0),
            groups=1, bias=None)
        assert_size_stride(buf9, (4, 192, 8, 8), (12288, 1, 1536, 192))
        buf10 = buf9
        del buf9
        buf11 = empty_strided_cuda((4, 192, 8, 8), (12288, 1, 1536, 192),
            torch.float32)
        triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_6[grid(49152)](
            buf10, primals_4, buf6, buf11, 49152, XBLOCK=512, num_warps=4,
            num_stages=1)
        buf12 = extern_kernels.convolution(buf11, buf2, stride=(2, 2),
            padding=(2, 2), dilation=(1, 1), transposed=True,
            output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf12, (4, 192, 16, 16), (49152, 1, 3072, 192))
        buf13 = buf12
        del buf12
        buf15 = empty_strided_cuda((4, 192, 16, 16), (49152, 1, 3072, 192),
            torch.float32)
        triton_poi_fused_convolution_pow_7[grid(196608)](buf13, primals_7,
            buf15, 196608, XBLOCK=512, num_warps=8, num_stages=1)
        del primals_7
        buf14 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf32 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf33 = empty_strided_cuda((192, 192), (192, 1), torch.bool)
        triton_poi_fused_ge_maximum_mul_pow_sub_8[grid(36864)](primals_9,
            buf14, buf32, buf33, 36864, XBLOCK=512, num_warps=4, num_stages=1)
        del primals_9
        buf16 = extern_kernels.convolution(buf15, reinterpret_tensor(buf14,
            (192, 192, 1, 1), (192, 1, 0, 0), 0), stride=(1, 1), padding=(0,
            0), dilation=(1, 1), transposed=False, output_padding=(0, 0),
            groups=1, bias=None)
        assert_size_stride(buf16, (4, 192, 16, 16), (49152, 1, 3072, 192))
        buf17 = buf16
        del buf16
        buf18 = empty_strided_cuda((4, 192, 16, 16), (49152, 1, 3072, 192),
            torch.float32)
        triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_9[grid(196608)](
            buf17, primals_8, buf13, buf18, 196608, XBLOCK=512, num_warps=8,
            num_stages=1)
        buf19 = extern_kernels.convolution(buf18, buf3, stride=(2, 2),
            padding=(2, 2), dilation=(1, 1), transposed=True,
            output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf19, (4, 192, 32, 32), (196608, 1, 6144, 192))
        buf20 = buf19
        del buf19
        buf22 = empty_strided_cuda((4, 192, 32, 32), (196608, 1, 6144, 192),
            torch.float32)
        triton_poi_fused_convolution_pow_10[grid(786432)](buf20, primals_11,
            buf22, 786432, XBLOCK=512, num_warps=8, num_stages=1)
        del primals_11
        buf21 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf28 = empty_strided_cuda((192, 192), (192, 1), torch.float32)
        buf29 = empty_strided_cuda((192, 192), (192, 1), torch.bool)
        triton_poi_fused_ge_maximum_mul_pow_sub_8[grid(36864)](primals_13,
            buf21, buf28, buf29, 36864, XBLOCK=512, num_warps=4, num_stages=1)
        del primals_13
        buf23 = extern_kernels.convolution(buf22, reinterpret_tensor(buf21,
            (192, 192, 1, 1), (192, 1, 0, 0), 0), stride=(1, 1), padding=(0,
            0), dilation=(1, 1), transposed=False, output_padding=(0, 0),
            groups=1, bias=None)
        assert_size_stride(buf23, (4, 192, 32, 32), (196608, 1, 6144, 192))
        buf24 = buf23
        del buf23
        buf25 = empty_strided_cuda((4, 192, 32, 32), (196608, 1, 6144, 192),
            torch.float32)
        triton_poi_fused_convolution_maximum_mul_pow_sqrt_sub_11[grid(786432)](
            buf24, primals_12, buf20, buf25, 786432, XBLOCK=512, num_warps=
            8, num_stages=1)
        buf26 = extern_kernels.convolution(buf25, buf4, stride=(2, 2),
            padding=(2, 2), dilation=(1, 1), transposed=True,
            output_padding=(1, 1), groups=1, bias=None)
        assert_size_stride(buf26, (4, 3, 64, 64), (12288, 1, 192, 3))
        buf27 = empty_strided_cuda((4, 3, 64, 64), (12288, 4096, 64, 1),
            torch.float32)
        triton_poi_fused_convolution_12[grid(12, 4096)](buf26, primals_15,
            buf27, 12, 4096, XBLOCK=64, YBLOCK=16, num_warps=4, num_stages=1)
        del buf26
        del primals_15
        buf30 = empty_strided_cuda((192,), (1,), torch.float32)
        buf31 = empty_strided_cuda((192,), (1,), torch.bool)
        triton_poi_fused_ge_maximum_mul_pow_13[grid(192)](primals_12, buf30,
            buf31, 192, XBLOCK=128, num_warps=4, num_stages=1)
        del primals_12
        buf34 = empty_strided_cuda((192,), (1,), torch.float32)
        buf35 = empty_strided_cuda((192,), (1,), torch.bool)
        triton_poi_fused_ge_maximum_mul_pow_13[grid(192)](primals_8, buf34,
            buf35, 192, XBLOCK=128, num_warps=4, num_stages=1)
        del primals_8
    return (buf27, buf0, buf1, primals_4, primals_5, buf2, buf3, buf4, buf6,
        reinterpret_tensor(buf7, (192, 192, 1, 1), (192, 1, 1, 1), 0), buf8,
        buf10, buf11, buf13, reinterpret_tensor(buf14, (192, 192, 1, 1), (
        192, 1, 1, 1), 0), buf15, buf17, buf18, buf20, reinterpret_tensor(
        buf21, (192, 192, 1, 1), (192, 1, 1, 1), 0), buf22, buf24, buf25,
        buf28, buf29, buf30, buf31, buf32, buf33, buf34, buf35)


class LowerBound(Function):

    @staticmethod
    def forward(ctx, inputs, bound):
        b = torch.ones_like(inputs) * bound
        ctx.save_for_backward(inputs, b)
        return torch.max(inputs, b)

    @staticmethod
    def backward(ctx, grad_output):
        inputs, b = ctx.saved_tensors
        pass_through_1 = inputs >= b
        pass_through_2 = grad_output < 0
        pass_through = pass_through_1 | pass_through_2
        return pass_through.type(grad_output.dtype) * grad_output, None


class GDN(nn.Module):
    """Generalized divisive normalization layer.
    y[i] = x[i] / sqrt(beta[i] + sum_j(gamma[j, i] * x[j]))
    """

    def __init__(self, ch, inverse=False, beta_min=1e-06, gamma_init=0.1,
        reparam_offset=2 ** -18):
        super(GDN, self).__init__()
        self.inverse = inverse
        self.beta_min = beta_min
        self.gamma_init = gamma_init
        self.reparam_offset = reparam_offset
        self.build(ch)

    def build(self, ch):
        self.pedestal = self.reparam_offset ** 2
        self.beta_bound = (self.beta_min + self.reparam_offset ** 2) ** 0.5
        self.gamma_bound = self.reparam_offset
        beta = torch.sqrt(torch.ones(ch) + self.pedestal)
        self.beta = nn.Parameter(beta)
        eye = torch.eye(ch)
        g = self.gamma_init * eye
        g = g + self.pedestal
        gamma = torch.sqrt(g)
        self.gamma = nn.Parameter(gamma)
        self.pedestal = self.pedestal

    def forward(self, inputs):
        unfold = False
        if inputs.dim() == 5:
            unfold = True
            bs, ch, d, w, h = inputs.size()
            inputs = inputs.view(bs, ch, d * w, h)
        _, ch, _, _ = inputs.size()
        beta = LowerBound.apply(self.beta, self.beta_bound)
        beta = beta ** 2 - self.pedestal
        gamma = LowerBound.apply(self.gamma, self.gamma_bound)
        gamma = gamma ** 2 - self.pedestal
        gamma = gamma.view(ch, ch, 1, 1)
        norm_ = nn.functional.conv2d(inputs ** 2, gamma, beta)
        norm_ = torch.sqrt(norm_)
        if self.inverse:
            outputs = inputs * norm_
        else:
            outputs = inputs / norm_
        if unfold:
            outputs = outputs.view(bs, ch, d, w, h)
        return outputs


class Synthesis_netNew(nn.Module):
    """
    Decode synthesis
    """

    def __init__(self, out_channel_N=192, out_channel_M=320):
        super(Synthesis_netNew, self).__init__()
        self.deconv1 = nn.ConvTranspose2d(out_channel_M, out_channel_N, 5,
            stride=2, padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv1.weight.data, math.sqrt(2 *
            1 * (out_channel_M + out_channel_N) / (out_channel_M +
            out_channel_M)))
        torch.nn.init.constant_(self.deconv1.bias.data, 0.01)
        self.igdn1 = GDN(out_channel_N, inverse=True)
        self.deconv2 = nn.ConvTranspose2d(out_channel_N, out_channel_N, 5,
            stride=2, padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv2.weight.data, math.sqrt(2 * 1)
            )
        torch.nn.init.constant_(self.deconv2.bias.data, 0.01)
        self.igdn2 = GDN(out_channel_N, inverse=True)
        self.deconv3 = nn.ConvTranspose2d(out_channel_N, out_channel_N, 5,
            stride=2, padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv3.weight.data, math.sqrt(2 * 1)
            )
        torch.nn.init.constant_(self.deconv3.bias.data, 0.01)
        self.igdn3 = GDN(out_channel_N, inverse=True)
        self.deconv4 = nn.ConvTranspose2d(out_channel_N, 3, 5, stride=2,
            padding=2, output_padding=1)
        torch.nn.init.xavier_normal_(self.deconv4.weight.data, math.sqrt(2 *
            1 * (out_channel_N + 3) / (out_channel_N + out_channel_N)))
        torch.nn.init.constant_(self.deconv4.bias.data, 0.01)

    def forward(self, input_0):
        primals_1 = self.deconv1.weight
        primals_2 = self.deconv1.bias
        primals_4 = self.igdn1.beta
        primals_5 = self.igdn1.gamma
        primals_6 = self.deconv2.weight
        primals_7 = self.deconv2.bias
        primals_8 = self.igdn2.beta
        primals_9 = self.igdn2.gamma
        primals_10 = self.deconv3.weight
        primals_11 = self.deconv3.bias
        primals_12 = self.igdn3.beta
        primals_13 = self.igdn3.gamma
        primals_14 = self.deconv4.weight
        primals_15 = self.deconv4.bias
        primals_3 = 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])
        return output[0]
