class_docstr: This class defines a simple fully connected layer with
  an optional bias term.
  Please consider ``FullyConnectedLayer`` if batch_norm and activation
  are also used.
class_docstr_tok: ["This","class","defines","a","simple","fully","connected","layer","with","an","optional","bias","term",".","Please","consider","``","FullyConnectedLayer","``","if","batch_norm","and","activation","are","also","used","."]
code: def __init__(
      self,
      n_output_chns,
      with_bias=True,
      w_initializer=None,
      w_regularizer=None,
      b_initializer=None,
      b_regularizer=None,
      name="fc",
  ):
      super(FCLayer, self).__init__(name=name)
  
      self.n_output_chns = n_output_chns
      self.with_bias = with_bias
  
      self.initializers = {
          "w": w_initializer
          if w_initializer
          else default_w_initializer(),
          "b": b_initializer
          if b_initializer
          else default_b_initializer(),
      }
  
      self.regularizers = {"w": w_regularizer, "b": b_regularizer}
  
file_path: NiftyNet/niftynet/layer/fully_connected.py
imports: from __future__ import absolute_import, print_function
  import numpy
  import tensorflow
  from niftynet.layer.activation import ActiLayer
  from niftynet.layer.base_layer import TrainableLayer
  from niftynet.layer.bn import BNLayer, InstanceNormLayer
  from niftynet.layer.gn import GNLayer
label_desc: Use image node_id 1 to create a new FCLayer object from inherited base classes: TrainableLayer with example: obj = FCLayer(n_output_chns, with_bias, w_initializer, w_regularizer, b_initializer, b_regularizer, name)