Skip to content

Commit

Permalink
remove unneeded casting
Browse files Browse the repository at this point in the history
  • Loading branch information
atl1502 committed Feb 8, 2024
1 parent 2ff6c6b commit daf604b
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions dataprofiler/profilers/numerical_column_stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -1810,8 +1810,6 @@ def _get_min(
else:
df_series = pl.from_pandas(df_series)
min_value = df_series.min()
if self.min is not None:
min_value = type(self.min)(min_value)
self.min = np.float64(
min_value if not self.min else min(self.min, min_value)
)
Expand Down Expand Up @@ -1890,15 +1888,13 @@ def _get_variance(
batch_count = subset_properties["match_count"]
batch_mean = 0.0 if not batch_count else float(sum_value) / batch_count
subset_properties["mean"] = batch_mean
self._biased_variance = np.float64(
self._merge_biased_variance(
self.match_count,
self._biased_variance,
prev_dependent_properties["mean"],
batch_count,
batch_biased_variance,
batch_mean,
)
self._biased_variance = self._merge_biased_variance(
self.match_count,
self._biased_variance,
prev_dependent_properties["mean"],
batch_count,
batch_biased_variance,
batch_mean,
)

@BaseColumnProfiler._timeit(name="skewness")
Expand Down

0 comments on commit daf604b

Please sign in to comment.