code: func GetBlockWeight(blk *btcutil.Block) int64 {
  	msgBlock := blk.MsgBlock()
  
  	baseSize := msgBlock.SerializeSizeStripped()
  	totalSize := msgBlock.SerializeSize()
  
  	// (baseSize * 3) + totalSize
  	return int64((baseSize * (WitnessScaleFactor - 1)) + totalSize)
  }
docs: // GetBlockWeight computes the value of the weight metric for a given block.
  // Currently the weight metric is simply the sum of the block's serialized size
  // without any witness data scaled proportionally by the WitnessScaleFactor,
  // and the block's serialized size including any witness data.