guidepost 0.2.16__tar.gz → 0.2.18__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.
- {guidepost-0.2.16/guidepost.egg-info → guidepost-0.2.18}/PKG-INFO +1 -1
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost/guidepost.py +23 -7
- guidepost-0.2.18/guidepost/version.py +2 -0
- {guidepost-0.2.16 → guidepost-0.2.18/guidepost.egg-info}/PKG-INFO +1 -1
- guidepost-0.2.16/guidepost/version.py +0 -2
- {guidepost-0.2.16 → guidepost-0.2.18}/LICENSE +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/MANIFEST.in +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/README.md +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost/__init__.py +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost/guidepost.js +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost.egg-info/SOURCES.txt +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost.egg-info/dependency_links.txt +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost.egg-info/requires.txt +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/guidepost.egg-info/top_level.txt +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/pyproject.toml +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/setup.cfg +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/setup.py +0 -0
- {guidepost-0.2.16 → guidepost-0.2.18}/tutorials/__init__.py +0 -0
|
@@ -24,11 +24,12 @@ class Guidepost(anywidget.AnyWidget):
|
|
|
24
24
|
in_cpy = in_df.copy()
|
|
25
25
|
in_cpy.insert(0, 'gp_idx', range(0, len(in_cpy)))
|
|
26
26
|
self.cached_records_df = in_cpy
|
|
27
|
+
_warn_skips = (os.path.dirname('.'),)
|
|
28
|
+
warn_supported_version = True
|
|
27
29
|
|
|
28
30
|
if sys.version_info.major < 3 or sys.version_info.minor < 12:
|
|
29
|
-
|
|
31
|
+
warn_supported_version = False
|
|
30
32
|
|
|
31
|
-
_warn_skips = (os.path.dirname('.'),)
|
|
32
33
|
original_cols = in_cpy.columns
|
|
33
34
|
o_df = in_cpy.dropna(axis=1, how='all')
|
|
34
35
|
|
|
@@ -37,7 +38,10 @@ class Guidepost(anywidget.AnyWidget):
|
|
|
37
38
|
if(len(col_diff)>0):
|
|
38
39
|
rmvd_cols = ', '.join(col_diff)
|
|
39
40
|
if(not supress_warnings):
|
|
40
|
-
|
|
41
|
+
if warn_supported_version:
|
|
42
|
+
warnings.warn("The following columns were dropped because they contained entirely 'na' values which guidepost does not support:[{}]".format(rmvd_cols), skip_file_prefixes=_warn_skips)
|
|
43
|
+
else:
|
|
44
|
+
print("Warning: The following columns were dropped because they contained entirely 'na' values which guidepost does not support:[{}]".format(rmvd_cols))
|
|
41
45
|
original_cols = o_df.columns
|
|
42
46
|
|
|
43
47
|
# drop rows where nans are present
|
|
@@ -47,7 +51,10 @@ class Guidepost(anywidget.AnyWidget):
|
|
|
47
51
|
if(row_diff>0):
|
|
48
52
|
rmvd_cols = ', '.join(col_diff)
|
|
49
53
|
if(not supress_warnings):
|
|
50
|
-
|
|
54
|
+
if warn_supported_version:
|
|
55
|
+
warnings.warn("Some rows were dropped because at least one column contained 'na' values which guidepost does not support.", skip_file_prefixes=_warn_skips)
|
|
56
|
+
else:
|
|
57
|
+
print("Warning: Some rows were dropped because at least one column contained 'na' values which guidepost does not support.")
|
|
51
58
|
original_cols = o_df.columns
|
|
52
59
|
|
|
53
60
|
#drop columns which are timedelta type
|
|
@@ -56,7 +63,10 @@ class Guidepost(anywidget.AnyWidget):
|
|
|
56
63
|
if(len(col_diff)>0):
|
|
57
64
|
rmvd_cols = ', '.join(col_diff)
|
|
58
65
|
if(not supress_warnings):
|
|
59
|
-
|
|
66
|
+
if warn_supported_version:
|
|
67
|
+
warnings.warn("The following columns were dropped because they contained 'timedelta' values which guidepost does not support:[{}]".format(rmvd_cols), skip_file_prefixes=_warn_skips)
|
|
68
|
+
else:
|
|
69
|
+
print("Warning: The following columns were dropped because they contained 'timedelta' values which guidepost does not support:[{}]".format(rmvd_cols))
|
|
60
70
|
original_cols = o_df.columns
|
|
61
71
|
|
|
62
72
|
#drop arrays/complex datatypes
|
|
@@ -69,14 +79,20 @@ class Guidepost(anywidget.AnyWidget):
|
|
|
69
79
|
if(len(col_diff)>0):
|
|
70
80
|
rmvd_cols = ', '.join(col_diff)
|
|
71
81
|
if(not supress_warnings):
|
|
72
|
-
|
|
82
|
+
if warn_supported_version:
|
|
83
|
+
warnings.warn("The following columns were dropped because they contained array values in cells which guidepost does not support:[{}]".format(rmvd_cols), skip_file_prefixes=_warn_skips)
|
|
84
|
+
else:
|
|
85
|
+
print("Warning: The following columns were dropped because they contained array values in cells which guidepost does not support:[{}]".format(rmvd_cols))
|
|
73
86
|
original_cols = o_df.columns
|
|
74
87
|
|
|
75
88
|
|
|
76
89
|
#add synthetic index
|
|
77
90
|
if(o_df.shape[0]>250_000):
|
|
78
91
|
if(not supress_warnings):
|
|
79
|
-
|
|
92
|
+
if warn_supported_version:
|
|
93
|
+
warnings.warn("Your dataframe is very large. You may experience performance issues. Consider subsampling or reducing the data down to below 200,000 rows to enhance performance.", skip_file_prefixes=_warn_skips)
|
|
94
|
+
else:
|
|
95
|
+
print("Warning: Your dataframe is very large. You may experience performance issues. Consider subsampling or reducing the data down to below 200,000 rows to enhance performance.")
|
|
80
96
|
|
|
81
97
|
|
|
82
98
|
self.vis_data = o_df.to_dict()
|
|
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
|