# AOT ID: ['0_inference']
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_4/inductor_cache/3g/c3gd5ipjfbufzu6hvujxufg6z3emufd62cvcqjyy3muqew2xvzbd.py
# Topologically Sorted Source Nodes: [sum_Q], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_Q => sum_1
# Graph fragment:
#   %sum_1 : [num_users=1] = call_function[target=torch.ops.aten.sum.default](args = (%permute,), kwargs = {})
triton_per_fused_sum_0 = async_compile.triton('triton_per_fused_sum_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.persistent_reduction(
    size_hints=[1, 16],
    reduction_hint=ReductionHint.INNER,
    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': {2: 1}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 3), equal_to_1=(2,))]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_per_fused_sum_0', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 1, '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}
)
@triton.jit
def triton_per_fused_sum_0(in_ptr0, out_ptr0, xnumel, rnumel, XBLOCK : tl.constexpr):
    xnumel = 1
    rnumel = 16
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    roffset = 0
    rmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    tmp0 = tl.load(in_ptr0 + (r0), None)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tl.store(out_ptr0 + (tl.full([XBLOCK, 1], 0, tl.int32)), tmp6, None)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/pb/cpb5rsib7fg2llnv7dg2enzvdhrqqrlufmxvryadr6zckhtmyysm.py
