metacountregressor 0.1.235__tar.gz → 0.1.236__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.
- {metacountregressor-0.1.235/metacountregressor.egg-info → metacountregressor-0.1.236}/PKG-INFO +1 -1
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/helperprocess.py +26 -2
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/solution.py +12 -8
- {metacountregressor-0.1.235 → metacountregressor-0.1.236/metacountregressor.egg-info}/PKG-INFO +1 -1
- metacountregressor-0.1.236/version.txt +1 -0
- metacountregressor-0.1.235/version.txt +0 -1
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/LICENSE.txt +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/MANIFEST.in +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/README.md +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/README.rst +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/__init__.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/_device_cust.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/app_main.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/data_split_helper.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/halton.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/main.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/main_old.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/metaheuristics.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/pareto_file.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/pareto_logger__plot.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/setup.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/single_objective_finder.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/test_generated_paper2.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/SOURCES.txt +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/dependency_links.txt +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/not-zip-safe +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/requires.txt +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/top_level.txt +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/setup.cfg +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/setup.py +0 -0
- {metacountregressor-0.1.235 → metacountregressor-0.1.236}/tests/test.py +0 -0
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/helperprocess.py
RENAMED
|
@@ -5,8 +5,8 @@ import csv
|
|
|
5
5
|
import matplotlib.pyplot as plt
|
|
6
6
|
from scipy import stats as st
|
|
7
7
|
from sklearn.preprocessing import StandardScaler
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
import os
|
|
9
|
+
import shutil
|
|
10
10
|
plt.style.use('https://github.com/dhaitz/matplotlib-stylesheets/raw/master/pitayasmoothie-dark.mplstyle')
|
|
11
11
|
|
|
12
12
|
|
|
@@ -22,6 +22,30 @@ def generate_param_combinations(param_grid):
|
|
|
22
22
|
combinations = [dict(zip(keys, v)) for v in product(*values)]
|
|
23
23
|
return combinations
|
|
24
24
|
|
|
25
|
+
def delete_all_folders(directory_path):
|
|
26
|
+
try:
|
|
27
|
+
# Check if the directory exists
|
|
28
|
+
if not os.path.exists(directory_path):
|
|
29
|
+
print(f"The directory '{directory_path}' does not exist.")
|
|
30
|
+
return
|
|
31
|
+
|
|
32
|
+
# Iterate through items in the directory
|
|
33
|
+
for item in os.listdir(directory_path):
|
|
34
|
+
item_path = os.path.join(directory_path, item)
|
|
35
|
+
|
|
36
|
+
# Check if the item is a folder
|
|
37
|
+
if os.path.isdir(item_path):
|
|
38
|
+
# Use shutil.rmtree to delete the folder and its contents
|
|
39
|
+
shutil.rmtree(item_path)
|
|
40
|
+
print(f"Deleted folder: {item_path}")
|
|
41
|
+
else:
|
|
42
|
+
print(f"Skipped non-folder item: {item_path}")
|
|
43
|
+
|
|
44
|
+
print("All folders deleted successfully.")
|
|
45
|
+
except Exception as e:
|
|
46
|
+
print(f"An error occurred: {e}")
|
|
47
|
+
|
|
48
|
+
|
|
25
49
|
|
|
26
50
|
##Select the best Features Based on RF
|
|
27
51
|
def select_features(X_train, y_train, n_f=16):
|
|
@@ -215,11 +215,14 @@ class ObjectiveFunction(object):
|
|
|
215
215
|
print('no name set, setting name as 0')
|
|
216
216
|
self.instance_number = str(0) # set an arbitrary instance number
|
|
217
217
|
|
|
218
|
-
if
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
218
|
+
if kwargs.get('save_directory', True):
|
|
219
|
+
self.save_state = True
|
|
220
|
+
if not os.path.exists(self.instance_number):
|
|
221
|
+
if kwargs.get('make_directory', True):
|
|
222
|
+
print('Making a Directory, if you want to stop from storing the files to this directory set argumet: make_directory:False')
|
|
223
|
+
os.makedirs(self.instance_number)
|
|
224
|
+
else:
|
|
225
|
+
self.save_state = False
|
|
223
226
|
if not hasattr(self, '_obj_1'):
|
|
224
227
|
print('_obj_1 required, define as bic, aic, ll')
|
|
225
228
|
raise Exception
|
|
@@ -482,7 +485,7 @@ class ObjectiveFunction(object):
|
|
|
482
485
|
model_types = [[0, 1]] # add 2 for Generalized Poisson
|
|
483
486
|
#model_types = [[0]]
|
|
484
487
|
|
|
485
|
-
if
|
|
488
|
+
if self:
|
|
486
489
|
model_types = [[0]]
|
|
487
490
|
self.grad_yes = False
|
|
488
491
|
|
|
@@ -1228,8 +1231,9 @@ class ObjectiveFunction(object):
|
|
|
1228
1231
|
|
|
1229
1232
|
if save_state:
|
|
1230
1233
|
# print(file_name)
|
|
1231
|
-
self.
|
|
1232
|
-
|
|
1234
|
+
if self.save_state:
|
|
1235
|
+
self.save_to_file(latextable.draw_latex(
|
|
1236
|
+
table, caption=caption, caption_above=True), file_name)
|
|
1233
1237
|
|
|
1234
1238
|
|
|
1235
1239
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
0.1.236
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
0.1.235
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/_device_cust.py
RENAMED
|
File without changes
|
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/data_split_helper.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/metaheuristics.py
RENAMED
|
File without changes
|
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor/pareto_logger__plot.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/not-zip-safe
RENAMED
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/requires.txt
RENAMED
|
File without changes
|
{metacountregressor-0.1.235 → metacountregressor-0.1.236}/metacountregressor.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|