mirror of
https://github.com/wassname/optuna-dashboard.git
synced 2026-10-04 12:50:44 +08:00
format
This commit is contained in:
1 parent
857122d5b1
commit
012b71a42a
1 file changed
+4
-1
@@ -161,7 +161,10 @@ class _SampledGP(botorch.models.model.Model):
|
||||
|
||||
class _PreferentialGP:
|
||||
def _kernel_func(
|
||||
self, x1: torch.Tensor, x2: torch.Tensor, lengthscale: torch.Tensor,
|
||||
self,
|
||||
x1: torch.Tensor,
|
||||
x2: torch.Tensor,
|
||||
lengthscale: torch.Tensor,
|
||||
) -> torch.Tensor:
|
||||
# Matern 3/2 kernel
|
||||
d = math.sqrt(3) * torch.cdist(x1 / lengthscale, x2 / lengthscale)
|
||||
|
||||
Reference in new issue
Block a user