def METHOD_NAME(in_channels, out_channels=None, pool=True):
    """wavelet decomposition using conv2d"""
    harr_wav_L = 1 / np.sqrt(2) * np.ones((1, 2))
    harr_wav_H = 1 / np.sqrt(2) * np.ones((1, 2))
    harr_wav_H[0, 0] = -1 * harr_wav_H[0, 0]
    harr_wav_LL = np.transpose(harr_wav_L) * harr_wav_L
    harr_wav_LH = np.transpose(harr_wav_L) * harr_wav_H
    harr_wav_HL = np.transpose(harr_wav_H) * harr_wav_L
    harr_wav_HH = np.transpose(harr_wav_H) * harr_wav_H
    filter_LL = torch.from_numpy(harr_wav_LL).unsqueeze(0)
    filter_LH = torch.from_numpy(harr_wav_LH).unsqueeze(0)
    filter_HL = torch.from_numpy(harr_wav_HL).unsqueeze(0)
    filter_HH = torch.from_numpy(harr_wav_HH).unsqueeze(0)
    if pool:
        net = nn.Conv2d
    else:
        net = nn.ConvTranspose2d
    if out_channels is None:
        out_channels = in_channels
    LL = net(
        in_channels,
        out_channels,
        kernel_size=2,
        stride=2,
        padding=0,
        bias=False,
        groups=in_channels)
    LH = net(
        in_channels,
        out_channels,
        kernel_size=2,
        stride=2,
        padding=0,
        bias=False,
        groups=in_channels)
    HL = net(
        in_channels,
        out_channels,
        kernel_size=2,
        stride=2,
        padding=0,
        bias=False,
        groups=in_channels)
    HH = net(
        in_channels,
        out_channels,
        kernel_size=2,
        stride=2,
        padding=0,
        bias=False,
        groups=in_channels)
    LL.weight.requires_grad = False
    LH.weight.requires_grad = False
    HL.weight.requires_grad = False
    HH.weight.requires_grad = False
    LL.weight.data = filter_LL.float().unsqueeze(0).expand(
        in_channels, -1, -1, -1)
    LH.weight.data = filter_LH.float().unsqueeze(0).expand(
        in_channels, -1, -1, -1)
    HL.weight.data = filter_HL.float().unsqueeze(0).expand(
        in_channels, -1, -1, -1)
    HH.weight.data = filter_HH.float().unsqueeze(0).expand(
        in_channels, -1, -1, -1)
    return LL, LH, HL, HH