You can get a
TN on the Amtrak routes that come from Canadian cities. I'm not sure what's involved -- I assume they pull you aside and have you wait in another part of the train while the TN is processed (since on the train, the CBP officers actually enter the train and interview you while you're in your seat) -- but I know that people have done it before.
As for flying, they probably will not let you catch your
flight if your TN is denied since there's a strong likelihood that you'll end up going to work. So I recommend buying a refundable ticket or getting to the terminal early enough so that, if you're denied, you have enough time to change the ticket (though you'll incur some sort of fee for doing that).