A Top specifies a single output blob (which could be one of several produced by a layer.)
| 80 | |
| 81 | |
| 82 | class Top(object): |
| 83 | """A Top specifies a single output blob (which could be one of several |
| 84 | produced by a layer.)""" |
| 85 | |
| 86 | def __init__(self, fn, n): |
| 87 | self.fn = fn |
| 88 | self.n = n |
| 89 | |
| 90 | def to_proto(self): |
| 91 | """Generate a NetParameter that contains all layers needed to compute |
| 92 | this top.""" |
| 93 | |
| 94 | return to_proto(self) |
| 95 | |
| 96 | def _to_proto(self, layers, names, autonames): |
| 97 | return self.fn._to_proto(layers, names, autonames) |
| 98 | |
| 99 | |
| 100 | class Function(object): |