(self, c, name: str = "", qualname: str = "")
| 729 | _constant_cache = {} |
| 730 | |
| 731 | def __init__(self, c, name: str = "", qualname: str = ""): |
| 732 | super().__init__() |
| 733 | assert isinstance(c, (RawTensor, Module)) |
| 734 | if isinstance(c, Module): |
| 735 | assert module_tracer.is_builtin(c) or c.is_qat |
| 736 | if type(c) is RawTensor: |
| 737 | with _exclude_from_trace(): |
| 738 | c = Tensor(c) |
| 739 | self.value = c |
| 740 | self.name = name |
| 741 | self.inputs = [] |
| 742 | node_cls = NodeMixin.get_wrapped_type(c) |
| 743 | self.outputs = [ |
| 744 | node_cls(self, name=name, qualname=qualname), |
| 745 | ] |
| 746 | |
| 747 | @classmethod |
| 748 | def make(cls, *args, **kwargs): |
nothing calls this directly
no test coverage detected