Skip to content

Add MPS backend - #52

Open
zitongzhan wants to merge 14 commits into
releasefrom
codex/mps-backend
Open

zitongzhan wants to merge 14 commits into
releasefrom
codex/mps-backend

Conversation

@zitongzhan

Copy link
Copy Markdown
Collaborator

No description provided.

Comment thread bae/sparse/tensor.py
kwargs = {} if kwargs is None else kwargs
aten = torch.ops.aten
if func in (aten.mv.default, aten.mv.out, aten.mm.default, aten.mm.out):
matrix, x = args
Comment thread bae/sparse/tensor.py
if isinstance(matrix, _SparseTensor) and not isinstance(x, _SparseTensor):
return matrix.matvec(x, out=kwargs.get("out"))
elif func is aten.add.Tensor:
left, right = args
Comment thread bae/sparse/tuple_ops.py
if not transpose:
use_tiles, tile_size = _tile_dispatch(values.shape[0], br, bc, size[0], values.device.type, tile_size)
else:
use_tiles = False
residual = torch.linspace(-1, 1, 6, device=device)
# Populate the transpose before creating the detached alias. Mutations via
# that alias must invalidate both stored values and canonical-index state.
transpose @ residual
Comment thread bae/utils/pysolvers.py
from pypose.optim.solver import CG
from bae.sparse.py_ops import spdiags_
from .linear_operator import DiagonalMatVec
from ..sparse import py_ops as _py_ops # Registers native sparse diagonal dispatch.
Comment thread bae/sparse/warp_wrappers.py Fixed
Comment thread bae/optim/optimizer.py Fixed
Comment thread bae/optim/strategy.py Fixed
Comment thread bae/sparse/warp_wrappers.py Fixed
Comment on lines +147 to +149
'All methods receive the same globally attended, undistorted DSLR prediction for each scene. '
'`BAE_USE_PYPOSE_AMBIENT_GRAD=1` is enabled. No scene is selected using its AUC. '
'Raw and guarded outcomes are separate. All table AUCs are percentages; JSON stores fractions.', '',
Comment on lines +160 to +162
lines += ['', 'Native D minimizes a joint photometric objective; Open3D D performs dense pairwise odometry followed by PGO. '
'Native E rebuilds a voxel-averaged structure; reference E uses TSDF fusion and rigid color-map optimization. '
'These are different formulations, so numerical equality is not guaranteed by correct gradients.', '',
Comment on lines +177 to +180
'- The reference arms here call the actual DA3 Form D/E functions on the same cached arrays as bae. '
'They use the showcase protocol: shared self-calibration, graph baseline filter 0.1 / rotation 1°, '
'D texture gate and internal guard disabled, then a common 512-pair wide guard. '
'D+E composes raw D then E and guards the whole proposal. This differs from the historical CLI defaults.',
Comment on lines +185 to +186
'- Camera ground truth is used only for evaluation. No optimizer receives COLMAP poses or calibrated intrinsics. '
'Fixed DSLR calibration is used only to undistort the input photographs.',
Comment on lines +187 to +188
'- Per-scene input filenames, memory search attempts, checkpoint revision, configuration and metrics are in JSON. '
'Full pair errors are saved beside each prediction as `evaluation_errors.npz`.', '',

This branch has not been deployed

No deployments
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.

1 participant