<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def to_dict(self):
 """ Create a JSON-serializable representation of the device Specs. The dictionary representation is of the form:: { '1Q': { "0": { "f1QRB": 0.99, "T1": 20e-6, }, "1": { "f1QRB": 0.989, "T1": 19e-6, }, }, '2Q': { "1-4": { "fBellState": 0.93, "fCZ": 0.92, "fCZ_std_err": 0.03, "fCPHASE": 0.91 }, "1-5": { "fBellState": 0.9, "fCZ": 0.89, "fCZ_std_err": 0.05, "fCPHASE": 0.88 }, }, } :return: A dctionary representation of self. :rtype: Dict[str, Any] """

        return {
            '1Q': {
                "{}".format(qs.id): {
                    'f1QRB': qs.f1QRB,
                    'fRO': qs.fRO,
                    'T1': qs.T1,
                    'T2': qs.T2,
                    'fActiveReset': qs.fActiveReset
                } for qs in self.qubits_specs
            },
            '2Q': {
                "{}-{}".format(*es.targets): {
                    'fBellState': es.fBellState,
                    'fCZ': es.fCZ,
                    'fCZ_std_err': es.fCZ_std_err,
                    'fCPHASE': es.fCPHASE
                } for es in self.edges_specs
            }
        }