Phonons, Localization, and Thermal Conductivity of Diamond Nanothreads and Amorphous Graphene.