class_docstr: SASRec is the first sequential recommender based on self-attentive mechanism.
  
  NOTE:
      In the author's implementation, the Point-Wise Feed-Forward Network (PFFN) is implemented
      by CNN with 1x1 kernel. In this implementation, we follows the original BERT implementation
      using Fully Connected Layer to implement the PFFN.
class_docstr_tok: ["SASRec","is","the","first","sequential","recommender","based","on","self-attentive","mechanism",".","NOTE",":","In","the","author","'s","implementation",",","the","Point-Wise","Feed-Forward","Network","(","PFFN",")","is","implemented","by","CNN","with","1x1","kernel",".","In","this","implementation",",","we","follows","the","original","BERT","implementation","using","Fully","Connected","Layer","to","implement","the","PFFN","."]
docstr: Initialize the weights
docstr_tok: ["Initialize","the","weights"]
code: def _init_weights(self, module):
      """Initialize the weights"""
      if isinstance(module, (nn.Linear, nn.Embedding)):
          # Slightly different from the TF version which uses truncated_normal for initialization
          # cf https://github.com/pytorch/pytorch/pull/5617
          module.weight.data.normal_(
              mean=0.0, std=self.initializer_range
          )
      elif isinstance(module, nn.LayerNorm):
          module.bias.data.zero_()
          module.weight.data.fill_(1.0)
      if isinstance(module, nn.Linear) and module.bias is not None:
          module.bias.data.zero_()
  
file_path: RecBole/recbole/model/sequential_recommender/sasrec.py
imports: import torch
  from torch import nn
  from recbole.model.abstract_recommender import SequentialRecommender
  from recbole.model.layers import TransformerEncoder
  from recbole.model.loss import BPRLoss
label_desc: Use image node_id 2 for calling the SASRec obj's underlying member method code with example usage: obj._init_weights(module) without return types