He looks intelligent, his eyes a little dreamy.

But behind those eyes lies the unrelentingly cruel, vicious and demented mind of a terrorist.

Meet Tamim Chowdhury -- the man who is now thought to have masterminded the Holey Artisan attack in Gulshan that left 20 diners, 17 of them foreigners -- dead on July 1. Only a week later, he led the attack near the Eid congregation in Sholakia that left four, including two cops, dead.

Terrifying new information has been gleaned about Tamim, a longtime resident of Calgary in Canada. He used to mix with people who had joined IS, and many of them went to Syria where the terror group controls a large part of territories.

He was deemed such a dangerous man that religious leaders in Windsor, where Tamim was born, had asked him around 2013 not to mix with youths at the mosques, fearing that he might radicalise them.

Amarnath Amarasingam, a fellow at the George Washington University's programme on extremism, who also co-directs a study of Western foreign fighters at the University of Waterloo in Canada, first came to know about Tamim in 2015 while investigating jihadis in Windsor.

He interviewed friends of a jihadi named Ahmad Waseem, also known as Abu Turab, who returned to Canada after being injured in fighting in Syria. Tamim's name appeared then. Tamim was thought to have left for Syria to become a terrorist although when exactly he left is uncertain.

But Waseem slipped into Syria on a fake passport after his mother seized his original travel document, according to the National Post, a Canadian newspaper, although his family, community and police tried to convince him to stay home.

A friend of Waseem told Amarnath that Tamim, facing harassment from law enforcement agencies in Canada, had decided to simply move back to his ancestral home in Bangladesh.

Since then he had been recruiting youths, radicalising them and masterminding ruthless attacks, according to police.

Investigators say Tamim accompanied the five Holey Artisan Bakery attackers from their Bashundhara flat to Gulshan and left the area after bidding them farewell just before the café siege began around 8:40pm on July 1.

And on July 7, the Eid day, he took the Sholakia attackers to a place near the police checkpoint in a CNG-run auto-rickshaw, briefed them and then left Kishoreganj, they add.

THE CALGARY CONNECTION

Calgary reserves a special spot in Canada's terrorism outlook. According to the National Post, a small group of young men left Calgary to fight in the Syrian conflict. Calgary is the home of some dangerous jihadists such as Damian Clairmont, Salman Ashrafi, Gregory and Collin Gordon and Farah Shirdon.

Salman Ashrafi, 22, has been identified by a jihadist group as a suicide bomber responsible for killing 46 people in Iraq in November 2013, according to a report by CBC on June 5, 2014.

The IS, according to the National Post of Canada, released in early June of 2014 photos of Ashrafi along with a eulogy saying he had carried out a car bombing in north of Baghdad.

Damian Clairmont, who converted to Islam at the age of 17, was part of a circle of friends in Calgary that included Ashrafi. Clairmon, who took the name Mustafa al-Gharib, prayed at the same mosque and lived in the same apartment building in downtown Calgary as Ashrafi. Clairmont left Calgary for Syria in November 2012 to fight with Jabhat al-Nusra, an al-Qaeda-affiliated rebel group consisting largely of foreign extremists. He was injured in battle and subsequently captured and killed by an unknown faction of the Free Syrian Army in the city of Aleppo.

Syed Soharwardy, a Calgary imam, told CBS television channel: “It is impossible for me to think the intelligence people do not know who is radicalising Muslim youth. It is going on undercover; it is going on openly sometimes.”

Ashrafi, Clairmont and other Calgary radicals were all friends who dined at the same restaurants, prayed at the same mosque and lived in the same apartment building in downtown Calgary, CBS News said.

According to one source who knew all the men, they had meetings, sometimes in Ashrafi's apartment, where he reportedly instructed them that the only way to live with non-Muslims was to either convert them or subjugate them, and failing that migrate to a land of Islam.

They all left Canada at roughly the same time in late 2012.

It is among such dangerous clout in Calgary that Tamim was seen hanging around and got radicalised.

An intelligence brief for the Canada Border Services Agency has shown how jihadists have used Canada on a large scale to join IS, according to Ottawacitizen.com.

It is estimated that some 180 Canadians have left the country to take part in jihadi war around the world, the director of Canadian Security Intelligence Service said in March, according to the National Post. About 60 have come back already, and Tamim was probably one of them.

According to Amarnath's article posted on jihadology.com, friends of these terrorists remembered Tamim in Calgary.

Tamim was born on July 25, 1986, and is a Canadian citizen.

According to Amarnath's findings, he probably attended JL Forster Secondary School in Windsor and was an active sportsman.

He completed his graduation in Chemistry from the University of Windsor in spring 2011 and then travelled to Calgary.

“It is unclear whether he moved to Calgary, or simply travelled back and forth several times,” Amarnath wrote. “The latter seems more likely since those I spoke with in Calgary only remember him intermittently. Tamim seems to have stayed low-key perhaps, and did not mix too closely with the Muslim community there.

“One source told me that he remembers Tamim hanging out with Damian Clairmont at the 8th and 8th Musallah, where Damian, Salman Ashrafi, Collin and Gregory Gordon, another individual named Waseem (last name unknown, but not Ahmad Waseem), and a few others held a private study circle. According to friends of theirs, Damian was likely the one who took a leadership role over the group, but it could be that Tamim was equally influential.”

Tamim then went to Syria, either directly from Calgary or from Windsor, probably in late 2012. But another source of Amarnath claims he saw Tamim hanging around the University of Calgary in 2013.

From Syria, Tamim perhaps came to Bangladesh, but the time of his arrival is not clear.

But since then he has been operating in Bangladesh in various guises. Police think he frequently changes his appearance to avoid arrest.

Tamim is thought to have taken up the name of Shaykh Abu Ibrahim al-Hanif. In this name he has given a chilling interview in Dabiq, the so-called magazine of IS.

“Bengal [Bangladesh] is an important region for the Khalifah and the global jihad due to its strategic geographical position. Having a strong jihadi base in Bengal will facilitate performing guerrilla attacks inside India,” he said.

As part of his assignment in Bangladesh, Tamim had been planning another big attack. He had set up a den in Kalyanpur which was busted by police on July 26. He had visited the den several times, police said.