Beispiel #1
0
def draw_inductor_for_fl_line(design, fl_line_idx):
    cpwrl_fl = self.cpw_fl_lines[fl_line_idx]
    cpwrl_fl_inductor_start = cpwrl_fl.end + \
                              DVector(0, -design.current_line_width / 2)
    cpwrl_fl_inductor = CPW(
        cpw_params=CPWParameters(width=design.current_line_width, gap=0),
        start=cpwrl_fl_inductor_start,
        end=cpwrl_fl_inductor_start +
        DVector(2 * abs(design.flux_lines_x_shifts[fl_line_idx]), 0))
    cpwrl_fl_inductor.place(design.region_ph)
    cpwrl_fl_inductor_empty_box = Rectangle(
        origin=cpwrl_fl.end +
        DVector(0, -design.current_line_width - 2 * design.z_md_fl.gap),
        width=cpwrl_fl_inductor.dr.abs(),
        height=2 * design.z_md_fl.gap,
        inverse=True)
    cpwrl_fl_inductor_empty_box.place(design.region_ph)
	def draw_el_dc_contacts(self, squids: AsymSquid = None):
		# if argument is omitted, use all squids stored in `self.squids`
		if squids is None:
			squids = self.squids + self.test_squids

		for squid in squids:
			r_pad = squid.params.pad_r
			center_up = squid.pad_up.center + DPoint(0, r_pad)
			center_down = squid.pad_down.center + DPoint(0, -r_pad)
			big_circle_r = 1.5 * r_pad
			self.el_dc_contacts.append(
				[Circle(center_up, big_circle_r), Circle(center_down, big_circle_r)]
			)
			for contact in self.el_dc_contacts[-1]:
				contact.place(self.region_el2)

			# DC contacts has to have intersection with empty layer in photo litography
			# to ensure that first e-beam layer does not broke at the step between
			# substrate and photolytography polygons.
			# Following rectangle pads are cutted from photo region to ensure
			# DC contacts are covering aforementioned level step.
			squid_pad_r = squid.params.pad_r
			squid_pads_d = squid.params.pads_distance - 2 * squid_pad_r
			rec_width = 1.6 * squid_pad_r - 2 * FABRICATION.OVERETCHING
			rec_height = 1.6 * squid_pad_r - FABRICATION.OVERETCHING
			# Rectangle for top DC contact pad
			p1 = squid.origin + DVector(-rec_width / 2, squid_pads_d / 2) + \
				 DVector(0, -FABRICATION.OVERETCHING)
			rec_top = Rectangle(p1, rec_width, rec_height, inverse=True)
			rec_top.place(self.region_ph)

			# Rectangle for bottom DC contact pad
			p2 = squid.origin + DVector(-rec_width / 2, -squid_pads_d / 2) + \
				 DVector(0, FABRICATION.OVERETCHING)
			rec_bot = Rectangle(p2, rec_width, -rec_height, inverse=True)
			rec_bot.place(self.region_ph)
