You only pay 4.4% of your salary if hired after 2014 (I only pay 0.8%). If you retire with 20+ years of service at 62 or later, you get 1.1% per year of your high-three salary. That amount is adjusted by cost-of-living increases as well, though of course that may not keep up with inflation.
Also keep in mind that TSP contributions are matched up to 5% of your salary. Consider the pension in the context of also maxing out contributions to TSP (which has the same yearly contributions cap as a 401k). A fair comparison should include the whole package.
You get far more money if you put that 4 % into a 401k or other investment vehicle.
Also, with loans being discharged, you have to have made a ton of payments, to the point that most will pay off their loans before they're eligible in a stem position.