omniopt2 8929__tar.gz → 8934__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of omniopt2 might be problematic. Click here for more details.

Files changed (41) hide show
  1. {omniopt2-8929 → omniopt2-8934}/.omniopt.py +35 -33
  2. {omniopt2-8929 → omniopt2-8934}/PKG-INFO +1 -1
  3. {omniopt2-8929 → omniopt2-8934}/omniopt2.egg-info/PKG-INFO +1 -1
  4. {omniopt2-8929 → omniopt2-8934}/pyproject.toml +1 -1
  5. {omniopt2-8929 → omniopt2-8934}/.colorfunctions.sh +0 -0
  6. {omniopt2-8929 → omniopt2-8934}/.dockerignore +0 -0
  7. {omniopt2-8929 → omniopt2-8934}/.general.sh +0 -0
  8. {omniopt2-8929 → omniopt2-8934}/.gitignore +0 -0
  9. {omniopt2-8929 → omniopt2-8934}/.helpers.py +0 -0
  10. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_cpu_ram_usage.py +0 -0
  11. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_general.py +0 -0
  12. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_gpu_usage.py +0 -0
  13. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_kde.py +0 -0
  14. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_scatter.py +0 -0
  15. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_scatter_generation_method.py +0 -0
  16. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_scatter_hex.py +0 -0
  17. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_time_and_exit_code.py +0 -0
  18. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_trial_index_result.py +0 -0
  19. {omniopt2-8929 → omniopt2-8934}/.omniopt_plot_worker.py +0 -0
  20. {omniopt2-8929 → omniopt2-8934}/.pareto.py +0 -0
  21. {omniopt2-8929 → omniopt2-8934}/.random_generator.py +0 -0
  22. {omniopt2-8929 → omniopt2-8934}/.shellscript_functions +0 -0
  23. {omniopt2-8929 → omniopt2-8934}/.tests/pylint.rc +0 -0
  24. {omniopt2-8929 → omniopt2-8934}/.tpe.py +0 -0
  25. {omniopt2-8929 → omniopt2-8934}/LICENSE +0 -0
  26. {omniopt2-8929 → omniopt2-8934}/MANIFEST.in +0 -0
  27. {omniopt2-8929 → omniopt2-8934}/README.md +0 -0
  28. {omniopt2-8929 → omniopt2-8934}/apt-dependencies.txt +0 -0
  29. {omniopt2-8929 → omniopt2-8934}/omniopt +0 -0
  30. {omniopt2-8929 → omniopt2-8934}/omniopt2.egg-info/SOURCES.txt +0 -0
  31. {omniopt2-8929 → omniopt2-8934}/omniopt2.egg-info/dependency_links.txt +0 -0
  32. {omniopt2-8929 → omniopt2-8934}/omniopt2.egg-info/requires.txt +0 -0
  33. {omniopt2-8929 → omniopt2-8934}/omniopt2.egg-info/top_level.txt +0 -0
  34. {omniopt2-8929 → omniopt2-8934}/omniopt_docker +0 -0
  35. {omniopt2-8929 → omniopt2-8934}/omniopt_evaluate +0 -0
  36. {omniopt2-8929 → omniopt2-8934}/omniopt_plot +0 -0
  37. {omniopt2-8929 → omniopt2-8934}/omniopt_share +0 -0
  38. {omniopt2-8929 → omniopt2-8934}/requirements.txt +0 -0
  39. {omniopt2-8929 → omniopt2-8934}/setup.cfg +0 -0
  40. {omniopt2-8929 → omniopt2-8934}/setup.py +0 -0
  41. {omniopt2-8929 → omniopt2-8934}/test_requirements.txt +0 -0
@@ -3943,7 +3943,7 @@ def _add_to_csv_acquire_lock(lockfile: str, dir_path: str) -> bool:
3943
3943
  time.sleep(wait_time)
3944
3944
  max_wait -= wait_time
3945
3945
  except Exception as e:
3946
- print("Lock error:", e)
3946
+ print_red(f"Lock error: {e}")
3947
3947
  return False
3948
3948
  return False
3949
3949
 
