Skip to content

Commit

Permalink
Update tune init (#29)
Browse files Browse the repository at this point in the history
* update

* update

* update

* update

* update

* update
  • Loading branch information
goodwanghan authored May 11, 2021
1 parent b107111 commit 5925084
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ Fugue for Kaggle users

## Release History

### 0.2.8

* Update tune init

### 0.2.7

* Update fugue and tune versions
Expand Down
6 changes: 5 additions & 1 deletion fuggle/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

def setup(default_engine: str = "") -> Any:
TUNE_OBJECT_FACTORY.set_temp_path("/tmp")
TUNE_OBJECT_FACTORY.set_noniterative_objective_runner_converter(_to_runner)
TUNE_OBJECT_FACTORY.set_noniterative_local_optimizer_converter(_to_runner)
TUNE_OBJECT_FACTORY.set_monitor_converter(_to_monitor)

# we no longer enable SQL highlighting, kaggle has changed
Expand All @@ -35,12 +35,16 @@ def setup(default_engine: str = "") -> Any:
def _to_runner(obj: Any) -> Optional[NonIterativeObjectiveLocalOptimizer]:
if obj is None:
return HyperoptLocalOptimizer(20, 0)
if isinstance(obj, NonIterativeObjectiveLocalOptimizer):
return obj
raise NotImplementedError(obj)


def _to_monitor(obj: Any) -> Optional[Monitor]:
if obj is None:
return None
if isinstance(obj, Monitor):
return obj
if isinstance(obj, str):
if obj == "hist":
return NotebookSimpleHist()
Expand Down
2 changes: 1 addition & 1 deletion fuggle_version/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.2.7"
__version__ = "0.2.8"

0 comments on commit 5925084

Please sign in to comment.