(self)
| 252 | self.param = param |
| 253 | |
| 254 | def __call__(self): |
| 255 | param = self.param |
| 256 | if param is None: |
| 257 | kernel = LinearKernel() |
| 258 | elif isinstance(param, KernelBase): |
| 259 | kernel = param |
| 260 | elif isinstance(param, str): |
| 261 | kernel = self.init_from_str() |
| 262 | elif isinstance(param, dict): |
| 263 | kernel = self.init_from_dict() |
| 264 | return kernel |
| 265 | |
| 266 | def init_from_str(self): |
| 267 | r = r"([a-zA-Z0-9]*)=([^,)]*)" |
nothing calls this directly
no test coverage detected