@@ -4016,12 +4016,12 @@ def find_file_paths(_text: str) -> List[str]:
4016
4016
  def check_file_info(file_path: str) -> str:
4017
4017
  if not os.path.exists(file_path):
4018
4018
  if not args.tests:
4019
- print(f"check_file_info: The file {file_path} does not exist.")
4019
+ print_red(f"check_file_info: The file {file_path} does not exist.")
4020
4020
  return ""
4021
4021
 
4022
4022
  if not os.access(file_path, os.R_OK):
4023
4023
  if not args.tests:
4024
- print(f"check_file_info: The file {file_path} is not readable.")
4024
+ print_red(f"check_file_info: The file {file_path} is not readable.")
4025
4025
  return ""
4026
4026
 
4027
4027
  file_stat = os.stat(file_path)
@@ -4135,7 +4135,7 @@ def count_defective_nodes(file_path: Union[str, None] = None, entry: Any = None)
4135
4135
  return sorted(set(entries))
4136
4136
 
4137
4137
  except Exception as e:
4138
- print(f"An error has occurred: {e}")
4138
+ print_red(f"An error has occurred: {e}")
4139
4139
  return []
4140
4140
 
4141
4141
  def test_gpu_before_evaluate(return_in_case_of_error: dict) -> Union[None, dict]:
@@ -4146,7 +4146,7 @@ def test_gpu_before_evaluate(return_in_case_of_error: dict) -> Union[None, dict]
4146
4146
 
4147
4147
  fool_linter(tmp)
4148
4148
  except RuntimeError:
4149
- print(f"Node {socket.gethostname()} was detected as faulty. It should have had a GPU, but there is an error initializing the CUDA driver. Adding this node to the --exclude list.")
4149
+ print_red(f"Node {socket.gethostname()} was detected as faulty. It should have had a GPU, but there is an error initializing the CUDA driver. Adding this node to the --exclude list.")
4150
4150
  count_defective_nodes(None, socket.gethostname())
4151
4151
  return return_in_case_of_error
4152
4152
  except Exception:
@@ -4856,7 +4856,7 @@ def replace_string_with_params(input_string: str, params: list) -> str:
4856
4856
  return replaced_string
4857
4857
  except AssertionError as e:
4858
4858
  error_text = f"Error in replace_string_with_params: {e}"
4859
- print(error_text)
4859
+ print_red(error_text)
4860
4860
  raise
4861
4861
 
4862
4862
  return ""
@@ -5133,9 +5133,7 @@ def get_sixel_graphics_data(_pd_csv: str, _force: bool = False) -> list:
5133
5133
  _params = [_command, plot, _tmp, plot_type, tmp_file, _width]
5134
5134
  data.append(_params)
5135
5135
  except Exception as e:
5136
- tb = traceback.format_exc()
5137
- print_red(f"Error trying to print {plot_type} to CLI: {e}, {tb}")
5138
- print_debug(f"Error trying to print {plot_type} to CLI: {e}")
5136
+ print_red(f"Error trying to print {plot_type} to CLI: {e}")
5139
5137
 
5140
5138
  return data
5141
5139
 
@@ -5336,8 +5334,7 @@ def abandon_job(job: Job, trial_index: int, reason: str) -> bool:
5336
5334
  else:
5337
5335
  _fatal_error("ax_client could not be found", 101)
5338
5336
  except Exception as e:
5339
- print(f"ERROR in line {get_line_info()}: {e}")
5340
- print_debug(f"ERROR in line {get_line_info()}: {e}")
5337
+ print_red(f"ERROR in line {get_line_info()}: {e}")
5341
5338
  return False
5342
5339
  job.cancel()
5343
5340
  return True
@@ -5386,7 +5383,7 @@ def end_program(_force: Optional[bool] = False, exit_code: Optional[int] = None)
5386
5383
  _exit = new_exit
5387
5384
  except (SignalUSR, SignalINT, SignalCONT, KeyboardInterrupt):
5388
5385
  print_red("\n⚠ You pressed CTRL+C or a signal was sent. Program execution halted while ending program.")
