zoo/jumpnet/jumpnet_c.py
def group(self, x, **metaparameters):
        """ Construct a Residual Group
            x         : input into the group
            n_blocks  : number of residual blocks with identity link
            n_filters : number of filters per group
        """
        n_blocks  = metaparameters['n_blocks']
        n_filters = metaparameters['n_filters']

        # Save the input to the group for the jump link at the end.
        shortcut = self.BatchNormalization(x)
        shortcut = self.Conv2D(shortcut, n_filters, (1, 1), strides=(2, 2))
    
        # Identity residual blocks
        for _ in range(n_blocks):
            x = self.identity_block(x, **metaparameters)

        # Feature Pooling at the end of the group
        x = self.BatchNormalization(x)
        x = self.ReLU(x)
        x = self.Conv2D(x, n_filters, (1, 1), strides=(2, 2))

        # Construct the jumpn link
        x = Concatenate()([shortcut, x])
        return x
 Construct a Residual Group
            x         : input into the group
            n_blocks  : number of residual blocks with identity link
            n_filters : number of filters per group
        
Construct a Residual Group
x         : input into the group
n_blocks  : number of residual blocks with identity link
n_filters : number of filters per group
Construct a Residual Group x : input into the group n_blocks : number of residual blocks with identity link n_filters : number of filters per group
def group(self, x, **metaparameters):
        n_blocks  = metaparameters['n_blocks']
        n_filters = metaparameters['n_filters']
        shortcut = self.BatchNormalization(x)
        shortcut = self.Conv2D(shortcut, n_filters, (1, 1), strides=(2, 2))
        for _ in range(n_blocks):
            x = self.identity_block(x, **metaparameters)
        x = self.BatchNormalization(x)
        x = self.ReLU(x)
        x = self.Conv2D(x, n_filters, (1, 1), strides=(2, 2))
        x = Concatenate()([shortcut, x])
        return x
def group ( self , x , ** metaparameters ) : n_blocks = metaparameters [ 'n_blocks' ] n_filters = metaparameters [ 'n_filters' ] shortcut = self . BatchNormalization ( x ) shortcut = self . Conv2D ( shortcut , n_filters , ( 1 , 1 ) , strides = ( 2 , 2 ) ) for _ in range ( n_blocks ) : x = self . identity_block ( x , ** metaparameters ) x = self . BatchNormalization ( x ) x = self . ReLU ( x ) x = self . Conv2D ( x , n_filters , ( 1 , 1 ) , strides = ( 2 , 2 ) ) x = Concatenate ( ) ( [ shortcut , x ] ) return x
Construct a Residual Group
x         : input into the group
n_blocks  : number of residual blocks with identity link
n_filters : number of filters per group
Construct a Residual Group x : input into the group n_blocks : number of residual blocks with identity link n_filters : number of filters per group
""" Construct a Residual Group
            x         : input into the group
            n_blocks  : number of residual blocks with identity link
            n_filters : number of filters per group
        """ # Save the input to the group for the jump link at the end. # Identity residual blocks # Feature Pooling at the end of the group # Construct the jumpn link
self
x