MCPcopy Create free account
hub / github.com/CausalLearning/robust-unlearnable-examples / bn_function

Method bn_function

models/densenet.py:47–50  ·  view source on GitHub ↗
(self, inputs: List[Tensor])

Source from the content-addressed store, hash-verified

45 self.memory_efficient = memory_efficient
46
47 def bn_function(self, inputs: List[Tensor]) -> Tensor:
48 concated_features = torch.cat(inputs, 1)
49 bottleneck_output = self.conv1(self.relu1(self.norm1(concated_features))) # noqa: T484
50 return bottleneck_output
51
52 # todo: rewrite when torchscript supports any
53 def any_requires_grad(self, input: List[Tensor]) -> bool:

Callers 2

closureMethod · 0.95
forwardMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected