Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions tidy3d/web/api/container.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
DEFAULT_NUM_WORKERS = 10
DEFAULT_DATA_PATH = "simulation_data.hdf5"
DEFAULT_DATA_DIR = "."
BATCH_MONITOR_PROGRESS_REFRESH_TIME = 0.02
BATCH_PROGRESS_REFRESH_TIME = 0.02

BatchCategoryType = Literal[
"tidy3d",
Expand Down Expand Up @@ -839,6 +839,9 @@ def upload(self) -> None:
completed += 1
progress.update(pbar, completed=completed)

progress.refresh()
time.sleep(BATCH_PROGRESS_REFRESH_TIME)

def get_info(self) -> dict[TaskName, TaskInfo]:
"""Get information about each task in the :class:`Batch`.

Expand Down Expand Up @@ -1070,7 +1073,7 @@ def pbar_description(
progress.update(pbar, description=desc, completed=pct)

progress.refresh()
time.sleep(BATCH_MONITOR_PROGRESS_REFRESH_TIME)
time.sleep(BATCH_PROGRESS_REFRESH_TIME)

# final render to terminal state for all bars
for task_name, job in self.jobs.items():
Expand Down
2 changes: 0 additions & 2 deletions tidy3d/web/api/tidy3d_stub.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,8 +308,6 @@ def postprocess(cls, file_path: str, lazy: bool = True) -> WorkflowDataType:
stub_data = Tidy3dStubData.from_file(
file_path, lazy=lazy, on_load=cls._check_convergence_and_warnings
)
if not lazy:
cls._check_convergence_and_warnings(stub_data)
return stub_data

@staticmethod
Expand Down
Loading