# Topologically Sorted Source Nodes: [sum_of_rows], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows => sum_2
# Graph fragment:
#   %sum_2 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_2, [1], True), kwargs = {})
triton_poi_fused_sum_1 = async_compile.triton('triton_poi_fused_sum_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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_1', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_sum_1(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (4 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (8 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (12 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + (x0), tmp21, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/ay/cayipr5tzejzfvzl7ba3w7cqhf2axor2ag2cqam22ambv3zsqfqn.py
# Topologically Sorted Source Nodes: [sum_3], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_3 => sum_3
# Graph fragment:
#   %sum_3 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_6, [0], True), kwargs = {})
triton_poi_fused_sum_2 = async_compile.triton('triton_poi_fused_sum_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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_2', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_sum_2(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (4*x0), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (0))
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (1 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp16 = tl.load(in_ptr2 + (1))
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (2 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp25 = tl.load(in_ptr2 + (2))
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (3 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp34 = tl.load(in_ptr2 + (3))
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + (x0), tmp38, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/gf/cgfazley3l5rdd6ypj2skdwbxoltt6cdo3d3mpt4z3kqywdlsil5.py
# Topologically Sorted Source Nodes: [sum_of_rows_1], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_1 => sum_4
# Graph fragment:
#   %sum_4 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_10, [1], True), kwargs = {})
triton_poi_fused_sum_3 = async_compile.triton('triton_poi_fused_sum_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=[4], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '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_sum_3', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 10, '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_sum_3(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (x0), xmask)
    tmp11 = tl.load(in_ptr3 + (0))
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (4 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + (1))
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (8 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + (2))
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (12 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + (3))
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + (x0), tmp47, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/im/cimyq4ncn2lt7wfmnkrejd4t7hctagm26a6wsjpob7y2e6gdebuy.py
# Topologically Sorted Source Nodes: [Q_7], Original ATen: [aten.div]
# Source node to ATen node mapping:
#   Q_7 => div_7
# Graph fragment:
#   %div_7 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%permute_12, 4), kwargs = {})
triton_poi_fused_div_4 = async_compile.triton('triton_poi_fused_div_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=[16], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '*fp32', 6: '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, 5, 6), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_div_4', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_div_4(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x0 = xindex % 4
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (x2), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (x0), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr3 + (x1), xmask, eviction_policy='evict_last')
    tmp14 = tl.load(in_ptr4 + (x0), xmask, eviction_policy='evict_last')
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp12 = tmp10 / tmp11
    tmp13 = tmp12 * tmp9
    tmp15 = tmp13 / tmp14
    tmp16 = tmp15 * tmp9
    tl.store(out_ptr0 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/f4/cf4q6mh4hv4abtcbirw4vkce7au36jgqitbjdciddckwumhdqyiq.py
# Topologically Sorted Source Nodes: [Q_9], Original ATen: [aten.div]
# Source node to ATen node mapping:
#   Q_9 => div_9
# Graph fragment:
#   %div_9 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%permute_16, 4), kwargs = {})
triton_poi_fused_div_5 = async_compile.triton('triton_poi_fused_div_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=[16], 
    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_div_5', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_div_5(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (x2), xmask)
    tmp1 = tl.load(in_ptr0 + (4*x1), xmask, eviction_policy='evict_last')
    tmp2 = tl.load(in_ptr0 + (1 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr0 + (2 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr0 + (3 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp3 = tmp1 + tmp2
    tmp5 = tmp3 + tmp4
    tmp7 = tmp5 + tmp6
    tmp8 = tmp0 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tl.store(out_ptr0 + (x2), tmp10, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/zl/czlhaiakbynkvvwkmvsahwmxzw7xdccr5ho7bxsxvn4m725ewzpe.py
# Topologically Sorted Source Nodes: [Q_11], Original ATen: [aten.div]
# Source node to ATen node mapping:
#   Q_11 => div_11
# Graph fragment:
#   %div_11 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%permute_20, 4), kwargs = {})
triton_poi_fused_div_6 = async_compile.triton('triton_poi_fused_div_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=[16], 
    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_div_6', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_div_6(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (x2), xmask)
    tmp1 = tl.load(in_ptr0 + (x0), xmask, eviction_policy='evict_last')
    tmp2 = tl.load(in_ptr0 + (4 + x0), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr0 + (8 + x0), xmask, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr0 + (12 + x0), xmask, eviction_policy='evict_last')
    tmp3 = tmp1 + tmp2
    tmp5 = tmp3 + tmp4
    tmp7 = tmp5 + tmp6
    tmp8 = tmp0 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tl.store(out_ptr0 + (x2), tmp10, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/zq/czqcd5dzpu5vwblosfp6mrfhziw4van5syy52ogdznuvysvejglt.py
# Topologically Sorted Source Nodes: [Q_14], Original ATen: [aten.mul]
# Source node to ATen node mapping:
#   Q_14 => mul
# Graph fragment:
#   %mul : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_26, 4), kwargs = {})
triton_poi_fused_mul_7 = async_compile.triton('triton_poi_fused_mul_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=[16], 
    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_mul_7', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_mul_7(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (x2), xmask)
    tmp1 = tl.load(in_ptr0 + (4*x1), xmask, eviction_policy='evict_last')
    tmp2 = tl.load(in_ptr0 + (1 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr0 + (2 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr0 + (3 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp3 = tmp1 + tmp2
    tmp5 = tmp3 + tmp4
    tmp7 = tmp5 + tmp6
    tmp8 = tmp0 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp11 = 4.0
    tmp12 = tmp10 * tmp11
    tl.store(out_ptr0 + (x2), tmp12, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/2o/c2oziyswbkb6ooscmnox5xojo4drqahfdvmtgtzz5unwazisafb7.py
# Topologically Sorted Source Nodes: [sum_Q_1], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_Q_1 => sum_22
# Graph fragment:
#   %sum_22 : [num_users=1] = call_function[target=torch.ops.aten.sum.default](args = (%permute_32,), kwargs = {})
#   %mul_tensor_12 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_18, 1), kwargs = {})
#   %amax_default_12 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_12, [1], True), kwargs = {})
#   %sub_tensor_12 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_12, %amax_default_12), kwargs = {})
#   %div_tensor_12 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_12, 0.1), kwargs = {})
#   %mul_tensor_5 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_26, 1), kwargs = {})
#   %amax_default_5 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_5, [1], True), kwargs = {})
#   %sub_tensor_5 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_5, %amax_default_5), kwargs = {})
#   %div_tensor_5 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_5, 0.1), kwargs = {})
triton_per_fused_sum_8 = async_compile.triton('triton_per_fused_sum_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.persistent_reduction(
    size_hints=[1, 16],
    reduction_hint=ReductionHint.DEFAULT,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: 'i32', 5: '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': {4: 1}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3, 5), equal_to_1=(4,))]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_per_fused_sum_8', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, 'num_reduction': 1, '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}
)
@triton.jit
def triton_per_fused_sum_8(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel, rnumel, XBLOCK : tl.constexpr):
    xnumel = 1
    rnumel = 16
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    roffset = 0
    rmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    r2 = (rindex // 4)
    tmp0 = tl.load(in_ptr0 + (16 + r0), None)
    tmp9 = tl.load(in_ptr0 + (16 + (4*r2)), None, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (17 + (4*r2)), None, eviction_policy='evict_last')
    tmp14 = tl.load(in_ptr0 + (18 + (4*r2)), None, eviction_policy='evict_last')
    tmp17 = tl.load(in_ptr0 + (19 + (4*r2)), None, eviction_policy='evict_last')
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tmp7 = 1.0
    tmp8 = tmp0 * tmp7
    tmp10 = tmp9 * tmp7
    tmp12 = tmp11 * tmp7
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp15 = tmp14 * tmp7
    tmp16 = triton_helpers.maximum(tmp13, tmp15)
    tmp18 = tmp17 * tmp7
    tmp19 = triton_helpers.maximum(tmp16, tmp18)
    tmp20 = tmp8 - tmp19
    tmp21 = 10.0
    tmp22 = tmp20 * tmp21
    tl.store(out_ptr1 + (tl.broadcast_to(r0, [XBLOCK, RBLOCK])), tmp22, None)
    tl.store(out_ptr2 + (tl.broadcast_to(r0, [XBLOCK, RBLOCK])), tmp22, None)
    tl.store(out_ptr0 + (tl.full([XBLOCK, 1], 0, tl.int32)), tmp6, None)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/gx/cgxhyecrtx7u6qjrmuu7kg45b4dlhwl7jr6ztpezyzreqxtwfd5r.py
# Topologically Sorted Source Nodes: [sum_of_rows_3], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_3 => sum_23
# Graph fragment:
#   %sum_23 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_34, [1], True), kwargs = {})
triton_poi_fused_sum_9 = async_compile.triton('triton_poi_fused_sum_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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_9', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_sum_9(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (16 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (20 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (24 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (28 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + (x0), tmp21, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/gg/cggk3re7n2vchxwvrujwqfrtrkzz53k2ysszjkctmcorctbnrwjn.py
# Topologically Sorted Source Nodes: [sum_17], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_17 => sum_24
# Graph fragment:
#   %sum_24 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_38, [0], True), kwargs = {})
triton_poi_fused_sum_10 = async_compile.triton('triton_poi_fused_sum_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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_10', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_sum_10(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (16 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (0))
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (17 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp16 = tl.load(in_ptr2 + (1))
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (18 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp25 = tl.load(in_ptr2 + (2))
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (19 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp34 = tl.load(in_ptr2 + (3))
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + (x0), tmp38, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/ys/cysm4kiitlxgr4z6f4ub5rd2focy27gqcmg2rwqbgxxtuy6mldou.py
# Topologically Sorted Source Nodes: [sum_of_rows_4], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_4 => sum_25
# Graph fragment:
#   %sum_25 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_42, [1], True), kwargs = {})
triton_poi_fused_sum_11 = async_compile.triton('triton_poi_fused_sum_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=[4], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '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_sum_11', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 10, '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_sum_11(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (16 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (x0), xmask)
    tmp11 = tl.load(in_ptr3 + (0))
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (20 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + (1))
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (24 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + (2))
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (28 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + (3))
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + (x0), tmp47, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/d3/cd3gefgcdmhdfyughxzotbsun6fbsyeopog67ravaw3wghfygqhr.py
# Topologically Sorted Source Nodes: [Q_22], Original ATen: [aten.div]
# Source node to ATen node mapping:
#   Q_22 => div_29
# Graph fragment:
#   %mul_tensor_27 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_1, 1), kwargs = {})
#   %amax_default_27 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_27, [1], True), kwargs = {})
#   %sub_tensor_27 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_27, %amax_default_27), kwargs = {})
#   %div_tensor_27 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_27, 0.1), kwargs = {})
#   %div_29 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%permute_44, 4), kwargs = {})
triton_poi_fused_div_12 = async_compile.triton('triton_poi_fused_div_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], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '*fp32', 6: '*fp32', 7: '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, 5, 6, 7), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_div_12', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_div_12(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4, out_ptr0, out_ptr1, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (16 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (16 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (17 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (18 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (19 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp20 = tl.load(in_ptr1 + (0))
    tmp21 = tl.broadcast_to(tmp20, [XBLOCK])
    tmp23 = tl.load(in_ptr2 + (x0), xmask, eviction_policy='evict_last')
    tmp27 = tl.load(in_ptr3 + (x1), xmask, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr4 + (x0), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tmp17 = 20.0
    tmp18 = tmp0 * tmp17
    tmp19 = tl_math.exp(tmp18)
    tmp22 = tmp19 / tmp21
    tmp24 = tmp22 / tmp23
    tmp25 = 0.25
    tmp26 = tmp24 * tmp25
    tmp28 = tmp26 / tmp27
    tmp29 = tmp28 * tmp25
    tmp31 = tmp29 / tmp30
    tmp32 = tmp31 * tmp25
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp32, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/tt/cttg2lnxpoxay4r27e6yymultf5wx23hbwstvoohxvcwcvlv7lne.py
# Topologically Sorted Source Nodes: [sum_Q_2], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_Q_2 => sum_43
# Graph fragment:
#   %sum_43 : [num_users=1] = call_function[target=torch.ops.aten.sum.default](args = (%permute_64,), kwargs = {})
#   %mul_tensor_4 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_27, 1), kwargs = {})
#   %amax_default_4 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_4, [1], True), kwargs = {})
#   %sub_tensor_4 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_4, %amax_default_4), kwargs = {})
#   %div_tensor_4 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_4, 0.1), kwargs = {})
triton_per_fused_sum_13 = async_compile.triton('triton_per_fused_sum_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.persistent_reduction(
    size_hints=[1, 16],
    reduction_hint=ReductionHint.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': {3: 1}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 4), equal_to_1=(3,))]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_per_fused_sum_13', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, 'num_reduction': 1, '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}
)
@triton.jit
def triton_per_fused_sum_13(in_ptr0, out_ptr0, out_ptr1, xnumel, rnumel, XBLOCK : tl.constexpr):
    xnumel = 1
    rnumel = 16
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    roffset = 0
    rmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    r2 = (rindex // 4)
    tmp0 = tl.load(in_ptr0 + (32 + r0), None)
    tmp9 = tl.load(in_ptr0 + (32 + (4*r2)), None, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (33 + (4*r2)), None, eviction_policy='evict_last')
    tmp14 = tl.load(in_ptr0 + (34 + (4*r2)), None, eviction_policy='evict_last')
    tmp17 = tl.load(in_ptr0 + (35 + (4*r2)), None, eviction_policy='evict_last')
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tmp7 = 1.0
    tmp8 = tmp0 * tmp7
    tmp10 = tmp9 * tmp7
    tmp12 = tmp11 * tmp7
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp15 = tmp14 * tmp7
    tmp16 = triton_helpers.maximum(tmp13, tmp15)
    tmp18 = tmp17 * tmp7
    tmp19 = triton_helpers.maximum(tmp16, tmp18)
    tmp20 = tmp8 - tmp19
    tmp21 = 10.0
    tmp22 = tmp20 * tmp21
    tl.store(out_ptr1 + (tl.broadcast_to(r0, [XBLOCK, RBLOCK])), tmp22, None)
    tl.store(out_ptr0 + (tl.full([XBLOCK, 1], 0, tl.int32)), tmp6, None)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/rs/crsq6qrm3t5shscjihgidrwsneusfut3iqrrk7iex7ld6v54lro4.py
# Topologically Sorted Source Nodes: [sum_of_rows_6], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_6 => sum_44
# Graph fragment:
#   %sum_44 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_66, [1], True), kwargs = {})
triton_poi_fused_sum_14 = async_compile.triton('triton_poi_fused_sum_14', '''
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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_14', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_sum_14(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (32 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (36 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (40 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (44 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + (x0), tmp21, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/p5/cp5kffayhihgup7sw7fmivxuc6kqm5s27wsgpzsyvv6f5c7cnvv2.py
# Topologically Sorted Source Nodes: [sum_31], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_31 => sum_45
# Graph fragment:
#   %sum_45 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_70, [0], True), kwargs = {})
triton_poi_fused_sum_15 = async_compile.triton('triton_poi_fused_sum_15', '''
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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_15', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_sum_15(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (32 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (0))
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (33 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp16 = tl.load(in_ptr2 + (1))
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (34 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp25 = tl.load(in_ptr2 + (2))
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (35 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp34 = tl.load(in_ptr2 + (3))
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + (x0), tmp38, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/ql/cql2xen4uqkei7lbsi5zq5b6xq5fzb7jd63dyiyjcisvyjkosvfv.py
# Topologically Sorted Source Nodes: [sum_of_rows_7], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_7 => sum_46
# Graph fragment:
#   %sum_46 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_74, [1], True), kwargs = {})
triton_poi_fused_sum_16 = async_compile.triton('triton_poi_fused_sum_16', '''
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=[4], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '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_sum_16', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 10, '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_sum_16(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (32 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (x0), xmask)
    tmp11 = tl.load(in_ptr3 + (0))
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (36 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + (1))
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (40 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + (2))
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (44 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + (3))
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + (x0), tmp47, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/xn/cxnxquhhhxb6dojpjiwgi5c62c3wmitjezayzfjio7k2jv7vqpsd.py
# Topologically Sorted Source Nodes: [Q_37], Original ATen: [aten.div]
# Source node to ATen node mapping:
#   Q_37 => div_51
# Graph fragment:
#   %mul_tensor_26 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_2, 1), kwargs = {})
#   %amax_default_26 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_26, [1], True), kwargs = {})
#   %sub_tensor_26 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_26, %amax_default_26), kwargs = {})
#   %div_tensor_26 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_26, 0.1), kwargs = {})
#   %mul_tensor_19 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_10, 1), kwargs = {})
#   %amax_default_19 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_19, [1], True), kwargs = {})
#   %sub_tensor_19 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_19, %amax_default_19), kwargs = {})
#   %div_tensor_19 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_19, 0.1), kwargs = {})
#   %div_51 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%permute_76, 4), kwargs = {})
triton_poi_fused_div_17 = async_compile.triton('triton_poi_fused_div_17', '''
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], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '*fp32', 6: '*fp32', 7: '*fp32', 8: '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, 5, 6, 7, 8), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_div_17', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_div_17(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4, out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (32 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (32 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (33 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (34 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (35 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp20 = tl.load(in_ptr1 + (0))
    tmp21 = tl.broadcast_to(tmp20, [XBLOCK])
    tmp23 = tl.load(in_ptr2 + (x0), xmask, eviction_policy='evict_last')
    tmp27 = tl.load(in_ptr3 + (x1), xmask, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr4 + (x0), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tmp17 = 20.0
    tmp18 = tmp0 * tmp17
    tmp19 = tl_math.exp(tmp18)
    tmp22 = tmp19 / tmp21
    tmp24 = tmp22 / tmp23
    tmp25 = 0.25
    tmp26 = tmp24 * tmp25
    tmp28 = tmp26 / tmp27
    tmp29 = tmp28 * tmp25
    tmp31 = tmp29 / tmp30
    tmp32 = tmp31 * tmp25
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp16, xmask)
    tl.store(out_ptr2 + (x2), tmp32, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/ua/cuanikw4qrep32zrex3uz6h4wr62oltdxm3gxoi2zv2qybounuk4.py
# Topologically Sorted Source Nodes: [sum_Q_3], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_Q_3 => sum_64
# Graph fragment:
#   %sum_64 : [num_users=1] = call_function[target=torch.ops.aten.sum.default](args = (%permute_96,), kwargs = {})
triton_per_fused_sum_18 = async_compile.triton('triton_per_fused_sum_18', '''
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.persistent_reduction(
    size_hints=[1, 16],
    reduction_hint=ReductionHint.INNER,
    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': {2: 1}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 3), equal_to_1=(2,))]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_per_fused_sum_18', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 1, 'num_reduction': 1, '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}
)
@triton.jit
def triton_per_fused_sum_18(in_ptr0, out_ptr0, xnumel, rnumel, XBLOCK : tl.constexpr):
    xnumel = 1
    rnumel = 16
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    roffset = 0
    rmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    tmp0 = tl.load(in_ptr0 + (48 + r0), None)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tl.store(out_ptr0 + (tl.full([XBLOCK, 1], 0, tl.int32)), tmp6, None)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/xx/cxxmu5ippz2osge53d6ltlbfzj363ko2cdlhkuv422dj24x4atll.py
# Topologically Sorted Source Nodes: [sum_of_rows_9], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_9 => sum_65
# Graph fragment:
#   %sum_65 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_98, [1], True), kwargs = {})
triton_poi_fused_sum_19 = async_compile.triton('triton_poi_fused_sum_19', '''
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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_19', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_sum_19(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (48 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (52 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (56 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (60 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + (x0), tmp21, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/iv/civ4enldjkrehizi4iifjk4xmuvxwl4hfaywx27qia42wl4csidk.py
# Topologically Sorted Source Nodes: [sum_45], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_45 => sum_66
# Graph fragment:
#   %sum_66 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_102, [0], True), kwargs = {})
triton_poi_fused_sum_20 = async_compile.triton('triton_poi_fused_sum_20', '''
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=[4], 
    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), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_sum_20', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_sum_20(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (48 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (0))
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (49 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp16 = tl.load(in_ptr2 + (1))
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (50 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp25 = tl.load(in_ptr2 + (2))
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (51 + (4*x0)), xmask, eviction_policy='evict_last')
    tmp34 = tl.load(in_ptr2 + (3))
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + (x0), tmp38, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/pq/cpqg526fen4aq5cgrdhu4a2oin6acmaawz6mcehy7umciw4im4ix.py
# Topologically Sorted Source Nodes: [sum_of_rows_10], Original ATen: [aten.sum]
# Source node to ATen node mapping:
#   sum_of_rows_10 => sum_67
# Graph fragment:
#   %sum_67 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%permute_106, [1], True), kwargs = {})
triton_poi_fused_sum_21 = async_compile.triton('triton_poi_fused_sum_21', '''
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=[4], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '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_sum_21', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 10, '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_sum_21(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (48 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + (0))
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + (x0), xmask)
    tmp11 = tl.load(in_ptr3 + (0))
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (52 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + (1))
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (56 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + (2))
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (60 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + (3))
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + (x0), tmp47, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/n4/cn4plb4lv6xccoz526fpmx4tom4f3ah4sfy35nahqhzq5al6uycs.py
# Topologically Sorted Source Nodes: [Q_52], Original ATen: [aten.div]
# Source node to ATen node mapping:
#   Q_52 => div_73
# Graph fragment:
#   %mul_tensor_25 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_3, 1), kwargs = {})
#   %amax_default_25 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_25, [1], True), kwargs = {})
#   %sub_tensor_25 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_25, %amax_default_25), kwargs = {})
#   %div_tensor_25 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_25, 0.1), kwargs = {})
#   %mul_tensor_18 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_11, 1), kwargs = {})
#   %amax_default_18 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_18, [1], True), kwargs = {})
#   %sub_tensor_18 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_18, %amax_default_18), kwargs = {})
#   %div_tensor_18 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_18, 0.1), kwargs = {})
#   %mul_tensor_11 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_19, 1), kwargs = {})
#   %amax_default_11 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_11, [1], True), kwargs = {})
#   %sub_tensor_11 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_11, %amax_default_11), kwargs = {})
#   %div_tensor_11 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_11, 0.1), kwargs = {})
#   %div_73 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%permute_108, 4), kwargs = {})
triton_poi_fused_div_22 = async_compile.triton('triton_poi_fused_div_22', '''
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], 
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '*fp32', 6: '*fp32', 7: '*fp32', 8: '*fp32', 9: '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, 5, 6, 7, 8, 9), equal_to_1=())]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_poi_fused_div_22', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 9, '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_div_22(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4, out_ptr0, out_ptr1, out_ptr2, out_ptr3, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (48 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (48 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (49 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (50 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (51 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp20 = tl.load(in_ptr1 + (0))
    tmp21 = tl.broadcast_to(tmp20, [XBLOCK])
    tmp23 = tl.load(in_ptr2 + (x0), xmask, eviction_policy='evict_last')
    tmp27 = tl.load(in_ptr3 + (x1), xmask, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr4 + (x0), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tmp17 = 20.0
    tmp18 = tmp0 * tmp17
    tmp19 = tl_math.exp(tmp18)
    tmp22 = tmp19 / tmp21
    tmp24 = tmp22 / tmp23
    tmp25 = 0.25
    tmp26 = tmp24 * tmp25
    tmp28 = tmp26 / tmp27
    tmp29 = tmp28 * tmp25
    tmp31 = tmp29 / tmp30
    tmp32 = tmp31 * tmp25
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp16, xmask)
    tl.store(out_ptr2 + (x2), tmp16, xmask)
    tl.store(out_ptr3 + (x2), tmp32, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/vp/cvpb5mtrsn3w4irxrcazvcy633nic3hupp3lgti6splnbwum5omh.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_24 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_4, 1), kwargs = {})
#   %amax_default_24 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_24, [1], True), kwargs = {})
#   %sub_tensor_24 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_24, %amax_default_24), kwargs = {})
#   %div_tensor_24 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_24, 0.1), kwargs = {})
#   %mul_tensor_17 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_12, 1), kwargs = {})
#   %amax_default_17 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_17, [1], True), kwargs = {})
#   %sub_tensor_17 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_17, %amax_default_17), kwargs = {})
#   %div_tensor_17 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_17, 0.1), kwargs = {})
#   %mul_tensor_10 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_20, 1), kwargs = {})
#   %amax_default_10 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_10, [1], True), kwargs = {})
#   %sub_tensor_10 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_10, %amax_default_10), kwargs = {})
#   %div_tensor_10 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_10, 0.1), kwargs = {})
triton_poi_fused_23 = async_compile.triton('triton_poi_fused_23', '''
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], 
    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_23', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_23(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (x2), xmask)
    tmp3 = tl.load(in_ptr0 + (4*x1), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (1 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (2 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (3 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp16, xmask)
    tl.store(out_ptr2 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/eb/cebycglrjxwo5vb3xw77tabmbrro5silpti6e23n5shzjssdcz2y.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_23 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_5, 1), kwargs = {})
#   %amax_default_23 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_23, [1], True), kwargs = {})
#   %sub_tensor_23 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_23, %amax_default_23), kwargs = {})
#   %div_tensor_23 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_23, 0.1), kwargs = {})
#   %mul_tensor_16 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_13, 1), kwargs = {})
#   %amax_default_16 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_16, [1], True), kwargs = {})
#   %sub_tensor_16 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_16, %amax_default_16), kwargs = {})
#   %div_tensor_16 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_16, 0.1), kwargs = {})
#   %mul_tensor_9 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_21, 1), kwargs = {})
#   %amax_default_9 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_9, [1], True), kwargs = {})
#   %sub_tensor_9 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_9, %amax_default_9), kwargs = {})
#   %div_tensor_9 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_9, 0.1), kwargs = {})
triton_poi_fused_24 = async_compile.triton('triton_poi_fused_24', '''
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], 
    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_24', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_24(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (16 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (16 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (17 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (18 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (19 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp16, xmask)
    tl.store(out_ptr2 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/wn/cwnlobrjuzsxonoax4oxycblbqzt6yimsshy6rjao2hwqcckct7e.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_22 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_6, 1), kwargs = {})
#   %amax_default_22 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_22, [1], True), kwargs = {})
#   %sub_tensor_22 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_22, %amax_default_22), kwargs = {})
#   %div_tensor_22 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_22, 0.1), kwargs = {})
#   %mul_tensor_15 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_14, 1), kwargs = {})
#   %amax_default_15 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_15, [1], True), kwargs = {})
#   %sub_tensor_15 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_15, %amax_default_15), kwargs = {})
#   %div_tensor_15 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_15, 0.1), kwargs = {})
#   %mul_tensor_8 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_22, 1), kwargs = {})
#   %amax_default_8 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_8, [1], True), kwargs = {})
#   %sub_tensor_8 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_8, %amax_default_8), kwargs = {})
#   %div_tensor_8 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_8, 0.1), kwargs = {})
triton_poi_fused_25 = async_compile.triton('triton_poi_fused_25', '''
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], 
    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_25', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_25(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (32 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (32 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (33 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (34 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (35 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp16, xmask)
    tl.store(out_ptr2 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/xb/cxbkq3bw5hyime7xxe4bzxgd2nnpfykwtvk22mjef7aetgsc2zrj.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_21 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_7, 1), kwargs = {})
#   %amax_default_21 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_21, [1], True), kwargs = {})
#   %sub_tensor_21 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_21, %amax_default_21), kwargs = {})
#   %div_tensor_21 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_21, 0.1), kwargs = {})
#   %mul_tensor_14 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_15, 1), kwargs = {})
#   %amax_default_14 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_14, [1], True), kwargs = {})
#   %sub_tensor_14 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_14, %amax_default_14), kwargs = {})
#   %div_tensor_14 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_14, 0.1), kwargs = {})
#   %mul_tensor_7 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_23, 1), kwargs = {})
#   %amax_default_7 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_7, [1], True), kwargs = {})
#   %sub_tensor_7 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_7, %amax_default_7), kwargs = {})
#   %div_tensor_7 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_7, 0.1), kwargs = {})
triton_poi_fused_26 = async_compile.triton('triton_poi_fused_26', '''
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], 
    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_26', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_26(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (48 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (48 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (49 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (50 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (51 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
    tl.store(out_ptr1 + (x2), tmp16, xmask)
    tl.store(out_ptr2 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/pn/cpnagcvhwbqe2rcvfgvmjcaxohah7uzhblpuio2lg6rdtez25o2c.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_3 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_28, 1), kwargs = {})
#   %amax_default_3 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_3, [1], True), kwargs = {})
#   %sub_tensor_3 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_3, %amax_default_3), kwargs = {})
#   %div_tensor_3 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_3, 0.1), kwargs = {})
triton_poi_fused_27 = async_compile.triton('triton_poi_fused_27', '''
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], 
    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_27', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_27(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (x2), xmask)
    tmp3 = tl.load(in_ptr0 + (4*x1), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (1 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (2 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (3 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/iw/ciw3zbnnlvqlllmj5a5gpcprapqy57rowpipu7cpawxbmcstu2i3.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_2 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_29, 1), kwargs = {})
#   %amax_default_2 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_2, [1], True), kwargs = {})
#   %sub_tensor_2 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_2, %amax_default_2), kwargs = {})
#   %div_tensor_2 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_2, 0.1), kwargs = {})
triton_poi_fused_28 = async_compile.triton('triton_poi_fused_28', '''
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], 
    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_28', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_28(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (16 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (16 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (17 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (18 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (19 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/24/c24vhpuzwkiqxza7n6dhlgskxjaib3f3u2rsi724hw7jp7njwrjn.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor_1 : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_30, 1), kwargs = {})
#   %amax_default_1 : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor_1, [1], True), kwargs = {})
#   %sub_tensor_1 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor_1, %amax_default_1), kwargs = {})
#   %div_tensor_1 : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor_1, 0.1), kwargs = {})
triton_poi_fused_29 = async_compile.triton('triton_poi_fused_29', '''
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], 
    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_29', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_29(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (32 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (32 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (33 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (34 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (35 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/qb/cqb4xqvf3w6zhnq2pjwk5ebvybb74fgqjxi3x4voqh2rgecnzvjg.py
# Topologically Sorted Source Nodes: [], Original ATen: []
# Source node to ATen node mapping:
# Graph fragment:
#   %mul_tensor : [num_users=2] = call_function[target=torch.ops.aten.mul.Tensor](args = (%select_31, 1), kwargs = {})
#   %amax_default : [num_users=1] = call_function[target=torch.ops.aten.amax.default](args = (%mul_tensor, [1], True), kwargs = {})
#   %sub_tensor : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%mul_tensor, %amax_default), kwargs = {})
#   %div_tensor : [num_users=2] = call_function[target=torch.ops.aten.div.Tensor](args = (%sub_tensor, 0.1), kwargs = {})
triton_poi_fused_30 = async_compile.triton('triton_poi_fused_30', '''
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], 
    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_30', 'mutated_arg_names': [], 'no_x_dim': False, 'num_load': 5, '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_30(in_ptr0, out_ptr0, xnumel, XBLOCK : tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = (xindex // 4)
    tmp0 = tl.load(in_ptr0 + (48 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (48 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (49 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (50 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (51 + (4*x1)), xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + (x2), tmp16, xmask)
''', device_str='cuda')


# kernel path: runs/run_shard_4/inductor_cache/xt/cxtuij5x42zgn4axuvkz6eiv2wtv6voipl2dxqeobqxx2vdpsins.py
# Topologically Sorted Source Nodes: [log_softmax, mul, sum_8, mean, neg, subloss, log_softmax_1, mul_1, sum_9, mean_1, neg_1, subloss_1, log_softmax_2, mul_2, sum_10, mean_2, neg_2, subloss_2, log_softmax_3, mul_3, sum_11, mean_3, neg_3, subloss_3, log_softmax_4, mul_4, sum_12, mean_4, neg_4, subloss_4, log_softmax_5, mul_5, sum_13, mean_5, neg_5, subloss_5, log_softmax_6, mul_6, sum_14, mean_6, neg_6, subloss_6, truediv_8, loss, log_softmax_7, mul_7, sum_22, mean_7, neg_7, subloss_7, log_softmax_8, mul_8, sum_23, mean_8, neg_8, subloss_8, log_softmax_9, mul_9, sum_24, mean_9, neg_9, subloss_9, log_softmax_10, mul_10, sum_25, mean_10, neg_10, subloss_10, log_softmax_11, mul_11, sum_26, mean_11, neg_11, subloss_11, log_softmax_12, mul_12, sum_27, mean_12, neg_12, subloss_12, log_softmax_13, mul_13, sum_28, mean_13, neg_13, subloss_13, truediv_17, loss_1, log_softmax_14, mul_14, sum_36, mean_14, neg_14, subloss_14, log_softmax_15, mul_15, sum_37, mean_15, neg_15, subloss_15, log_softmax_16, mul_16, sum_38, mean_16, neg_16, subloss_16, log_softmax_17, mul_17, sum_39, mean_17, neg_17, subloss_17, log_softmax_18, mul_18, sum_40, mean_18, neg_18, subloss_18, log_softmax_19, mul_19, sum_41, mean_19, neg_19, subloss_19, log_softmax_20, mul_20, sum_42, mean_20, neg_20, subloss_20, truediv_26, loss_2, log_softmax_21, mul_21, sum_50, mean_21, neg_21, subloss_21, log_softmax_22, mul_22, sum_51, mean_22, neg_22, subloss_22, log_softmax_23, mul_23, sum_52, mean_23, neg_23, subloss_23, log_softmax_24, mul_24, sum_53, mean_24, neg_24, subloss_24, log_softmax_25, mul_25, sum_54, mean_25, neg_25, subloss_25, log_softmax_26, mul_26, sum_55, mean_26, neg_26, subloss_26, log_softmax_27, mul_27, sum_56, mean_27, neg_27, subloss_27, truediv_35, loss_3, truediv_36], Original ATen: [aten._log_softmax, aten.mul, aten.sum, aten.mean, aten.neg, aten.add, aten.div]
# Source node to ATen node mapping:
#   log_softmax => exp_1, log, sub_1, sum_8
#   log_softmax_1 => exp_2, log_1, sub_3, sum_10
#   log_softmax_10 => exp_12, log_10, sub_21, sum_35
#   log_softmax_11 => exp_13, log_11, sub_23, sum_37
#   log_softmax_12 => exp_14, log_12, sub_25, sum_39
#   log_softmax_13 => exp_15, log_13, sub_27, sum_41
#   log_softmax_14 => exp_17, log_14, sub_29, sum_50
#   log_softmax_15 => exp_18, log_15, sub_31, sum_52
#   log_softmax_16 => exp_19, log_16, sub_33, sum_54
#   log_softmax_17 => exp_20, log_17, sub_35, sum_56
#   log_softmax_18 => exp_21, log_18, sub_37, sum_58
#   log_softmax_19 => exp_22, log_19, sub_39, sum_60
#   log_softmax_2 => exp_3, log_2, sub_5, sum_12
#   log_softmax_20 => exp_23, log_20, sub_41, sum_62
#   log_softmax_21 => exp_25, log_21, sub_43, sum_71
#   log_softmax_22 => exp_26, log_22, sub_45, sum_73
#   log_softmax_23 => exp_27, log_23, sub_47, sum_75
#   log_softmax_24 => exp_28, log_24, sub_49, sum_77
#   log_softmax_25 => exp_29, log_25, sub_51, sum_79
#   log_softmax_26 => exp_30, log_26, sub_53, sum_81
#   log_softmax_27 => exp_31, log_27, sub_55, sum_83
#   log_softmax_3 => exp_4, log_3, sub_7, sum_14
#   log_softmax_4 => exp_5, log_4, sub_9, sum_16
#   log_softmax_5 => exp_6, log_5, sub_11, sum_18
#   log_softmax_6 => exp_7, log_6, sub_13, sum_20
#   log_softmax_7 => exp_9, log_7, sub_15, sum_29
#   log_softmax_8 => exp_10, log_8, sub_17, sum_31
#   log_softmax_9 => exp_11, log_9, sub_19, sum_33
#   loss => add_7
#   loss_1 => add_15
#   loss_2 => add_23
#   loss_3 => add_31
#   mean => mean
#   mean_1 => mean_1
#   mean_10 => mean_10
#   mean_11 => mean_11
#   mean_12 => mean_12
#   mean_13 => mean_13
#   mean_14 => mean_14
#   mean_15 => mean_15
#   mean_16 => mean_16
#   mean_17 => mean_17
#   mean_18 => mean_18
#   mean_19 => mean_19
#   mean_2 => mean_2
#   mean_20 => mean_20
#   mean_21 => mean_21
#   mean_22 => mean_22
#   mean_23 => mean_23
#   mean_24 => mean_24
#   mean_25 => mean_25
#   mean_26 => mean_26
#   mean_27 => mean_27
#   mean_3 => mean_3
#   mean_4 => mean_4
#   mean_5 => mean_5
#   mean_6 => mean_6
#   mean_7 => mean_7
#   mean_8 => mean_8
#   mean_9 => mean_9
#   mul => mul_1
#   mul_1 => mul_2
#   mul_10 => mul_12
#   mul_11 => mul_13
#   mul_12 => mul_14
#   mul_13 => mul_15
#   mul_14 => mul_17
#   mul_15 => mul_18
#   mul_16 => mul_19
#   mul_17 => mul_20
#   mul_18 => mul_21
#   mul_19 => mul_22
#   mul_2 => mul_3
#   mul_20 => mul_23
#   mul_21 => mul_25
#   mul_22 => mul_26
#   mul_23 => mul_27
#   mul_24 => mul_28
#   mul_25 => mul_29
#   mul_26 => mul_30
#   mul_27 => mul_31
#   mul_3 => mul_4
#   mul_4 => mul_5
#   mul_5 => mul_6
#   mul_6 => mul_7
#   mul_7 => mul_9
#   mul_8 => mul_10
#   mul_9 => mul_11
#   neg => neg
#   neg_1 => neg_1
#   neg_10 => neg_10
#   neg_11 => neg_11
#   neg_12 => neg_12
#   neg_13 => neg_13
#   neg_14 => neg_14
#   neg_15 => neg_15
#   neg_16 => neg_16
#   neg_17 => neg_17
#   neg_18 => neg_18
#   neg_19 => neg_19
#   neg_2 => neg_2
#   neg_20 => neg_20
#   neg_21 => neg_21
#   neg_22 => neg_22
#   neg_23 => neg_23
#   neg_24 => neg_24
#   neg_25 => neg_25
#   neg_26 => neg_26
#   neg_27 => neg_27
#   neg_3 => neg_3
#   neg_4 => neg_4
#   neg_5 => neg_5
#   neg_6 => neg_6
#   neg_7 => neg_7
#   neg_8 => neg_8
#   neg_9 => neg_9
#   subloss => add
#   subloss_1 => add_1
#   subloss_10 => add_11
#   subloss_11 => add_12
#   subloss_12 => add_13
#   subloss_13 => add_14
#   subloss_14 => add_16
#   subloss_15 => add_17
#   subloss_16 => add_18
#   subloss_17 => add_19
#   subloss_18 => add_20
#   subloss_19 => add_21
#   subloss_2 => add_2
#   subloss_20 => add_22
#   subloss_21 => add_24
#   subloss_22 => add_25
#   subloss_23 => add_26
#   subloss_24 => add_27
#   subloss_25 => add_28
#   subloss_26 => add_29
#   subloss_27 => add_30
#   subloss_3 => add_3
#   subloss_4 => add_4
#   subloss_5 => add_5
#   subloss_6 => add_6
#   subloss_7 => add_8
#   subloss_8 => add_9
#   subloss_9 => add_10
#   sum_10 => sum_13
#   sum_11 => sum_15
#   sum_12 => sum_17
#   sum_13 => sum_19
#   sum_14 => sum_21
#   sum_22 => sum_30
#   sum_23 => sum_32
#   sum_24 => sum_34
#   sum_25 => sum_36
#   sum_26 => sum_38
#   sum_27 => sum_40
#   sum_28 => sum_42
#   sum_36 => sum_51
#   sum_37 => sum_53
#   sum_38 => sum_55
#   sum_39 => sum_57
#   sum_40 => sum_59
#   sum_41 => sum_61
#   sum_42 => sum_63
#   sum_50 => sum_72
#   sum_51 => sum_74
#   sum_52 => sum_76
#   sum_53 => sum_78
#   sum_54 => sum_80
#   sum_55 => sum_82
#   sum_56 => sum_84
#   sum_8 => sum_9
#   sum_9 => sum_11
#   truediv_17 => div_43
#   truediv_26 => div_65
#   truediv_35 => div_87
#   truediv_36 => div_88
#   truediv_8 => div_21
# Graph fragment:
#   %exp_1 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_27,), kwargs = {})
#   %sum_8 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_1, [1], True), kwargs = {})
#   %log : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_8,), kwargs = {})
#   %sub_1 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_27, %log), kwargs = {})
#   %mul_1 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_1), kwargs = {})
#   %sum_9 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_1, [1]), kwargs = {})
#   %mean : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_9,), kwargs = {})
#   %neg : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean,), kwargs = {})
#   %add : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%neg, 0.0), kwargs = {})
#   %exp_2 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_26,), kwargs = {})
#   %sum_10 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_2, [1], True), kwargs = {})
#   %log_1 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_10,), kwargs = {})
#   %sub_3 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_26, %log_1), kwargs = {})
#   %mul_2 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_3), kwargs = {})
#   %sum_11 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_2, [1]), kwargs = {})
#   %mean_1 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_11,), kwargs = {})
#   %neg_1 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_1,), kwargs = {})
#   %add_1 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add, %neg_1), kwargs = {})
#   %exp_3 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_25,), kwargs = {})
#   %sum_12 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_3, [1], True), kwargs = {})
#   %log_2 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_12,), kwargs = {})
#   %sub_5 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_25, %log_2), kwargs = {})
#   %mul_3 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_5), kwargs = {})
#   %sum_13 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_3, [1]), kwargs = {})
#   %mean_2 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_13,), kwargs = {})
#   %neg_2 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_2,), kwargs = {})
#   %add_2 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_1, %neg_2), kwargs = {})
#   %exp_4 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_24,), kwargs = {})
#   %sum_14 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_4, [1], True), kwargs = {})
#   %log_3 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_14,), kwargs = {})
#   %sub_7 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_24, %log_3), kwargs = {})
#   %mul_4 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_7), kwargs = {})
#   %sum_15 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_4, [1]), kwargs = {})
#   %mean_3 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_15,), kwargs = {})
#   %neg_3 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_3,), kwargs = {})
#   %add_3 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_2, %neg_3), kwargs = {})
#   %exp_5 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_23,), kwargs = {})
#   %sum_16 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_5, [1], True), kwargs = {})
#   %log_4 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_16,), kwargs = {})
#   %sub_9 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_23, %log_4), kwargs = {})
#   %mul_5 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_9), kwargs = {})
#   %sum_17 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_5, [1]), kwargs = {})
#   %mean_4 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_17,), kwargs = {})
#   %neg_4 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_4,), kwargs = {})
#   %add_4 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_3, %neg_4), kwargs = {})
#   %exp_6 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_22,), kwargs = {})
#   %sum_18 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_6, [1], True), kwargs = {})
#   %log_5 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_18,), kwargs = {})
#   %sub_11 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_22, %log_5), kwargs = {})
#   %mul_6 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_11), kwargs = {})
#   %sum_19 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_6, [1]), kwargs = {})
#   %mean_5 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_19,), kwargs = {})
#   %neg_5 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_5,), kwargs = {})
#   %add_5 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_4, %neg_5), kwargs = {})
#   %exp_7 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_21,), kwargs = {})
#   %sum_20 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_7, [1], True), kwargs = {})
#   %log_6 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_20,), kwargs = {})
#   %sub_13 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_21, %log_6), kwargs = {})
#   %mul_7 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_31, %sub_13), kwargs = {})
#   %sum_21 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_7, [1]), kwargs = {})
#   %mean_6 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_21,), kwargs = {})
#   %neg_6 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_6,), kwargs = {})
#   %add_6 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_5, %neg_6), kwargs = {})
#   %div_21 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%add_6, 7), kwargs = {})
#   %add_7 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%div_21, 0.0), kwargs = {})
#   %exp_9 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_20,), kwargs = {})
#   %sum_29 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_9, [1], True), kwargs = {})
#   %log_7 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_29,), kwargs = {})
#   %sub_15 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_20, %log_7), kwargs = {})
#   %mul_9 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_15), kwargs = {})
#   %sum_30 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_9, [1]), kwargs = {})
#   %mean_7 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_30,), kwargs = {})
#   %neg_7 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_7,), kwargs = {})
#   %add_8 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%neg_7, 0.0), kwargs = {})
#   %exp_10 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_19,), kwargs = {})
#   %sum_31 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_10, [1], True), kwargs = {})
#   %log_8 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_31,), kwargs = {})
#   %sub_17 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_19, %log_8), kwargs = {})
#   %mul_10 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_17), kwargs = {})
#   %sum_32 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_10, [1]), kwargs = {})
#   %mean_8 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_32,), kwargs = {})
#   %neg_8 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_8,), kwargs = {})
#   %add_9 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_8, %neg_8), kwargs = {})
#   %exp_11 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_18,), kwargs = {})
#   %sum_33 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_11, [1], True), kwargs = {})
#   %log_9 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_33,), kwargs = {})
#   %sub_19 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_18, %log_9), kwargs = {})
#   %mul_11 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_19), kwargs = {})
#   %sum_34 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_11, [1]), kwargs = {})
#   %mean_9 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_34,), kwargs = {})
#   %neg_9 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_9,), kwargs = {})
#   %add_10 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_9, %neg_9), kwargs = {})
#   %exp_12 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_17,), kwargs = {})
#   %sum_35 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_12, [1], True), kwargs = {})
#   %log_10 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_35,), kwargs = {})
#   %sub_21 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_17, %log_10), kwargs = {})
#   %mul_12 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_21), kwargs = {})
#   %sum_36 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_12, [1]), kwargs = {})
#   %mean_10 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_36,), kwargs = {})
#   %neg_10 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_10,), kwargs = {})
#   %add_11 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_10, %neg_10), kwargs = {})
#   %exp_13 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_16,), kwargs = {})
#   %sum_37 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_13, [1], True), kwargs = {})
#   %log_11 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_37,), kwargs = {})
#   %sub_23 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_16, %log_11), kwargs = {})
#   %mul_13 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_23), kwargs = {})
#   %sum_38 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_13, [1]), kwargs = {})
#   %mean_11 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_38,), kwargs = {})
#   %neg_11 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_11,), kwargs = {})
#   %add_12 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_11, %neg_11), kwargs = {})
#   %exp_14 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_15,), kwargs = {})
#   %sum_39 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_14, [1], True), kwargs = {})
#   %log_12 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_39,), kwargs = {})
#   %sub_25 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_15, %log_12), kwargs = {})
#   %mul_14 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_25), kwargs = {})
#   %sum_40 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_14, [1]), kwargs = {})
#   %mean_12 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_40,), kwargs = {})
#   %neg_12 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_12,), kwargs = {})
#   %add_13 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_12, %neg_12), kwargs = {})
#   %exp_15 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_14,), kwargs = {})
#   %sum_41 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_15, [1], True), kwargs = {})
#   %log_13 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_41,), kwargs = {})
#   %sub_27 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_14, %log_13), kwargs = {})
#   %mul_15 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_63, %sub_27), kwargs = {})
#   %sum_42 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_15, [1]), kwargs = {})
#   %mean_13 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_42,), kwargs = {})
#   %neg_13 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_13,), kwargs = {})
#   %add_14 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_13, %neg_13), kwargs = {})
#   %div_43 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%add_14, 7), kwargs = {})
#   %add_15 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_7, %div_43), kwargs = {})
#   %exp_17 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_13,), kwargs = {})
#   %sum_50 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_17, [1], True), kwargs = {})
#   %log_14 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_50,), kwargs = {})
#   %sub_29 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_13, %log_14), kwargs = {})
#   %mul_17 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_29), kwargs = {})
#   %sum_51 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_17, [1]), kwargs = {})
#   %mean_14 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_51,), kwargs = {})
#   %neg_14 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_14,), kwargs = {})
#   %add_16 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%neg_14, 0.0), kwargs = {})
#   %exp_18 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_12,), kwargs = {})
#   %sum_52 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_18, [1], True), kwargs = {})
#   %log_15 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_52,), kwargs = {})
#   %sub_31 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_12, %log_15), kwargs = {})
#   %mul_18 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_31), kwargs = {})
#   %sum_53 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_18, [1]), kwargs = {})
#   %mean_15 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_53,), kwargs = {})
#   %neg_15 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_15,), kwargs = {})
#   %add_17 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_16, %neg_15), kwargs = {})
#   %exp_19 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_11,), kwargs = {})
#   %sum_54 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_19, [1], True), kwargs = {})
#   %log_16 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_54,), kwargs = {})
#   %sub_33 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_11, %log_16), kwargs = {})
#   %mul_19 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_33), kwargs = {})
#   %sum_55 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_19, [1]), kwargs = {})
#   %mean_16 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_55,), kwargs = {})
#   %neg_16 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_16,), kwargs = {})
#   %add_18 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_17, %neg_16), kwargs = {})
#   %exp_20 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_10,), kwargs = {})
#   %sum_56 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_20, [1], True), kwargs = {})
#   %log_17 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_56,), kwargs = {})
#   %sub_35 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_10, %log_17), kwargs = {})
#   %mul_20 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_35), kwargs = {})
#   %sum_57 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_20, [1]), kwargs = {})
#   %mean_17 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_57,), kwargs = {})
#   %neg_17 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_17,), kwargs = {})
#   %add_19 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_18, %neg_17), kwargs = {})
#   %exp_21 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_9,), kwargs = {})
#   %sum_58 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_21, [1], True), kwargs = {})
#   %log_18 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_58,), kwargs = {})
#   %sub_37 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_9, %log_18), kwargs = {})
#   %mul_21 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_37), kwargs = {})
#   %sum_59 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_21, [1]), kwargs = {})
#   %mean_18 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_59,), kwargs = {})
#   %neg_18 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_18,), kwargs = {})
#   %add_20 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_19, %neg_18), kwargs = {})
#   %exp_22 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_8,), kwargs = {})
#   %sum_60 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_22, [1], True), kwargs = {})
#   %log_19 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_60,), kwargs = {})
#   %sub_39 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_8, %log_19), kwargs = {})
#   %mul_22 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_39), kwargs = {})
#   %sum_61 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_22, [1]), kwargs = {})
#   %mean_19 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_61,), kwargs = {})
#   %neg_19 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_19,), kwargs = {})
#   %add_21 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_20, %neg_19), kwargs = {})
#   %exp_23 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_7,), kwargs = {})
#   %sum_62 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_23, [1], True), kwargs = {})
#   %log_20 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_62,), kwargs = {})
#   %sub_41 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_7, %log_20), kwargs = {})
#   %mul_23 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_95, %sub_41), kwargs = {})
#   %sum_63 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_23, [1]), kwargs = {})
#   %mean_20 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_63,), kwargs = {})
#   %neg_20 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_20,), kwargs = {})
#   %add_22 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_21, %neg_20), kwargs = {})
#   %div_65 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%add_22, 7), kwargs = {})
#   %add_23 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_15, %div_65), kwargs = {})
#   %exp_25 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_6,), kwargs = {})
#   %sum_71 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_25, [1], True), kwargs = {})
#   %log_21 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_71,), kwargs = {})
#   %sub_43 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_6, %log_21), kwargs = {})
#   %mul_25 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_43), kwargs = {})
#   %sum_72 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_25, [1]), kwargs = {})
#   %mean_21 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_72,), kwargs = {})
#   %neg_21 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_21,), kwargs = {})
#   %add_24 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%neg_21, 0.0), kwargs = {})
#   %exp_26 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_5,), kwargs = {})
#   %sum_73 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_26, [1], True), kwargs = {})
#   %log_22 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_73,), kwargs = {})
#   %sub_45 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_5, %log_22), kwargs = {})
#   %mul_26 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_45), kwargs = {})
#   %sum_74 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_26, [1]), kwargs = {})
#   %mean_22 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_74,), kwargs = {})
#   %neg_22 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_22,), kwargs = {})
#   %add_25 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_24, %neg_22), kwargs = {})
#   %exp_27 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_4,), kwargs = {})
#   %sum_75 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_27, [1], True), kwargs = {})
#   %log_23 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_75,), kwargs = {})
#   %sub_47 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_4, %log_23), kwargs = {})
#   %mul_27 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_47), kwargs = {})
#   %sum_76 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_27, [1]), kwargs = {})
#   %mean_23 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_76,), kwargs = {})
#   %neg_23 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_23,), kwargs = {})
#   %add_26 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_25, %neg_23), kwargs = {})
#   %exp_28 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_3,), kwargs = {})
#   %sum_77 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_28, [1], True), kwargs = {})
#   %log_24 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_77,), kwargs = {})
#   %sub_49 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_3, %log_24), kwargs = {})
#   %mul_28 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_49), kwargs = {})
#   %sum_78 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_28, [1]), kwargs = {})
#   %mean_24 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_78,), kwargs = {})
#   %neg_24 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_24,), kwargs = {})
#   %add_27 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_26, %neg_24), kwargs = {})
#   %exp_29 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_2,), kwargs = {})
#   %sum_79 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_29, [1], True), kwargs = {})
#   %log_25 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_79,), kwargs = {})
#   %sub_51 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_2, %log_25), kwargs = {})
#   %mul_29 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_51), kwargs = {})
#   %sum_80 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_29, [1]), kwargs = {})
#   %mean_25 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_80,), kwargs = {})
#   %neg_25 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_25,), kwargs = {})
#   %add_28 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_27, %neg_25), kwargs = {})
#   %exp_30 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor_1,), kwargs = {})
#   %sum_81 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_30, [1], True), kwargs = {})
#   %log_26 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_81,), kwargs = {})
#   %sub_53 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor_1, %log_26), kwargs = {})
#   %mul_30 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_53), kwargs = {})
#   %sum_82 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_30, [1]), kwargs = {})
#   %mean_26 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_82,), kwargs = {})
#   %neg_26 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_26,), kwargs = {})
#   %add_29 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_28, %neg_26), kwargs = {})
#   %exp_31 : [num_users=1] = call_function[target=torch.ops.aten.exp.default](args = (%div_tensor,), kwargs = {})
#   %sum_83 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%exp_31, [1], True), kwargs = {})
#   %log_27 : [num_users=1] = call_function[target=torch.ops.aten.log.default](args = (%sum_83,), kwargs = {})
#   %sub_55 : [num_users=1] = call_function[target=torch.ops.aten.sub.Tensor](args = (%div_tensor, %log_27), kwargs = {})
#   %mul_31 : [num_users=1] = call_function[target=torch.ops.aten.mul.Tensor](args = (%permute_127, %sub_55), kwargs = {})
#   %sum_84 : [num_users=1] = call_function[target=torch.ops.aten.sum.dim_IntList](args = (%mul_31, [1]), kwargs = {})
#   %mean_27 : [num_users=1] = call_function[target=torch.ops.aten.mean.default](args = (%sum_84,), kwargs = {})
#   %neg_27 : [num_users=1] = call_function[target=torch.ops.aten.neg.default](args = (%mean_27,), kwargs = {})
#   %add_30 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_29, %neg_27), kwargs = {})
#   %div_87 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%add_30, 7), kwargs = {})
#   %add_31 : [num_users=1] = call_function[target=torch.ops.aten.add.Tensor](args = (%add_23, %div_87), kwargs = {})
#   %div_88 : [num_users=1] = call_function[target=torch.ops.aten.div.Tensor](args = (%add_31, 4), kwargs = {})
triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31 = async_compile.triton('triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31', '''
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.persistent_reduction(
    size_hints=[1, 4],
    reduction_hint=ReductionHint.INNER,
    filename=__file__,
    triton_meta={'signature': {0: '*fp32', 1: '*fp32', 2: '*fp32', 3: '*fp32', 4: '*fp32', 5: '*fp32', 6: '*fp32', 7: '*fp32', 8: '*fp32', 9: '*fp32', 10: '*fp32', 11: '*fp32', 12: '*fp32', 13: '*fp32', 14: '*fp32', 15: '*fp32', 16: '*fp32', 17: '*fp32', 18: '*fp32', 19: '*fp32', 20: '*fp32', 21: '*fp32', 22: '*fp32', 23: '*fp32', 24: '*fp32', 25: '*fp32', 26: '*fp32', 27: '*fp32', 28: '*fp32', 29: '*fp32', 30: '*fp32', 31: '*fp32', 32: '*fp32', 33: 'i32', 34: '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': {33: 1}, 'configs': [AttrsDescriptor(divisible_by_16=(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32), equal_to_1=(33,))]},
    inductor_meta={'autotune_hints': set(), 'kernel_name': 'triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31', 'mutated_arg_names': ['in_out_ptr0'], 'no_x_dim': False, 'num_load': 128, 'num_reduction': 28, '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}
)
@triton.jit
def triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31(in_out_ptr0, in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4, in_ptr5, in_ptr6, in_ptr7, in_ptr8, in_ptr9, in_ptr10, in_ptr11, in_ptr12, in_ptr13, in_ptr14, in_ptr15, in_ptr16, in_ptr17, in_ptr18, in_ptr19, in_ptr20, in_ptr21, in_ptr22, in_ptr23, in_ptr24, in_ptr25, in_ptr26, in_ptr27, in_ptr28, in_ptr29, in_ptr30, in_ptr31, xnumel, rnumel, XBLOCK : tl.constexpr):
    xnumel = 1
    rnumel = 4
    RBLOCK: tl.constexpr = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:, None]
    xmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    roffset = 0
    rmask = tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    tmp0 = tl.load(in_ptr0 + (4*r0), None, eviction_policy='evict_last')
    tmp1 = tl.load(in_ptr1 + (4*r0), None, eviction_policy='evict_last')
    tmp3 = tl.load(in_ptr1 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr1 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp9 = tl.load(in_ptr1 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp15 = tl.load(in_ptr0 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp19 = tl.load(in_ptr0 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp23 = tl.load(in_ptr0 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr2 + (4*r0), None, eviction_policy='evict_last')
    tmp32 = tl.load(in_ptr2 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp35 = tl.load(in_ptr2 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp38 = tl.load(in_ptr2 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp56 = tl.load(in_ptr3 + (4*r0), None, eviction_policy='evict_last')
    tmp58 = tl.load(in_ptr3 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp61 = tl.load(in_ptr3 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp64 = tl.load(in_ptr3 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp82 = tl.load(in_ptr4 + (4*r0), None, eviction_policy='evict_last')
    tmp84 = tl.load(in_ptr4 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp87 = tl.load(in_ptr4 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp90 = tl.load(in_ptr4 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp108 = tl.load(in_ptr5 + (4*r0), None, eviction_policy='evict_last')
    tmp110 = tl.load(in_ptr5 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp113 = tl.load(in_ptr5 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp116 = tl.load(in_ptr5 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp134 = tl.load(in_ptr6 + (4*r0), None, eviction_policy='evict_last')
    tmp136 = tl.load(in_ptr6 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp139 = tl.load(in_ptr6 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp142 = tl.load(in_ptr6 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp160 = tl.load(in_ptr7 + (4*r0), None, eviction_policy='evict_last')
    tmp162 = tl.load(in_ptr7 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp165 = tl.load(in_ptr7 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp168 = tl.load(in_ptr7 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp186 = tl.load(in_ptr8 + (4*r0), None, eviction_policy='evict_last')
    tmp187 = tl.load(in_ptr9 + (4*r0), None, eviction_policy='evict_last')
    tmp189 = tl.load(in_ptr9 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp192 = tl.load(in_ptr9 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp195 = tl.load(in_ptr9 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp201 = tl.load(in_ptr8 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp205 = tl.load(in_ptr8 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp209 = tl.load(in_ptr8 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp216 = tl.load(in_ptr10 + (4*r0), None, eviction_policy='evict_last')
    tmp218 = tl.load(in_ptr10 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp221 = tl.load(in_ptr10 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp224 = tl.load(in_ptr10 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp242 = tl.load(in_ptr11 + (4*r0), None, eviction_policy='evict_last')
    tmp244 = tl.load(in_ptr11 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp247 = tl.load(in_ptr11 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp250 = tl.load(in_ptr11 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp268 = tl.load(in_ptr12 + (4*r0), None, eviction_policy='evict_last')
    tmp270 = tl.load(in_ptr12 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp273 = tl.load(in_ptr12 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp276 = tl.load(in_ptr12 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp294 = tl.load(in_ptr13 + (4*r0), None, eviction_policy='evict_last')
    tmp296 = tl.load(in_ptr13 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp299 = tl.load(in_ptr13 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp302 = tl.load(in_ptr13 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp320 = tl.load(in_ptr14 + (4*r0), None, eviction_policy='evict_last')
    tmp322 = tl.load(in_ptr14 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp325 = tl.load(in_ptr14 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp328 = tl.load(in_ptr14 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp346 = tl.load(in_ptr15 + (4*r0), None, eviction_policy='evict_last')
    tmp348 = tl.load(in_ptr15 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp351 = tl.load(in_ptr15 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp354 = tl.load(in_ptr15 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp372 = tl.load(in_ptr16 + (4*r0), None, eviction_policy='evict_last')
    tmp373 = tl.load(in_ptr17 + (4*r0), None, eviction_policy='evict_last')
    tmp375 = tl.load(in_ptr17 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp378 = tl.load(in_ptr17 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp381 = tl.load(in_ptr17 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp387 = tl.load(in_ptr16 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp391 = tl.load(in_ptr16 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp395 = tl.load(in_ptr16 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp402 = tl.load(in_ptr18 + (4*r0), None, eviction_policy='evict_last')
    tmp404 = tl.load(in_ptr18 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp407 = tl.load(in_ptr18 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp410 = tl.load(in_ptr18 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp428 = tl.load(in_ptr19 + (4*r0), None, eviction_policy='evict_last')
    tmp430 = tl.load(in_ptr19 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp433 = tl.load(in_ptr19 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp436 = tl.load(in_ptr19 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp454 = tl.load(in_ptr20 + (4*r0), None, eviction_policy='evict_last')
    tmp456 = tl.load(in_ptr20 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp459 = tl.load(in_ptr20 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp462 = tl.load(in_ptr20 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp480 = tl.load(in_ptr21 + (4*r0), None, eviction_policy='evict_last')
    tmp482 = tl.load(in_ptr21 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp485 = tl.load(in_ptr21 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp488 = tl.load(in_ptr21 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp506 = tl.load(in_ptr22 + (4*r0), None, eviction_policy='evict_last')
    tmp508 = tl.load(in_ptr22 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp511 = tl.load(in_ptr22 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp514 = tl.load(in_ptr22 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp532 = tl.load(in_ptr23 + (4*r0), None, eviction_policy='evict_last')
    tmp534 = tl.load(in_ptr23 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp537 = tl.load(in_ptr23 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp540 = tl.load(in_ptr23 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp558 = tl.load(in_ptr24 + (4*r0), None, eviction_policy='evict_last')
    tmp559 = tl.load(in_ptr25 + (4*r0), None, eviction_policy='evict_last')
    tmp561 = tl.load(in_ptr25 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp564 = tl.load(in_ptr25 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp567 = tl.load(in_ptr25 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp573 = tl.load(in_ptr24 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp577 = tl.load(in_ptr24 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp581 = tl.load(in_ptr24 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp588 = tl.load(in_ptr26 + (4*r0), None, eviction_policy='evict_last')
    tmp590 = tl.load(in_ptr26 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp593 = tl.load(in_ptr26 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp596 = tl.load(in_ptr26 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp614 = tl.load(in_ptr27 + (4*r0), None, eviction_policy='evict_last')
    tmp616 = tl.load(in_ptr27 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp619 = tl.load(in_ptr27 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp622 = tl.load(in_ptr27 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp640 = tl.load(in_ptr28 + (4*r0), None, eviction_policy='evict_last')
    tmp642 = tl.load(in_ptr28 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp645 = tl.load(in_ptr28 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp648 = tl.load(in_ptr28 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp666 = tl.load(in_ptr29 + (4*r0), None, eviction_policy='evict_last')
    tmp668 = tl.load(in_ptr29 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp671 = tl.load(in_ptr29 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp674 = tl.load(in_ptr29 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp692 = tl.load(in_ptr30 + (4*r0), None, eviction_policy='evict_last')
    tmp694 = tl.load(in_ptr30 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp697 = tl.load(in_ptr30 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp700 = tl.load(in_ptr30 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp718 = tl.load(in_ptr31 + (4*r0), None, eviction_policy='evict_last')
    tmp720 = tl.load(in_ptr31 + (1 + (4*r0)), None, eviction_policy='evict_last')
    tmp723 = tl.load(in_ptr31 + (2 + (4*r0)), None, eviction_policy='evict_last')
    tmp726 = tl.load(in_ptr31 + (3 + (4*r0)), None, eviction_policy='evict_last')
    tmp2 = tl_math.exp(tmp1)
    tmp4 = tl_math.exp(tmp3)
    tmp5 = tmp2 + tmp4
    tmp7 = tl_math.exp(tmp6)
    tmp8 = tmp5 + tmp7
    tmp10 = tl_math.exp(tmp9)
    tmp11 = tmp8 + tmp10
    tmp12 = tl_math.log(tmp11)
    tmp13 = tmp1 - tmp12
    tmp14 = tmp0 * tmp13
    tmp16 = tmp3 - tmp12
    tmp17 = tmp15 * tmp16
    tmp18 = tmp14 + tmp17
    tmp20 = tmp6 - tmp12
    tmp21 = tmp19 * tmp20
    tmp22 = tmp18 + tmp21
    tmp24 = tmp9 - tmp12
    tmp25 = tmp23 * tmp24
    tmp26 = tmp22 + tmp25
    tmp27 = tl.broadcast_to(tmp26, [XBLOCK, RBLOCK])
    tmp29 = tl.sum(tmp27, 1)[:, None]
    tmp31 = tl_math.exp(tmp30)
    tmp33 = tl_math.exp(tmp32)
    tmp34 = tmp31 + tmp33
    tmp36 = tl_math.exp(tmp35)
    tmp37 = tmp34 + tmp36
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp37 + tmp39
    tmp41 = tl_math.log(tmp40)
    tmp42 = tmp30 - tmp41
    tmp43 = tmp0 * tmp42
    tmp44 = tmp32 - tmp41
    tmp45 = tmp15 * tmp44
    tmp46 = tmp43 + tmp45
    tmp47 = tmp35 - tmp41
    tmp48 = tmp19 * tmp47
    tmp49 = tmp46 + tmp48
    tmp50 = tmp38 - tmp41
    tmp51 = tmp23 * tmp50
    tmp52 = tmp49 + tmp51
    tmp53 = tl.broadcast_to(tmp52, [XBLOCK, RBLOCK])
    tmp55 = tl.sum(tmp53, 1)[:, None]
    tmp57 = tl_math.exp(tmp56)
    tmp59 = tl_math.exp(tmp58)
    tmp60 = tmp57 + tmp59
    tmp62 = tl_math.exp(tmp61)
    tmp63 = tmp60 + tmp62
    tmp65 = tl_math.exp(tmp64)
    tmp66 = tmp63 + tmp65
    tmp67 = tl_math.log(tmp66)
    tmp68 = tmp56 - tmp67
    tmp69 = tmp0 * tmp68
    tmp70 = tmp58 - tmp67
    tmp71 = tmp15 * tmp70
    tmp72 = tmp69 + tmp71
    tmp73 = tmp61 - tmp67
    tmp74 = tmp19 * tmp73
    tmp75 = tmp72 + tmp74
    tmp76 = tmp64 - tmp67
    tmp77 = tmp23 * tmp76
    tmp78 = tmp75 + tmp77
    tmp79 = tl.broadcast_to(tmp78, [XBLOCK, RBLOCK])
    tmp81 = tl.sum(tmp79, 1)[:, None]
    tmp83 = tl_math.exp(tmp82)
    tmp85 = tl_math.exp(tmp84)
    tmp86 = tmp83 + tmp85
    tmp88 = tl_math.exp(tmp87)
    tmp89 = tmp86 + tmp88
    tmp91 = tl_math.exp(tmp90)
    tmp92 = tmp89 + tmp91
    tmp93 = tl_math.log(tmp92)
    tmp94 = tmp82 - tmp93
    tmp95 = tmp0 * tmp94
    tmp96 = tmp84 - tmp93
    tmp97 = tmp15 * tmp96
    tmp98 = tmp95 + tmp97
    tmp99 = tmp87 - tmp93
    tmp100 = tmp19 * tmp99
    tmp101 = tmp98 + tmp100
    tmp102 = tmp90 - tmp93
    tmp103 = tmp23 * tmp102
    tmp104 = tmp101 + tmp103
    tmp105 = tl.broadcast_to(tmp104, [XBLOCK, RBLOCK])
    tmp107 = tl.sum(tmp105, 1)[:, None]
    tmp109 = tl_math.exp(tmp108)
    tmp111 = tl_math.exp(tmp110)
    tmp112 = tmp109 + tmp111
    tmp114 = tl_math.exp(tmp113)
    tmp115 = tmp112 + tmp114
    tmp117 = tl_math.exp(tmp116)
    tmp118 = tmp115 + tmp117
    tmp119 = tl_math.log(tmp118)
    tmp120 = tmp108 - tmp119
    tmp121 = tmp0 * tmp120
    tmp122 = tmp110 - tmp119
    tmp123 = tmp15 * tmp122
    tmp124 = tmp121 + tmp123
    tmp125 = tmp113 - tmp119
    tmp126 = tmp19 * tmp125
    tmp127 = tmp124 + tmp126
    tmp128 = tmp116 - tmp119
    tmp129 = tmp23 * tmp128
    tmp130 = tmp127 + tmp129
    tmp131 = tl.broadcast_to(tmp130, [XBLOCK, RBLOCK])
    tmp133 = tl.sum(tmp131, 1)[:, None]
    tmp135 = tl_math.exp(tmp134)
    tmp137 = tl_math.exp(tmp136)
    tmp138 = tmp135 + tmp137
    tmp140 = tl_math.exp(tmp139)
    tmp141 = tmp138 + tmp140
    tmp143 = tl_math.exp(tmp142)
    tmp144 = tmp141 + tmp143
    tmp145 = tl_math.log(tmp144)
    tmp146 = tmp134 - tmp145
    tmp147 = tmp0 * tmp146
    tmp148 = tmp136 - tmp145
    tmp149 = tmp15 * tmp148
    tmp150 = tmp147 + tmp149
    tmp151 = tmp139 - tmp145
    tmp152 = tmp19 * tmp151
    tmp153 = tmp150 + tmp152
    tmp154 = tmp142 - tmp145
    tmp155 = tmp23 * tmp154
    tmp156 = tmp153 + tmp155
    tmp157 = tl.broadcast_to(tmp156, [XBLOCK, RBLOCK])
    tmp159 = tl.sum(tmp157, 1)[:, None]
    tmp161 = tl_math.exp(tmp160)
    tmp163 = tl_math.exp(tmp162)
    tmp164 = tmp161 + tmp163
    tmp166 = tl_math.exp(tmp165)
    tmp167 = tmp164 + tmp166
    tmp169 = tl_math.exp(tmp168)
    tmp170 = tmp167 + tmp169
    tmp171 = tl_math.log(tmp170)
    tmp172 = tmp160 - tmp171
    tmp173 = tmp0 * tmp172
    tmp174 = tmp162 - tmp171
    tmp175 = tmp15 * tmp174
    tmp176 = tmp173 + tmp175
    tmp177 = tmp165 - tmp171
    tmp178 = tmp19 * tmp177
    tmp179 = tmp176 + tmp178
    tmp180 = tmp168 - tmp171
    tmp181 = tmp23 * tmp180
    tmp182 = tmp179 + tmp181
    tmp183 = tl.broadcast_to(tmp182, [XBLOCK, RBLOCK])
    tmp185 = tl.sum(tmp183, 1)[:, None]
    tmp188 = tl_math.exp(tmp187)
    tmp190 = tl_math.exp(tmp189)
    tmp191 = tmp188 + tmp190
    tmp193 = tl_math.exp(tmp192)
    tmp194 = tmp191 + tmp193
    tmp196 = tl_math.exp(tmp195)
    tmp197 = tmp194 + tmp196
    tmp198 = tl_math.log(tmp197)
    tmp199 = tmp187 - tmp198
    tmp200 = tmp186 * tmp199
    tmp202 = tmp189 - tmp198
    tmp203 = tmp201 * tmp202
    tmp204 = tmp200 + tmp203
    tmp206 = tmp192 - tmp198
    tmp207 = tmp205 * tmp206
    tmp208 = tmp204 + tmp207
    tmp210 = tmp195 - tmp198
    tmp211 = tmp209 * tmp210
    tmp212 = tmp208 + tmp211
    tmp213 = tl.broadcast_to(tmp212, [XBLOCK, RBLOCK])
    tmp215 = tl.sum(tmp213, 1)[:, None]
    tmp217 = tl_math.exp(tmp216)
    tmp219 = tl_math.exp(tmp218)
    tmp220 = tmp217 + tmp219
    tmp222 = tl_math.exp(tmp221)
    tmp223 = tmp220 + tmp222
    tmp225 = tl_math.exp(tmp224)
    tmp226 = tmp223 + tmp225
    tmp227 = tl_math.log(tmp226)
    tmp228 = tmp216 - tmp227
    tmp229 = tmp186 * tmp228
    tmp230 = tmp218 - tmp227
    tmp231 = tmp201 * tmp230
    tmp232 = tmp229 + tmp231
    tmp233 = tmp221 - tmp227
    tmp234 = tmp205 * tmp233
    tmp235 = tmp232 + tmp234
    tmp236 = tmp224 - tmp227
    tmp237 = tmp209 * tmp236
    tmp238 = tmp235 + tmp237
    tmp239 = tl.broadcast_to(tmp238, [XBLOCK, RBLOCK])
    tmp241 = tl.sum(tmp239, 1)[:, None]
    tmp243 = tl_math.exp(tmp242)
    tmp245 = tl_math.exp(tmp244)
    tmp246 = tmp243 + tmp245
    tmp248 = tl_math.exp(tmp247)
    tmp249 = tmp246 + tmp248
    tmp251 = tl_math.exp(tmp250)
    tmp252 = tmp249 + tmp251
    tmp253 = tl_math.log(tmp252)
    tmp254 = tmp242 - tmp253
    tmp255 = tmp186 * tmp254
    tmp256 = tmp244 - tmp253
    tmp257 = tmp201 * tmp256
    tmp258 = tmp255 + tmp257
    tmp259 = tmp247 - tmp253
    tmp260 = tmp205 * tmp259
    tmp261 = tmp258 + tmp260
    tmp262 = tmp250 - tmp253
    tmp263 = tmp209 * tmp262
    tmp264 = tmp261 + tmp263
    tmp265 = tl.broadcast_to(tmp264, [XBLOCK, RBLOCK])
    tmp267 = tl.sum(tmp265, 1)[:, None]
    tmp269 = tl_math.exp(tmp268)
    tmp271 = tl_math.exp(tmp270)
    tmp272 = tmp269 + tmp271
    tmp274 = tl_math.exp(tmp273)
    tmp275 = tmp272 + tmp274
    tmp277 = tl_math.exp(tmp276)
    tmp278 = tmp275 + tmp277
    tmp279 = tl_math.log(tmp278)
    tmp280 = tmp268 - tmp279
    tmp281 = tmp186 * tmp280
    tmp282 = tmp270 - tmp279
    tmp283 = tmp201 * tmp282
    tmp284 = tmp281 + tmp283
    tmp285 = tmp273 - tmp279
    tmp286 = tmp205 * tmp285
    tmp287 = tmp284 + tmp286
    tmp288 = tmp276 - tmp279
    tmp289 = tmp209 * tmp288
    tmp290 = tmp287 + tmp289
    tmp291 = tl.broadcast_to(tmp290, [XBLOCK, RBLOCK])
    tmp293 = tl.sum(tmp291, 1)[:, None]
    tmp295 = tl_math.exp(tmp294)
    tmp297 = tl_math.exp(tmp296)
    tmp298 = tmp295 + tmp297
    tmp300 = tl_math.exp(tmp299)
    tmp301 = tmp298 + tmp300
    tmp303 = tl_math.exp(tmp302)
    tmp304 = tmp301 + tmp303
    tmp305 = tl_math.log(tmp304)
    tmp306 = tmp294 - tmp305
    tmp307 = tmp186 * tmp306
    tmp308 = tmp296 - tmp305
    tmp309 = tmp201 * tmp308
    tmp310 = tmp307 + tmp309
    tmp311 = tmp299 - tmp305
    tmp312 = tmp205 * tmp311
    tmp313 = tmp310 + tmp312
    tmp314 = tmp302 - tmp305
    tmp315 = tmp209 * tmp314
    tmp316 = tmp313 + tmp315
    tmp317 = tl.broadcast_to(tmp316, [XBLOCK, RBLOCK])
    tmp319 = tl.sum(tmp317, 1)[:, None]
    tmp321 = tl_math.exp(tmp320)
    tmp323 = tl_math.exp(tmp322)
    tmp324 = tmp321 + tmp323
    tmp326 = tl_math.exp(tmp325)
    tmp327 = tmp324 + tmp326
    tmp329 = tl_math.exp(tmp328)
    tmp330 = tmp327 + tmp329
    tmp331 = tl_math.log(tmp330)
    tmp332 = tmp320 - tmp331
    tmp333 = tmp186 * tmp332
    tmp334 = tmp322 - tmp331
    tmp335 = tmp201 * tmp334
    tmp336 = tmp333 + tmp335
    tmp337 = tmp325 - tmp331
    tmp338 = tmp205 * tmp337
    tmp339 = tmp336 + tmp338
    tmp340 = tmp328 - tmp331
    tmp341 = tmp209 * tmp340
    tmp342 = tmp339 + tmp341
    tmp343 = tl.broadcast_to(tmp342, [XBLOCK, RBLOCK])
    tmp345 = tl.sum(tmp343, 1)[:, None]
    tmp347 = tl_math.exp(tmp346)
    tmp349 = tl_math.exp(tmp348)
    tmp350 = tmp347 + tmp349
    tmp352 = tl_math.exp(tmp351)
    tmp353 = tmp350 + tmp352
    tmp355 = tl_math.exp(tmp354)
    tmp356 = tmp353 + tmp355
    tmp357 = tl_math.log(tmp356)
    tmp358 = tmp346 - tmp357
    tmp359 = tmp186 * tmp358
    tmp360 = tmp348 - tmp357
    tmp361 = tmp201 * tmp360
    tmp362 = tmp359 + tmp361
    tmp363 = tmp351 - tmp357
    tmp364 = tmp205 * tmp363
    tmp365 = tmp362 + tmp364
    tmp366 = tmp354 - tmp357
    tmp367 = tmp209 * tmp366
    tmp368 = tmp365 + tmp367
    tmp369 = tl.broadcast_to(tmp368, [XBLOCK, RBLOCK])
    tmp371 = tl.sum(tmp369, 1)[:, None]
    tmp374 = tl_math.exp(tmp373)
    tmp376 = tl_math.exp(tmp375)
    tmp377 = tmp374 + tmp376
    tmp379 = tl_math.exp(tmp378)
    tmp380 = tmp377 + tmp379
    tmp382 = tl_math.exp(tmp381)
    tmp383 = tmp380 + tmp382
    tmp384 = tl_math.log(tmp383)
    tmp385 = tmp373 - tmp384
    tmp386 = tmp372 * tmp385
    tmp388 = tmp375 - tmp384
    tmp389 = tmp387 * tmp388
    tmp390 = tmp386 + tmp389
    tmp392 = tmp378 - tmp384
    tmp393 = tmp391 * tmp392
    tmp394 = tmp390 + tmp393
    tmp396 = tmp381 - tmp384
    tmp397 = tmp395 * tmp396
    tmp398 = tmp394 + tmp397
    tmp399 = tl.broadcast_to(tmp398, [XBLOCK, RBLOCK])
    tmp401 = tl.sum(tmp399, 1)[:, None]
    tmp403 = tl_math.exp(tmp402)
    tmp405 = tl_math.exp(tmp404)
    tmp406 = tmp403 + tmp405
    tmp408 = tl_math.exp(tmp407)
    tmp409 = tmp406 + tmp408
    tmp411 = tl_math.exp(tmp410)
    tmp412 = tmp409 + tmp411
    tmp413 = tl_math.log(tmp412)
    tmp414 = tmp402 - tmp413
    tmp415 = tmp372 * tmp414
    tmp416 = tmp404 - tmp413
    tmp417 = tmp387 * tmp416
    tmp418 = tmp415 + tmp417
    tmp419 = tmp407 - tmp413
    tmp420 = tmp391 * tmp419
    tmp421 = tmp418 + tmp420
    tmp422 = tmp410 - tmp413
    tmp423 = tmp395 * tmp422
    tmp424 = tmp421 + tmp423
    tmp425 = tl.broadcast_to(tmp424, [XBLOCK, RBLOCK])
    tmp427 = tl.sum(tmp425, 1)[:, None]
    tmp429 = tl_math.exp(tmp428)
    tmp431 = tl_math.exp(tmp430)
    tmp432 = tmp429 + tmp431
    tmp434 = tl_math.exp(tmp433)
    tmp435 = tmp432 + tmp434
    tmp437 = tl_math.exp(tmp436)
    tmp438 = tmp435 + tmp437
    tmp439 = tl_math.log(tmp438)
    tmp440 = tmp428 - tmp439
    tmp441 = tmp372 * tmp440
    tmp442 = tmp430 - tmp439
    tmp443 = tmp387 * tmp442
    tmp444 = tmp441 + tmp443
    tmp445 = tmp433 - tmp439
    tmp446 = tmp391 * tmp445
    tmp447 = tmp444 + tmp446
    tmp448 = tmp436 - tmp439
    tmp449 = tmp395 * tmp448
    tmp450 = tmp447 + tmp449
    tmp451 = tl.broadcast_to(tmp450, [XBLOCK, RBLOCK])
    tmp453 = tl.sum(tmp451, 1)[:, None]
    tmp455 = tl_math.exp(tmp454)
    tmp457 = tl_math.exp(tmp456)
    tmp458 = tmp455 + tmp457
    tmp460 = tl_math.exp(tmp459)
    tmp461 = tmp458 + tmp460
    tmp463 = tl_math.exp(tmp462)
    tmp464 = tmp461 + tmp463
    tmp465 = tl_math.log(tmp464)
    tmp466 = tmp454 - tmp465
    tmp467 = tmp372 * tmp466
    tmp468 = tmp456 - tmp465
    tmp469 = tmp387 * tmp468
    tmp470 = tmp467 + tmp469
    tmp471 = tmp459 - tmp465
    tmp472 = tmp391 * tmp471
    tmp473 = tmp470 + tmp472
    tmp474 = tmp462 - tmp465
    tmp475 = tmp395 * tmp474
    tmp476 = tmp473 + tmp475
    tmp477 = tl.broadcast_to(tmp476, [XBLOCK, RBLOCK])
    tmp479 = tl.sum(tmp477, 1)[:, None]
    tmp481 = tl_math.exp(tmp480)
    tmp483 = tl_math.exp(tmp482)
    tmp484 = tmp481 + tmp483
    tmp486 = tl_math.exp(tmp485)
    tmp487 = tmp484 + tmp486
    tmp489 = tl_math.exp(tmp488)
    tmp490 = tmp487 + tmp489
    tmp491 = tl_math.log(tmp490)
    tmp492 = tmp480 - tmp491
    tmp493 = tmp372 * tmp492
    tmp494 = tmp482 - tmp491
    tmp495 = tmp387 * tmp494
    tmp496 = tmp493 + tmp495
    tmp497 = tmp485 - tmp491
    tmp498 = tmp391 * tmp497
    tmp499 = tmp496 + tmp498
    tmp500 = tmp488 - tmp491
    tmp501 = tmp395 * tmp500
    tmp502 = tmp499 + tmp501
    tmp503 = tl.broadcast_to(tmp502, [XBLOCK, RBLOCK])
    tmp505 = tl.sum(tmp503, 1)[:, None]
    tmp507 = tl_math.exp(tmp506)
    tmp509 = tl_math.exp(tmp508)
    tmp510 = tmp507 + tmp509
    tmp512 = tl_math.exp(tmp511)
    tmp513 = tmp510 + tmp512
    tmp515 = tl_math.exp(tmp514)
    tmp516 = tmp513 + tmp515
    tmp517 = tl_math.log(tmp516)
    tmp518 = tmp506 - tmp517
    tmp519 = tmp372 * tmp518
    tmp520 = tmp508 - tmp517
    tmp521 = tmp387 * tmp520
    tmp522 = tmp519 + tmp521
    tmp523 = tmp511 - tmp517
    tmp524 = tmp391 * tmp523
    tmp525 = tmp522 + tmp524
    tmp526 = tmp514 - tmp517
    tmp527 = tmp395 * tmp526
    tmp528 = tmp525 + tmp527
    tmp529 = tl.broadcast_to(tmp528, [XBLOCK, RBLOCK])
    tmp531 = tl.sum(tmp529, 1)[:, None]
    tmp533 = tl_math.exp(tmp532)
    tmp535 = tl_math.exp(tmp534)
    tmp536 = tmp533 + tmp535
    tmp538 = tl_math.exp(tmp537)
    tmp539 = tmp536 + tmp538
    tmp541 = tl_math.exp(tmp540)
    tmp542 = tmp539 + tmp541
    tmp543 = tl_math.log(tmp542)
    tmp544 = tmp532 - tmp543
    tmp545 = tmp372 * tmp544
    tmp546 = tmp534 - tmp543
    tmp547 = tmp387 * tmp546
    tmp548 = tmp545 + tmp547
    tmp549 = tmp537 - tmp543
    tmp550 = tmp391 * tmp549
    tmp551 = tmp548 + tmp550
    tmp552 = tmp540 - tmp543
    tmp553 = tmp395 * tmp552
    tmp554 = tmp551 + tmp553
    tmp555 = tl.broadcast_to(tmp554, [XBLOCK, RBLOCK])
    tmp557 = tl.sum(tmp555, 1)[:, None]
    tmp560 = tl_math.exp(tmp559)
    tmp562 = tl_math.exp(tmp561)
    tmp563 = tmp560 + tmp562
    tmp565 = tl_math.exp(tmp564)
    tmp566 = tmp563 + tmp565
    tmp568 = tl_math.exp(tmp567)
    tmp569 = tmp566 + tmp568
    tmp570 = tl_math.log(tmp569)
    tmp571 = tmp559 - tmp570
    tmp572 = tmp558 * tmp571
    tmp574 = tmp561 - tmp570
    tmp575 = tmp573 * tmp574
    tmp576 = tmp572 + tmp575
    tmp578 = tmp564 - tmp570
    tmp579 = tmp577 * tmp578
    tmp580 = tmp576 + tmp579
    tmp582 = tmp567 - tmp570
    tmp583 = tmp581 * tmp582
    tmp584 = tmp580 + tmp583
    tmp585 = tl.broadcast_to(tmp584, [XBLOCK, RBLOCK])
    tmp587 = tl.sum(tmp585, 1)[:, None]
    tmp589 = tl_math.exp(tmp588)
    tmp591 = tl_math.exp(tmp590)
    tmp592 = tmp589 + tmp591
    tmp594 = tl_math.exp(tmp593)
    tmp595 = tmp592 + tmp594
    tmp597 = tl_math.exp(tmp596)
    tmp598 = tmp595 + tmp597
    tmp599 = tl_math.log(tmp598)
    tmp600 = tmp588 - tmp599
    tmp601 = tmp558 * tmp600
    tmp602 = tmp590 - tmp599
    tmp603 = tmp573 * tmp602
    tmp604 = tmp601 + tmp603
    tmp605 = tmp593 - tmp599
    tmp606 = tmp577 * tmp605
    tmp607 = tmp604 + tmp606
    tmp608 = tmp596 - tmp599
    tmp609 = tmp581 * tmp608
    tmp610 = tmp607 + tmp609
    tmp611 = tl.broadcast_to(tmp610, [XBLOCK, RBLOCK])
    tmp613 = tl.sum(tmp611, 1)[:, None]
    tmp615 = tl_math.exp(tmp614)
    tmp617 = tl_math.exp(tmp616)
    tmp618 = tmp615 + tmp617
    tmp620 = tl_math.exp(tmp619)
    tmp621 = tmp618 + tmp620
    tmp623 = tl_math.exp(tmp622)
    tmp624 = tmp621 + tmp623
    tmp625 = tl_math.log(tmp624)
    tmp626 = tmp614 - tmp625
    tmp627 = tmp558 * tmp626
    tmp628 = tmp616 - tmp625
    tmp629 = tmp573 * tmp628
    tmp630 = tmp627 + tmp629
    tmp631 = tmp619 - tmp625
    tmp632 = tmp577 * tmp631
    tmp633 = tmp630 + tmp632
    tmp634 = tmp622 - tmp625
    tmp635 = tmp581 * tmp634
    tmp636 = tmp633 + tmp635
    tmp637 = tl.broadcast_to(tmp636, [XBLOCK, RBLOCK])
    tmp639 = tl.sum(tmp637, 1)[:, None]
    tmp641 = tl_math.exp(tmp640)
    tmp643 = tl_math.exp(tmp642)
    tmp644 = tmp641 + tmp643
    tmp646 = tl_math.exp(tmp645)
    tmp647 = tmp644 + tmp646
    tmp649 = tl_math.exp(tmp648)
    tmp650 = tmp647 + tmp649
    tmp651 = tl_math.log(tmp650)
    tmp652 = tmp640 - tmp651
    tmp653 = tmp558 * tmp652
    tmp654 = tmp642 - tmp651
    tmp655 = tmp573 * tmp654
    tmp656 = tmp653 + tmp655
    tmp657 = tmp645 - tmp651
    tmp658 = tmp577 * tmp657
    tmp659 = tmp656 + tmp658
    tmp660 = tmp648 - tmp651
    tmp661 = tmp581 * tmp660
    tmp662 = tmp659 + tmp661
    tmp663 = tl.broadcast_to(tmp662, [XBLOCK, RBLOCK])
    tmp665 = tl.sum(tmp663, 1)[:, None]
    tmp667 = tl_math.exp(tmp666)
    tmp669 = tl_math.exp(tmp668)
    tmp670 = tmp667 + tmp669
    tmp672 = tl_math.exp(tmp671)
    tmp673 = tmp670 + tmp672
    tmp675 = tl_math.exp(tmp674)
    tmp676 = tmp673 + tmp675
    tmp677 = tl_math.log(tmp676)
    tmp678 = tmp666 - tmp677
    tmp679 = tmp558 * tmp678
    tmp680 = tmp668 - tmp677
    tmp681 = tmp573 * tmp680
    tmp682 = tmp679 + tmp681
    tmp683 = tmp671 - tmp677
    tmp684 = tmp577 * tmp683
    tmp685 = tmp682 + tmp684
    tmp686 = tmp674 - tmp677
    tmp687 = tmp581 * tmp686
    tmp688 = tmp685 + tmp687
    tmp689 = tl.broadcast_to(tmp688, [XBLOCK, RBLOCK])
    tmp691 = tl.sum(tmp689, 1)[:, None]
    tmp693 = tl_math.exp(tmp692)
    tmp695 = tl_math.exp(tmp694)
    tmp696 = tmp693 + tmp695
    tmp698 = tl_math.exp(tmp697)
    tmp699 = tmp696 + tmp698
    tmp701 = tl_math.exp(tmp700)
    tmp702 = tmp699 + tmp701
    tmp703 = tl_math.log(tmp702)
    tmp704 = tmp692 - tmp703
    tmp705 = tmp558 * tmp704
    tmp706 = tmp694 - tmp703
    tmp707 = tmp573 * tmp706
    tmp708 = tmp705 + tmp707
    tmp709 = tmp697 - tmp703
    tmp710 = tmp577 * tmp709
    tmp711 = tmp708 + tmp710
    tmp712 = tmp700 - tmp703
    tmp713 = tmp581 * tmp712
    tmp714 = tmp711 + tmp713
    tmp715 = tl.broadcast_to(tmp714, [XBLOCK, RBLOCK])
    tmp717 = tl.sum(tmp715, 1)[:, None]
    tmp719 = tl_math.exp(tmp718)
    tmp721 = tl_math.exp(tmp720)
    tmp722 = tmp719 + tmp721
    tmp724 = tl_math.exp(tmp723)
    tmp725 = tmp722 + tmp724
    tmp727 = tl_math.exp(tmp726)
    tmp728 = tmp725 + tmp727
    tmp729 = tl_math.log(tmp728)
    tmp730 = tmp718 - tmp729
    tmp731 = tmp558 * tmp730
    tmp732 = tmp720 - tmp729
    tmp733 = tmp573 * tmp732
    tmp734 = tmp731 + tmp733
    tmp735 = tmp723 - tmp729
    tmp736 = tmp577 * tmp735
    tmp737 = tmp734 + tmp736
    tmp738 = tmp726 - tmp729
    tmp739 = tmp581 * tmp738
    tmp740 = tmp737 + tmp739
    tmp741 = tl.broadcast_to(tmp740, [XBLOCK, RBLOCK])
    tmp743 = tl.sum(tmp741, 1)[:, None]
    tmp744 = 4.0
    tmp745 = tmp587 / tmp744
    tmp746 = -tmp745
    tmp747 = 0.0
    tmp748 = tmp746 + tmp747
    tmp749 = tmp613 / tmp744
    tmp750 = -tmp749
    tmp751 = tmp748 + tmp750
    tmp752 = tmp639 / tmp744
    tmp753 = -tmp752
    tmp754 = tmp751 + tmp753
    tmp755 = tmp665 / tmp744
    tmp756 = -tmp755
    tmp757 = tmp754 + tmp756
    tmp758 = tmp691 / tmp744
    tmp759 = -tmp758
    tmp760 = tmp757 + tmp759
    tmp761 = tmp717 / tmp744
    tmp762 = -tmp761
    tmp763 = tmp760 + tmp762
    tmp764 = tmp743 / tmp744
    tmp765 = -tmp764
    tmp766 = tmp763 + tmp765
    tmp767 = 0.14285714285714285
    tmp768 = tmp766 * tmp767
    tmp769 = tmp401 / tmp744
    tmp770 = -tmp769
    tmp771 = tmp770 + tmp747
    tmp772 = tmp427 / tmp744
    tmp773 = -tmp772
    tmp774 = tmp771 + tmp773
    tmp775 = tmp453 / tmp744
    tmp776 = -tmp775
    tmp777 = tmp774 + tmp776
    tmp778 = tmp479 / tmp744
    tmp779 = -tmp778
    tmp780 = tmp777 + tmp779
    tmp781 = tmp505 / tmp744
    tmp782 = -tmp781
    tmp783 = tmp780 + tmp782
    tmp784 = tmp531 / tmp744
    tmp785 = -tmp784
    tmp786 = tmp783 + tmp785
    tmp787 = tmp557 / tmp744
    tmp788 = -tmp787
    tmp789 = tmp786 + tmp788
    tmp790 = tmp789 * tmp767
    tmp791 = tmp215 / tmp744
    tmp792 = -tmp791
    tmp793 = tmp792 + tmp747
    tmp794 = tmp241 / tmp744
    tmp795 = -tmp794
    tmp796 = tmp793 + tmp795
    tmp797 = tmp267 / tmp744
    tmp798 = -tmp797
    tmp799 = tmp796 + tmp798
    tmp800 = tmp293 / tmp744
    tmp801 = -tmp800
    tmp802 = tmp799 + tmp801
    tmp803 = tmp319 / tmp744
    tmp804 = -tmp803
    tmp805 = tmp802 + tmp804
    tmp806 = tmp345 / tmp744
    tmp807 = -tmp806
    tmp808 = tmp805 + tmp807
    tmp809 = tmp371 / tmp744
    tmp810 = -tmp809
    tmp811 = tmp808 + tmp810
    tmp812 = tmp811 * tmp767
    tmp813 = tmp29 / tmp744
    tmp814 = -tmp813
    tmp815 = tmp814 + tmp747
    tmp816 = tmp55 / tmp744
    tmp817 = -tmp816
    tmp818 = tmp815 + tmp817
    tmp819 = tmp81 / tmp744
    tmp820 = -tmp819
    tmp821 = tmp818 + tmp820
    tmp822 = tmp107 / tmp744
    tmp823 = -tmp822
    tmp824 = tmp821 + tmp823
    tmp825 = tmp133 / tmp744
    tmp826 = -tmp825
    tmp827 = tmp824 + tmp826
    tmp828 = tmp159 / tmp744
    tmp829 = -tmp828
    tmp830 = tmp827 + tmp829
    tmp831 = tmp185 / tmp744
    tmp832 = -tmp831
    tmp833 = tmp830 + tmp832
    tmp834 = tmp833 * tmp767
    tmp835 = tmp768 + tmp747
    tmp836 = tmp835 + tmp790
    tmp837 = tmp836 + tmp812
    tmp838 = tmp837 + tmp834
    tmp839 = 0.25
    tmp840 = tmp838 * tmp839
    tl.debug_barrier()
    tl.store(in_out_ptr0 + (tl.full([XBLOCK, 1], 0, tl.int32)), tmp840, None)
''', device_str='cuda')


async_compile.wait(globals())
del async_compile

def call(args):
    arg0_1, arg1_1 = args
    args.clear()
    assert_size_stride(arg0_1, (4, 4, 4), (16, 4, 1))
    assert_size_stride(arg1_1, (4, 4, 4), (16, 4, 1))
    with torch.cuda._DeviceGuard(0):
        torch.cuda.set_device(0)
        buf0 = empty_strided_cuda((), (), torch.float32)
        # Topologically Sorted Source Nodes: [sum_Q], Original ATen: [aten.sum]
        stream0 = get_raw_stream(0)
        triton_per_fused_sum_0.run(arg0_1, buf0, 1, 16, grid=grid(1), stream=stream0)
        buf1 = empty_strided_cuda((4, 1), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [sum_of_rows], Original ATen: [aten.sum]
        triton_poi_fused_sum_1.run(arg0_1, buf0, buf1, 4, grid=grid(4), stream=stream0)
        buf2 = empty_strided_cuda((1, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [sum_3], Original ATen: [aten.sum]
        triton_poi_fused_sum_2.run(arg0_1, buf0, buf1, buf2, 4, grid=grid(4), stream=stream0)
        buf3 = empty_strided_cuda((4, 1), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [sum_of_rows_1], Original ATen: [aten.sum]
        triton_poi_fused_sum_3.run(arg0_1, buf0, buf1, buf2, buf3, 4, grid=grid(4), stream=stream0)
        buf4 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_7], Original ATen: [aten.div]
        triton_poi_fused_div_4.run(arg0_1, buf0, buf1, buf2, buf3, buf4, 16, grid=grid(16), stream=stream0)
        buf5 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_9], Original ATen: [aten.div]
        triton_poi_fused_div_5.run(buf4, buf5, 16, grid=grid(16), stream=stream0)
        buf6 = buf4; del buf4  # reuse
        # Topologically Sorted Source Nodes: [Q_11], Original ATen: [aten.div]
        triton_poi_fused_div_6.run(buf5, buf6, 16, grid=grid(16), stream=stream0)
        buf7 = buf5; del buf5  # reuse
        # Topologically Sorted Source Nodes: [Q_14], Original ATen: [aten.mul]
        triton_poi_fused_mul_7.run(buf6, buf7, 16, grid=grid(16), stream=stream0)
        buf23 = buf0; del buf0  # reuse
        buf56 = reinterpret_tensor(buf6, (4, 4), (4, 1), 0); del buf6  # reuse
        buf79 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [sum_Q_1], Original ATen: [aten.sum]
        triton_per_fused_sum_8.run(arg0_1, buf23, buf56, buf79, 1, 16, grid=grid(1), stream=stream0)
        buf24 = buf3; del buf3  # reuse
        # Topologically Sorted Source Nodes: [sum_of_rows_3], Original ATen: [aten.sum]
        triton_poi_fused_sum_9.run(arg0_1, buf23, buf24, 4, grid=grid(4), stream=stream0)
        buf25 = buf2; del buf2  # reuse
        # Topologically Sorted Source Nodes: [sum_17], Original ATen: [aten.sum]
        triton_poi_fused_sum_10.run(arg0_1, buf23, buf24, buf25, 4, grid=grid(4), stream=stream0)
        buf26 = buf1; del buf1  # reuse
        # Topologically Sorted Source Nodes: [sum_of_rows_4], Original ATen: [aten.sum]
        triton_poi_fused_sum_11.run(arg0_1, buf23, buf24, buf25, buf26, 4, grid=grid(4), stream=stream0)
        buf8 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf27 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_22], Original ATen: [aten.div]
        triton_poi_fused_div_12.run(arg0_1, buf23, buf24, buf25, buf26, buf8, buf27, 16, grid=grid(16), stream=stream0)
        buf46 = buf23; del buf23  # reuse
        buf81 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [sum_Q_2], Original ATen: [aten.sum]
        triton_per_fused_sum_13.run(arg0_1, buf46, buf81, 1, 16, grid=grid(1), stream=stream0)
        buf47 = buf26; del buf26  # reuse
        # Topologically Sorted Source Nodes: [sum_of_rows_6], Original ATen: [aten.sum]
        triton_poi_fused_sum_14.run(arg0_1, buf46, buf47, 4, grid=grid(4), stream=stream0)
        buf48 = buf25; del buf25  # reuse
        # Topologically Sorted Source Nodes: [sum_31], Original ATen: [aten.sum]
        triton_poi_fused_sum_15.run(arg0_1, buf46, buf47, buf48, 4, grid=grid(4), stream=stream0)
        buf49 = buf24; del buf24  # reuse
        # Topologically Sorted Source Nodes: [sum_of_rows_7], Original ATen: [aten.sum]
        triton_poi_fused_sum_16.run(arg0_1, buf46, buf47, buf48, buf49, 4, grid=grid(4), stream=stream0)
        buf10 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf33 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf50 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_37], Original ATen: [aten.div]
        triton_poi_fused_div_17.run(arg0_1, buf46, buf47, buf48, buf49, buf10, buf33, buf50, 16, grid=grid(16), stream=stream0)
        buf69 = buf46; del buf46  # reuse
        # Topologically Sorted Source Nodes: [sum_Q_3], Original ATen: [aten.sum]
        triton_per_fused_sum_18.run(arg0_1, buf69, 1, 16, grid=grid(1), stream=stream0)
        buf70 = buf49; del buf49  # reuse
        # Topologically Sorted Source Nodes: [sum_of_rows_9], Original ATen: [aten.sum]
        triton_poi_fused_sum_19.run(arg0_1, buf69, buf70, 4, grid=grid(4), stream=stream0)
        buf71 = buf48; del buf48  # reuse
        # Topologically Sorted Source Nodes: [sum_45], Original ATen: [aten.sum]
        triton_poi_fused_sum_20.run(arg0_1, buf69, buf70, buf71, 4, grid=grid(4), stream=stream0)
        buf72 = buf47; del buf47  # reuse
        # Topologically Sorted Source Nodes: [sum_of_rows_10], Original ATen: [aten.sum]
        triton_poi_fused_sum_21.run(arg0_1, buf69, buf70, buf71, buf72, 4, grid=grid(4), stream=stream0)
        buf12 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf35 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf58 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf73 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_52], Original ATen: [aten.div]
        triton_poi_fused_div_22.run(arg0_1, buf69, buf70, buf71, buf72, buf12, buf35, buf58, buf73, 16, grid=grid(16), stream=stream0)
        del buf70
        del buf71
        del buf72
        buf14 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf37 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf60 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_23.run(arg1_1, buf14, buf37, buf60, 16, grid=grid(16), stream=stream0)
        buf16 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf39 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf62 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_24.run(arg1_1, buf16, buf39, buf62, 16, grid=grid(16), stream=stream0)
        buf18 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf41 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf64 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_25.run(arg1_1, buf18, buf41, buf64, 16, grid=grid(16), stream=stream0)
        buf20 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf43 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf66 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_26.run(arg1_1, buf20, buf43, buf66, 16, grid=grid(16), stream=stream0)
        buf28 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_24], Original ATen: [aten.div]
        triton_poi_fused_div_5.run(buf27, buf28, 16, grid=grid(16), stream=stream0)
        buf29 = buf27; del buf27  # reuse
        # Topologically Sorted Source Nodes: [Q_26], Original ATen: [aten.div]
        triton_poi_fused_div_6.run(buf28, buf29, 16, grid=grid(16), stream=stream0)
        buf30 = buf28; del buf28  # reuse
        # Topologically Sorted Source Nodes: [Q_29], Original ATen: [aten.mul]
        triton_poi_fused_mul_7.run(buf29, buf30, 16, grid=grid(16), stream=stream0)
        buf31 = reinterpret_tensor(buf29, (4, 4), (4, 1), 0); del buf29  # reuse
        buf54 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf77 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_23.run(arg0_1, buf31, buf54, buf77, 16, grid=grid(16), stream=stream0)
        del arg0_1
        buf51 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        # Topologically Sorted Source Nodes: [Q_39], Original ATen: [aten.div]
        triton_poi_fused_div_5.run(buf50, buf51, 16, grid=grid(16), stream=stream0)
        buf52 = buf50; del buf50  # reuse
        # Topologically Sorted Source Nodes: [Q_41], Original ATen: [aten.div]
        triton_poi_fused_div_6.run(buf51, buf52, 16, grid=grid(16), stream=stream0)
        buf53 = buf51; del buf51  # reuse
        # Topologically Sorted Source Nodes: [Q_44], Original ATen: [aten.mul]
        triton_poi_fused_mul_7.run(buf52, buf53, 16, grid=grid(16), stream=stream0)
        buf74 = buf52; del buf52  # reuse
        # Topologically Sorted Source Nodes: [Q_54], Original ATen: [aten.div]
        triton_poi_fused_div_5.run(buf73, buf74, 16, grid=grid(16), stream=stream0)
        buf75 = buf73; del buf73  # reuse
        # Topologically Sorted Source Nodes: [Q_56], Original ATen: [aten.div]
        triton_poi_fused_div_6.run(buf74, buf75, 16, grid=grid(16), stream=stream0)
        buf76 = buf74; del buf74  # reuse
        # Topologically Sorted Source Nodes: [Q_59], Original ATen: [aten.mul]
        triton_poi_fused_mul_7.run(buf75, buf76, 16, grid=grid(16), stream=stream0)
        buf83 = reinterpret_tensor(buf75, (4, 4), (4, 1), 0); del buf75  # reuse
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_27.run(arg1_1, buf83, 16, grid=grid(16), stream=stream0)
        buf85 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_28.run(arg1_1, buf85, 16, grid=grid(16), stream=stream0)
        buf87 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_29.run(arg1_1, buf87, 16, grid=grid(16), stream=stream0)
        buf89 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        # Topologically Sorted Source Nodes: [], Original ATen: []
        triton_poi_fused_30.run(arg1_1, buf89, 16, grid=grid(16), stream=stream0)
        del arg1_1
        buf11 = buf69; del buf69  # reuse
        buf22 = buf11; del buf11  # reuse
        buf92 = buf22; del buf22  # reuse
        # Topologically Sorted Source Nodes: [log_softmax, mul, sum_8, mean, neg, subloss, log_softmax_1, mul_1, sum_9, mean_1, neg_1, subloss_1, log_softmax_2, mul_2, sum_10, mean_2, neg_2, subloss_2, log_softmax_3, mul_3, sum_11, mean_3, neg_3, subloss_3, log_softmax_4, mul_4, sum_12, mean_4, neg_4, subloss_4, log_softmax_5, mul_5, sum_13, mean_5, neg_5, subloss_5, log_softmax_6, mul_6, sum_14, mean_6, neg_6, subloss_6, truediv_8, loss, log_softmax_7, mul_7, sum_22, mean_7, neg_7, subloss_7, log_softmax_8, mul_8, sum_23, mean_8, neg_8, subloss_8, log_softmax_9, mul_9, sum_24, mean_9, neg_9, subloss_9, log_softmax_10, mul_10, sum_25, mean_10, neg_10, subloss_10, log_softmax_11, mul_11, sum_26, mean_11, neg_11, subloss_11, log_softmax_12, mul_12, sum_27, mean_12, neg_12, subloss_12, log_softmax_13, mul_13, sum_28, mean_13, neg_13, subloss_13, truediv_17, loss_1, log_softmax_14, mul_14, sum_36, mean_14, neg_14, subloss_14, log_softmax_15, mul_15, sum_37, mean_15, neg_15, subloss_15, log_softmax_16, mul_16, sum_38, mean_16, neg_16, subloss_16, log_softmax_17, mul_17, sum_39, mean_17, neg_17, subloss_17, log_softmax_18, mul_18, sum_40, mean_18, neg_18, subloss_18, log_softmax_19, mul_19, sum_41, mean_19, neg_19, subloss_19, log_softmax_20, mul_20, sum_42, mean_20, neg_20, subloss_20, truediv_26, loss_2, log_softmax_21, mul_21, sum_50, mean_21, neg_21, subloss_21, log_softmax_22, mul_22, sum_51, mean_22, neg_22, subloss_22, log_softmax_23, mul_23, sum_52, mean_23, neg_23, subloss_23, log_softmax_24, mul_24, sum_53, mean_24, neg_24, subloss_24, log_softmax_25, mul_25, sum_54, mean_25, neg_25, subloss_25, log_softmax_26, mul_26, sum_55, mean_26, neg_26, subloss_26, log_softmax_27, mul_27, sum_56, mean_27, neg_27, subloss_27, truediv_35, loss_3, truediv_36], Original ATen: [aten._log_softmax, aten.mul, aten.sum, aten.mean, aten.neg, aten.add, aten.div]
        triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31.run(buf92, buf76, buf77, buf79, buf81, buf83, buf85, buf87, buf89, buf53, buf54, buf56, buf58, buf60, buf62, buf64, buf66, buf30, buf31, buf33, buf35, buf37, buf39, buf41, buf43, buf7, buf8, buf10, buf12, buf14, buf16, buf18, buf20, 1, 4, grid=grid(1), stream=stream0)
        del buf10
        del buf12
        del buf14
        del buf16
        del buf18
        del buf20
        del buf30
        del buf31
        del buf33
        del buf35
        del buf37
        del buf39
        del buf41
        del buf43
        del buf53
        del buf54
        del buf56
        del buf58
        del buf60
        del buf62
        del buf64
        del buf66
        del buf7
        del buf76
        del buf77
        del buf79
        del buf8
        del buf81
        del buf83
        del buf85
        del buf87
        del buf89
    return (buf92, )


def benchmark_compiled_module(times=10, repeat=10):
    from torch._dynamo.testing import rand_strided
    from torch._inductor.utils import print_performance
    arg0_1 = rand_strided((4, 4, 4), (16, 4, 1), device='cuda:0', dtype=torch.float32)
    arg1_1 = rand_strided((4, 4, 4), (16, 4, 1), device='cuda:0', dtype=torch.float32)
    fn = lambda: call([arg0_1, arg1_1])
    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)

import torch
import torch.nn.functional as F
from typing import List
import torch.nn as nn


@torch.no_grad()
def sinkhorn(out: 'torch.Tensor', iterations: 'int'=3, epsilon: 'float'=0.05):
    """Distributed sinkhorn algorithm.

    As outlined in [0] and implemented in [1].

    [0]: SwaV, 2020, https://arxiv.org/abs/2006.09882
    [1]: https://github.com/facebookresearch/swav/

    Args:
        out:
            Similarity of the features and the SwaV prototypes.
        iterations:
            Number of sinkhorn iterations.
        epsilon:
            Temperature parameter.

    Returns:
        Soft codes Q assigning each feature to a prototype.
    """
    Q = torch.exp(out / epsilon).t()
    sum_Q = torch.sum(Q)
    Q /= sum_Q
    B = Q.shape[1]
    K = Q.shape[0]
    for i in range(iterations):
        sum_of_rows = torch.sum(Q, dim=1, keepdim=True)
        Q /= sum_of_rows
        Q /= K
        Q /= torch.sum(Q, dim=0, keepdim=True)
        Q /= B
    Q *= B
    return Q.t()


class SwaVLoss(nn.Module):
    """Implementation of the SwaV loss.

    Attributes:
        temperature:
            Temperature parameter used for cross entropy calculations.
        sinkhorn_iterations:
            Number of iterations of the sinkhorn algorithm.
        sinkhorn_epsilon:
            Temperature parameter used in the sinkhorn algorithm.
    """

    def __init__(self, temperature: 'float'=0.1, sinkhorn_iterations: 'int'
        =3, sinkhorn_epsilon: 'float'=0.05):
        super(SwaVLoss, self).__init__()
        self.temperature = temperature
        self.sinkhorn_iterations = sinkhorn_iterations
        self.sinkhorn_epsilon = sinkhorn_epsilon

    def subloss(self, z: 'torch.Tensor', q: 'torch.Tensor'):
        """Calculates the cross entropy for the SwaV prediction problem.

        Args:
            z:
                Similarity of the features and the SwaV prototypes.
            q:
                Codes obtained from Sinkhorn iterations.

        Returns:
            Cross entropy between predictions z and codes q.
        """
        return -torch.mean(torch.sum(q * F.log_softmax(z / self.temperature,
            dim=1), dim=1))

    def forward(self, high_resolution_outputs: 'List[torch.Tensor]',
        low_resolution_outputs: 'List[torch.Tensor]'):
        """Computes the SwaV loss for a set of high and low resolution outputs.

        Args:
            high_resolution_outputs:
                List of similarities of features and SwaV prototypes for the
                high resolution crops.
            low_resolution_outputs:
                List of similarities of features and SwaV prototypes for the
                low resolution crops.

        Returns:
            Swapping assignments between views loss (SwaV) as described in [0].

        [0]: SwaV, 2020, https://arxiv.org/abs/2006.09882
        """
        n_crops = len(high_resolution_outputs) + len(low_resolution_outputs)
        loss = 0.0
        for i in range(len(high_resolution_outputs)):
            with torch.no_grad():
                q = sinkhorn(high_resolution_outputs[i].detach(),
                    iterations=self.sinkhorn_iterations, epsilon=self.
                    sinkhorn_epsilon)
            subloss = 0.0
            for v in range(len(high_resolution_outputs)):
                if v != i:
                    subloss += self.subloss(high_resolution_outputs[v], q)
            for v in range(len(low_resolution_outputs)):
                subloss += self.subloss(low_resolution_outputs[v], q)
            loss += subloss / (n_crops - 1)
        return loss / len(high_resolution_outputs)


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


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

import torch
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 math as tl_math
import torch.nn.functional as F
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
reinterpret_tensor = torch._C._dynamo.guards._reinterpret_tensor


@triton.jit
def triton_per_fused_sum_0(in_ptr0, out_ptr0, xnumel, rnumel, XBLOCK: tl.
    constexpr):
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xoffset + tl.arange(0, XBLOCK)[:, None]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    tmp0 = tl.load(in_ptr0 + r0, None)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tl.store(out_ptr0 + tl.full([XBLOCK, 1], 0, tl.int32), tmp6, None)


@triton.jit
def triton_poi_fused_sum_1(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.
    constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + x0, xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (4 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (8 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (12 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + x0, tmp21, xmask)


@triton.jit
def triton_poi_fused_sum_2(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + 4 * x0, xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + 0)
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (1 + 4 * x0), xmask, eviction_policy='evict_last'
        )
    tmp16 = tl.load(in_ptr2 + 1)
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (2 + 4 * x0), xmask, eviction_policy='evict_last'
        )
    tmp25 = tl.load(in_ptr2 + 2)
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (3 + 4 * x0), xmask, eviction_policy='evict_last'
        )
    tmp34 = tl.load(in_ptr2 + 3)
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + x0, tmp38, xmask)


@triton.jit
def triton_poi_fused_sum_3(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + x0, xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + x0, xmask)
    tmp11 = tl.load(in_ptr3 + 0)
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (4 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + 1)
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (8 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + 2)
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (12 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + 3)
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + x0, tmp47, xmask)


@triton.jit
def triton_poi_fused_div_4(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4,
    out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x0 = xindex % 4
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + x2, xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + x0, xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr3 + x1, xmask, eviction_policy='evict_last')
    tmp14 = tl.load(in_ptr4 + x0, xmask, eviction_policy='evict_last')
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp12 = tmp10 / tmp11
    tmp13 = tmp12 * tmp9
    tmp15 = tmp13 / tmp14
    tmp16 = tmp15 * tmp9
    tl.store(out_ptr0 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_div_5(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + x2, xmask)
    tmp1 = tl.load(in_ptr0 + 4 * x1, xmask, eviction_policy='evict_last')
    tmp2 = tl.load(in_ptr0 + (1 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr0 + (2 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr0 + (3 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp3 = tmp1 + tmp2
    tmp5 = tmp3 + tmp4
    tmp7 = tmp5 + tmp6
    tmp8 = tmp0 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tl.store(out_ptr0 + x2, tmp10, xmask)


@triton.jit
def triton_poi_fused_div_6(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + x2, xmask)
    tmp1 = tl.load(in_ptr0 + x0, xmask, eviction_policy='evict_last')
    tmp2 = tl.load(in_ptr0 + (4 + x0), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr0 + (8 + x0), xmask, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr0 + (12 + x0), xmask, eviction_policy='evict_last')
    tmp3 = tmp1 + tmp2
    tmp5 = tmp3 + tmp4
    tmp7 = tmp5 + tmp6
    tmp8 = tmp0 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tl.store(out_ptr0 + x2, tmp10, xmask)


@triton.jit
def triton_poi_fused_mul_7(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + x2, xmask)
    tmp1 = tl.load(in_ptr0 + 4 * x1, xmask, eviction_policy='evict_last')
    tmp2 = tl.load(in_ptr0 + (1 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp4 = tl.load(in_ptr0 + (2 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr0 + (3 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp3 = tmp1 + tmp2
    tmp5 = tmp3 + tmp4
    tmp7 = tmp5 + tmp6
    tmp8 = tmp0 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp11 = 4.0
    tmp12 = tmp10 * tmp11
    tl.store(out_ptr0 + x2, tmp12, xmask)


@triton.jit
def triton_per_fused_sum_8(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel,
    rnumel, XBLOCK: tl.constexpr):
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xoffset + tl.arange(0, XBLOCK)[:, None]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    r2 = rindex // 4
    tmp0 = tl.load(in_ptr0 + (16 + r0), None)
    tmp9 = tl.load(in_ptr0 + (16 + 4 * r2), None, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (17 + 4 * r2), None, eviction_policy='evict_last'
        )
    tmp14 = tl.load(in_ptr0 + (18 + 4 * r2), None, eviction_policy='evict_last'
        )
    tmp17 = tl.load(in_ptr0 + (19 + 4 * r2), None, eviction_policy='evict_last'
        )
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tmp7 = 1.0
    tmp8 = tmp0 * tmp7
    tmp10 = tmp9 * tmp7
    tmp12 = tmp11 * tmp7
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp15 = tmp14 * tmp7
    tmp16 = triton_helpers.maximum(tmp13, tmp15)
    tmp18 = tmp17 * tmp7
    tmp19 = triton_helpers.maximum(tmp16, tmp18)
    tmp20 = tmp8 - tmp19
    tmp21 = 10.0
    tmp22 = tmp20 * tmp21
    tl.store(out_ptr1 + tl.broadcast_to(r0, [XBLOCK, RBLOCK]), tmp22, None)
    tl.store(out_ptr2 + tl.broadcast_to(r0, [XBLOCK, RBLOCK]), tmp22, None)
    tl.store(out_ptr0 + tl.full([XBLOCK, 1], 0, tl.int32), tmp6, None)


@triton.jit
def triton_poi_fused_sum_9(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.
    constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (16 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (20 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (24 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (28 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + x0, tmp21, xmask)


@triton.jit
def triton_poi_fused_sum_10(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (16 + 4 * x0), xmask, eviction_policy='evict_last'
        )
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + 0)
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (17 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp16 = tl.load(in_ptr2 + 1)
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (18 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp25 = tl.load(in_ptr2 + 2)
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (19 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp34 = tl.load(in_ptr2 + 3)
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + x0, tmp38, xmask)


@triton.jit
def triton_poi_fused_sum_11(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (16 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + x0, xmask)
    tmp11 = tl.load(in_ptr3 + 0)
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (20 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + 1)
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (24 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + 2)
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (28 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + 3)
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + x0, tmp47, xmask)


@triton.jit
def triton_poi_fused_div_12(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4,
    out_ptr0, out_ptr1, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (16 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (16 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (17 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (18 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (19 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp20 = tl.load(in_ptr1 + 0)
    tmp21 = tl.broadcast_to(tmp20, [XBLOCK])
    tmp23 = tl.load(in_ptr2 + x0, xmask, eviction_policy='evict_last')
    tmp27 = tl.load(in_ptr3 + x1, xmask, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr4 + x0, xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tmp17 = 20.0
    tmp18 = tmp0 * tmp17
    tmp19 = tl_math.exp(tmp18)
    tmp22 = tmp19 / tmp21
    tmp24 = tmp22 / tmp23
    tmp25 = 0.25
    tmp26 = tmp24 * tmp25
    tmp28 = tmp26 / tmp27
    tmp29 = tmp28 * tmp25
    tmp31 = tmp29 / tmp30
    tmp32 = tmp31 * tmp25
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp32, xmask)


@triton.jit
def triton_per_fused_sum_13(in_ptr0, out_ptr0, out_ptr1, xnumel, rnumel,
    XBLOCK: tl.constexpr):
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xoffset + tl.arange(0, XBLOCK)[:, None]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    r2 = rindex // 4
    tmp0 = tl.load(in_ptr0 + (32 + r0), None)
    tmp9 = tl.load(in_ptr0 + (32 + 4 * r2), None, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (33 + 4 * r2), None, eviction_policy='evict_last'
        )
    tmp14 = tl.load(in_ptr0 + (34 + 4 * r2), None, eviction_policy='evict_last'
        )
    tmp17 = tl.load(in_ptr0 + (35 + 4 * r2), None, eviction_policy='evict_last'
        )
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tmp7 = 1.0
    tmp8 = tmp0 * tmp7
    tmp10 = tmp9 * tmp7
    tmp12 = tmp11 * tmp7
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp15 = tmp14 * tmp7
    tmp16 = triton_helpers.maximum(tmp13, tmp15)
    tmp18 = tmp17 * tmp7
    tmp19 = triton_helpers.maximum(tmp16, tmp18)
    tmp20 = tmp8 - tmp19
    tmp21 = 10.0
    tmp22 = tmp20 * tmp21
    tl.store(out_ptr1 + tl.broadcast_to(r0, [XBLOCK, RBLOCK]), tmp22, None)
    tl.store(out_ptr0 + tl.full([XBLOCK, 1], 0, tl.int32), tmp6, None)


@triton.jit
def triton_poi_fused_sum_14(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.
    constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (32 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (36 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (40 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (44 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + x0, tmp21, xmask)


@triton.jit
def triton_poi_fused_sum_15(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (32 + 4 * x0), xmask, eviction_policy='evict_last'
        )
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + 0)
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (33 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp16 = tl.load(in_ptr2 + 1)
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (34 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp25 = tl.load(in_ptr2 + 2)
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (35 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp34 = tl.load(in_ptr2 + 3)
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + x0, tmp38, xmask)


@triton.jit
def triton_poi_fused_sum_16(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (32 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + x0, xmask)
    tmp11 = tl.load(in_ptr3 + 0)
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (36 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + 1)
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (40 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + 2)
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (44 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + 3)
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + x0, tmp47, xmask)


@triton.jit
def triton_poi_fused_div_17(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4,
    out_ptr0, out_ptr1, out_ptr2, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (32 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (32 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (33 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (34 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (35 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp20 = tl.load(in_ptr1 + 0)
    tmp21 = tl.broadcast_to(tmp20, [XBLOCK])
    tmp23 = tl.load(in_ptr2 + x0, xmask, eviction_policy='evict_last')
    tmp27 = tl.load(in_ptr3 + x1, xmask, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr4 + x0, xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tmp17 = 20.0
    tmp18 = tmp0 * tmp17
    tmp19 = tl_math.exp(tmp18)
    tmp22 = tmp19 / tmp21
    tmp24 = tmp22 / tmp23
    tmp25 = 0.25
    tmp26 = tmp24 * tmp25
    tmp28 = tmp26 / tmp27
    tmp29 = tmp28 * tmp25
    tmp31 = tmp29 / tmp30
    tmp32 = tmp31 * tmp25
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp16, xmask)
    tl.store(out_ptr2 + x2, tmp32, xmask)


@triton.jit
def triton_per_fused_sum_18(in_ptr0, out_ptr0, xnumel, rnumel, XBLOCK: tl.
    constexpr):
    RBLOCK: tl.constexpr = 16
    xoffset = tl.program_id(0) * XBLOCK
    xoffset + tl.arange(0, XBLOCK)[:, None]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    tmp0 = tl.load(in_ptr0 + (48 + r0), None)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp4 = tl.broadcast_to(tmp3, [XBLOCK, RBLOCK])
    tmp6 = tl.sum(tmp4, 1)[:, None]
    tl.store(out_ptr0 + tl.full([XBLOCK, 1], 0, tl.int32), tmp6, None)


@triton.jit
def triton_poi_fused_sum_19(in_ptr0, in_ptr1, out_ptr0, xnumel, XBLOCK: tl.
    constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (48 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr0 + (52 + x0), xmask)
    tmp12 = tl.load(in_ptr0 + (56 + x0), xmask)
    tmp17 = tl.load(in_ptr0 + (60 + x0), xmask)
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp7 * tmp1
    tmp9 = tl_math.exp(tmp8)
    tmp10 = tmp9 / tmp5
    tmp11 = tmp6 + tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp16 = tmp11 + tmp15
    tmp18 = tmp17 * tmp1
    tmp19 = tl_math.exp(tmp18)
    tmp20 = tmp19 / tmp5
    tmp21 = tmp16 + tmp20
    tl.store(out_ptr0 + x0, tmp21, xmask)


@triton.jit
def triton_poi_fused_sum_20(in_ptr0, in_ptr1, in_ptr2, out_ptr0, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (48 + 4 * x0), xmask, eviction_policy='evict_last'
        )
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + 0)
    tmp8 = tl.broadcast_to(tmp7, [XBLOCK])
    tmp12 = tl.load(in_ptr0 + (49 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp16 = tl.load(in_ptr2 + 1)
    tmp17 = tl.broadcast_to(tmp16, [XBLOCK])
    tmp21 = tl.load(in_ptr0 + (50 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp25 = tl.load(in_ptr2 + 2)
    tmp26 = tl.broadcast_to(tmp25, [XBLOCK])
    tmp30 = tl.load(in_ptr0 + (51 + 4 * x0), xmask, eviction_policy=
        'evict_last')
    tmp34 = tl.load(in_ptr2 + 3)
    tmp35 = tl.broadcast_to(tmp34, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp9 = tmp6 / tmp8
    tmp10 = 0.25
    tmp11 = tmp9 * tmp10
    tmp13 = tmp12 * tmp1
    tmp14 = tl_math.exp(tmp13)
    tmp15 = tmp14 / tmp5
    tmp18 = tmp15 / tmp17
    tmp19 = tmp18 * tmp10
    tmp20 = tmp11 + tmp19
    tmp22 = tmp21 * tmp1
    tmp23 = tl_math.exp(tmp22)
    tmp24 = tmp23 / tmp5
    tmp27 = tmp24 / tmp26
    tmp28 = tmp27 * tmp10
    tmp29 = tmp20 + tmp28
    tmp31 = tmp30 * tmp1
    tmp32 = tl_math.exp(tmp31)
    tmp33 = tmp32 / tmp5
    tmp36 = tmp33 / tmp35
    tmp37 = tmp36 * tmp10
    tmp38 = tmp29 + tmp37
    tl.store(out_ptr0 + x0, tmp38, xmask)


@triton.jit
def triton_poi_fused_sum_21(in_ptr0, in_ptr1, in_ptr2, in_ptr3, out_ptr0,
    xnumel, XBLOCK: tl.constexpr):
    xnumel = 4
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x0 = xindex
    tmp0 = tl.load(in_ptr0 + (48 + x0), xmask)
    tmp4 = tl.load(in_ptr1 + 0)
    tmp5 = tl.broadcast_to(tmp4, [XBLOCK])
    tmp7 = tl.load(in_ptr2 + x0, xmask)
    tmp11 = tl.load(in_ptr3 + 0)
    tmp12 = tl.broadcast_to(tmp11, [XBLOCK])
    tmp15 = tl.load(in_ptr0 + (52 + x0), xmask)
    tmp21 = tl.load(in_ptr3 + 1)
    tmp22 = tl.broadcast_to(tmp21, [XBLOCK])
    tmp26 = tl.load(in_ptr0 + (56 + x0), xmask)
    tmp32 = tl.load(in_ptr3 + 2)
    tmp33 = tl.broadcast_to(tmp32, [XBLOCK])
    tmp37 = tl.load(in_ptr0 + (60 + x0), xmask)
    tmp43 = tl.load(in_ptr3 + 3)
    tmp44 = tl.broadcast_to(tmp43, [XBLOCK])
    tmp1 = 20.0
    tmp2 = tmp0 * tmp1
    tmp3 = tl_math.exp(tmp2)
    tmp6 = tmp3 / tmp5
    tmp8 = tmp6 / tmp7
    tmp9 = 0.25
    tmp10 = tmp8 * tmp9
    tmp13 = tmp10 / tmp12
    tmp14 = tmp13 * tmp9
    tmp16 = tmp15 * tmp1
    tmp17 = tl_math.exp(tmp16)
    tmp18 = tmp17 / tmp5
    tmp19 = tmp18 / tmp7
    tmp20 = tmp19 * tmp9
    tmp23 = tmp20 / tmp22
    tmp24 = tmp23 * tmp9
    tmp25 = tmp14 + tmp24
    tmp27 = tmp26 * tmp1
    tmp28 = tl_math.exp(tmp27)
    tmp29 = tmp28 / tmp5
    tmp30 = tmp29 / tmp7
    tmp31 = tmp30 * tmp9
    tmp34 = tmp31 / tmp33
    tmp35 = tmp34 * tmp9
    tmp36 = tmp25 + tmp35
    tmp38 = tmp37 * tmp1
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp39 / tmp5
    tmp41 = tmp40 / tmp7
    tmp42 = tmp41 * tmp9
    tmp45 = tmp42 / tmp44
    tmp46 = tmp45 * tmp9
    tmp47 = tmp36 + tmp46
    tl.store(out_ptr0 + x0, tmp47, xmask)


@triton.jit
def triton_poi_fused_div_22(in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4,
    out_ptr0, out_ptr1, out_ptr2, out_ptr3, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    x0 = xindex % 4
    tmp0 = tl.load(in_ptr0 + (48 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (48 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (49 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (50 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (51 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp20 = tl.load(in_ptr1 + 0)
    tmp21 = tl.broadcast_to(tmp20, [XBLOCK])
    tmp23 = tl.load(in_ptr2 + x0, xmask, eviction_policy='evict_last')
    tmp27 = tl.load(in_ptr3 + x1, xmask, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr4 + x0, xmask, eviction_policy='evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tmp17 = 20.0
    tmp18 = tmp0 * tmp17
    tmp19 = tl_math.exp(tmp18)
    tmp22 = tmp19 / tmp21
    tmp24 = tmp22 / tmp23
    tmp25 = 0.25
    tmp26 = tmp24 * tmp25
    tmp28 = tmp26 / tmp27
    tmp29 = tmp28 * tmp25
    tmp31 = tmp29 / tmp30
    tmp32 = tmp31 * tmp25
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp16, xmask)
    tl.store(out_ptr2 + x2, tmp16, xmask)
    tl.store(out_ptr3 + x2, tmp32, xmask)


@triton.jit
def triton_poi_fused_23(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + x2, xmask)
    tmp3 = tl.load(in_ptr0 + 4 * x1, xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (1 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (2 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (3 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp16, xmask)
    tl.store(out_ptr2 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_24(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + (16 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (16 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (17 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (18 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (19 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp16, xmask)
    tl.store(out_ptr2 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_25(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + (32 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (32 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (33 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (34 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (35 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp16, xmask)
    tl.store(out_ptr2 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_26(in_ptr0, out_ptr0, out_ptr1, out_ptr2, xnumel,
    XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + (48 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (48 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (49 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (50 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (51 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)
    tl.store(out_ptr1 + x2, tmp16, xmask)
    tl.store(out_ptr2 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_27(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + x2, xmask)
    tmp3 = tl.load(in_ptr0 + 4 * x1, xmask, eviction_policy='evict_last')
    tmp5 = tl.load(in_ptr0 + (1 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp8 = tl.load(in_ptr0 + (2 + 4 * x1), xmask, eviction_policy='evict_last')
    tmp11 = tl.load(in_ptr0 + (3 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_28(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + (16 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (16 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (17 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (18 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (19 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_29(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + (32 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (32 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (33 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (34 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (35 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)


@triton.jit
def triton_poi_fused_30(in_ptr0, out_ptr0, xnumel, XBLOCK: tl.constexpr):
    xnumel = 16
    xoffset = tl.program_id(0) * XBLOCK
    xindex = xoffset + tl.arange(0, XBLOCK)[:]
    xmask = xindex < xnumel
    x2 = xindex
    x1 = xindex // 4
    tmp0 = tl.load(in_ptr0 + (48 + x2), xmask)
    tmp3 = tl.load(in_ptr0 + (48 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp5 = tl.load(in_ptr0 + (49 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp8 = tl.load(in_ptr0 + (50 + 4 * x1), xmask, eviction_policy='evict_last'
        )
    tmp11 = tl.load(in_ptr0 + (51 + 4 * x1), xmask, eviction_policy=
        'evict_last')
    tmp1 = 1.0
    tmp2 = tmp0 * tmp1
    tmp4 = tmp3 * tmp1
    tmp6 = tmp5 * tmp1
    tmp7 = triton_helpers.maximum(tmp4, tmp6)
    tmp9 = tmp8 * tmp1
    tmp10 = triton_helpers.maximum(tmp7, tmp9)
    tmp12 = tmp11 * tmp1
    tmp13 = triton_helpers.maximum(tmp10, tmp12)
    tmp14 = tmp2 - tmp13
    tmp15 = 10.0
    tmp16 = tmp14 * tmp15
    tl.store(out_ptr0 + x2, tmp16, xmask)


@triton.jit
def triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31(in_out_ptr0,
    in_ptr0, in_ptr1, in_ptr2, in_ptr3, in_ptr4, in_ptr5, in_ptr6, in_ptr7,
    in_ptr8, in_ptr9, in_ptr10, in_ptr11, in_ptr12, in_ptr13, in_ptr14,
    in_ptr15, in_ptr16, in_ptr17, in_ptr18, in_ptr19, in_ptr20, in_ptr21,
    in_ptr22, in_ptr23, in_ptr24, in_ptr25, in_ptr26, in_ptr27, in_ptr28,
    in_ptr29, in_ptr30, in_ptr31, xnumel, rnumel, XBLOCK: tl.constexpr):
    RBLOCK: tl.constexpr = 4
    xoffset = tl.program_id(0) * XBLOCK
    xoffset + tl.arange(0, XBLOCK)[:, None]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    rindex = tl.arange(0, RBLOCK)[None, :]
    tl.full([XBLOCK, RBLOCK], True, tl.int1)
    r0 = rindex
    tmp0 = tl.load(in_ptr0 + 4 * r0, None, eviction_policy='evict_last')
    tmp1 = tl.load(in_ptr1 + 4 * r0, None, eviction_policy='evict_last')
    tmp3 = tl.load(in_ptr1 + (1 + 4 * r0), None, eviction_policy='evict_last')
    tmp6 = tl.load(in_ptr1 + (2 + 4 * r0), None, eviction_policy='evict_last')
    tmp9 = tl.load(in_ptr1 + (3 + 4 * r0), None, eviction_policy='evict_last')
    tmp15 = tl.load(in_ptr0 + (1 + 4 * r0), None, eviction_policy='evict_last')
    tmp19 = tl.load(in_ptr0 + (2 + 4 * r0), None, eviction_policy='evict_last')
    tmp23 = tl.load(in_ptr0 + (3 + 4 * r0), None, eviction_policy='evict_last')
    tmp30 = tl.load(in_ptr2 + 4 * r0, None, eviction_policy='evict_last')
    tmp32 = tl.load(in_ptr2 + (1 + 4 * r0), None, eviction_policy='evict_last')
    tmp35 = tl.load(in_ptr2 + (2 + 4 * r0), None, eviction_policy='evict_last')
    tmp38 = tl.load(in_ptr2 + (3 + 4 * r0), None, eviction_policy='evict_last')
    tmp56 = tl.load(in_ptr3 + 4 * r0, None, eviction_policy='evict_last')
    tmp58 = tl.load(in_ptr3 + (1 + 4 * r0), None, eviction_policy='evict_last')
    tmp61 = tl.load(in_ptr3 + (2 + 4 * r0), None, eviction_policy='evict_last')
    tmp64 = tl.load(in_ptr3 + (3 + 4 * r0), None, eviction_policy='evict_last')
    tmp82 = tl.load(in_ptr4 + 4 * r0, None, eviction_policy='evict_last')
    tmp84 = tl.load(in_ptr4 + (1 + 4 * r0), None, eviction_policy='evict_last')
    tmp87 = tl.load(in_ptr4 + (2 + 4 * r0), None, eviction_policy='evict_last')
    tmp90 = tl.load(in_ptr4 + (3 + 4 * r0), None, eviction_policy='evict_last')
    tmp108 = tl.load(in_ptr5 + 4 * r0, None, eviction_policy='evict_last')
    tmp110 = tl.load(in_ptr5 + (1 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp113 = tl.load(in_ptr5 + (2 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp116 = tl.load(in_ptr5 + (3 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp134 = tl.load(in_ptr6 + 4 * r0, None, eviction_policy='evict_last')
    tmp136 = tl.load(in_ptr6 + (1 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp139 = tl.load(in_ptr6 + (2 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp142 = tl.load(in_ptr6 + (3 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp160 = tl.load(in_ptr7 + 4 * r0, None, eviction_policy='evict_last')
    tmp162 = tl.load(in_ptr7 + (1 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp165 = tl.load(in_ptr7 + (2 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp168 = tl.load(in_ptr7 + (3 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp186 = tl.load(in_ptr8 + 4 * r0, None, eviction_policy='evict_last')
    tmp187 = tl.load(in_ptr9 + 4 * r0, None, eviction_policy='evict_last')
    tmp189 = tl.load(in_ptr9 + (1 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp192 = tl.load(in_ptr9 + (2 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp195 = tl.load(in_ptr9 + (3 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp201 = tl.load(in_ptr8 + (1 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp205 = tl.load(in_ptr8 + (2 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp209 = tl.load(in_ptr8 + (3 + 4 * r0), None, eviction_policy='evict_last'
        )
    tmp216 = tl.load(in_ptr10 + 4 * r0, None, eviction_policy='evict_last')
    tmp218 = tl.load(in_ptr10 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp221 = tl.load(in_ptr10 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp224 = tl.load(in_ptr10 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp242 = tl.load(in_ptr11 + 4 * r0, None, eviction_policy='evict_last')
    tmp244 = tl.load(in_ptr11 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp247 = tl.load(in_ptr11 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp250 = tl.load(in_ptr11 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp268 = tl.load(in_ptr12 + 4 * r0, None, eviction_policy='evict_last')
    tmp270 = tl.load(in_ptr12 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp273 = tl.load(in_ptr12 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp276 = tl.load(in_ptr12 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp294 = tl.load(in_ptr13 + 4 * r0, None, eviction_policy='evict_last')
    tmp296 = tl.load(in_ptr13 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp299 = tl.load(in_ptr13 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp302 = tl.load(in_ptr13 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp320 = tl.load(in_ptr14 + 4 * r0, None, eviction_policy='evict_last')
    tmp322 = tl.load(in_ptr14 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp325 = tl.load(in_ptr14 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp328 = tl.load(in_ptr14 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp346 = tl.load(in_ptr15 + 4 * r0, None, eviction_policy='evict_last')
    tmp348 = tl.load(in_ptr15 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp351 = tl.load(in_ptr15 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp354 = tl.load(in_ptr15 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp372 = tl.load(in_ptr16 + 4 * r0, None, eviction_policy='evict_last')
    tmp373 = tl.load(in_ptr17 + 4 * r0, None, eviction_policy='evict_last')
    tmp375 = tl.load(in_ptr17 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp378 = tl.load(in_ptr17 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp381 = tl.load(in_ptr17 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp387 = tl.load(in_ptr16 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp391 = tl.load(in_ptr16 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp395 = tl.load(in_ptr16 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp402 = tl.load(in_ptr18 + 4 * r0, None, eviction_policy='evict_last')
    tmp404 = tl.load(in_ptr18 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp407 = tl.load(in_ptr18 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp410 = tl.load(in_ptr18 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp428 = tl.load(in_ptr19 + 4 * r0, None, eviction_policy='evict_last')
    tmp430 = tl.load(in_ptr19 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp433 = tl.load(in_ptr19 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp436 = tl.load(in_ptr19 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp454 = tl.load(in_ptr20 + 4 * r0, None, eviction_policy='evict_last')
    tmp456 = tl.load(in_ptr20 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp459 = tl.load(in_ptr20 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp462 = tl.load(in_ptr20 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp480 = tl.load(in_ptr21 + 4 * r0, None, eviction_policy='evict_last')
    tmp482 = tl.load(in_ptr21 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp485 = tl.load(in_ptr21 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp488 = tl.load(in_ptr21 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp506 = tl.load(in_ptr22 + 4 * r0, None, eviction_policy='evict_last')
    tmp508 = tl.load(in_ptr22 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp511 = tl.load(in_ptr22 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp514 = tl.load(in_ptr22 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp532 = tl.load(in_ptr23 + 4 * r0, None, eviction_policy='evict_last')
    tmp534 = tl.load(in_ptr23 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp537 = tl.load(in_ptr23 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp540 = tl.load(in_ptr23 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp558 = tl.load(in_ptr24 + 4 * r0, None, eviction_policy='evict_last')
    tmp559 = tl.load(in_ptr25 + 4 * r0, None, eviction_policy='evict_last')
    tmp561 = tl.load(in_ptr25 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp564 = tl.load(in_ptr25 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp567 = tl.load(in_ptr25 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp573 = tl.load(in_ptr24 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp577 = tl.load(in_ptr24 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp581 = tl.load(in_ptr24 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp588 = tl.load(in_ptr26 + 4 * r0, None, eviction_policy='evict_last')
    tmp590 = tl.load(in_ptr26 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp593 = tl.load(in_ptr26 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp596 = tl.load(in_ptr26 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp614 = tl.load(in_ptr27 + 4 * r0, None, eviction_policy='evict_last')
    tmp616 = tl.load(in_ptr27 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp619 = tl.load(in_ptr27 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp622 = tl.load(in_ptr27 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp640 = tl.load(in_ptr28 + 4 * r0, None, eviction_policy='evict_last')
    tmp642 = tl.load(in_ptr28 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp645 = tl.load(in_ptr28 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp648 = tl.load(in_ptr28 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp666 = tl.load(in_ptr29 + 4 * r0, None, eviction_policy='evict_last')
    tmp668 = tl.load(in_ptr29 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp671 = tl.load(in_ptr29 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp674 = tl.load(in_ptr29 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp692 = tl.load(in_ptr30 + 4 * r0, None, eviction_policy='evict_last')
    tmp694 = tl.load(in_ptr30 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp697 = tl.load(in_ptr30 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp700 = tl.load(in_ptr30 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp718 = tl.load(in_ptr31 + 4 * r0, None, eviction_policy='evict_last')
    tmp720 = tl.load(in_ptr31 + (1 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp723 = tl.load(in_ptr31 + (2 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp726 = tl.load(in_ptr31 + (3 + 4 * r0), None, eviction_policy=
        'evict_last')
    tmp2 = tl_math.exp(tmp1)
    tmp4 = tl_math.exp(tmp3)
    tmp5 = tmp2 + tmp4
    tmp7 = tl_math.exp(tmp6)
    tmp8 = tmp5 + tmp7
    tmp10 = tl_math.exp(tmp9)
    tmp11 = tmp8 + tmp10
    tmp12 = tl_math.log(tmp11)
    tmp13 = tmp1 - tmp12
    tmp14 = tmp0 * tmp13
    tmp16 = tmp3 - tmp12
    tmp17 = tmp15 * tmp16
    tmp18 = tmp14 + tmp17
    tmp20 = tmp6 - tmp12
    tmp21 = tmp19 * tmp20
    tmp22 = tmp18 + tmp21
    tmp24 = tmp9 - tmp12
    tmp25 = tmp23 * tmp24
    tmp26 = tmp22 + tmp25
    tmp27 = tl.broadcast_to(tmp26, [XBLOCK, RBLOCK])
    tmp29 = tl.sum(tmp27, 1)[:, None]
    tmp31 = tl_math.exp(tmp30)
    tmp33 = tl_math.exp(tmp32)
    tmp34 = tmp31 + tmp33
    tmp36 = tl_math.exp(tmp35)
    tmp37 = tmp34 + tmp36
    tmp39 = tl_math.exp(tmp38)
    tmp40 = tmp37 + tmp39
    tmp41 = tl_math.log(tmp40)
    tmp42 = tmp30 - tmp41
    tmp43 = tmp0 * tmp42
    tmp44 = tmp32 - tmp41
    tmp45 = tmp15 * tmp44
    tmp46 = tmp43 + tmp45
    tmp47 = tmp35 - tmp41
    tmp48 = tmp19 * tmp47
    tmp49 = tmp46 + tmp48
    tmp50 = tmp38 - tmp41
    tmp51 = tmp23 * tmp50
    tmp52 = tmp49 + tmp51
    tmp53 = tl.broadcast_to(tmp52, [XBLOCK, RBLOCK])
    tmp55 = tl.sum(tmp53, 1)[:, None]
    tmp57 = tl_math.exp(tmp56)
    tmp59 = tl_math.exp(tmp58)
    tmp60 = tmp57 + tmp59
    tmp62 = tl_math.exp(tmp61)
    tmp63 = tmp60 + tmp62
    tmp65 = tl_math.exp(tmp64)
    tmp66 = tmp63 + tmp65
    tmp67 = tl_math.log(tmp66)
    tmp68 = tmp56 - tmp67
    tmp69 = tmp0 * tmp68
    tmp70 = tmp58 - tmp67
    tmp71 = tmp15 * tmp70
    tmp72 = tmp69 + tmp71
    tmp73 = tmp61 - tmp67
    tmp74 = tmp19 * tmp73
    tmp75 = tmp72 + tmp74
    tmp76 = tmp64 - tmp67
    tmp77 = tmp23 * tmp76
    tmp78 = tmp75 + tmp77
    tmp79 = tl.broadcast_to(tmp78, [XBLOCK, RBLOCK])
    tmp81 = tl.sum(tmp79, 1)[:, None]
    tmp83 = tl_math.exp(tmp82)
    tmp85 = tl_math.exp(tmp84)
    tmp86 = tmp83 + tmp85
    tmp88 = tl_math.exp(tmp87)
    tmp89 = tmp86 + tmp88
    tmp91 = tl_math.exp(tmp90)
    tmp92 = tmp89 + tmp91
    tmp93 = tl_math.log(tmp92)
    tmp94 = tmp82 - tmp93
    tmp95 = tmp0 * tmp94
    tmp96 = tmp84 - tmp93
    tmp97 = tmp15 * tmp96
    tmp98 = tmp95 + tmp97
    tmp99 = tmp87 - tmp93
    tmp100 = tmp19 * tmp99
    tmp101 = tmp98 + tmp100
    tmp102 = tmp90 - tmp93
    tmp103 = tmp23 * tmp102
    tmp104 = tmp101 + tmp103
    tmp105 = tl.broadcast_to(tmp104, [XBLOCK, RBLOCK])
    tmp107 = tl.sum(tmp105, 1)[:, None]
    tmp109 = tl_math.exp(tmp108)
    tmp111 = tl_math.exp(tmp110)
    tmp112 = tmp109 + tmp111
    tmp114 = tl_math.exp(tmp113)
    tmp115 = tmp112 + tmp114
    tmp117 = tl_math.exp(tmp116)
    tmp118 = tmp115 + tmp117
    tmp119 = tl_math.log(tmp118)
    tmp120 = tmp108 - tmp119
    tmp121 = tmp0 * tmp120
    tmp122 = tmp110 - tmp119
    tmp123 = tmp15 * tmp122
    tmp124 = tmp121 + tmp123
    tmp125 = tmp113 - tmp119
    tmp126 = tmp19 * tmp125
    tmp127 = tmp124 + tmp126
    tmp128 = tmp116 - tmp119
    tmp129 = tmp23 * tmp128
    tmp130 = tmp127 + tmp129
    tmp131 = tl.broadcast_to(tmp130, [XBLOCK, RBLOCK])
    tmp133 = tl.sum(tmp131, 1)[:, None]
    tmp135 = tl_math.exp(tmp134)
    tmp137 = tl_math.exp(tmp136)
    tmp138 = tmp135 + tmp137
    tmp140 = tl_math.exp(tmp139)
    tmp141 = tmp138 + tmp140
    tmp143 = tl_math.exp(tmp142)
    tmp144 = tmp141 + tmp143
    tmp145 = tl_math.log(tmp144)
    tmp146 = tmp134 - tmp145
    tmp147 = tmp0 * tmp146
    tmp148 = tmp136 - tmp145
    tmp149 = tmp15 * tmp148
    tmp150 = tmp147 + tmp149
    tmp151 = tmp139 - tmp145
    tmp152 = tmp19 * tmp151
    tmp153 = tmp150 + tmp152
    tmp154 = tmp142 - tmp145
    tmp155 = tmp23 * tmp154
    tmp156 = tmp153 + tmp155
    tmp157 = tl.broadcast_to(tmp156, [XBLOCK, RBLOCK])
    tmp159 = tl.sum(tmp157, 1)[:, None]
    tmp161 = tl_math.exp(tmp160)
    tmp163 = tl_math.exp(tmp162)
    tmp164 = tmp161 + tmp163
    tmp166 = tl_math.exp(tmp165)
    tmp167 = tmp164 + tmp166
    tmp169 = tl_math.exp(tmp168)
    tmp170 = tmp167 + tmp169
    tmp171 = tl_math.log(tmp170)
    tmp172 = tmp160 - tmp171
    tmp173 = tmp0 * tmp172
    tmp174 = tmp162 - tmp171
    tmp175 = tmp15 * tmp174
    tmp176 = tmp173 + tmp175
    tmp177 = tmp165 - tmp171
    tmp178 = tmp19 * tmp177
    tmp179 = tmp176 + tmp178
    tmp180 = tmp168 - tmp171
    tmp181 = tmp23 * tmp180
    tmp182 = tmp179 + tmp181
    tmp183 = tl.broadcast_to(tmp182, [XBLOCK, RBLOCK])
    tmp185 = tl.sum(tmp183, 1)[:, None]
    tmp188 = tl_math.exp(tmp187)
    tmp190 = tl_math.exp(tmp189)
    tmp191 = tmp188 + tmp190
    tmp193 = tl_math.exp(tmp192)
    tmp194 = tmp191 + tmp193
    tmp196 = tl_math.exp(tmp195)
    tmp197 = tmp194 + tmp196
    tmp198 = tl_math.log(tmp197)
    tmp199 = tmp187 - tmp198
    tmp200 = tmp186 * tmp199
    tmp202 = tmp189 - tmp198
    tmp203 = tmp201 * tmp202
    tmp204 = tmp200 + tmp203
    tmp206 = tmp192 - tmp198
    tmp207 = tmp205 * tmp206
    tmp208 = tmp204 + tmp207
    tmp210 = tmp195 - tmp198
    tmp211 = tmp209 * tmp210
    tmp212 = tmp208 + tmp211
    tmp213 = tl.broadcast_to(tmp212, [XBLOCK, RBLOCK])
    tmp215 = tl.sum(tmp213, 1)[:, None]
    tmp217 = tl_math.exp(tmp216)
    tmp219 = tl_math.exp(tmp218)
    tmp220 = tmp217 + tmp219
    tmp222 = tl_math.exp(tmp221)
    tmp223 = tmp220 + tmp222
    tmp225 = tl_math.exp(tmp224)
    tmp226 = tmp223 + tmp225
    tmp227 = tl_math.log(tmp226)
    tmp228 = tmp216 - tmp227
    tmp229 = tmp186 * tmp228
    tmp230 = tmp218 - tmp227
    tmp231 = tmp201 * tmp230
    tmp232 = tmp229 + tmp231
    tmp233 = tmp221 - tmp227
    tmp234 = tmp205 * tmp233
    tmp235 = tmp232 + tmp234
    tmp236 = tmp224 - tmp227
    tmp237 = tmp209 * tmp236
    tmp238 = tmp235 + tmp237
    tmp239 = tl.broadcast_to(tmp238, [XBLOCK, RBLOCK])
    tmp241 = tl.sum(tmp239, 1)[:, None]
    tmp243 = tl_math.exp(tmp242)
    tmp245 = tl_math.exp(tmp244)
    tmp246 = tmp243 + tmp245
    tmp248 = tl_math.exp(tmp247)
    tmp249 = tmp246 + tmp248
    tmp251 = tl_math.exp(tmp250)
    tmp252 = tmp249 + tmp251
    tmp253 = tl_math.log(tmp252)
    tmp254 = tmp242 - tmp253
    tmp255 = tmp186 * tmp254
    tmp256 = tmp244 - tmp253
    tmp257 = tmp201 * tmp256
    tmp258 = tmp255 + tmp257
    tmp259 = tmp247 - tmp253
    tmp260 = tmp205 * tmp259
    tmp261 = tmp258 + tmp260
    tmp262 = tmp250 - tmp253
    tmp263 = tmp209 * tmp262
    tmp264 = tmp261 + tmp263
    tmp265 = tl.broadcast_to(tmp264, [XBLOCK, RBLOCK])
    tmp267 = tl.sum(tmp265, 1)[:, None]
    tmp269 = tl_math.exp(tmp268)
    tmp271 = tl_math.exp(tmp270)
    tmp272 = tmp269 + tmp271
    tmp274 = tl_math.exp(tmp273)
    tmp275 = tmp272 + tmp274
    tmp277 = tl_math.exp(tmp276)
    tmp278 = tmp275 + tmp277
    tmp279 = tl_math.log(tmp278)
    tmp280 = tmp268 - tmp279
    tmp281 = tmp186 * tmp280
    tmp282 = tmp270 - tmp279
    tmp283 = tmp201 * tmp282
    tmp284 = tmp281 + tmp283
    tmp285 = tmp273 - tmp279
    tmp286 = tmp205 * tmp285
    tmp287 = tmp284 + tmp286
    tmp288 = tmp276 - tmp279
    tmp289 = tmp209 * tmp288
    tmp290 = tmp287 + tmp289
    tmp291 = tl.broadcast_to(tmp290, [XBLOCK, RBLOCK])
    tmp293 = tl.sum(tmp291, 1)[:, None]
    tmp295 = tl_math.exp(tmp294)
    tmp297 = tl_math.exp(tmp296)
    tmp298 = tmp295 + tmp297
    tmp300 = tl_math.exp(tmp299)
    tmp301 = tmp298 + tmp300
    tmp303 = tl_math.exp(tmp302)
    tmp304 = tmp301 + tmp303
    tmp305 = tl_math.log(tmp304)
    tmp306 = tmp294 - tmp305
    tmp307 = tmp186 * tmp306
    tmp308 = tmp296 - tmp305
    tmp309 = tmp201 * tmp308
    tmp310 = tmp307 + tmp309
    tmp311 = tmp299 - tmp305
    tmp312 = tmp205 * tmp311
    tmp313 = tmp310 + tmp312
    tmp314 = tmp302 - tmp305
    tmp315 = tmp209 * tmp314
    tmp316 = tmp313 + tmp315
    tmp317 = tl.broadcast_to(tmp316, [XBLOCK, RBLOCK])
    tmp319 = tl.sum(tmp317, 1)[:, None]
    tmp321 = tl_math.exp(tmp320)
    tmp323 = tl_math.exp(tmp322)
    tmp324 = tmp321 + tmp323
    tmp326 = tl_math.exp(tmp325)
    tmp327 = tmp324 + tmp326
    tmp329 = tl_math.exp(tmp328)
    tmp330 = tmp327 + tmp329
    tmp331 = tl_math.log(tmp330)
    tmp332 = tmp320 - tmp331
    tmp333 = tmp186 * tmp332
    tmp334 = tmp322 - tmp331
    tmp335 = tmp201 * tmp334
    tmp336 = tmp333 + tmp335
    tmp337 = tmp325 - tmp331
    tmp338 = tmp205 * tmp337
    tmp339 = tmp336 + tmp338
    tmp340 = tmp328 - tmp331
    tmp341 = tmp209 * tmp340
    tmp342 = tmp339 + tmp341
    tmp343 = tl.broadcast_to(tmp342, [XBLOCK, RBLOCK])
    tmp345 = tl.sum(tmp343, 1)[:, None]
    tmp347 = tl_math.exp(tmp346)
    tmp349 = tl_math.exp(tmp348)
    tmp350 = tmp347 + tmp349
    tmp352 = tl_math.exp(tmp351)
    tmp353 = tmp350 + tmp352
    tmp355 = tl_math.exp(tmp354)
    tmp356 = tmp353 + tmp355
    tmp357 = tl_math.log(tmp356)
    tmp358 = tmp346 - tmp357
    tmp359 = tmp186 * tmp358
    tmp360 = tmp348 - tmp357
    tmp361 = tmp201 * tmp360
    tmp362 = tmp359 + tmp361
    tmp363 = tmp351 - tmp357
    tmp364 = tmp205 * tmp363
    tmp365 = tmp362 + tmp364
    tmp366 = tmp354 - tmp357
    tmp367 = tmp209 * tmp366
    tmp368 = tmp365 + tmp367
    tmp369 = tl.broadcast_to(tmp368, [XBLOCK, RBLOCK])
    tmp371 = tl.sum(tmp369, 1)[:, None]
    tmp374 = tl_math.exp(tmp373)
    tmp376 = tl_math.exp(tmp375)
    tmp377 = tmp374 + tmp376
    tmp379 = tl_math.exp(tmp378)
    tmp380 = tmp377 + tmp379
    tmp382 = tl_math.exp(tmp381)
    tmp383 = tmp380 + tmp382
    tmp384 = tl_math.log(tmp383)
    tmp385 = tmp373 - tmp384
    tmp386 = tmp372 * tmp385
    tmp388 = tmp375 - tmp384
    tmp389 = tmp387 * tmp388
    tmp390 = tmp386 + tmp389
    tmp392 = tmp378 - tmp384
    tmp393 = tmp391 * tmp392
    tmp394 = tmp390 + tmp393
    tmp396 = tmp381 - tmp384
    tmp397 = tmp395 * tmp396
    tmp398 = tmp394 + tmp397
    tmp399 = tl.broadcast_to(tmp398, [XBLOCK, RBLOCK])
    tmp401 = tl.sum(tmp399, 1)[:, None]
    tmp403 = tl_math.exp(tmp402)
    tmp405 = tl_math.exp(tmp404)
    tmp406 = tmp403 + tmp405
    tmp408 = tl_math.exp(tmp407)
    tmp409 = tmp406 + tmp408
    tmp411 = tl_math.exp(tmp410)
    tmp412 = tmp409 + tmp411
    tmp413 = tl_math.log(tmp412)
    tmp414 = tmp402 - tmp413
    tmp415 = tmp372 * tmp414
    tmp416 = tmp404 - tmp413
    tmp417 = tmp387 * tmp416
    tmp418 = tmp415 + tmp417
    tmp419 = tmp407 - tmp413
    tmp420 = tmp391 * tmp419
    tmp421 = tmp418 + tmp420
    tmp422 = tmp410 - tmp413
    tmp423 = tmp395 * tmp422
    tmp424 = tmp421 + tmp423
    tmp425 = tl.broadcast_to(tmp424, [XBLOCK, RBLOCK])
    tmp427 = tl.sum(tmp425, 1)[:, None]
    tmp429 = tl_math.exp(tmp428)
    tmp431 = tl_math.exp(tmp430)
    tmp432 = tmp429 + tmp431
    tmp434 = tl_math.exp(tmp433)
    tmp435 = tmp432 + tmp434
    tmp437 = tl_math.exp(tmp436)
    tmp438 = tmp435 + tmp437
    tmp439 = tl_math.log(tmp438)
    tmp440 = tmp428 - tmp439
    tmp441 = tmp372 * tmp440
    tmp442 = tmp430 - tmp439
    tmp443 = tmp387 * tmp442
    tmp444 = tmp441 + tmp443
    tmp445 = tmp433 - tmp439
    tmp446 = tmp391 * tmp445
    tmp447 = tmp444 + tmp446
    tmp448 = tmp436 - tmp439
    tmp449 = tmp395 * tmp448
    tmp450 = tmp447 + tmp449
    tmp451 = tl.broadcast_to(tmp450, [XBLOCK, RBLOCK])
    tmp453 = tl.sum(tmp451, 1)[:, None]
    tmp455 = tl_math.exp(tmp454)
    tmp457 = tl_math.exp(tmp456)
    tmp458 = tmp455 + tmp457
    tmp460 = tl_math.exp(tmp459)
    tmp461 = tmp458 + tmp460
    tmp463 = tl_math.exp(tmp462)
    tmp464 = tmp461 + tmp463
    tmp465 = tl_math.log(tmp464)
    tmp466 = tmp454 - tmp465
    tmp467 = tmp372 * tmp466
    tmp468 = tmp456 - tmp465
    tmp469 = tmp387 * tmp468
    tmp470 = tmp467 + tmp469
    tmp471 = tmp459 - tmp465
    tmp472 = tmp391 * tmp471
    tmp473 = tmp470 + tmp472
    tmp474 = tmp462 - tmp465
    tmp475 = tmp395 * tmp474
    tmp476 = tmp473 + tmp475
    tmp477 = tl.broadcast_to(tmp476, [XBLOCK, RBLOCK])
    tmp479 = tl.sum(tmp477, 1)[:, None]
    tmp481 = tl_math.exp(tmp480)
    tmp483 = tl_math.exp(tmp482)
    tmp484 = tmp481 + tmp483
    tmp486 = tl_math.exp(tmp485)
    tmp487 = tmp484 + tmp486
    tmp489 = tl_math.exp(tmp488)
    tmp490 = tmp487 + tmp489
    tmp491 = tl_math.log(tmp490)
    tmp492 = tmp480 - tmp491
    tmp493 = tmp372 * tmp492
    tmp494 = tmp482 - tmp491
    tmp495 = tmp387 * tmp494
    tmp496 = tmp493 + tmp495
    tmp497 = tmp485 - tmp491
    tmp498 = tmp391 * tmp497
    tmp499 = tmp496 + tmp498
    tmp500 = tmp488 - tmp491
    tmp501 = tmp395 * tmp500
    tmp502 = tmp499 + tmp501
    tmp503 = tl.broadcast_to(tmp502, [XBLOCK, RBLOCK])
    tmp505 = tl.sum(tmp503, 1)[:, None]
    tmp507 = tl_math.exp(tmp506)
    tmp509 = tl_math.exp(tmp508)
    tmp510 = tmp507 + tmp509
    tmp512 = tl_math.exp(tmp511)
    tmp513 = tmp510 + tmp512
    tmp515 = tl_math.exp(tmp514)
    tmp516 = tmp513 + tmp515
    tmp517 = tl_math.log(tmp516)
    tmp518 = tmp506 - tmp517
    tmp519 = tmp372 * tmp518
    tmp520 = tmp508 - tmp517
    tmp521 = tmp387 * tmp520
    tmp522 = tmp519 + tmp521
    tmp523 = tmp511 - tmp517
    tmp524 = tmp391 * tmp523
    tmp525 = tmp522 + tmp524
    tmp526 = tmp514 - tmp517
    tmp527 = tmp395 * tmp526
    tmp528 = tmp525 + tmp527
    tmp529 = tl.broadcast_to(tmp528, [XBLOCK, RBLOCK])
    tmp531 = tl.sum(tmp529, 1)[:, None]
    tmp533 = tl_math.exp(tmp532)
    tmp535 = tl_math.exp(tmp534)
    tmp536 = tmp533 + tmp535
    tmp538 = tl_math.exp(tmp537)
    tmp539 = tmp536 + tmp538
    tmp541 = tl_math.exp(tmp540)
    tmp542 = tmp539 + tmp541
    tmp543 = tl_math.log(tmp542)
    tmp544 = tmp532 - tmp543
    tmp545 = tmp372 * tmp544
    tmp546 = tmp534 - tmp543
    tmp547 = tmp387 * tmp546
    tmp548 = tmp545 + tmp547
    tmp549 = tmp537 - tmp543
    tmp550 = tmp391 * tmp549
    tmp551 = tmp548 + tmp550
    tmp552 = tmp540 - tmp543
    tmp553 = tmp395 * tmp552
    tmp554 = tmp551 + tmp553
    tmp555 = tl.broadcast_to(tmp554, [XBLOCK, RBLOCK])
    tmp557 = tl.sum(tmp555, 1)[:, None]
    tmp560 = tl_math.exp(tmp559)
    tmp562 = tl_math.exp(tmp561)
    tmp563 = tmp560 + tmp562
    tmp565 = tl_math.exp(tmp564)
    tmp566 = tmp563 + tmp565
    tmp568 = tl_math.exp(tmp567)
    tmp569 = tmp566 + tmp568
    tmp570 = tl_math.log(tmp569)
    tmp571 = tmp559 - tmp570
    tmp572 = tmp558 * tmp571
    tmp574 = tmp561 - tmp570
    tmp575 = tmp573 * tmp574
    tmp576 = tmp572 + tmp575
    tmp578 = tmp564 - tmp570
    tmp579 = tmp577 * tmp578
    tmp580 = tmp576 + tmp579
    tmp582 = tmp567 - tmp570
    tmp583 = tmp581 * tmp582
    tmp584 = tmp580 + tmp583
    tmp585 = tl.broadcast_to(tmp584, [XBLOCK, RBLOCK])
    tmp587 = tl.sum(tmp585, 1)[:, None]
    tmp589 = tl_math.exp(tmp588)
    tmp591 = tl_math.exp(tmp590)
    tmp592 = tmp589 + tmp591
    tmp594 = tl_math.exp(tmp593)
    tmp595 = tmp592 + tmp594
    tmp597 = tl_math.exp(tmp596)
    tmp598 = tmp595 + tmp597
    tmp599 = tl_math.log(tmp598)
    tmp600 = tmp588 - tmp599
    tmp601 = tmp558 * tmp600
    tmp602 = tmp590 - tmp599
    tmp603 = tmp573 * tmp602
    tmp604 = tmp601 + tmp603
    tmp605 = tmp593 - tmp599
    tmp606 = tmp577 * tmp605
    tmp607 = tmp604 + tmp606
    tmp608 = tmp596 - tmp599
    tmp609 = tmp581 * tmp608
    tmp610 = tmp607 + tmp609
    tmp611 = tl.broadcast_to(tmp610, [XBLOCK, RBLOCK])
    tmp613 = tl.sum(tmp611, 1)[:, None]
    tmp615 = tl_math.exp(tmp614)
    tmp617 = tl_math.exp(tmp616)
    tmp618 = tmp615 + tmp617
    tmp620 = tl_math.exp(tmp619)
    tmp621 = tmp618 + tmp620
    tmp623 = tl_math.exp(tmp622)
    tmp624 = tmp621 + tmp623
    tmp625 = tl_math.log(tmp624)
    tmp626 = tmp614 - tmp625
    tmp627 = tmp558 * tmp626
    tmp628 = tmp616 - tmp625
    tmp629 = tmp573 * tmp628
    tmp630 = tmp627 + tmp629
    tmp631 = tmp619 - tmp625
    tmp632 = tmp577 * tmp631
    tmp633 = tmp630 + tmp632
    tmp634 = tmp622 - tmp625
    tmp635 = tmp581 * tmp634
    tmp636 = tmp633 + tmp635
    tmp637 = tl.broadcast_to(tmp636, [XBLOCK, RBLOCK])
    tmp639 = tl.sum(tmp637, 1)[:, None]
    tmp641 = tl_math.exp(tmp640)
    tmp643 = tl_math.exp(tmp642)
    tmp644 = tmp641 + tmp643
    tmp646 = tl_math.exp(tmp645)
    tmp647 = tmp644 + tmp646
    tmp649 = tl_math.exp(tmp648)
    tmp650 = tmp647 + tmp649
    tmp651 = tl_math.log(tmp650)
    tmp652 = tmp640 - tmp651
    tmp653 = tmp558 * tmp652
    tmp654 = tmp642 - tmp651
    tmp655 = tmp573 * tmp654
    tmp656 = tmp653 + tmp655
    tmp657 = tmp645 - tmp651
    tmp658 = tmp577 * tmp657
    tmp659 = tmp656 + tmp658
    tmp660 = tmp648 - tmp651
    tmp661 = tmp581 * tmp660
    tmp662 = tmp659 + tmp661
    tmp663 = tl.broadcast_to(tmp662, [XBLOCK, RBLOCK])
    tmp665 = tl.sum(tmp663, 1)[:, None]
    tmp667 = tl_math.exp(tmp666)
    tmp669 = tl_math.exp(tmp668)
    tmp670 = tmp667 + tmp669
    tmp672 = tl_math.exp(tmp671)
    tmp673 = tmp670 + tmp672
    tmp675 = tl_math.exp(tmp674)
    tmp676 = tmp673 + tmp675
    tmp677 = tl_math.log(tmp676)
    tmp678 = tmp666 - tmp677
    tmp679 = tmp558 * tmp678
    tmp680 = tmp668 - tmp677
    tmp681 = tmp573 * tmp680
    tmp682 = tmp679 + tmp681
    tmp683 = tmp671 - tmp677
    tmp684 = tmp577 * tmp683
    tmp685 = tmp682 + tmp684
    tmp686 = tmp674 - tmp677
    tmp687 = tmp581 * tmp686
    tmp688 = tmp685 + tmp687
    tmp689 = tl.broadcast_to(tmp688, [XBLOCK, RBLOCK])
    tmp691 = tl.sum(tmp689, 1)[:, None]
    tmp693 = tl_math.exp(tmp692)
    tmp695 = tl_math.exp(tmp694)
    tmp696 = tmp693 + tmp695
    tmp698 = tl_math.exp(tmp697)
    tmp699 = tmp696 + tmp698
    tmp701 = tl_math.exp(tmp700)
    tmp702 = tmp699 + tmp701
    tmp703 = tl_math.log(tmp702)
    tmp704 = tmp692 - tmp703
    tmp705 = tmp558 * tmp704
    tmp706 = tmp694 - tmp703
    tmp707 = tmp573 * tmp706
    tmp708 = tmp705 + tmp707
    tmp709 = tmp697 - tmp703
    tmp710 = tmp577 * tmp709
    tmp711 = tmp708 + tmp710
    tmp712 = tmp700 - tmp703
    tmp713 = tmp581 * tmp712
    tmp714 = tmp711 + tmp713
    tmp715 = tl.broadcast_to(tmp714, [XBLOCK, RBLOCK])
    tmp717 = tl.sum(tmp715, 1)[:, None]
    tmp719 = tl_math.exp(tmp718)
    tmp721 = tl_math.exp(tmp720)
    tmp722 = tmp719 + tmp721
    tmp724 = tl_math.exp(tmp723)
    tmp725 = tmp722 + tmp724
    tmp727 = tl_math.exp(tmp726)
    tmp728 = tmp725 + tmp727
    tmp729 = tl_math.log(tmp728)
    tmp730 = tmp718 - tmp729
    tmp731 = tmp558 * tmp730
    tmp732 = tmp720 - tmp729
    tmp733 = tmp573 * tmp732
    tmp734 = tmp731 + tmp733
    tmp735 = tmp723 - tmp729
    tmp736 = tmp577 * tmp735
    tmp737 = tmp734 + tmp736
    tmp738 = tmp726 - tmp729
    tmp739 = tmp581 * tmp738
    tmp740 = tmp737 + tmp739
    tmp741 = tl.broadcast_to(tmp740, [XBLOCK, RBLOCK])
    tmp743 = tl.sum(tmp741, 1)[:, None]
    tmp744 = 4.0
    tmp745 = tmp587 / tmp744
    tmp746 = -tmp745
    tmp747 = 0.0
    tmp748 = tmp746 + tmp747
    tmp749 = tmp613 / tmp744
    tmp750 = -tmp749
    tmp751 = tmp748 + tmp750
    tmp752 = tmp639 / tmp744
    tmp753 = -tmp752
    tmp754 = tmp751 + tmp753
    tmp755 = tmp665 / tmp744
    tmp756 = -tmp755
    tmp757 = tmp754 + tmp756
    tmp758 = tmp691 / tmp744
    tmp759 = -tmp758
    tmp760 = tmp757 + tmp759
    tmp761 = tmp717 / tmp744
    tmp762 = -tmp761
    tmp763 = tmp760 + tmp762
    tmp764 = tmp743 / tmp744
    tmp765 = -tmp764
    tmp766 = tmp763 + tmp765
    tmp767 = 0.14285714285714285
    tmp768 = tmp766 * tmp767
    tmp769 = tmp401 / tmp744
    tmp770 = -tmp769
    tmp771 = tmp770 + tmp747
    tmp772 = tmp427 / tmp744
    tmp773 = -tmp772
    tmp774 = tmp771 + tmp773
    tmp775 = tmp453 / tmp744
    tmp776 = -tmp775
    tmp777 = tmp774 + tmp776
    tmp778 = tmp479 / tmp744
    tmp779 = -tmp778
    tmp780 = tmp777 + tmp779
    tmp781 = tmp505 / tmp744
    tmp782 = -tmp781
    tmp783 = tmp780 + tmp782
    tmp784 = tmp531 / tmp744
    tmp785 = -tmp784
    tmp786 = tmp783 + tmp785
    tmp787 = tmp557 / tmp744
    tmp788 = -tmp787
    tmp789 = tmp786 + tmp788
    tmp790 = tmp789 * tmp767
    tmp791 = tmp215 / tmp744
    tmp792 = -tmp791
    tmp793 = tmp792 + tmp747
    tmp794 = tmp241 / tmp744
    tmp795 = -tmp794
    tmp796 = tmp793 + tmp795
    tmp797 = tmp267 / tmp744
    tmp798 = -tmp797
    tmp799 = tmp796 + tmp798
    tmp800 = tmp293 / tmp744
    tmp801 = -tmp800
    tmp802 = tmp799 + tmp801
    tmp803 = tmp319 / tmp744
    tmp804 = -tmp803
    tmp805 = tmp802 + tmp804
    tmp806 = tmp345 / tmp744
    tmp807 = -tmp806
    tmp808 = tmp805 + tmp807
    tmp809 = tmp371 / tmp744
    tmp810 = -tmp809
    tmp811 = tmp808 + tmp810
    tmp812 = tmp811 * tmp767
    tmp813 = tmp29 / tmp744
    tmp814 = -tmp813
    tmp815 = tmp814 + tmp747
    tmp816 = tmp55 / tmp744
    tmp817 = -tmp816
    tmp818 = tmp815 + tmp817
    tmp819 = tmp81 / tmp744
    tmp820 = -tmp819
    tmp821 = tmp818 + tmp820
    tmp822 = tmp107 / tmp744
    tmp823 = -tmp822
    tmp824 = tmp821 + tmp823
    tmp825 = tmp133 / tmp744
    tmp826 = -tmp825
    tmp827 = tmp824 + tmp826
    tmp828 = tmp159 / tmp744
    tmp829 = -tmp828
    tmp830 = tmp827 + tmp829
    tmp831 = tmp185 / tmp744
    tmp832 = -tmp831
    tmp833 = tmp830 + tmp832
    tmp834 = tmp833 * tmp767
    tmp835 = tmp768 + tmp747
    tmp836 = tmp835 + tmp790
    tmp837 = tmp836 + tmp812
    tmp838 = tmp837 + tmp834
    tmp839 = 0.25
    tmp840 = tmp838 * tmp839
    tl.debug_barrier()
    tl.store(in_out_ptr0 + tl.full([XBLOCK, 1], 0, tl.int32), tmp840, None)


def call(args):
    arg0_1, arg1_1 = args
    args.clear()
    assert_size_stride(arg0_1, (4, 4, 4), (16, 4, 1))
    assert_size_stride(arg1_1, (4, 4, 4), (16, 4, 1))
    with torch.cuda._DeviceGuard(0):
        torch.cuda.set_device(0)
        buf0 = empty_strided_cuda((), (), torch.float32)
        get_raw_stream(0)
        triton_per_fused_sum_0[grid(1)](arg0_1, buf0, 1, 16, XBLOCK=1,
            num_warps=2, num_stages=1)
        buf1 = empty_strided_cuda((4, 1), (1, 4), torch.float32)
        triton_poi_fused_sum_1[grid(4)](arg0_1, buf0, buf1, 4, XBLOCK=4,
            num_warps=1, num_stages=1)
        buf2 = empty_strided_cuda((1, 4), (4, 1), torch.float32)
        triton_poi_fused_sum_2[grid(4)](arg0_1, buf0, buf1, buf2, 4, XBLOCK
            =4, num_warps=1, num_stages=1)
        buf3 = empty_strided_cuda((4, 1), (1, 4), torch.float32)
        triton_poi_fused_sum_3[grid(4)](arg0_1, buf0, buf1, buf2, buf3, 4,
            XBLOCK=4, num_warps=1, num_stages=1)
        buf4 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_4[grid(16)](arg0_1, buf0, buf1, buf2, buf3,
            buf4, 16, XBLOCK=16, num_warps=1, num_stages=1)
        buf5 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_5[grid(16)](buf4, buf5, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf6 = buf4
        del buf4
        triton_poi_fused_div_6[grid(16)](buf5, buf6, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf7 = buf5
        del buf5
        triton_poi_fused_mul_7[grid(16)](buf6, buf7, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf23 = buf0
        del buf0
        buf56 = reinterpret_tensor(buf6, (4, 4), (4, 1), 0)
        del buf6
        buf79 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_per_fused_sum_8[grid(1)](arg0_1, buf23, buf56, buf79, 1, 16,
            XBLOCK=1, num_warps=2, num_stages=1)
        buf24 = buf3
        del buf3
        triton_poi_fused_sum_9[grid(4)](arg0_1, buf23, buf24, 4, XBLOCK=4,
            num_warps=1, num_stages=1)
        buf25 = buf2
        del buf2
        triton_poi_fused_sum_10[grid(4)](arg0_1, buf23, buf24, buf25, 4,
            XBLOCK=4, num_warps=1, num_stages=1)
        buf26 = buf1
        del buf1
        triton_poi_fused_sum_11[grid(4)](arg0_1, buf23, buf24, buf25, buf26,
            4, XBLOCK=4, num_warps=1, num_stages=1)
        buf8 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf27 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_12[grid(16)](arg0_1, buf23, buf24, buf25,
            buf26, buf8, buf27, 16, XBLOCK=16, num_warps=1, num_stages=1)
        buf46 = buf23
        del buf23
        buf81 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_per_fused_sum_13[grid(1)](arg0_1, buf46, buf81, 1, 16,
            XBLOCK=1, num_warps=2, num_stages=1)
        buf47 = buf26
        del buf26
        triton_poi_fused_sum_14[grid(4)](arg0_1, buf46, buf47, 4, XBLOCK=4,
            num_warps=1, num_stages=1)
        buf48 = buf25
        del buf25
        triton_poi_fused_sum_15[grid(4)](arg0_1, buf46, buf47, buf48, 4,
            XBLOCK=4, num_warps=1, num_stages=1)
        buf49 = buf24
        del buf24
        triton_poi_fused_sum_16[grid(4)](arg0_1, buf46, buf47, buf48, buf49,
            4, XBLOCK=4, num_warps=1, num_stages=1)
        buf10 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf33 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf50 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_17[grid(16)](arg0_1, buf46, buf47, buf48,
            buf49, buf10, buf33, buf50, 16, XBLOCK=16, num_warps=1,
            num_stages=1)
        buf69 = buf46
        del buf46
        triton_per_fused_sum_18[grid(1)](arg0_1, buf69, 1, 16, XBLOCK=1,
            num_warps=2, num_stages=1)
        buf70 = buf49
        del buf49
        triton_poi_fused_sum_19[grid(4)](arg0_1, buf69, buf70, 4, XBLOCK=4,
            num_warps=1, num_stages=1)
        buf71 = buf48
        del buf48
        triton_poi_fused_sum_20[grid(4)](arg0_1, buf69, buf70, buf71, 4,
            XBLOCK=4, num_warps=1, num_stages=1)
        buf72 = buf47
        del buf47
        triton_poi_fused_sum_21[grid(4)](arg0_1, buf69, buf70, buf71, buf72,
            4, XBLOCK=4, num_warps=1, num_stages=1)
        buf12 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf35 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf58 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf73 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_22[grid(16)](arg0_1, buf69, buf70, buf71,
            buf72, buf12, buf35, buf58, buf73, 16, XBLOCK=16, num_warps=1,
            num_stages=1)
        del buf70
        del buf71
        del buf72
        buf14 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf37 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf60 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_23[grid(16)](arg1_1, buf14, buf37, buf60, 16,
            XBLOCK=16, num_warps=1, num_stages=1)
        buf16 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf39 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf62 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_24[grid(16)](arg1_1, buf16, buf39, buf62, 16,
            XBLOCK=16, num_warps=1, num_stages=1)
        buf18 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf41 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf64 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_25[grid(16)](arg1_1, buf18, buf41, buf64, 16,
            XBLOCK=16, num_warps=1, num_stages=1)
        buf20 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf43 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf66 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_26[grid(16)](arg1_1, buf20, buf43, buf66, 16,
            XBLOCK=16, num_warps=1, num_stages=1)
        buf28 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_5[grid(16)](buf27, buf28, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf29 = buf27
        del buf27
        triton_poi_fused_div_6[grid(16)](buf28, buf29, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf30 = buf28
        del buf28
        triton_poi_fused_mul_7[grid(16)](buf29, buf30, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf31 = reinterpret_tensor(buf29, (4, 4), (4, 1), 0)
        del buf29
        buf54 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        buf77 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_23[grid(16)](arg0_1, buf31, buf54, buf77, 16,
            XBLOCK=16, num_warps=1, num_stages=1)
        del arg0_1
        buf51 = empty_strided_cuda((4, 4), (1, 4), torch.float32)
        triton_poi_fused_div_5[grid(16)](buf50, buf51, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf52 = buf50
        del buf50
        triton_poi_fused_div_6[grid(16)](buf51, buf52, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf53 = buf51
        del buf51
        triton_poi_fused_mul_7[grid(16)](buf52, buf53, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf74 = buf52
        del buf52
        triton_poi_fused_div_5[grid(16)](buf73, buf74, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf75 = buf73
        del buf73
        triton_poi_fused_div_6[grid(16)](buf74, buf75, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf76 = buf74
        del buf74
        triton_poi_fused_mul_7[grid(16)](buf75, buf76, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf83 = reinterpret_tensor(buf75, (4, 4), (4, 1), 0)
        del buf75
        triton_poi_fused_27[grid(16)](arg1_1, buf83, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf85 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_28[grid(16)](arg1_1, buf85, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf87 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_29[grid(16)](arg1_1, buf87, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        buf89 = empty_strided_cuda((4, 4), (4, 1), torch.float32)
        triton_poi_fused_30[grid(16)](arg1_1, buf89, 16, XBLOCK=16,
            num_warps=1, num_stages=1)
        del arg1_1
        buf11 = buf69
        del buf69
        buf22 = buf11
        del buf11
        buf92 = buf22
        del buf22
        triton_per_fused__log_softmax_add_div_mean_mul_neg_sum_31[grid(1)](
            buf92, buf76, buf77, buf79, buf81, buf83, buf85, buf87, buf89,
            buf53, buf54, buf56, buf58, buf60, buf62, buf64, buf66, buf30,
            buf31, buf33, buf35, buf37, buf39, buf41, buf43, buf7, buf8,
            buf10, buf12, buf14, buf16, buf18, buf20, 1, 4, XBLOCK=1,
            num_warps=2, num_stages=1)
        del buf10
        del buf12
        del buf14
        del buf16
        del buf18
        del buf20
        del buf30
        del buf31
        del buf33
        del buf35
        del buf37
        del buf39
        del buf41
        del buf43
        del buf53
        del buf54
        del buf56
        del buf58
        del buf60
        del buf62
        del buf64
        del buf66
        del buf7
        del buf76
        del buf77
        del buf79
        del buf8
        del buf81
        del buf83
        del buf85
        del buf87
        del buf89
    return buf92,


@torch.no_grad()
def sinkhorn(out: 'torch.Tensor', iterations: 'int'=3, epsilon: 'float'=0.05):
    """Distributed sinkhorn algorithm.

    As outlined in [0] and implemented in [1].

    [0]: SwaV, 2020, https://arxiv.org/abs/2006.09882
    [1]: https://github.com/facebookresearch/swav/

    Args:
        out:
            Similarity of the features and the SwaV prototypes.
        iterations:
            Number of sinkhorn iterations.
        epsilon:
            Temperature parameter.

    Returns:
        Soft codes Q assigning each feature to a prototype.
    """
    Q = torch.exp(out / epsilon).t()
    sum_Q = torch.sum(Q)
    Q /= sum_Q
    B = Q.shape[1]
    K = Q.shape[0]
    for i in range(iterations):
        sum_of_rows = torch.sum(Q, dim=1, keepdim=True)
        Q /= sum_of_rows
        Q /= K
        Q /= torch.sum(Q, dim=0, keepdim=True)
        Q /= B
    Q *= B
    return Q.t()


class SwaVLossNew(nn.Module):
    """Implementation of the SwaV loss.

    Attributes:
        temperature:
            Temperature parameter used for cross entropy calculations.
        sinkhorn_iterations:
            Number of iterations of the sinkhorn algorithm.
        sinkhorn_epsilon:
            Temperature parameter used in the sinkhorn algorithm.
    """

    def __init__(self, temperature: 'float'=0.1, sinkhorn_iterations: 'int'
        =3, sinkhorn_epsilon: 'float'=0.05):
        super(SwaVLossNew, self).__init__()
        self.temperature = temperature
        self.sinkhorn_iterations = sinkhorn_iterations
        self.sinkhorn_epsilon = sinkhorn_epsilon

    def subloss(self, z: 'torch.Tensor', q: 'torch.Tensor'):
        """Calculates the cross entropy for the SwaV prediction problem.

        Args:
            z:
                Similarity of the features and the SwaV prototypes.
            q:
                Codes obtained from Sinkhorn iterations.

        Returns:
            Cross entropy between predictions z and codes q.
        """
        return -torch.mean(torch.sum(q * F.log_softmax(z / self.temperature,
            dim=1), dim=1))

    def forward(self, input_0, input_1):
        arg0_1 = input_0
        arg1_1 = input_1
        output = call([arg0_1, arg1_1])
        return output[0]
