MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / Init

Method Init

tensorflow/core/util/guarded_philox_random.cc:21–32  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19namespace tensorflow {
20
21Status GuardedPhiloxRandom::Init(OpKernelConstruction* context) {
22 // Grab seed Attrs.
23 int64 seed, seed2;
24 auto status = context->GetAttr("seed", &seed);
25 if (!status.ok()) return status;
26 status = context->GetAttr("seed2", &seed2);
27 if (!status.ok()) return status;
28
29 // Initialize with the given seeds
30 Init(seed, seed2);
31 return Status::OK();
32}
33
34void GuardedPhiloxRandom::Init(int64 seed, int64 seed2) {
35 CHECK(!initialized_);

Callers

nothing calls this directly

Calls 5

New64Function · 0.85
PhiloxRandomClass · 0.85
InitFunction · 0.50
GetAttrMethod · 0.45
okMethod · 0.45

Tested by

no test coverage detected