CAIRO (AP) – Libyan authorities forcibly removed dozens of migrants who had barricaded themselves in a container ship in the port city of Misrata for the past 10 days after being picked up at sea.

The migrants had refused to disembark, saying Libya is too dangerous for them. They were attempting to cross the Mediterranean Sea to Europe earlier this month when they were rescued at sea by a cargo ship, Nivin, that was already bound for Misrata.

Human Rights Watch said some migrants were taken to hospital late Tuesday while others were taken to a detention center in Misrata.

Libya’s navy spokesman, Ayoub Jassem, said security forces boarded the ship after negotiations with the migrants failed to convince them to disembark voluntarily.

“Only 14 of at least 94 migrants agreed to leave the ship,” he told The Associated Press. “Only six migrants were wounded in the operation and they were taken to a nearby hospital.”

Libya was plunged into chaos after the 2011 uprising that toppled Moammar Gadhafi, and has since emerged as a major transit point for migrants fleeing war and poverty in Africa and seeking a better life in Europe. Rights groups say migrants face exploitation and abuse in Libya at the hands of smugglers and local militias.

In recent years, European countries have provided training and funds to Libyan authorities to reduce the hazardous sea crossings, which have claimed thousands of lives. But critics say those efforts leave the migrants trapped in Libya.

“This is the worst possible conclusion to the desperate plea of the people on board the Nivin to avoid inhuman detention in Libya,” said Judith Sunderland, of HRW.

“The situation is the result of efforts by Italy and the European Union to obstruct rescue operations by non-governmental organizations and empower the Libyan coast guard even when Europe knows that Libya is not a safe place.”

Human Rights Watch has urged Libyan authorities to “immediately allow United Nations and non-governmental personnel to visit the people removed from the cargo ship, find alternatives to their detention, and investigate the possible use of unlawful force.”

The U.N.’s humanitarian coordinator for Libya, Maria Ribeiro, said in a statement Tuesday that the “humanitarian community is saddened by the turn of events.”

“Their reluctance to leave the relative safety of the ship that rescued them from peril at sea is an understandable human reaction. … It is regrettable that mediation efforts undertaken did not lead to a peaceful resolution,” Ribeiro said.

The migrants had been in the Misrata port since earlier this month, with the captain and crew of the ship taking refuge on the upper decks.

With just one rescue ship patrolling the Mediterranean, and European ports refusing to take in rescued migrants, commercial ships have become increasingly leery of rescuing people at sea. Repeatedly in recent months, they have found themselves caught in the middle between governments hostile to new migrants and an obligation under international maritime law to save.

The United Nations migration agency says more than 850 migrants have died while attempting to cross the Mediterranean since the start of 2018, down from some 2,100 deaths during the same period in 2017. The agency estimates that more than 40,000 have reached Europe since January, compared to around 80,000 over the same period in 2017.