error
37_FrobeniusNorm_.py
started
2026-05-02T23:38:41Z
reference PyTorch source (the prompt the agent sees)
import torch
import torch.nn as nn
class Model(nn.Module):
"""
Simple model that performs Frobenius norm normalization.
"""
def __init__(self):
"""
Initializes the Frobenius norm normalization layer.
"""
super(Model, self).__init__()
def forward(self, x: torch.Tensor) -> torch.Tensor:
"""
Applies Frobenius norm normalization to the input tensor.
Args:
x (torch.Tensor): Input tensor of arbitrary shape.
Returns:
torch.Tensor: Output tensor with Frobenius norm normalization applied, same shape as input.
"""
norm = torch.norm(x, p='fro')
return x / norm
batch_size = 112
features = 64
dim1 = 512
dim2 = 512
def get_inputs():
x = torch.rand(batch_size, features, dim1, dim2)
return [x]
def get_init_inputs():
return []turn 07200.0s turn · 7200.0s LLM · 0.0s tools
feedbackLLM call failed: _WorkItemTimeout: work item exceeded soft timeout budget