Canadian researchers have been behind some recent major breakthroughs in artificial intelligence. Now, the country is betting on becoming a big player in one of the hottest fields in technology, with help from the likes of Google and RBC.
In an unassuming building on the University of Toronto's downtown campus, Geoff Hinton laboured for years on the "lunatic fringe" of academia and artificial intelligence, pursuing research in an area of AI called neural networks.
Also known as "deep learning", neural networks are computer programs that learn in a similar way to human brains. The field showed early promise in the 1980s, but the tech sector turned its attention to other AI methods after that promise seemed slow to develop.
"The approaches that I thought were silly were in the ascendancy and the approach that I thought was the right approach was regarded as silly," says the British-born professor, who splits his time between the university and Google, where he is a vice-president of engineering fellow.
Now, neural networks - which allow computers to do things like teach themselves to play games like Texas hold 'em - are considered tech's next big thing, and Hinton is recognised globally for his work.
Neural networks perform complex and intuitive tasks through exposure to huge amounts of data. Today's more powerful computers and massive sets of data allowed for breakthroughs in neural network technology, improving accuracy in speech recognition and computer vision, which is helping make self-driving cars a reality.
Neural networks are used by the likes of Netflix to recommend what you should binge watch and smartphones with voice assistance tools. Google DeepMind's AlphaGo AI used them to win against a human in the ancient game of Go in 2016.
Foteini Agrafioti, who heads up the new RBC Research in Machine Learning lab at the University of Toronto, said those recent innovations made AI attractive to researchers and the tech industry.
"Anything that's powering Google's engines right now is powered by deep learning," she says.
Developments in the field helped jumpstart innovation and paved the way for the technology's commercialisation. They also captured the attention of Google, IBM and Microsoft, and kicked off a hiring race in the field.
The renewed focus on neural networks has boosted the careers of early Canadian AI machine learning pioneers like Hinton, the University of Montreal's Yoshua Bengio, and University of Alberta's Richard Sutton.
Money from big tech is coming north, along with investments by domestic corporations like banking multinational RBC and auto parts giant Magna, and millions of dollars in government funding.
Toronto will soon get the Vector Institute for Artificial Intelligence, geared to fuelling "Canada's amazing AI momentum".
The new research facility, which will be officially launched on Thursday, will be dedicated to expanding the applications of AI through explorations in deep learning and other forms of machine learning. It has received about C$170m (US$127m/£102m) in funding from the Canadian and Ontario governments and a group of 30 businesses, including Google and RBC.
Hinton will be the institute's chief scientific adviser.
Former banking executive Ed Clark will head the institute, and says the goal is to make Toronto, which has the largest concentration of AI-related industries in Canada, one of the top five places in the world for AI innovation and business.
The founders also want it to serve as a magnet and retention tool for top talent aggressively head-hunted by US firms.
Clark says they want to "wake up" Canadian industry to the possibilities of AI, which is expected to have a massive impact on fields like healthcare, banking, manufacturing and transportation.
The Vector Institute is just the latest infusion of cash into Canada's AI sector.
Google invested C$4.5m (US$3.4m/£2.7m) last November in the University of Montreal's Montreal Institute for Learning Algorithms.
Microsoft is funding a Montreal startup, Element AI. The Seattle-based company also announced it would acquire Montreal-based Maluuba and help fund AI research at the University of Montreal and McGill University.
Thomson Reuters and General Motors both recently moved AI labs to Toronto.
Earlier this month, the federal government announced C$125m ($94m/£75m) for a "pan-Canadian AI strategy".
RBC is also investing in the future of AI in Canada, including opening a machine learning lab headed by Agrafioti, co-funding a program to bring global AI talent and entrepreneurs to Toronto, and collaborating with Sutton and the University of Alberta's Machine Intelligence Institute.
Those trying to build Canada's AI scene admit places like Silicon Valley will always be attractive to tech talent. But they hope strategic investments like these will allow Canada to fuel the growth of domestic startups.
Canadian tech also sees the travel uncertainty created by the Trump administration in the US as making Canada more attractive to foreign talent. (One of Clark's selling points is that Toronto as an "open and diverse" city).
"I would hate to see one more professor moving south," Agrafioti says. "Really, I hope that five years from now we look back and say we almost lost it but we caught it in time and reversed it."