A new study uses 'deep-learning' computer networks inspired by the layered and hierarchical architecture of the human brain to design basic nanophotonic, metamaterial elements for energy harvesting and medical diagnostics.