Killer robots capable of using facial recognition before slaughtering people 'will be devastating to humankind', a top professor warned.

Professor Stuart Russell, a leading artificial intelligence (AI) expert at the University of California, said allowing machines to kill humans would endanger freedom and security.

He remarked on the chilling vision following an appearance at the end of a short film which explores how AI could be used to take out targeted individuals.

The film, entitled Slaughterbots , shows a dystopian future where tiny drones are programmed to carry out mass killings.

Professor Stuart Russell discussed the chilling prophecy in a new film (
Image:
autonomousweapons.org)

It was shown at a United Nations summit that heard stark warnings about the growing danger of killer drone attacks.

Professor Russell states: "This short film is more than just speculation, it shows the results of integrating and miniaturising technologies that we already have.

"I've worked in AI for more than 35 years. Its potential to benefit humanity is enormous, even in defence.

"But allowing machines to choose to kill humans will be devastating to our security and freedom - thousands of my fellow researchers agree.

"We have an opportunity to prevent the future you just saw, but the window to act is closing fast."

The film explores how artificial intelligence could be used to take out targeted individuals (
Image:
autonomousweapons.org)
Tiny drones are shown programmed to carry out mass killings (
Image:
autonomousweapons.org)

Slaughterbots was filmed around Edinburgh and features an attack on students in the city.

Campaigners hope that the film will help bolster the case for a global ban on lethal weapons systems.

The seven-minute film, produced by the Campaign To Stop Killer Robots, shows a classroom full of students being murdered after a swarm of drones are launched.

The film was released at the UN Convention on Conventional Weapons in Geneva (
Image:
autonomousweapons.org)
The film shows students under attack in Edinburgh, where it was filmed (
Image:
autonomousweapons.org)

It features a miniaturised drone -- which is small enough to fit into the palm of a hand and is said to react 100 times faster than a human being.

Locations throughout Edinburgh's Old Town were deployed in the film, which was released at the UN Convention on Conventional Weapons in Geneva.

It was instigated by the Future of Life Institute, an AI watchdog backed by the likes of physicist Stephen Hawking.

The Slaughterbots film was made by UK firm Space Digital, based at the media hub in Salford, in Greater Manchester.

The film is entitled Slaughterbots (
Image:
autonomousweapons.org)
It was produced by the Campaign To Stop Killer Robots (
Image:
autonomousweapons.org)

The company worked with the Film Edinburgh commission to shoot in locations like Castle Terrace, Calton Road, the Cowgate and Victoria Street.

Rosie Ellison, manager of Film Edinburgh, called the results of the film "very chilling".

He said: "We were contacted by Space Digital about a film they were making about the potential dangers of AI weapons falling into the wrong hands, in which university students get attacked, and for this element they were looking for iconic parts of the UK and had decided on Edinburgh.

"They wanted to show deserted streets patrolled by armed police. The 'bots' would be added in post-production.

"Our involvement was to look at how and where this might be achieved and advise the producers about the procedures to put this into action."