def rates(filename, **kwargs): """ Plot scattering rates """ from amset.plot.rates import RatesPlotter plotter = RatesPlotter(filename) plt = plotter.get_plot(separate_rates=kwargs["separate_rates"]) save_plot(plt, "rates", kwargs["directory"], kwargs["prefix"], kwargs["image_format"]) return plt
def rates(filename, **kwargs): """ Plot scattering rates """ from amset.plot.rates import RatesPlotter save_kwargs = [ kwargs.pop(d) for d in ["directory", "prefix", "image_format"] ] kwargs["doping_idx"] = _all_or_int(kwargs["doping_idx"]) kwargs["temperature_idx"] = _all_or_int(kwargs["temperature_idx"]) plotter = RatesPlotter(filename) plt = plotter.get_plot(**kwargs) plt.subplots_adjust(hspace=0.3, wspace=0.3) save_plot(plt, "rates", *save_kwargs) return plt
# general settings "doping": [-3e13], "temperatures": [201, 290, 401, 506, 605, 789, 994], "bandgap": 1.33, # electronic_structure settings "interpolation_factor": 50, # scattering rate settings "deformation_potential": (1.2, 8.6), "elastic_constant": 139.7, "donor_charge": 1, "acceptor_charge": 1, "static_dielectric": 12.18, "high_frequency_dielectric": 10.32, "pop_frequency": 8.16, # performance settings "mobility_rates_only": True, "write_mesh": True, } if __name__ == "__main__": runner = Runner.from_vasprun("vasprun.xml.gz", settings) amset_data = runner.run() plotter = RatesPlotter(amset_data) plt = plotter.get_plot() plt.savefig("GaAs_rates.png", bbox_inches="tight", dpi=400)