Skip to content

Commit 5f36307

Browse files
committed
doc v0.5 updates
1 parent f8ae4ad commit 5f36307

16 files changed

+333
-219
lines changed

MinkowskiEngine/MinkowskiCoordinateManager.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def set_gpu_allocator(backend: GPUMemoryAllocatorType):
7171
than allocating GPU directly using raw CUDA calls.
7272
7373
By default, the Minkowski Engine uses
74-
:attr:`ME.MemoryManagerBackend.PYTORCH` for memory management.
74+
:attr:`ME.GPUMemoryAllocatorType.PYTORCH` for memory management.
7575
7676
Example::
7777
@@ -84,7 +84,7 @@ def set_gpu_allocator(backend: GPUMemoryAllocatorType):
8484
"""
8585
assert isinstance(
8686
backend, GPUMemoryAllocatorType
87-
), f"Input must be an instance of MemoryManagerBackend not {backend}"
87+
), f"Input must be an instance of GPUMemoryAllocatorType not {backend}"
8888
global _allocator_type
8989
_allocator_type = backend
9090

MinkowskiEngine/MinkowskiTensor.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,17 +99,26 @@ def set_sparse_tensor_operation_mode(operation_mode: SparseTensorOperationMode):
9999
_sparse_tensor_operation_mode = operation_mode
100100

101101

102-
def sparse_tensor_operation_mode():
102+
def sparse_tensor_operation_mode() -> SparseTensorOperationMode:
103+
r"""Return the current sparse tensor operation mode.
104+
"""
103105
global _sparse_tensor_operation_mode
104106
return copy.deepcopy(_sparse_tensor_operation_mode)
105107

106108

107109
def global_coordinate_manager():
110+
r"""Return the current global coordinate manager
111+
"""
108112
global _global_coordinate_manager
109113
return _global_coordinate_manager
110114

111115

112116
def set_global_coordinate_manager(coordinate_manager):
117+
r"""Set the global coordinate manager.
118+
119+
:attr:`MinkowskiEngine.CoordinateManager` The coordinate manager which will
120+
be set to the global coordinate manager.
121+
"""
113122
global _global_coordinate_manager
114123
_global_coordinate_manager = coordinate_manager
115124

MinkowskiEngine/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@
7373
SparseTensorQuantizationMode,
7474
set_sparse_tensor_operation_mode,
7575
sparse_tensor_operation_mode,
76+
global_coordinate_manager,
77+
set_global_coordinate_manager,
7678
clear_global_coordinate_manager,
7779
)
7880

MinkowskiEngine/utils/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,5 @@
2323
# of the code.
2424
from .quantization import sparse_quantize, ravel_hash_vec, fnv_hash_vec, unique_coordinate_map
2525
from .collation import SparseCollation, batched_coordinates, sparse_collate, batch_sparse_collate
26-
from .coords import get_coords_map
26+
# from .coords import get_coords_map
2727
from .init import kaiming_normal_

docs/benchmark.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Benchmark
22

3-
We report the feed forward and backward pass time of a convolution layer, and a small U-network. Note that the kernel map can be reused for other layers with the same tensor-stride, stride, and kernel offsets, thus the time reported in this page can be amortized across all layers used in a large nueral network.
3+
We report the feed forward and backward pass time of a convolution layer, and a small U-network for v0.4.3. Note that the kernel map can be reused for other layers with the same tensor-stride, stride, and kernel offsets, thus the time reported in this page can be amortized across all layers used in a large nueral network.
44

55
We use a Titan X for the experiments.
66

docs/coords.rst

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,32 @@
11
Coordinate Management
22
=====================
33

4-
CoordsKey
5-
---------
4+
CoordinateMapKey
5+
----------------
66

7-
.. autoclass:: MinkowskiEngine.CoordsKey
7+
.. autoclass:: MinkowskiEngine.CoordinateMapKey
88
:members:
99
:undoc-members:
1010
:exclude-members: __repr__
1111

1212
.. automethod:: __init__
1313

1414

15-
CoordsManager
16-
-------------
15+
CoordinateManager
16+
-----------------
1717

18-
.. autoclass:: MinkowskiEngine.CoordsManager
18+
.. autoclass:: MinkowskiEngine.CoordinateManager
1919
:members:
2020
:undoc-members:
2121
:exclude-members: __repr__
2222

2323
.. automethod:: __init__
2424

2525

26-
Coordinate GPU Memory Manager
27-
-----------------------------
26+
GPU Memory Allocator
27+
--------------------
2828

29-
.. autoclass:: MinkowskiEngine.MemoryManagerBackend
29+
.. autoclass:: MinkowskiEngine.GPUMemoryAllocatorType
3030
:members:
3131

32-
.. autofunction:: MinkowskiEngine.MinkowskiCoords.set_memory_manager_backend
32+
.. autofunction:: MinkowskiEngine.set_gpu_allocator

docs/demo/interop.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ a min-batch.
3232
kernel_size=3,
3333
stride=2,
3434
dilation=1,
35-
has_bias=False,
35+
bias=False,
3636
dimension=D), ME.MinkowskiBatchNorm(64), ME.MinkowskiReLU(),
3737
ME.MinkowskiConvolution(
3838
in_channels=64,
@@ -66,7 +66,7 @@ accessing the features of the sparse tensor
6666
6767
# Get new data
6868
coords, feat, label = data_loader()
69-
input = ME.SparseTensor(feat, coords=coords).to(device)
69+
input = ME.SparseTensor(features=feat, coordinates=coords, device=device)
7070
label = label.to(device)
7171
7272
# Forward

0 commit comments

Comments
 (0)