def window_reverse(windows, window_size, height, width):
    """
    Args:
        windows (`torch.FloatTensor` of shape `(num_windows * batch_size, window_size, window_size, num_channels)`):
            Input windows
        window_size (`int`):
            Window size
        height (`int`):
            Height of the resized audio
        width (`int`):
            Width of the resized audio
    """
    batch_size = int(windows.shape[0] / (height * width / window_size / window_size))

    hidden_states = windows.view(batch_size, height // window_size, width // window_size, window_size, window_size, -1)
    hidden_states = hidden_states.permute(0, 1, 3, 2, 4, 5).contiguous().view(batch_size, height, width, -1)
    return hidden_states

    Args:
        windows (`torch.FloatTensor` of shape `(num_windows * batch_size, window_size, window_size, num_channels)`):
            Input windows
        window_size (`int`):
            Window size
        height (`int`):
            Height of the resized audio
        width (`int`):
            Width of the resized audio
    
dpkd/transformers/src/transformers/models/clap/modeling_clap.py