Beispiel #3
0
    def init_regions(self):
        origin = DPoint(0, 0)
        w = self.out_a / 2 - self.in_a / 2

        rec1 = Rectangle(origin, w, w)
        p2 = origin + DPoint(self.in_a + w, 0)
        rec2 = Rectangle(p2, w, w)
        p3 = origin + DPoint(self.in_a + w, self.in_a + w)
        rec3 = Rectangle(p3, w, w)
        p4 = origin + DPoint(0, self.in_a + w)
        rec4 = Rectangle(p4, w, w)

        tmp_reg = Region()

        rec1.place(tmp_reg)
        rec2.place(tmp_reg)
        rec3.place(tmp_reg)
        rec4.place(tmp_reg)

        rec = Rectangle(origin, self.out_a, self.out_a)
        rec.place(self.metal_region)

        self.empty_region = tmp_reg
        self.connections = [self.center]
	def draw_test_structures(self):
		new_pars_squid = AsymSquidParams(
			pad_r=5e3, pads_distance=30e3,
			p_ext_width=10e3, p_ext_r=200,
			sq_len=15e3, sq_area=200e6,
			j_width_1=94, j_width_2=347,
			intermediate_width=500, b_ext=1e3, j_length=94, n=20,
			bridge=180, j_length_2=250
		)

		struct_centers = [DPoint(1e6, 4e6), DPoint(8.7e6, 5.7e6), DPoint(6.5e6, 2.7e6)]
		for struct_center in struct_centers:
			## JJ test structures ##
			# test structure with big critical current
			test_struct1 = TestStructurePads(struct_center)
			test_struct1.place(self.region_ph)
			text_reg = pya.TextGenerator.default_generator().text("48.32 nA", 0.001, 50, False, 0, 0)
			text_bl = test_struct1.empty_rectangle.origin + DPoint(
				test_struct1.gnd_gap, -4 * test_struct1.gnd_gap
			)
			text_reg.transform(ICplxTrans(1.0, 0, False, text_bl.x, text_bl.y))
			self.region_ph -= text_reg
			test_jj = AsymSquid(test_struct1.center, new_pars_squid, side=1)
			self.test_squids.append(test_jj)
			test_jj.place(self.region_el)

			# test structure with low critical current
			test_struct2 = TestStructurePads(struct_center + DPoint(0.3e6, 0))
			test_struct2.place(self.region_ph)
			text_reg = pya.TextGenerator.default_generator().text("9.66 nA", 0.001, 50, False, 0, 0)
			text_bl = test_struct2.empty_rectangle.origin + DPoint(
				test_struct2.gnd_gap, -4 * test_struct2.gnd_gap
			)
			text_reg.transform(ICplxTrans(1.0, 0, False, text_bl.x, text_bl.y))
			self.region_ph -= text_reg
			test_jj = AsymSquid(test_struct2.center, new_pars_squid, side=-1)
			self.test_squids.append(test_jj)
			test_jj.place(self.region_el)

			# test structure for bridge DC contact
			test_struct3 = TestStructurePads(struct_center + DPoint(0.6e6, 0))
			test_struct3.place(self.region_ph)
			text_reg = pya.TextGenerator.default_generator().text("DC", 0.001, 50, False, 0, 0)
			text_bl = test_struct3.empty_rectangle.origin + DPoint(
				test_struct3.gnd_gap, -4 * test_struct3.gnd_gap
			)
			text_reg.transform(ICplxTrans(1.0, 0, False, test_struct3.center.x, text_bl.y))
			self.region_ph -= text_reg

			test_bridges = []
			for i in range(3):
				bridge = Bridge1(test_struct3.center + DPoint(50e3 * (i - 1), 0),
								 gnd_touch_dx=20e3)
				test_bridges.append(bridge)
				bridge.place(self.region_bridges1, region_name="bridges_1")
				bridge.place(self.region_bridges2, region_name="bridges_2")

		# bandages test structures
		test_dc_el2_centers = [
			DPoint(2.5e6, 2.4e6),
			DPoint(4.2e6, 1.6e6),
			DPoint(9.0e6, 3.8e6)
		]
		for struct_center in test_dc_el2_centers:
			test_struct1 = TestStructurePads(struct_center)
			test_struct1.place(self.region_ph)
			text_reg = pya.TextGenerator.default_generator().text("Bandage", 0.001, 40, False, 0, 0)
			text_bl = test_struct1.empty_rectangle.origin + DPoint(
				test_struct1.gnd_gap, -4 * test_struct1.gnd_gap
			)
			text_reg.transform(ICplxTrans(1.0, 0, False, text_bl.x, text_bl.y))
			self.region_ph -= text_reg

			rec_width = 10e3
			rec_height = test_struct1.rectangles_gap + 2 * FABRICATION.OVERETCHING + 2 * rec_width
			p1 = struct_center - DVector(rec_width / 2, rec_height / 2)
			dc_rec = Rectangle(p1, rec_width, rec_height)
			dc_rec.place(self.region_el2)
    def draw_test_structures(self):
        struct_centers = [
            DPoint(1e6, 4e6),
            DPoint(8.7e6, 5.7e6),
            DPoint(6.5e6, 2.7e6)
        ]
        for struct_center in struct_centers:
            ## JJ test structures ##
            # test structure with big critical current
            test_struct1 = TestStructurePads(struct_center)
            test_struct1.place(self.region_ph)
            text_reg = pya.TextGenerator.default_generator().text(
                "48.32 nA", 0.001, 50, False, 0, 0)
            text_bl = test_struct1.empty_rectangle.origin + DPoint(
                test_struct1.gnd_gap, -4 * test_struct1.gnd_gap)
            text_reg.transform(ICplxTrans(1.0, 0, False, text_bl.x, text_bl.y))
            self.region_ph -= text_reg
            test_jj = AsymSquidDCFlux(test_struct1.center,
                                      SQUID_PARAMETERS,
                                      side=1)
            self.test_squids.append(test_jj)
            test_jj.place(self.region_el)

            # test structure with low critical current
            test_struct2 = TestStructurePads(struct_center + DPoint(0.3e6, 0))
            test_struct2.place(self.region_ph)
            text_reg = pya.TextGenerator.default_generator().text(
                "9.66 nA", 0.001, 50, False, 0, 0)
            text_bl = test_struct2.empty_rectangle.origin + DPoint(
                test_struct2.gnd_gap, -4 * test_struct2.gnd_gap)
            text_reg.transform(ICplxTrans(1.0, 0, False, text_bl.x, text_bl.y))
            self.region_ph -= text_reg
            test_jj = AsymSquidDCFlux(test_struct2.center,
                                      SQUID_PARAMETERS,
                                      side=-1)
            self.test_squids.append(test_jj)
            test_jj.place(self.region_el)

            # test structure for bridge DC contact
            test_struct3 = TestStructurePads(struct_center + DPoint(0.6e6, 0))
            test_struct3.place(self.region_ph)
            text_reg = pya.TextGenerator.default_generator().text(
                "DC", 0.001, 50, False, 0, 0)
            text_bl = test_struct3.empty_rectangle.origin + DPoint(
                test_struct3.gnd_gap, -4 * test_struct3.gnd_gap)
            text_reg.transform(
                ICplxTrans(1.0, 0, False, test_struct3.center.x, text_bl.y))
            self.region_ph -= text_reg

            test_bridges = []
            for i in range(3):
                bridge = Bridge1(test_struct3.center +
                                 DPoint(50e3 * (i - 1), 0),
                                 gnd_touch_dx=20e3)
                test_bridges.append(bridge)
                bridge.place(self.region_bridges1, region_name="bridges_1")
                bridge.place(self.region_bridges2, region_name="bridges_2")

        # bandages test structures
        test_dc_el2_centers = [
            DPoint(2.5e6, 2.4e6),
            DPoint(4.2e6, 1.6e6),
            DPoint(9.0e6, 3.8e6)
        ]
        for struct_center in test_dc_el2_centers:
            test_struct1 = TestStructurePads(struct_center)
            test_struct1.place(self.region_ph)
            text_reg = pya.TextGenerator.default_generator().text(
                "Bandage", 0.001, 40, False, 0, 0)
            text_bl = test_struct1.empty_rectangle.origin + DPoint(
                test_struct1.gnd_gap, -4 * test_struct1.gnd_gap)
            text_reg.transform(ICplxTrans(1.0, 0, False, text_bl.x, text_bl.y))
            self.region_ph -= text_reg

            rec_width = 10e3
            rec_height = test_struct1.rectangles_gap + 2 * rec_width
            p1 = struct_center - DVector(rec_width / 2, rec_height / 2)
            dc_rec = Rectangle(p1, rec_width, rec_height)
            dc_rec.place(self.region_el2)
    resolution_dx = 4e3
    resolution_dy = 4e3

    for k in list(range(5))[1:2]:
        ### DRAWING SECTION START ###
        design = Design5Q("testScript")
        design.draw(q_idx=k)

        worm = design.resonators[k]
        xmonCross = design.xmons[k]
        worm_start = list(worm.primitives.values())[0].start

        # draw open end at the resonators start
        p1 = worm_start - DVector(design.Z_res.b / 2, 0)
        rec = Rectangle(p1, design.Z_res.b, design.Z_res.b / 2, inverse=True)
        rec.place(design.region_ph)

        if worm_start.x < xmonCross.center.x:
            dr = (worm_start - xmonCross.cpw_r.end)
        else:
            dr = (worm_start - xmonCross.cpw_l.end)
        dr.x = abs(dr.x)
        dr.y = abs(dr.y)

        center = (worm_start + xmonCross.center) / 2
        box_side_x = 8 * xmonCross.sideX_length
        box_side_y = 8 * xmonCross.sideY_length
        dv = DVector(box_side_x / 2, box_side_y / 2)

        crop_box = pya.Box().from_dbox(
            pya.Box(xmonCross.center + dv, xmonCross.center + (-1) * dv))