A police sergeant who decided to leave a convicted rapist on the streets - who went on to kill his parents - said he got it "very wrong", an inquest has heard.
Ashraf Amrani, 30, was on bail when his body was discovered on a first-floor roof in Westbourne Park Road, west London, on February 13 2015.
When police went to inform his parents the following day, Hassan, 72, and Zohra, 59, were found dead at their flat, which was on the same street.
On February 10 2015 Amrani had been arrested on suspicion of affray, having reportedly pursued a stranger through the street with a large knife.
Officers took him to St Mary's Hospital after he became unwell, he was treated for taking nine ecstasy tablets. Amrani went on to discharge himself at 3am the following day.
He was released on street bail - when a suspect is bailed without being taken to the police station - and is usually used for offences such as shoplifting.
Sergeant Sandy Gordon, who made the bail decision, gave evidence at the second day of the inquest into the three deaths being held at the Royal Courts of Justice in London on Tuesday.
When asked by coroner Bernard Richmond QC if, looking back, he got the decision right or wrong, Sgt Gordon said: "Very wrong."
The court heard how Sgt Gordon had conducted a police national computer search of Amrani who gave an alias name to officers, and discovered there were five names he had been known by before.
He also found Amrani had a rape conviction - for which he had been handed a seven year prison sentence, with two and a half years left to run on his licence.
"Weren't there alarm bells ringing in that you had a convicted rapist potentially changing his name?," asked Mr Richmond.
Sgt Gordon, said: "It wasn't that he was using that name for the first time. It was always on his record. I did not really consider that."
He said at about 1am Pc Alexander Gill had informed him that Amrani, who had previously been restrained with handcuffs and leg straps, was "quite calm" and "seemed to accept" he needed to stay at the hospital for 48 hours.
Sgt Gordon admitted that making this a bail condition "would have helped", saying he drew on his experiences and went off what he had been told about the situation at the hospital.
"He had taken a lot of drugs, I just thought now he was more reasonable, was coming down off the drugs - the danger has passed," he added.
The court heard how Amrani also had a conviction for the possession of an offensive weapon - which Sgt Gordon said he was aware of after checking his records.
Nick Yeo, his barrister, asked Sgt Gordon if Amrani's rape conviction and possession of cannabis were an "important consideration or not when making his bail decision".
He replied that "it was an important decision" - and after spending time in prison, he thought "he had learnt his lessons and was a grown up".
Amrani had a history of drug abuse and traces of cannabis and MDMA were discovered in his system after he died.
His family had sought to get him psychiatric care in the past and his GP said he had reported suicide attempts.
Mr Richmond asked: "We have heard from the family drug use was much more problematic - had you been aware he had an ongoing drug problem what effect would that have had on your decision (to bail)?"
Sgt Gordon said: "I genuinely thought this was a one off. Someone who is a substantial user generally does not overdose on drugs".
In his evidence Pc Gill said he was told by Sgt Gordon to relay to medics at the hospital that if Amrani tried to leave they should call 999.
Mr Richmond described this instruction as "pretty useless" because "in the absence of an offence there is nothing they can do" - saying it had "zero effect whatsoever".
The inquest continues on Wednesday from 10.15am.