Created
September 12, 2022 07:17
-
-
Save FrancescAlted/262993a98e6b9e34f8b6cc4d436a4595 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@udf.scalar() | |
def square_filter(val: udf.float32) -> udf.float32: | |
if val >= 0.5: | |
return 1. | |
return math.nan |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment