A former Sydney teacher who preyed on girls he taught and covertly filmed them in class has avoided going straight to jail when granted bail to appeal his sentence.
Eric Wong, 29, pleaded guilty to two counts of filming a person's private parts without consent.
His sentencing in May was delayed for a report on the possibility of autism spectrum disorder, which could have impacted on his sentencing.
Barrister Peter Givorshner told a local court two eminent doctors had agreed.
"He needs treatment, and he's not going to get it in jail," Mr Givorshner said on Wednesday.
Wong can get treatment after he's released, Magistrate Alexander Mijovich said.
He jailed Wong for at least six months with a total sentence of 14 months.
About two hours later, Wong was released, appealing the decision to the District Court.
"They may have a different view, they may be convinced," Mr Mijovich said.
He noted Wong had been on bail since January and there was no sign of him breaching it.
His barrister had sought an intensive corrections order which would allow Wong to serve his sentence outside jail.
The court was satisfied imprisonment was the only suitable punishment, with Mr Mijovich saying "the threshold is well and truly crossed".
"You abused a position of trust and authority of multiple victims," he told Wong.
"These occurred in the confines of a school, where the victims and families are entitled to feel safe from any predatory or other behaviour."
The teacher preyed on girls he taught, photographing and filming their pelvic and chest areas under their school uniforms in a "brazen, predatory and opportunist" way, agreed facts filed with the court state.
A 16-year-old student, asked to stay behind after class to complete a survey, bumped into a smartboard at Cammeraygal High School on Sydney's lower north shore and revealed a hidden phone strategically placed to film.
Wong immediately leant down to pick up the phone, said he left it there before class, and changed the topic when the girl questioned him.
Police later found 90 videos and 300 photos of uniformed students, including images taken up skirts and down shirts when they searched his home.
The files were found on two computers, showing him "randomly walking around" his classroom recording on his phone, targeting only the girls.
He walks up next to or behind them, and while supervising their schoolwork, discreetly films their private parts under their school uniforms.
Some videos show him glancing towards the phone before repositioning it, which the magistrate said showed a degree of planning in his offending, occurring over a period of time.
While Wong may have autism with Asperger's syndrome according to the medical reports, he was also described as having above average intelligence.
"You would have had a full understanding this was completely inappropriate conduct," Mr Mijovich told Wong in Hornsby Local Court.
Wong has been ordered to live with his parents at Surry Hills, not to contact any students or witnesses, not to work as a tutor, and not upload any more educational science videos to social media while on bail pending his appeal.
1800 RESPECT (1800 737 732)
National Sexual Abuse and Redress Support Service 1800 211 028