Odd…

N=1000
Delta = 0.001
def smush(m):
    x=m[1] % N * N
    y=int((m[2]/Delta))*10
    return int(x+y)

d['loc']=d.apply(smush, axis=1)