-
-
Save mmeendez8/874ea37859b7b93e22ba95dd787335b2 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| def remove_noise(image): | |
| alpha = tf.greater(image[:, :, 3], 50) | |
| alpha = tf.expand_dims(tf.cast(alpha, dtype=tf.uint8), 2) | |
| noise_filtered = tf.multiply(alpha, image) | |
| return noise_filtered[..., :3] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment