Skip to content

Commit

Permalink
internal inly
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 651442932
  • Loading branch information
tfx-copybara committed Jul 11, 2024
1 parent 29f0b0c commit ce6f947
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tfx/components/statistics_gen/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
from absl import logging
import tensorflow_data_validation as tfdv
from tensorflow_data_validation.statistics import stats_options as options
from tensorflow_data_validation.utils import dashboard_util
from tfx import types
from tfx.components.statistics_gen import stats_artifact_utils
from tfx.components.util import examples_utils
Expand All @@ -28,6 +27,7 @@
from tfx.types import standard_component_specs
from tfx.utils import io_utils
from tfx.utils import json_utils
from tfx.utils import stats_utils


# Default file name for stats generated.
Expand Down Expand Up @@ -151,7 +151,8 @@ def Do(

try:
statistics_artifact.set_string_custom_property(
STATS_DASHBOARD_LINK, dashboard_util.generate_stats_dashboard_link()
STATS_DASHBOARD_LINK,
stats_utils.generate_stats_dashboard_link(statistics_artifact),
)
except Exception as e: # pylint: disable=broad-except
# log on failures to not bring down Statsgen jobs
Expand Down
21 changes: 21 additions & 0 deletions tfx/utils/stats_utils.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Copyright 2024 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""stats_utils.
This module is the parity for internal implementation, not available in OSS.
"""


def generate_stats_dashboard_link(unused_statistics_artifact):
return ''

0 comments on commit ce6f947

Please sign in to comment.