Actually, I see what your problem is. You are building the model incorrectly: the FloatFunctional is a “stateful” layer that needs to be initialized in the model constructor. Otherwise, it will not be visible to the convert script. Here is how you can rewrite the model (just an example):
def __init__(self):
        super().__init__()
        # ... Any other definitions
        self.q_add0 = FloatFunctional()
        self.q_add1 = FloatFunctional()
        self.q_add2 = FloatFunctional()
        # ... Any other definitions

def forward(self, x, x2=None, x3=None):
        x_size = x.size()
        resl = x
        for i in range(len(self.pools_sizes)):

            y = self.convs[i](self.pools[i](x))
            # q_add0 = FloatFunctional()
#error is because of this line below
            resl = self.q_add0.add(resl, nn.functional.interpolate(y, x_size[2:], mode='bilinear', align_corners=True))  #error is because of this line
        resl = self.relu(resl)
        if self.need_x2:
            
            resl = nn.functional.interpolate(resl, x2.size()[2:], mode='bilinear', align_corners=True)
        resl = self.conv_sum(resl)
        if self.need_fuse:
            # q_add1 = FloatFunctional()
            # q_add2 = FloatFunctional()
            resl = self.conv_sum_c(self.q_add1.add(self.q_add2.add(resl, x2), x3))
        return resl