Coder Social home page Coder Social logo

optuna create-study --storage $STORAGE_URL raises RuntimeError: The runtime optuna version 3.6.0 is no longer compatible with the table schema (set up by optuna 3.6.0). Please try updating optuna to the latest version by `$ pip install -U optuna`. about optuna HOT 7 CLOSED

scls19fr avatar scls19fr commented on May 31, 2024
optuna create-study --storage $STORAGE_URL raises RuntimeError: The runtime optuna version 3.6.0 is no longer compatible with the table schema (set up by optuna 3.6.0). Please try updating optuna to the latest version by `$ pip install -U optuna`.

from optuna.

Comments (7)

scls19fr avatar scls19fr commented on May 31, 2024 3

There was some tables from mlflow.
I will try with a clean database and let you know.
Maybe using table prefix could help.

from optuna.

scls19fr avatar scls19fr commented on May 31, 2024

I also tried the following command:

# optuna storage upgrade --storage $STORAGE_URL

which raised a warning

workspaces/optuna/cli.py:744: UserWarning: Your optuna version seems outdated against the storage version. Please try updating optuna to the latest version by `$ pip install -U optuna`.

and

# optuna create-study --storage $STORAGE_URL

still raises same RuntimeError

from optuna.

nzw0301 avatar nzw0301 commented on May 31, 2024

Is there any tables in the database when you ran optuna create-study? Can you create a database from scratch?

from optuna.

scls19fr avatar scls19fr commented on May 31, 2024

I can confirm that this problem doesn't occur with a separate database just for optuna.

from optuna.

nzw0301 avatar nzw0301 commented on May 31, 2024

Thanks. I think database for optuna should not contain MLFlow's schema. So I don't think the reported issue is not the bug of optuna.

I had a similar example with SQLite:

rm -rf mlruns.db
export MLFLOW_TRACKING_URI=sqlite:///mlruns.db

python mlflow_example.py
optuna create-study --storage $MLFLOW_TRACKING_URI
# Same error message

The python script for mlflow, which is a copied from https://mlflow.org/docs/latest/tracking/tutorials/local-database.html.

import mlflow

from sklearn.model_selection import train_test_split
from sklearn.datasets import load_diabetes
from sklearn.ensemble import RandomForestRegressor

mlflow.sklearn.autolog()

db = load_diabetes()
X_train, X_test, y_train, y_test = train_test_split(db.data, db.target)

# Create and train models.
rf = RandomForestRegressor(n_estimators=100, max_depth=6, max_features=3)
rf.fit(X_train, y_train)

# Use the model to make predictions on the test dataset.
predictions = rf.predict(X_test)

from optuna.

scls19fr avatar scls19fr commented on May 31, 2024

With table prefix this kind of problem should probably be avoided. Maybe that's something which should be considered. Closing for now

from optuna.

moleary-gsa avatar moleary-gsa commented on May 31, 2024

How do we use a table prefix? It doesn't mention it here or here

from optuna.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.