```python
import torch
import torch.nn as nn
from torch.utils.cpp_extension import load_inline


_cuda_source = r"""
#include <torch/extension.h>
#include <ATen/cuda/CUDAContext.h>
#include <c10/cuda/CUDAGuard.h>
#include <c10/cuda/CUDAException.h>
#include <cuda_runtime.h>
#include <algorithm>
#include <cstdint>

__global__ void subtract_tanh_kernel(
    const float* __restrict__ x,
    const float* __restrict__ bias,
    float* __restrict__ out,
    int64_t size,
    int64_t spatial,
    int64_t channels)
{
    const int64_t tid =
        static_cast<int64_t>(blockIdx.x) * blockDim.x + threadIdx.x;
    const int64_t step =
        static_cast<int64_t>(gridDim.x) * blockDim.x;
    const int64_t vectors = size / 4;

    const float4* x4 = reinterpret_cast<const float4*>(x);
    float4* out4 = reinterpret_cast<float4*>(out);

    for (int64_t v = tid; v < vectors; v += step) {
        const int64_t i = v * 4;
        const int64_t plane = i / spatial;
        const int64_t remaining = spatial - (i - plane * spatial);

        float4 value = x4[v];
        float4 result;

        if (remaining >= 4) {
            const float b = bias[plane % channels];
            result.x = tanhf(value.x - b);
            result.y = tanhf(value.y - b);
            result.z = tanhf(value.z - b);
            result.w = tanhf(value.w - b);
        } else {
            result.x = tanhf(value.x - bias[(i / spatial) % channels]);
            result.y = tanhf(value.y - bias[((i + 1) / spatial) % channels]);
            result.z = tanhf(value.z - bias[((i + 2) / spatial) % channels]);
            result.w = tanhf(value.w - bias[((i + 3) / spatial) % channels]);
        }

        out4[v] = result;
    }

    const int64_t tail = vectors * 4 + tid;
    if (tail < size) {
        out[tail] = tanhf(x[tail] - bias[(tail / spatial) % channels]);
    }
}

torch::Tensor subtract_tanh_cuda(torch::Tensor x, torch::Tensor bias) {
    TORCH_CHECK(x.is_cuda() && bias.is_cuda(), "Expected CUDA tensors");
    TORCH_CHECK(x.device() == bias.device(), "Device mismatch");
    TORCH_CHECK(
        x.scalar_type() == at::kFloat && bias.scalar_type() == at::kFloat,
        "Expected float32 tensors");
    TORCH_CHECK(x.dim() == 4 && x.is_contiguous(),
                "Expected contiguous NCHW input");
    TORCH_CHECK(bias.is_contiguous() && bias.numel() == x.size(1),
                "Expected one contiguous bias value per channel");

    const c10::cuda::CUDAGuard device_guard(x.device());
    auto out = torch::empty_like(x);
    const int64_t size = x.numel();

    if (size == 0) {
        return out;
    }

    constexpr int threads = 256;
    const int64_t work = (size + 3) / 4;
    const int blocks = static_cast<int>(
        std::min<int64_t>((work + threads - 1) / threads, 4096));

    subtract_tanh_kernel<<<
        blocks, threads, 0, at::cuda::getCurrentCUDAStream()
    >>>(
        x.data_ptr<float>(),
        bias.data_ptr<float>(),
        out.data_ptr<float>(),
        size,
        x.size(2) * x.size(3),
        x.size(1));

    C10_CUDA_KERNEL_LAUNCH_CHECK();
    return out;
}
"""

_fused_ops = load_inline(
    name="conv_transpose_subtract_tanh_fused",
    cpp_sources=(
        "torch::Tensor subtract_tanh_cuda("
        "torch::Tensor x, torch::Tensor bias);"
    ),
    cuda_sources=_cuda_source,
    functions=["subtract_tanh_cuda"],
    extra_cflags=["-O3"],
    extra_cuda_cflags=["-O3"],
    verbose=False,
)


class ModelNew(nn.Module):
    def __init__(
        self,
        in_channels,
        out_channels,
        kernel_size,
        bias_shape,
        stride=2,
        padding=1,
        output_padding=1,
    ):
        super().__init__()
        self.conv_transpose = nn.ConvTranspose2d(
            in_channels,
            out_channels,
            kernel_size,
            stride=stride,
            padding=padding,
            output_padding=output_padding,
        )
        self.bias = nn.Parameter(torch.randn(bias_shape))

    def forward(self, x):
        x = self.conv_transpose(x)

        channel_bias = (
            tuple(self.bias.shape) == (x.shape[1], 1, 1)
            or tuple(self.bias.shape) == (1, x.shape[1], 1, 1)
        )

        if (
            x.is_cuda
            and x.dtype == torch.float32
            and self.bias.dtype == torch.float32
            and self.bias.device == x.device
            and x.is_contiguous()
            and channel_bias
            and not (
                torch.is_grad_enabled()
                and (x.requires_grad or self.bias.requires_grad)
            )
        ):
            return _fused_ops.subtract_tanh_cuda(x, self.bias.contiguous())

        return torch.tanh(x - self.bias)
```