@@ -207,7 +207,7 @@ def setup_event_writer(
207207 log_dir : Path ,
208208 experiment_name : str ,
209209 project_name : str = "nerfstudio-project" ,
210- workspace_name : str = None ,
210+ workspace_name : Optional [ str ] = None ,
211211) -> None :
212212 """Initialization of all event writers specified in config
213213 Args:
@@ -218,11 +218,15 @@ def setup_event_writer(
218218 using_event_writer = False
219219
220220 if is_comet_enabled :
221- curr_writer = CometWriter (log_dir = log_dir , experiment_name = experiment_name , project_name = project_name , workspace_name = workspace_name )
221+ curr_writer = CometWriter (
222+ log_dir = log_dir , experiment_name = experiment_name , project_name = project_name , workspace_name = workspace_name
223+ )
222224 EVENT_WRITERS .append (curr_writer )
223225 using_event_writer = True
224226 if is_wandb_enabled :
225- curr_writer = WandbWriter (log_dir = log_dir , experiment_name = experiment_name , project_name = project_name , workspace_name = workspace_name )
227+ curr_writer = WandbWriter (
228+ log_dir = log_dir , experiment_name = experiment_name , project_name = project_name , workspace_name = workspace_name
229+ )
226230 EVENT_WRITERS .append (curr_writer )
227231 using_event_writer = True
228232 if is_tensorboard_enabled :
@@ -306,7 +310,13 @@ def __exit__(self, *args):
306310class WandbWriter (Writer ):
307311 """WandDB Writer Class"""
308312
309- def __init__ (self , log_dir : Path , experiment_name : str , project_name : str = "nerfstudio-project" , workspace_name : str = None ):
313+ def __init__ (
314+ self ,
315+ log_dir : Path ,
316+ experiment_name : str ,
317+ project_name : str = "nerfstudio-project" ,
318+ workspace_name : Optional [str ] = None ,
319+ ):
310320 import wandb # wandb is slow to import, so we only import it if we need it.
311321
312322 opt_args = {
@@ -370,7 +380,13 @@ def write_config(self, name: str, config_dict: Dict[str, Any], step: int):
370380class CometWriter (Writer ):
371381 """Comet_ML Writer Class"""
372382
373- def __init__ (self , log_dir : Path , experiment_name : str , project_name : str = "nerfstudio-project" , workspace_name : str = None ):
383+ def __init__ (
384+ self ,
385+ log_dir : Path ,
386+ experiment_name : str ,
387+ project_name : str = "nerfstudio-project" ,
388+ workspace_name : Optional [str ] = None ,
389+ ):
374390 # comet_ml is slow to import, so we only do it if we need it.
375391 import comet_ml
376392
0 commit comments