Skip to content

Fix divide by 0 issue in roofline model data conversion #1334

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions frontend/app/services/data_service/data_service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,17 +41,24 @@ export class DataService {
options: {[key: string]: any} = {},
notifyError = true,
): Observable<T|null> {
// Clear error message before making a new request.
// Currently only 1 error message is displayed at a time, this may cause
// issue for multi-request pages.
this.store.dispatch(setErrorMessageStateAction({errorMessage: ''}));
return this.httpClient.get<T>(url, options)
.pipe(
catchError((error: HttpErrorResponse) => {
console.log(error);
console.error(error);
const url = new URL(error.url || '');
const errorString = typeof error.error === 'object' ?
String(error.error?.error?.message) :
String(error.error);
const errorMessage = 'There was an error in the requested URL ' +
url.pathname + url.search + '.<br><br>' +
'<b>message:</b> ' + error.message + '<br>' +
'<b>status:</b> ' + String(error.status) + '<br>' +
'<b>statusText:</b> ' + error.statusText + '<br>' +
'<b>error:</b> ' + String(error.error);
'<b>error:</b> ' + errorString;
if (notifyError) {
this.store.dispatch(setErrorMessageStateAction({errorMessage}));
}
Expand Down
8 changes: 4 additions & 4 deletions plugin/tensorboard_plugin_profile/profile_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -731,7 +731,7 @@ def capture_route_impl(self, request: wrappers.Request) -> wrappers.Response:
return respond(
{'error': 'TensorFlow is not installed.'},
'application/json',
code=200,
code=500,
)

def get_worker_list(
Expand Down Expand Up @@ -771,12 +771,12 @@ def get_worker_list(
)
master_grpc_addr = tpu_cluster_resolver.get_master()
except (ImportError, RuntimeError) as err:
return respond({'error': repr(err)}, 'application/json', code=200)
return respond({'error': repr(err)}, 'application/json', code=500)
except (ValueError, TypeError):
return respond(
{'error': 'no TPUs with the specified names exist.'},
'application/json',
code=200,
code=500,
)
if not worker_list:
worker_list = get_worker_list(tpu_cluster_resolver)
Expand Down Expand Up @@ -817,7 +817,7 @@ def get_worker_list(
return respond(
{'error': str(e)},
'application/json',
code=200,
code=500,
)

def _get_graph_viewer_options(
Expand Down