MCPcopy Create free account
hub / github.com/BIT-MCS/DRL-eFresh / init_normc_

Function init_normc_

utils/base_utils.py:242–244  ·  view source on GitHub ↗
(weight, gain=1)

Source from the content-addressed store, hash-verified

240
241# https://github.com/openai/baselines/blob/master/baselines/common/tf_util.py #L87
242def init_normc_(weight, gain=1):
243 weight.normal_(0, 1)
244 weight *= gain / torch.sqrt(weight.pow(2).sum(1, keepdim=True))
245
246def plot_line(name,list_data,full_path):
247 pdf = PdfPages(full_path+"/"+name+'.pdf')

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected