Kenya's opposition leader Raila Odinga. Picture: Reuters/Baz Ratner

Nairobi - Kenyan opposition leader Raila Odinga was set to be "sworn in" as president on Tuesday, despite warnings that the staged ceremony could amount to treason.

Several local television channels were taken off air Tuesday morning to prevent any screening of the event, which is scheduled to take place in Nairobi's Uhuru Park.

"Stage is set for the inauguration of the President and Deputy President of the Republic of Kenya #FreedomIsComing," Odinga's NASA coalition tweeted early Tuesday, showing footage of a stage at the venue.

Local media reported that thousands were gathering at the park.

A political crisis erupted in Kenya after the Supreme Court threw out the results of an August election - won by President Uhuru Kenyatta - due to irregularities.

A re-run of the election was held on October 26 and again won by Kenyatta - by a huge margin - after Odinga boycotted it and called it a "sham."

Several people were killed in clashes over a three-day period during the vote.

After Kenyatta's inauguration the populist leader immediately vowed to hold his own swearing in, which the attorney-general last year said could amount to treason.

On the eve of the "inauguration" the non-profit International Crisis Group warned that the swearing-in could "provoke protests, further police crackdowns and much avoidable destruction and bloodshed, while deepening already dangerous levels of polarization."