Solved by sgugger in post #2 
              
              
                I don’t knoe where you read that code, but Trainer does not have a save_pretrained method. Checkout the documentaiton for a list of its methods!