Comments (5)
Hi, can you give us a minimal example to reproduce this error? I'm wondering if your application is too concurrent-intensive: https://stackoverflow.com/questions/3172929/operationalerror-database-is-locked
So far, all of our unit tests pass, so we haven't encountered this error before.
from vizier.
Thanks @xingyousong
I am using the simple cookie example from vizier demo (code below).
from vizier import service
from vizier.service import clients
from vizier.service import pyvizier as vz
problem = vz.ProblemStatement()
problem.search_space.root.add_float_param('chocolate', 0.0, 1.0)
problem.metric_information.append(vz.MetricInformation(name='taste', goal=vz.ObjectiveMetricGoal.MAXIMIZE))
def evaluate(chocolate: float) -> float:
return 1-2*(chocolate -.3)**2
study_config = vz.StudyConfig.from_problem(problem)
study_config.algorithm = 'GAUSSIAN_PROCESS_BANDIT'
study_client = clients.Study.from_study_config(study_config, owner='bhawandeepsingh', study_id='cookie_study_0')
print('****************Local SQL database file located at: ', service.VIZIER_DB_PATH)
for _ in range(1) :
suggestions = study_client.suggest(count=1)
for suggestion in suggestions :
chocolate = suggestion.parameters['chocolate']
objective = evaluate(chocolate)
print (chocolate, objective)
final_measurement = vz.Measurement({'taste': objective})
suggestion.complete(final_measurement)
I am using Ubuntu 22.04 and Python 3.10.12
Please let me know if any additional information can help you to find the root cause and I will provide it. Thanks
from vizier.
I just tried your code in colab (after installing with !pip install google-vizier[jax]
) and everything worked fine. Can you make sure you have a fresh install (and even fresh colab kernel) when you execute that code snippet?
from vizier.
The Vizier server is using an in memory SQLITE database, so restarting the Colab runtime should solve this issue, or a fresh Colab runtime as Richard suggested above.
Best,
Sagi
from vizier.
Works in collab as specified.
from vizier.
Related Issues (20)
- Pakage Installition HOT 1
- pip install google-vizier[jax] failed HOT 9
- How much (continous) variables can the optimizer handle in practice HOT 2
- QUASI_RANDOM_SEARCH no work HOT 4
- Desktop responsiveness
- Getting `UnparsedFlagAccessError` with example code HOT 6
- Bug: broken hyperlink to the policy factory
- Python 3.8: field() got an unexpected keyword argument 'kw_only' HOT 4
- sqlalchemy requeriment is too strict HOT 1
- [Bug] suggest() of EagleStrategyDesigner will raise AttributeError: 'float' object has no attribute 'flatten' HOT 4
- Seeding the Random Number Generators? HOT 2
- Add weight to MetricInformation HOT 1
- Getting started example error HOT 3
- SQLAlchemy maximum precludes using Pandas
- Test from README fails HOT 2
- How to run "evaluate" function offline ? HOT 6
- pyglove/backend.py: possible dependency on internal google vizier module? HOT 1
- PyGlove interface errors with google-vizier 0.1.13 HOT 11
- How to set the port for Default Vizier Server
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vizier.