Skip to content

Commit

Permalink
removing tf.keras dependency (#771)
Browse files Browse the repository at this point in the history
* removing tf.keras dependency

* removing tf.keras dependency

* removing tf.keras dependency

* removing tf.keras dependency
  • Loading branch information
asingh9530 authored Aug 22, 2023
1 parent e6a39ba commit 675652e
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions keras_core/layers/preprocessing/hashed_crossing_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,9 +145,7 @@ def test_tf_string(self):
outputs = layer((feat1, feat2))
self.assertAllClose(outputs, 1)

layer = tf.keras.layers.HashedCrossing(
num_bins=5, output_mode="one_hot"
)
layer = layers.HashedCrossing(num_bins=5, output_mode="one_hot")
feat1 = tf.constant(["A", "B", "A", "B", "A"])
feat2 = tf.constant([101, 101, 101, 102, 102])
self.assertAllClose(
Expand All @@ -163,7 +161,7 @@ def test_tf_string(self):
layer((feat1, feat2)),
)

layer = tf.keras.layers.HashedCrossing(num_bins=5)
layer = layers.HashedCrossing(num_bins=5)
feat1 = tf.constant(["A", "B", "A", "B", "A"])
feat2 = tf.constant([101, 101, 101, 102, 102])
self.assertAllClose(tf.constant([1, 4, 1, 1, 3]), layer((feat1, feat2)))
Expand Down

0 comments on commit 675652e

Please sign in to comment.