5389
- print("\n⚠ KeyboardInterrupt signal was sent. Ending program will still run.")
5386
+ print_red("\n⚠ KeyboardInterrupt signal was sent. Ending program will still run.")
5390
5387
  new_exit = show_end_table_and_save_end_files()
5391
5388
  if new_exit > 0:
5392
5389
  _exit = new_exit
@@ -5420,9 +5417,9 @@ def save_ax_client_to_json_file(checkpoint_filepath: str) -> None:
5420
5417
  def save_checkpoint(trial_nr: int = 0, eee: Union[None, str, Exception] = None) -> None:
5421
5418
  if trial_nr > 3:
5422
5419
  if eee:
5423
- print(f"Error during saving checkpoint: {eee}")
5420
+ print_red(f"Error during saving checkpoint: {eee}")
5424
5421
  else:
5425
- print("Error during saving checkpoint")
5422
+ print_red("Error during saving checkpoint")
5426
5423
  return
5427
5424
 
5428
5425
  try:
@@ -5592,7 +5589,7 @@ def parse_equation_item(comparer_found: bool, item: str, parsed: list, parsed_or
5592
5589
  })
5593
5590
  elif item in [">=", "<="]:
5594
5591
  if comparer_found:
5595
- print("There is already one comparison operator! Cannot have more than one in an equation!")
5592
+ print_red("There is already one comparison operator! Cannot have more than one in an equation!")
5596
5593
  return_totally = True
5597
5594
  comparer_found = True
5598
5595
 
@@ -6280,7 +6277,6 @@ def parse_single_experiment_parameter_table(classic_params: Optional[Union[list,
6280
6277
  _upper = param["bounds"][1]
6281
6278
 
6282
6279
  _possible_int_lower = str(helpers.to_int_when_possible(_lower))
6283
- #print(f"name: {_name}, _possible_int_lower: {_possible_int_lower}, lower: {_lower}")
6284
6280
  _possible_int_upper = str(helpers.to_int_when_possible(_upper))
6285
6281
 
6286
6282
  rows.append([_name, _short_type, _possible_int_lower, _possible_int_upper, "", value_type, log_scale])
@@ -6513,7 +6509,7 @@ def update_progress_bar(nr: int) -> None:
6513
6509
  try:
6514
6510
  progress_bar.update(nr)
6515
6511
  except Exception as e:
6516
- print(f"Error updating progress bar: {e}")
6512
+ print_red(f"Error updating progress bar: {e}")
6517
6513
  else:
6518
6514
  print_red("update_progress_bar: progress_bar was None")
6519
6515
 
@@ -6953,7 +6949,7 @@ def get_generation_node_for_index(
6953
6949
 
6954
6950
  return generation_node
6955
6951
  except Exception as e:
6956
- print(f"Error while get_generation_node_for_index: {e}")
6952
+ print_red(f"Error while get_generation_node_for_index: {e}")
6957
6953
  return "MANUAL"
6958
6954
 
6959
6955
  def _get_generation_node_for_index_index_valid(
@@ -7568,7 +7564,7 @@ def get_parameters_from_outfile(stdout_path: str) -> Union[None, dict, str]:
7568
7564
  if not args.tests:
7569
7565
  original_print(f"get_parameters_from_outfile: The file '{stdout_path}' was not found.")
7570
7566
  except Exception as e:
7571
- print(f"get_parameters_from_outfile: There was an error: {e}")
7567
+ print_red(f"get_parameters_from_outfile: There was an error: {e}")
7572
7568
 
7573
7569
  return None
7574
7570
 
@@ -7586,7 +7582,7 @@ def get_hostname_from_outfile(stdout_path: Optional[str]) -> Optional[str]:
7586
7582
  original_print(f"The file '{stdout_path}' was not found.")
7587
7583
  return None
7588
7584
  except Exception as e:
7589
- print(f"There was an error: {e}")
7585
+ print_red(f"There was an error: {e}")
7590
7586
  return None
7591
7587
 
7592
7588
  def add_to_global_error_list(msg: str) -> None:
@@ -7649,7 +7645,7 @@ def check_valid_result(result: Union[None, dict]) -> bool:
7649
7645
  else:
7650
7646
  values.append(obj)
7651
7647
  except Exception as e:
7652
- print(f"Error while flattening values: {e}")
7648
+ print_red(f"Error while flattening values: {e}")
7653
7649
  return values
7654
7650
 
7655
7651
  if result is None:
@@ -7662,7 +7658,7 @@ def check_valid_result(result: Union[None, dict]) -> bool:
7662
7658
  return False
7663
7659
  return True
7664
7660
  except Exception as e:
7665
- print(f"Error while checking result validity: {e}")
7661
+ print_red(f"Error while checking result validity: {e}")
7666
7662
  return False
7667
7663
 
7668
7664
  def update_ax_client_trial(trial_idx: int, result: Union[list, dict]) -> None:
@@ -7798,7 +7794,7 @@ def finish_job_core(job: Any, trial_index: int, this_jobs_finished: int) -> int:
7798
7794
  if len(arg_result_names) > 1 and count_done_jobs() > 1 and not job_calculate_pareto_front(get_current_run_folder(), True):
7799
7795
  print_red("job_calculate_pareto_front post job failed")
7800
7796
  except Exception as e:
7801
- print(f"ERROR in line {get_line_info()}: {e}")
7797
+ print_red(f"ERROR in line {get_line_info()}: {e}")
7802
7798
  else:
7803
7799
  _finish_job_core_helper_mark_failure(job, trial_index, _trial)
7804
7800
  else:
@@ -8137,7 +8133,7 @@ def handle_restart(stdout_path: str, trial_index: int) -> None:
8137
8133
  if parameters:
8138
8134
  orchestrator_start_trial(parameters, trial_index)
8139
8135
  else:
8140
- print(f"Could not determine parameters from outfile {stdout_path} for restarting job")
8136
+ print_red(f"Could not determine parameters from outfile {stdout_path} for restarting job")
8141
8137
 
8142
8138
  def check_alternate_path(path: str) -> str:
8143
8139
  if os.path.exists(path):
@@ -8333,7 +8329,7 @@ def cancel_failed_job(trial_index: int, new_job: Job) -> None:
8333
8329
  else:
8334
8330
  _fatal_error("ax_client not defined", 101)
8335
8331
  except Exception as e:
8336
- print(f"ERROR in line {get_line_info()}: {e}")
8332
+ print_red(f"ERROR in line {get_line_info()}: {e}")
8337
8333
  new_job.cancel()
8338
8334
 
8339
8335
  print_debug(f"cancel_failed_job: removing job {new_job}, trial_index: {trial_index}")
@@ -8633,7 +8629,7 @@ def mark_abandoned(trial: Any, reason: str, trial_index: int) -> None:
8633
8629
  print_debug(f"[INFO] Marking trial {trial.index} ({trial.arm.name}) as abandoned, trial-index: {trial_index}. Reason: {reason}")
8634
8630
  trial.mark_abandoned(reason)
8635
8631
  except Exception as e:
8636
- print(f"[ERROR] Could not mark trial as abandoned: {e}")
8632
+ print_red(f"[ERROR] Could not mark trial as abandoned: {e}")
8637
8633
 
8638
8634
  def create_and_handle_trial(arm: Any) -> Optional[Tuple[int, float, bool]]:
8639
8635
  if ax_client is None:
@@ -9160,10 +9156,10 @@ def parse_generation_strategy_string(gen_strat_str: str) -> tuple[list[dict[str,
9160
9156
 
9161
9157
  for s in splitted_by_comma:
9162
9158
  if "=" not in s:
9163
- print(f"'{s}' does not contain '='")
9159
+ print_red(f"'{s}' does not contain '='")
9164
9160
  my_exit(123)
9165
9161
  if s.count("=") != 1:
9166
- print(f"There can only be one '=' in the gen_strat_str's element '{s}'")
9162
+ print_red(f"There can only be one '=' in the gen_strat_str's element '{s}'")
9167
9163
  my_exit(123)
9168
9164
 
9169
9165
  model_name, nr_str = s.split("=")
@@ -9173,13 +9169,13 @@ def parse_generation_strategy_string(gen_strat_str: str) -> tuple[list[dict[str,
9173
9169
  _fatal_error(f"Model {matching_model} is not valid for custom generation strategy.", 56)
9174
9170
 
9175
9171
  if not matching_model:
9176
- print(f"'{model_name}' not found in SUPPORTED_MODELS")
9172
+ print_red(f"'{model_name}' not found in SUPPORTED_MODELS")
9177
9173
  my_exit(123)
9178
9174
 
9179
9175
  try:
9180
9176
  nr = int(nr_str)
9181
9177
  except ValueError:
9182
- print(f"Invalid number of generations '{nr_str}' for model '{model_name}'")
9178
+ print_red(f"Invalid number of generations '{nr_str}' for model '{model_name}'")
9183
9179
  my_exit(123)
9184
9180
 
9185
9181
  gen_strat_list.append({matching_model: nr})
@@ -9736,7 +9732,7 @@ def execute_nvidia_smi() -> None:
9736
9732
  if not host:
9737
9733
  print_debug("host not defined")
9738
9734
  except Exception as e:
9739
- print(f"execute_nvidia_smi: An error occurred: {e}")
9735
+ print_red(f"execute_nvidia_smi: An error occurred: {e}")
9740
9736
  if is_slurm_job() and not args.force_local_execution:
9741
9737
  _sleep(30)
9742
9738
 
@@ -9907,7 +9903,7 @@ def parse_orchestrator_file(_f: str, _test: bool = False) -> Union[dict, None]:
9907
9903
 
9908
9904
  return data
9909
9905
  except Exception as e:
9910
- print(f"Error while parse_experiment_parameters({_f}): {e}")
9906
+ print_red(f"Error while parse_experiment_parameters({_f}): {e}")
9911
9907
  else:
9912
9908
  print_red(f"{_f} could not be found")
9913
9909
 
@@ -9975,7 +9971,7 @@ def save_experiment_state() -> None:
9975
9971
  def wait_for_state_file(state_path: str, min_size: int = 5, max_wait_seconds: int = 60) -> bool:
9976
9972
  try:
9977
9973
  if not os.path.exists(state_path):
9978
- print(f"[ERROR] File '{state_path}' does not exist.")
9974
+ print_debug(f"[ERROR] File '{state_path}' does not exist.")
9979
9975
  return False
9980
9976
 
9981
9977
  i = 0
@@ -10653,6 +10649,12 @@ def show_omniopt_call() -> None:
10653
10649
 
10654
10650
  original_print(oo_call + " " + cleaned)
10655
10651
 
10652
+ if args.dependency is not None and args.dependency != "":
10653
+ print(f"Dependency: {args.dependency}")
10654
+
10655
+ if args.ui_url is not None and args.ui_url != "":
10656
+ print_yellow("--ui_url is deprecated. Do not use it anymore. It will be ignored and one day be removed.")
10657
+
10656
10658
  def main() -> None:
10657
10659
  global RESULT_CSV_FILE, LOGFILE_DEBUG_GET_NEXT_TRIALS
10658
10660
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: omniopt2
3
- Version: 8929
3
+ Version: 8934
4
4
  Summary: Automatic highly parallelized hyperparameter optimizer based on Ax/Botorch
5
5
  Home-page: https://scads.ai/transfer-2/verfuegbare-software-dienste-en/omniopt/
6
6
  Author: Norman Koch
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: omniopt2
3
- Version: 8929
3
+ Version: 8934
4
4
  Summary: Automatic highly parallelized hyperparameter optimizer based on Ax/Botorch
5
5
  Home-page: https://scads.ai/transfer-2/verfuegbare-software-dienste-en/omniopt/
6
6
  Author: Norman Koch
@@ -5,7 +5,7 @@ authors = [
5
5
  {email = "norman.koch@tu-dresden.de"},
6
6
  {name = "Norman Koch"}
7
7
  ]
8
- version = "8929"
8
+ version = "8934"
9
9
 
10
10
  readme = "README.md"
11
11
  dynamic = ["dependencies"]
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes