Oh, i didn’t see the code at all.
You should be able to pass a tensor rewriting it as
def train():
    log_sigma_A = torch.tensor([1.]).requires_grad_()
    log_sigma_B = torch.tensor([1.]).requires_grad_()

    loss_weight_list = [log_sigma_A, log_sigma_B]
    optimizer = torch.optim.SGD([{'params': loss_weight_list, 'lr': 0.1}])

    for i in range(10):
        sigma_A = torch.Tensor.exp(log_sigma_A)
        sigma_B = torch.Tensor.exp(log_sigma_B)
        loss = sigma_A + sigma_B
        optimizer.zero_grad()
        loss.backward()
        print('A grad: %f' % log_sigma_A)
        print('B grad: %f' % log_sigma_B)
        print('Loss %f' % loss.item())
        optimizer.step()

A grad: 1.000000
B grad: 1.000000
Loss 5.436563
A grad: 0.728172
B grad: 0.728172
Loss 4.142581
A grad: 0.521043
B grad: 0.521043
Loss 3.367565
A grad: 0.352665
B grad: 0.352665
Loss 2.845707
A grad: 0.210379
B grad: 0.210379
Loss 2.468292
A grad: 0.086965
B grad: 0.086965
Loss 2.181716
A grad: -0.022121
B grad: -0.022121
Loss 1.956243
A grad: -0.119933
B grad: -0.119933
Loss 1.773959
A grad: -0.208631
B grad: -0.208631
Loss 1.623389
A grad: -0.289801
B grad: -0.289801
Loss 1.496825

There is learning.
In fact, i rewrote the snippet to emulate little bit better your code
log_sigma_A = torch.tensor([1.]).requires_grad_()
log_sigma_B = torch.tensor([1.]).requires_grad_()
loss_weight_list = [log_sigma_A, log_sigma_B]
optimizer = torch.optim.SGD([{'params': loss_weight_list, 'lr': 0.1}])

def train(log_sigma_A,log_sigma_B):
    log_sigma_A = log_sigma_A.cuda()
    log_sigma_B = log_sigma_B.cuda()

    sigma_A = torch.Tensor.exp(log_sigma_A)
    sigma_B = torch.Tensor.exp(log_sigma_B)
    loss = sigma_A + sigma_B
    optimizer.zero_grad()
    loss.backward()
    print('A grad: %f' % log_sigma_A)
    print('B grad: %f' % log_sigma_B)
    print('Loss %f' % loss.item())
    optimizer.step()
for i in range(10):
    train(log_sigma_A,log_sigma_B)

As you define everything outside train function but keeps working very well.
Can you try to define logs as tensor (lowercase tensor as it’s not the same torch.tensor than torch.Tensor) and using requires_grad true and 1.0 (float) instead of 1?