basic_utils/utils.py
def Variable(tensor, *args, **kwargs):
    """
    The augmented Variable() function which automatically applies cuda() when gpu is available.
    """
    if use_cuda:
        return torch.autograd.Variable(tensor, *args, **kwargs).cuda()
    else:
        return torch.autograd.Variable(tensor, *args, **kwargs)

    The augmented Variable() function which automatically applies cuda() when gpu is available.
    
The augmented Variable() function which automatically applies cuda() when gpu is available.
The augmented Variable () function which automatically applies cuda () when gpu is available .
def Variable(tensor, *args, **kwargs):
    if use_cuda:
        return torch.autograd.Variable(tensor, *args, **kwargs).cuda()
    else:
        return torch.autograd.Variable(tensor, *args, **kwargs)
def Variable ( tensor , * args , ** kwargs ) : if use_cuda : return torch . autograd . Variable ( tensor , * args , ** kwargs ) . cuda ( ) else : return torch . autograd . Variable ( tensor , * args , ** kwargs )
The augmented Variable() function which automatically applies cuda() when gpu is available.
The augmented Variable () function which automatically applies cuda () when gpu is available .
"""
    The augmented Variable() function which automatically applies cuda() when gpu is available.
    """
tensor