South Africa’s Impala Platinum (Implats) swung into first-half profit, boosted by increased output, higher metals’ basket price and a weaker rand, the miner said on Thursday.

Headline earnings per share (HEPS) came in at 310 cents in the six months ended December 2018, from a loss of 21 cents per share in the year-ago period, Implats said.HEPS is the main profit gauge in South Africa, which strips out certain one-off items. Revenue surged 36 percent to 23.52 billion rand ($1.69 billion) from the previous year. Company’s revenue soared on the back of upbeat sales, which increased by 3.02 billion rand, and higher rhodium, palladium, ruthenium, nickel and iridium prices that partially offset a lower platinum rate, the firm said.

Implats, which announced last year that it would slash about a third of its workforce at its Rustenburg operations over two years as the firm looks to restructure, said it hopes to complete the process by the end of 2021 financial year. “The group continues to make strides towards eliminating loss‐making production, which culminated in the decision to restructure Impala Rustenburg,” said Chief Executive Nico Muller in a statement.

The mining company expects full-year refined platinum production to be between 1.5 million ounces and 1.6 million ounces