Changed to work with microseconds instead of millis, need to test with torch.