I want to get my delta exposure for every option in my portfolio, this is what I do:

( I want to add up all the deltas to get total delta )
def getDelta(  ):
        for inst in self.Portfolio:
            if inst.Value.Invested: 
                #here I try to get the delta but "inst" is OptionHolding object and not option