You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So, I tried to change the datatype of each operand and checked errors.
First, I changed the type of perturbation from tf.float32 to tf.float64 with tf.cast. But I got an OOM error.
And then, It was solved by changing the type of self.kernel_centers from tf.float64 to tf.float32.
I want to know this modification has no problem.
What do you think about this case?
The text was updated successfully, but these errors were encountered:
Can you show us the full code and the full stack-trace? Generally with tensorflow and torch frameworks, all tensors should be float32 by default, so I'm curious how the "was expected to be a double tensor" can happen.
Note that in our example notebook the data is cast to np.float32 before doing anything else (cell 4), this ensures that any further operations produce float32 tensors.
Is this something we need to document better across the library? @ojcobb@ascillitoe
Thank you very much. I got it. I will convert data type tp np.float32 for
the input of the detector.
2023년 5월 26일 (금) 오후 7:33, Janis Klaise ***@***.***>님이 작성:
Hi,
When I run drift detection with LSDDOnlineDrift class, the following error occurred.
[Error Message]
InvalidArgumentError: cannot compute AddV2 as input #1(zero-based) was expected to be a double tensor but is a float tensor [Op:AddV2]
[Code]
perturbation = tf.random.normal(self.kernel_centers.shape, mean=0, stddev=1e-6)
self.kernel_centers = self.kernel_centers + perturbation
So, I tried to change the datatype of each operand and checked errors.
First, I changed the type of perturbation from tf.float32 to tf.float64 with tf.cast. But I got an OOM error.
And then, It was solved by changing the type of self.kernel_centers from tf.float64 to tf.float32.
I want to know this modification has no problem.
What do you think about this case?
The text was updated successfully, but these errors were encountered: