zoo/resnet/resnet_cifar10_v2_c.py
def classifier(self, x, n_classes):
        ''' Construct the Classifier
            x         : input into the classifier
            n_classes : number of classes
        '''
        # Pool the feature maps after the end of all the residual blocks
        x = self.BatchNormalization(x)
        x = self.ReLU(x)
        x = AveragePooling2D(pool_size=8)(x)
    
        # Flatten into 1D vector
        x = Flatten()(x)

        # Add hidden dropout
        self.encoding = x
        x = Dropout(0.0)(x)
        self.embedding = x

        # Final Dense Outputting Layer 
        outputs = self.Dense(x, n_classes)
        self.probabilities = outputs
        outputs = Activation('softmax')(outputs)
        self.softmax = outputs
        return outputs
 Construct the Classifier
            x         : input into the classifier
            n_classes : number of classes
        
Construct the Classifier
x         : input into the classifier
n_classes : number of classes
Construct the Classifier x : input into the classifier n_classes : number of classes
def classifier(self, x, n_classes):
        x = self.BatchNormalization(x)
        x = self.ReLU(x)
        x = AveragePooling2D(pool_size=8)(x)
        x = Flatten()(x)
        self.encoding = x
        x = Dropout(0.0)(x)
        self.embedding = x
        outputs = self.Dense(x, n_classes)
        self.probabilities = outputs
        outputs = Activation('softmax')(outputs)
        self.softmax = outputs
        return outputs
def classifier ( self , x , n_classes ) : x = self . BatchNormalization ( x ) x = self . ReLU ( x ) x = AveragePooling2D ( pool_size = 8 ) ( x ) x = Flatten ( ) ( x ) self . encoding = x x = Dropout ( 0.0 ) ( x ) self . embedding = x outputs = self . Dense ( x , n_classes ) self . probabilities = outputs outputs = Activation ( 'softmax' ) ( outputs ) self . softmax = outputs return outputs
Construct the Classifier
x         : input into the classifier
n_classes : number of classes
Construct the Classifier x : input into the classifier n_classes : number of classes
''' Construct the Classifier
            x         : input into the classifier
            n_classes : number of classes
        ''' # Pool the feature maps after the end of all the residual blocks # Flatten into 1D vector # Add hidden dropout # Final Dense Outputting Layer 
self
x
n_classes