mirror of
https://github.com/wassname/optuna-dashboard.git
synced 2026-09-10 12:23:22 +08:00
format
This commit is contained in:
@@ -9,10 +9,10 @@ from typing import NoReturn
|
||||
import uuid
|
||||
|
||||
from optuna_dashboard.artifact.file_system import FileSystemBackend
|
||||
import streamlit as st
|
||||
|
||||
from optuna_dashboard.preferential import load_study
|
||||
|
||||
import streamlit as st
|
||||
|
||||
|
||||
STORAGE_URL = "sqlite:///st-example.db"
|
||||
artifact_path = os.path.join(os.path.dirname(__file__), "artifact")
|
||||
|
||||
@@ -2,20 +2,16 @@ from __future__ import annotations
|
||||
|
||||
import os
|
||||
import tempfile
|
||||
import textwrap
|
||||
import time
|
||||
from time import sleep
|
||||
from typing import NoReturn
|
||||
|
||||
import optuna
|
||||
from optuna_dashboard import save_note
|
||||
from optuna_dashboard.artifact import upload_artifact
|
||||
from optuna_dashboard.artifact.file_system import FileSystemBackend
|
||||
from PIL import Image
|
||||
|
||||
from optuna_dashboard.preferential import create_study
|
||||
from optuna_dashboard.preferential.samplers._gp import PreferentialGPSampler
|
||||
|
||||
from optuna_dashboard import save_note
|
||||
import textwrap
|
||||
from PIL import Image
|
||||
|
||||
|
||||
STORAGE_URL = "sqlite:///st-example.db"
|
||||
@@ -58,7 +54,6 @@ def main() -> NoReturn:
|
||||
trial.set_user_attr("image_caption", f"(R, G, B) = ({r}, {g}, {b})")
|
||||
print("RGB:", (r, g, b))
|
||||
|
||||
|
||||
# 4. Save Note
|
||||
note = textwrap.dedent(
|
||||
f"""\
|
||||
|
||||
@@ -260,7 +260,10 @@ class _PreferentialGP(GPyTorchModel, ExactGP):
|
||||
|
||||
|
||||
def _set_params(
|
||||
module: gpytorch.Module, params_dict: dict[str, torch.Tensor], memo: set | None=None, prefix: str=""
|
||||
module: gpytorch.Module,
|
||||
params_dict: dict[str, torch.Tensor],
|
||||
memo: set | None = None,
|
||||
prefix: str = "",
|
||||
) -> None:
|
||||
if memo is None:
|
||||
memo = set()
|
||||
|
||||
Reference in New Issue
Block a user