mirror of
https://github.com/nerfstudio-project/nerfstudio.git
synced 2026-11-17 21:33:56 +08:00
updated event writing logic/moved save and print to after config set (#502)
* (1) if wandb/tb enabled always eval; (2) move printing of config to after all variables set * (3) save config after everything is set * dont change config; just disable eval with decorator
This commit is contained in:
1 parent
7cf97348ee
commit
0c43e7c4b2
4 files changed
+83
-47
No files matched your search
@@ -61,6 +61,18 @@ def check_viewer_enabled(func: Callable) -> Callable:
|
||||
return wrapper
|
||||
|
||||
|
||||
def check_eval_enabled(func: Callable) -> Callable:
|
||||
"""Decorator: check if evaluation step is enabled"""
|
||||
|
||||
def wrapper(self, *args, **kwargs):
|
||||
ret = None
|
||||
if self.config.logging.event_writer != "none":
|
||||
ret = func(self, *args, **kwargs)
|
||||
return ret
|
||||
|
||||
return wrapper
|
||||
|
||||
|
||||
def check_main_thread(func: Callable) -> Callable:
|
||||
"""Decorator: check if you are on main thread"""
|
||||
|
||||
|
||||
Reference in new issue
Block a user