quantum: revised matrix loading functionality