Skip to content

Add markdown for Schur/matrix-free memory performance in /doc#40

Merged
SEOKWOOPARK merged 8 commits into
releasefrom
schur-performance-graph
Jun 20, 2026
Merged

Add markdown for Schur/matrix-free memory performance in /doc#40
SEOKWOOPARK merged 8 commits into
releasefrom
schur-performance-graph

Conversation

@SEOKWOOPARK

@SEOKWOOPARK SEOKWOOPARK commented Jun 17, 2026

Copy link
Copy Markdown
Collaborator

I added doc/memory_performance.md with a GPU-memory benchmark of bae's optimizers across three configurations: LM (matrix-free), Schur (normal), and Schur (matrix-free).
The PR explains the Schur complement and the matrix_free_normal path. It also shows that Schur + matrix-free cuts peak GPU memory by ~43% versus the LM baseline on the largest problem (venice with 3.0 M parameters). This change is documentation only.

1 2 3 4

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a detailed documentation file, doc/memory_performance.md, explaining the GPU-memory performance benefits of using Schur complement and matrix-free optimizers in the bae package. The review feedback highlights several opportunities to improve the accuracy and completeness of this documentation. Specifically, the reviewer recommends updating the parameter formula to account for optimized intrinsics, correcting the reject parameter value to match the reference script, adding the missing benchmark script path, and fixing the formatting of the conditions table.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread doc/memory_performance.md Outdated

| Metric | Meaning |
| --- | --- |
| Number of parameters | The count of optimizable parameters: 3 per 3D point (xyz position) plus 7 per camera — i.e. 3 × (number of 3D points) + 7 × (number of cameras) |

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

In the description of the Number of parameters metric, it states:
3 per 3D point (xyz position) plus 7 per camera — i.e. 3 × (number of 3D points) + 7 × (number of cameras)

However, the benchmark is configured with OPTIMIZE_INTRINSICS = True (as mentioned in line 101), which means there are 10 camera parameters per camera (7 for pose + 3 for intrinsics).

Please update this formula to reflect the actual 10 parameters per camera used in the benchmark, or make it general to cover both cases (e.g., 7 or 10 parameters depending on whether intrinsics are optimized).

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SEOKWOOPARK This needs to be resolved. We should optimize intr in all experiments.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed all points from '7 camera parameters' to '10 camera parameters'.

Comment thread doc/memory_performance.md
Comment thread doc/memory_performance.md Outdated
Comment thread doc/memory_performance.md Outdated
@SEOKWOOPARK SEOKWOOPARK requested a review from zitongzhan June 17, 2026 19:15

@zitongzhan zitongzhan left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment thread doc/memory_performance.md Outdated
@@ -0,0 +1,159 @@
# Improvement by Schur and Matrix-Free

GPU-memory benchmark sweep for `bae`'s Bundle Adjustment optimizers. It runs a

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to be specific here. What are "Bundle Adjustment optimizers"
Also need to provide more context before begining with benchmark sweep. Reader's won't understand what benchmark sweep is for without any context.

Comment thread doc/memory_performance.md Outdated

GPU-memory benchmark sweep for `bae`'s Bundle Adjustment optimizers. It runs a
set of [BAL](https://grail.cs.washington.edu/projects/bal/) problems through
several optimizer configurations, records peak and average GPU memory, and plots

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Readers won't understand what are "several optimizer configurations"

Comment thread doc/memory_performance.md Outdated
Comment thread doc/memory_performance.md Outdated
Comment thread doc/memory_performance.md Outdated
and intrinsics together with 3D point positions to minimize reprojection error.
As scenes scale to millions of parameters, GPU
memory becomes the bottleneck, and how that linear system is
solved largely decides how much memory is used.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no need to explain BA.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I deleted it. BA's meaning can be described in the main page of repo.

Comment thread doc/memory_performance.md Outdated
@@ -1,9 +1,25 @@
# Comparing GPU Memory: Schur, Matrix-Free, and LM

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comparing GPU Memory: Vanilla LM, Schur-complement Optimizer, and Matrix-free options

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for suggesting a more detail title.

@SEOKWOOPARK SEOKWOOPARK requested a review from zitongzhan June 20, 2026 21:04
@SEOKWOOPARK SEOKWOOPARK merged commit a8c0af3 into release Jun 20, 2026
3 checks passed
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.

2 participants