Amtrak, New Jersey Transit and Long Island Rail Road schedules, which were changed as part of the infrastructure repair work at the nation’s busiest rail terminal, are slated to return to normal on Sept. 5, Amtrak announced Thursday.

Amtrak owns and operates Penn Station’s 21 tracks, which, along with the switches, have been replaced as part of the agency’s major infrastructure renewal that began July 10.

“We thank customers for their patience while we renew the infrastructure at New York Penn Station,” CEO Wick Moorman said in a statement. “Our engineering forces are making great progress, and we look forward to resuming scheduled operations Sept. 5.”

The first seven weeks of the two-month repair work focused on a sorting mechanism called A interlocking, which routes incoming and outgoing trains from the Hudson River tunnel and the LIRR’s West Side Yard to tracks and platforms at Penn Station.

As part of the summer repairs, weekday rail schedules for several Amtrak, NJ Transit and the LIRR trains were either adjusted or canceled in order to accelerate work.

The MTA’s discounted fares for LIRR riders to use alternate stations during the repair work will end Sept. 1, the agency said. Temporary bus and ferry service for LIRR customers will also end Sept. 1.

“I want to thank our customers for their patience and willingness to try the temporary travel options, as well as our employees for their hard work to make the transition as smooth as possible,” Chairman Joe Lhota said. “Together, we were all able to get where we needed to go this summer with minimal disruption, and we are pleased that our customers will return from the Labor Day holiday to their regular timetables.”

NJ Transit’s Morris and Essex lines will resume service to and from Penn Station and no longer divert to Hoboken as of Sept. 5, and North Jersey Coast Line trains will resume Hoboken operations.

The agency’s alternate options, discounted fares and cross-honoring will also end, as will the Morristown, Madison, Summit, Maplewood, South Orange and New Broad Street morning express buses to Port Authority.

The ‘summer of heck’

When Amtrak first announced the service changes to accommodate accelerated repairs, New York Gov. Andrew Cuomo said they would cause a “summer of hell” for commuters, a phrase that was adopted by riders and media alike.

But as the work got underway, it wasn’t nearly as chaotic as many people expected.

“I called it the ‘summer of heck.’ It wasn’t so bad as long as you had some flexibility to arrive a bit late and leave a bit early from work,” said Phil Ryan, who lives in New Jersey and works in Midtown.

Ryan told Metro back in July that he would be switching from his regular train to a bus and would work from home more often to “avoid Penn Station at all costs” during the work.

While he said he experienced “a lot fewer late or delayed trains this summer,” he has his doubts that the rest of the Penn Station repairs will be done on schedule.

“I expect service to be limited [or] back to sh–ty normal after it’s done,” he said.

Amtrak will continue its infrastructure work at Penn Station through approximately June 2018, the agency said, and the bulk of that work is scheduled to occur on weekends.