Skip to content

Conversation

@copybara-service
Copy link

The tensor_shape processing logic in src/ui/src/components/visualizer/worker/graph_processor.ts blindly adds spaces around x to format dimensions (e.g., 1x2 -> 1 x 2), but this regex-like behavior inadvertently affects types containing x, such as complex64. I replaced the .split('x').join(' x ') with a regex replacement (".replace(/(\d|?)x/g, '$1 x ');") that only targets x when it's likely being used as a dimension separator (e.g., preceded by a digit or ?).

@google-cla
Copy link

google-cla bot commented Jan 6, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@copybara-service copybara-service bot force-pushed the test_852956369 branch 4 times, most recently from 3761916 to b414bd2 Compare January 14, 2026 19:17
…r/worker/graph_processor.ts` blindly adds spaces around x to format dimensions (e.g., 1x2 -> 1 x 2), but this regex-like behavior inadvertently affects types containing x, such as complex64. I replaced the .split('x').join(' x ') with a regex replacement (".replace(/(\d|\?)x/g, '$1 x ');") that only targets x when it's likely being used as a dimension separator (e.g., preceded by a digit or ?).

PiperOrigin-RevId: 856292811
@copybara-service copybara-service bot merged commit 5e856f4 into main Jan 14, 2026
@copybara-service copybara-service bot deleted the test_852956369 branch January 14, 2026 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants