Update Eigen to
f93841b53e
PiperOrigin-RevId: 335147393
Change-Id: I0ed4e283c551e5a96c85b40300243403b09428e7
This commit is contained in:
parent
0f7d38ba0e
commit
4fa8162dd8
tensorflow
@ -131,8 +131,8 @@ SpatialMaxPooling(const Input& input, DenseIndex patchRows,
|
||||
.extract_image_patches(
|
||||
patchRows, patchCols, strideRows, strideCols, in_strideRows,
|
||||
in_strideCols, padding_type,
|
||||
-Eigen::NumTraits<typename internal::remove_const<
|
||||
typename internal::traits<Input>::Scalar>::type>::highest())
|
||||
Eigen::NumTraits<typename internal::remove_const<
|
||||
typename internal::traits<Input>::Scalar>::type>::lowest())
|
||||
.maximum(reduction_dims)
|
||||
.reshape(post_reduce_dims);
|
||||
}
|
||||
|
@ -43,7 +43,8 @@ namespace tensorflow {
|
||||
// We have to be able to detect and handle overflows in int32, so this function
|
||||
// uses doubles and int64's to make sure we have enough room.
|
||||
template <class T>
|
||||
int64 FloatToQuantizedUnclamped(float input, float range_min, float range_max) {
|
||||
inline int64 FloatToQuantizedUnclamped(float input, float range_min,
|
||||
float range_max) {
|
||||
const int64 lowest_quantized =
|
||||
static_cast<double>(Eigen::NumTraits<T>::lowest());
|
||||
if (range_min == range_max) {
|
||||
@ -60,6 +61,12 @@ int64 FloatToQuantizedUnclamped(float input, float range_min, float range_max) {
|
||||
return quantized;
|
||||
}
|
||||
|
||||
template <>
|
||||
inline int64 FloatToQuantizedUnclamped<float>(float input, float range_min,
|
||||
float range_max) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
// This converts the float into the final quantized type, clamping/saturating
|
||||
// any over or underflows.
|
||||
template <class T>
|
||||
|
@ -1288,7 +1288,7 @@ def mean_squared_logarithmic_error(y_true, y_pred):
|
||||
>>> assert loss.shape == (2,)
|
||||
>>> y_true = np.maximum(y_true, 1e-7)
|
||||
>>> y_pred = np.maximum(y_pred, 1e-7)
|
||||
>>> assert np.array_equal(
|
||||
>>> assert np.allclose(
|
||||
... loss.numpy(),
|
||||
... np.mean(
|
||||
... np.square(np.log(y_true + 1.) - np.log(y_pred + 1.)), axis=-1))
|
||||
|
@ -235,11 +235,11 @@ def tf_repositories(path_prefix = "", tf_repo_name = ""):
|
||||
name = "eigen_archive",
|
||||
build_file = clean_dep("//third_party:eigen.BUILD"),
|
||||
patch_file = clean_dep("//third_party/eigen3:gpu_packet_math.patch"),
|
||||
sha256 = "a3c10a8c14f55e9f09f98b0a0ac6874c21bda91f65b7469d9b1f6925990e867b", # SHARED_EIGEN_SHA
|
||||
strip_prefix = "eigen-d10b27fe37736d2944630ecd7557cefa95cf87c9",
|
||||
sha256 = "00ff67c15f8e8faf14495482e7396cc1d99cdfaaa2151f4aafef92bc754e634d", # SHARED_EIGEN_SHA
|
||||
strip_prefix = "eigen-22c971a225dbb567cd1a45f6006d16c4aa618551",
|
||||
urls = [
|
||||
"https://storage.googleapis.com/mirror.tensorflow.org/gitlab.com/libeigen/eigen/-/archive/d10b27fe37736d2944630ecd7557cefa95cf87c9/eigen-d10b27fe37736d2944630ecd7557cefa95cf87c9.tar.gz",
|
||||
"https://gitlab.com/libeigen/eigen/-/archive/d10b27fe37736d2944630ecd7557cefa95cf87c9/eigen-d10b27fe37736d2944630ecd7557cefa95cf87c9.tar.gz",
|
||||
"https://storage.googleapis.com/mirror.tensorflow.org/gitlab.com/libeigen/eigen/-/archive/22c971a225dbb567cd1a45f6006d16c4aa618551/eigen-22c971a225dbb567cd1a45f6006d16c4aa618551.tar.gz",
|
||||
"https://gitlab.com/libeigen/eigen/-/archive/22c971a225dbb567cd1a45f6006d16c4aa618551/eigen-22c971a225dbb567cd1a45f6006d16c4aa618551.tar.gz",
|
||||
],
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user