File tree Expand file tree Collapse file tree 2 files changed +3
-8
lines changed
Expand file tree Collapse file tree 2 files changed +3
-8
lines changed Original file line number Diff line number Diff line change 55 $ cnb-tools --help
66 $ cnb-tools --version
77"""
8+
89from typing import Optional
910from typing_extensions import Annotated
1011import typer
Original file line number Diff line number Diff line change 1- from typing import Union
2-
31from pandas import Series
42
53
@@ -100,9 +98,7 @@ def check_nan_values(pred_col: Series) -> str:
10098 return ""
10199
102100
103- def check_binary_values (
104- pred_col : Series , label1 : int = 0 , label2 : int = 1
105- ) -> str :
101+ def check_binary_values (pred_col : Series , label1 : int = 0 , label2 : int = 1 ) -> str :
106102 """Check that values are binary (default: 0 or 1).
107103
108104 Tip: Example Use Case
@@ -123,9 +119,7 @@ def check_binary_values(
123119
124120
125121def check_values_range (
126- pred_col : Series ,
127- min_val : Union [int , float ] = 0 ,
128- max_val : Union [int , float ] = 1
122+ pred_col : Series , min_val : int | float = 0 , max_val : int | float = 1
129123) -> str :
130124 """Check that values are between min and max values, inclusive.
131125
You can’t perform that action at this time.
0 commit comments