DRC_command, pull_interacting.

Hi Sir,
Is it possible to check if L1 with 2 polygon on L2 ?

such as "shape=mesh_line_a.pull_interacting(Layer2)" , but I want to add more condition as below figure.

Comments

  • Hi Laurent
    Thanks for your code... but may I know that how to using that code?
    I am a new user for Klayout and Ruby...

  • Hi Laurent
    I got the way to running that code..
    but it can't working cause that is not a array shape.(it is just some of polygon)
    you can check with picture to find what the pattern do I have...

  • Here is an exemple of contact over Poly :smile:

    #  DRC scripts 
    
    # Define a new custom function that selects polygons by their number of holes:
    # It will return a new layer containing those polygons with min to max holes.
    # max can be nil to omit the upper limit.
    class DRC::DRCLayer
      def with_holes(min, max)
        new_data = RBA::Region::new
        self.data.each do |p|
          if p.holes >= (min || 0) && (!max || p.holes <= max)
            new_data.insert(p)
          end
        end
        DRC::DRCLayer::new(@engine, new_data)
      end
    end 
    
    # This is a sample:
    poly = input(1)
    contact=input(3)
    metal = input(2)
    poly.and(metal).not(contact).with_holes(1,1).output("2_PL_CT", "Min. 2 Contacts on Poly is recommended")
    

    Laurent

  • Hi Laurent
    could you please help it....
    (when I run this DRC function , I get a message ..".No layout loaded. , no default layout..."
    then , even I just input a layer or run another DRC code , I still get same message..

  • Hi Laurent,
    I find answer !!! Thanks very much for your help~

Sign In or Register to comment.