The accuracy is slightly better but that is well within the margin of what I would call as random   But it was very important to do an Apples-to-Apples comparison.  So, Thank you for catching the difference in architecture.
Regarding your other point in the response, I did convert the numpy function to pyTorch tensors function.  f1_prev shown below is slightly different from the one above in that this one allows for groups of scores (specified using cut).  In my model I want to use an age-based threshold rather than a single threshold and this allows that.
This function gives me a HUGE speed up over what I had.  Can you suggest any changes…sorry for the newbie questions:
def f1_prev(label, score, cut):
    cmat = torch.zeros((cut.unique().shape[0],3), device=device)  #tp,fp,fn
    i = 0
    for n in cut.unique():
        ind = (cut==n).nonzero()[:,0]
        labelt,scoret = label[ind],score[ind]
        ncase = labelt.sum().int()
        ncont = (labelt.shape[0]-ncase).int()

        newlab = labelt[torch.argsort(scoret)]
        cmat[i,0] = newlab[ncont:].sum()  #tp
        cmat[i,1] = newlab[:ncont].sum()  #fp
        cmat[i,2] = ncase-cmat[i,0] #fn
        i += 1

    cmat = cmat.sum(dim=0)
    val = 2.*cmat[0]/(2.*cmat[0]+cmat[1]+cmat[2])
    return val.item()