pub fn flatten_cgroup_stats( stats: &BTreeMap<String, CgroupStats>, patterns: &[Pattern], cgroup_key_map: Option<&BTreeMap<String, String>>, ) -> BTreeMap<String, CgroupStats>