(self, name, fc, phase)
| 490 | super().__init__() |
| 491 | |
| 492 | def create_plugin(self, name, fc, phase): |
| 493 | if len(fc) == 1 and fc[0].name == "__plugin_pickle_obj__": |
| 494 | data = fc[0].data |
| 495 | plugin_dict = pickle.loads(data) # nosec B301 |
| 496 | plugin = self.plugin_cls.__new__(self.plugin_cls) |
| 497 | super(self.plugin_cls, plugin).__init__() |
| 498 | plugin.__dict__.update(plugin_dict) |
| 499 | else: |
| 500 | raise RuntimeError("Expect to be called by TRT") |
| 501 | plugin.plugin_phase = phase |
| 502 | return plugin |
| 503 | |
| 504 | |
| 505 | def trtllm_plugin( |
no test coverage detected