Commit f0ffe617 authored by yan.yan's avatar yan.yan
Browse files

add new prebuilts for 3.13 and cu126

parent 125a194d
from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union
from pccm.stubs import EnumValue, EnumClassValue from pccm.stubs import EnumValue, EnumClassValue, enum
from cumm.tensorview import Tensor from cumm.tensorview import Tensor
from cumm.tensorview.gemm import Activation from cumm.tensorview.gemm import Activation
class InferenceOps: class InferenceOps:
......
from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union
from pccm.stubs import EnumValue, EnumClassValue from pccm.stubs import EnumValue, EnumClassValue, enum
from cumm.tensorview import Tensor from cumm.tensorview import Tensor
class BoxOps: class BoxOps:
@staticmethod @staticmethod
......
from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union
from pccm.stubs import EnumValue, EnumClassValue from pccm.stubs import EnumValue, EnumClassValue, enum
from cumm.tensorview import Tensor from cumm.tensorview import Tensor
class PointCloudCompress: class PointCloudCompress:
@staticmethod @staticmethod
...@@ -43,8 +43,8 @@ class PointCloudCompress: ...@@ -43,8 +43,8 @@ class PointCloudCompress:
data: data:
""" """
... ...
class EncodeType: class EncodeType(enum.Enum):
XYZ_8 = EnumClassValue(0) # type: EnumClassValue XYZ_8 = 0
XYZI_8 = EnumClassValue(1) # type: EnumClassValue XYZI_8 = 1
@staticmethod @staticmethod
def __members__() -> Dict[str, EnumClassValue]: ... def __members__() -> Dict[str, EnumClassValue]: ...
from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union
from pccm.stubs import EnumValue, EnumClassValue from pccm.stubs import EnumValue, EnumClassValue, enum
class CompileInfo: class CompileInfo:
@staticmethod @staticmethod
def get_compiled_cuda_version() -> Tuple[int, int]: ... def get_compiled_cuda_version() -> Tuple[int, int]: ...
......
from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union
from pccm.stubs import EnumValue, EnumClassValue from pccm.stubs import EnumValue, EnumClassValue, enum
from cumm.tensorview.gemm import ConvParams from cumm.tensorview.gemm import ConvParams
class ConvMainUnitTest: class ConvMainUnitTest:
@staticmethod @staticmethod
......
from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union from typing import overload, Any, Callable, Dict, List, Optional, Set, Tuple, Type, Union
from pccm.stubs import EnumValue, EnumClassValue from pccm.stubs import EnumValue, EnumClassValue, enum
from cumm.tensorview.gemm import GemmAlgoDesp from cumm.tensorview.gemm import GemmAlgoDesp
from cumm.tensorview.gemm import GemmParams from cumm.tensorview.gemm import GemmParams
class GemmMainUnitTest: class GemmMainUnitTest:
......
...@@ -95,7 +95,7 @@ class PointCloudCompress(pccm.Class): ...@@ -95,7 +95,7 @@ class PointCloudCompress(pccm.Class):
enc[3] = uint8_t(inten); enc[3] = uint8_t(inten);
}} }}
auto pos_uint = pos_int + hash_t::direct_hash_offset(); auto pos_uint = pos_int + hash_t::direct_hash_offset();
uint64_t scalar = hash_t::encode(pos_int[0], pos_int[1], pos_int[2]); uint64_t scalar = hash_t::encode(pos_uint[0], pos_uint[1], pos_uint[2]);
auto iter = hash.find(scalar); auto iter = hash.find(scalar);
if (iter == hash.end()){{ if (iter == hash.end()){{
auto pos_offset = pos_int.cast<float>() * vsize; auto pos_offset = pos_int.cast<float>() * vsize;
...@@ -116,6 +116,7 @@ class PointCloudCompress(pccm.Class): ...@@ -116,6 +116,7 @@ class PointCloudCompress(pccm.Class):
}} }}
}} }}
points_data += point_stride; points_data += point_stride;
intensity_data += inten_stride;
}} }}
res = tv::empty({{final_size}}, tv::uint8, -1); res = tv::empty({{final_size}}, tv::uint8, -1);
......
...@@ -41,8 +41,12 @@ _T = TypeVar("_T") ...@@ -41,8 +41,12 @@ _T = TypeVar("_T")
def identity_decorator(func: _T) -> _T: def identity_decorator(func: _T) -> _T:
return func return func
if PYTORCH_VERSION >= [2, 5, 0]:
import torch.amp as amp
_TORCH_CUSTOM_FWD = amp.custom_fwd(cast_inputs=torch.float16, device_type="cuda")
_TORCH_CUSTOM_BWD = amp.custom_bwd(device_type="cuda")
if PYTORCH_VERSION >= [1, 6, 0]: elif PYTORCH_VERSION >= [1, 6, 0]:
import torch.cuda.amp as amp import torch.cuda.amp as amp
_TORCH_CUSTOM_FWD = amp.custom_fwd(cast_inputs=torch.float16) _TORCH_CUSTOM_FWD = amp.custom_fwd(cast_inputs=torch.float16)
_TORCH_CUSTOM_BWD = amp.custom_bwd _TORCH_CUSTOM_BWD = amp.custom_bwd
......
...@@ -27,24 +27,16 @@ function repair_wheel { ...@@ -27,24 +27,16 @@ function repair_wheel {
gcc -v gcc -v
export SPCONV_DISABLE_JIT="1" export SPCONV_DISABLE_JIT="1"
export CUMM_CUDA_ARCH_LIST="8.6" export CUMM_CUDA_ARCH_LIST="8.6"
# export SPCONV_PYTHON_LIST="3.7;3.8;3.9;3.10" export SPCONV_PYTHON_LIST="3.13"
# Compile wheels, we only support 3.6-3.10. # Compile wheels, we only support 3.6-3.10.
# "/opt/python/cp36-cp36m/bin/pip" wheel /io/ --no-deps -w /io/wheelhouse_tmp # "/opt/python/cp36-cp36m/bin/pip" wheel /io/ --no-deps -w /io/wheelhouse_tmp
for PYVER in ${SPCONV_PYTHON_LIST//;/ } for PYVER in ${SPCONV_PYTHON_LIST//;/ }
do do
PYVER2=`echo "$PYVER" | sed 's/\.//'` PYVER2=`echo "$PYVER" | sed 's/\.//'`
PYVER_CP="cp$PYVER2-cp$PYVER2" PYVER_T=`echo "$PYVER2" | sed 's/t//'`
if [ "$PYVER2" = "36" ]; then
PYVER_CP="cp$PYVER2-cp${PYVER2}m"
fi
if [ "$PYVER2" = "37" ]; then
PYVER_CP="cp$PYVER2-cp${PYVER2}m"
fi
if [[ $PYVER2 == *"311"* ]]; then
PYVER_CP="cp311-cp311"
fi
PYVER_CP="cp$PYVER_T-cp$PYVER2"
"/opt/python/$PYVER_CP/bin/pip" wheel /io/ -v --no-deps -w /io/wheelhouse_tmp "/opt/python/$PYVER_CP/bin/pip" wheel /io/ -v --no-deps -w /io/wheelhouse_tmp
done done
......
...@@ -34,17 +34,9 @@ export CUMM_CUDA_ARCH_LIST="all" ...@@ -34,17 +34,9 @@ export CUMM_CUDA_ARCH_LIST="all"
for PYVER in ${SPCONV_PYTHON_LIST//;/ } for PYVER in ${SPCONV_PYTHON_LIST//;/ }
do do
PYVER2=`echo "$PYVER" | sed 's/\.//'` PYVER2=`echo "$PYVER" | sed 's/\.//'`
PYVER_CP="cp$PYVER2-cp$PYVER2" PYVER_T=`echo "$PYVER2" | sed 's/\t//'`
if [ "$PYVER2" = "36" ]; then
PYVER_CP="cp$PYVER2-cp${PYVER2}m"
fi
if [ "$PYVER2" = "37" ]; then
PYVER_CP="cp$PYVER2-cp${PYVER2}m"
fi
if [[ $PYVER2 == *"311"* ]]; then
PYVER_CP="cp311-cp311"
fi
PYVER_CP="cp$PYVER_T-cp$PYVER2"
"/opt/python/$PYVER_CP/bin/pip" wheel /io/ -v --no-deps -w /io/wheelhouse_tmp "/opt/python/$PYVER_CP/bin/pip" wheel /io/ -v --no-deps -w /io/wheelhouse_tmp
done done
......
...@@ -13,7 +13,13 @@ $CUDA_KNOWN_URLS = @{ ...@@ -13,7 +13,13 @@ $CUDA_KNOWN_URLS = @{
"11.6" = "https://developer.download.nvidia.com/compute/cuda/11.6.2/network_installers/cuda_11.6.2_windows_network.exe"; "11.6" = "https://developer.download.nvidia.com/compute/cuda/11.6.2/network_installers/cuda_11.6.2_windows_network.exe";
"11.7" = "https://developer.download.nvidia.com/compute/cuda/11.7.1/network_installers/cuda_11.7.1_windows_network.exe"; "11.7" = "https://developer.download.nvidia.com/compute/cuda/11.7.1/network_installers/cuda_11.7.1_windows_network.exe";
"11.8" = "https://developer.download.nvidia.com/compute/cuda/11.8.0/network_installers/cuda_11.8.0_windows_network.exe"; "11.8" = "https://developer.download.nvidia.com/compute/cuda/11.8.0/network_installers/cuda_11.8.0_windows_network.exe";
"12.0" = "https://developer.download.nvidia.com/compute/cuda/12.0.0/network_installers/cuda_12.0.0_windows_network.exe"; "12.0" = "https://developer.download.nvidia.com/compute/cuda/12.0.1/network_installers/cuda_12.0.1_windows_network.exe";
"12.1" = "https://developer.download.nvidia.com/compute/cuda/12.1.1/network_installers/cuda_12.1.1_windows_network.exe";
"12.2" = "https://developer.download.nvidia.com/compute/cuda/12.2.2/network_installers/cuda_12.2.2_windows_network.exe";
"12.3" = "https://developer.download.nvidia.com/compute/cuda/12.3.2/network_installers/cuda_12.3.2_windows_network.exe";
"12.4" = "https://developer.download.nvidia.com/compute/cuda/12.4.1/network_installers/cuda_12.4.1_windows_network.exe";
"12.5" = "https://developer.download.nvidia.com/compute/cuda/12.5.1/network_installers/cuda_12.5.1_windows_network.exe";
"12.6" = "https://developer.download.nvidia.com/compute/cuda/12.6.1/network_installers/cuda_12.6.1_windows_network.exe";
} }
# cuda_runtime.h is in nvcc <= 10.2, but cudart >= 11.0 # cuda_runtime.h is in nvcc <= 10.2, but cudart >= 11.0
...@@ -34,46 +40,28 @@ $CUDA_KNOWN_URLS = @{ ...@@ -34,46 +40,28 @@ $CUDA_KNOWN_URLS = @{
$CUDA_VERSION_FULL = $env:cuda $CUDA_VERSION_FULL = $env:cuda
# Make sure CUDA_VERSION_FULL is set and valid, otherwise error. # Make sure CUDA_VERSION_FULL is set and valid, otherwise error.
if (($CUDA_VERSION_FULL -eq "10.2") -or ($CUDA_VERSION_FULL -eq "11.0") -or ($CUDA_VERSION_FULL -eq "11.1") -or ($CUDA_VERSION_FULL -eq "11.2") -or ($CUDA_VERSION_FULL -eq "11.3")){
if (($CUDA_VERSION_FULL -eq "10.2") -or ($CUDA_VERSION_FULL -eq "11.0") -or ($CUDA_VERSION_FULL -eq "11.1") -or ($CUDA_VERSION_FULL -eq "11.2")){
$CUDA_PACKAGES_IN = @( $CUDA_PACKAGES_IN = @(
"nvcc"; "nvcc";
"visual_studio_integration"; "visual_studio_integration";
"nvrtc_dev";
"cudart";
"curand_dev"; "curand_dev";
# before 11.3, thrust are included by default and no explicit package exists
)
} elseif ($CUDA_VERSION_FULL -eq "11.3"){
$CUDA_PACKAGES_IN = @(
"nvcc";
"visual_studio_integration";
"nvrtc_dev"; "nvrtc_dev";
"cudart"; "cudart";
"thrust";
"curand_dev";
) )
} else { } else {
# after cuda 11.4 # after cuda 11.4
$CUDA_PACKAGES_IN = @( $CUDA_PACKAGES_IN = @(
"nvcc"; "nvcc";
"visual_studio_integration"; "visual_studio_integration";
"curand_dev";
"nvrtc_dev"; "nvrtc_dev";
"cudart"; "cudart";
"thrust";
"curand_dev";
"cuxxfilt"; "cuxxfilt";
# we need this to get libcu++ headers in cuda 12.0.
"thrust";
) )
} }
## -------------------
## Select CUDA version
## -------------------
# Get the cuda version from the environment as env:cuda.
# Make sure CUDA_VERSION_FULL is set and valid, otherwise error.
# Validate CUDA version, extracting components via regex # Validate CUDA version, extracting components via regex
$cuda_ver_matched = $CUDA_VERSION_FULL -match "^(?<major>[1-9][0-9]*)\.(?<minor>[0-9]+)$" $cuda_ver_matched = $CUDA_VERSION_FULL -match "^(?<major>[1-9][0-9]*)\.(?<minor>[0-9]+)$"
if(-not $cuda_ver_matched){ if(-not $cuda_ver_matched){
...@@ -83,7 +71,6 @@ if(-not $cuda_ver_matched){ ...@@ -83,7 +71,6 @@ if(-not $cuda_ver_matched){
$CUDA_MAJOR=$Matches.major $CUDA_MAJOR=$Matches.major
$CUDA_MINOR=$Matches.minor $CUDA_MINOR=$Matches.minor
## ------------------------------------------------ ## ------------------------------------------------
## Select CUDA packages to install from environment ## Select CUDA packages to install from environment
## ------------------------------------------------ ## ------------------------------------------------
......
sudo docker run --rm -it -e CUMM_CUDA_VERSION=126 -e PLAT=manylinux_2_28_x86_64 -v `pwd`:/io -v $HOME:/myhome manylinux2014-cuda:cu126-devel bash -c "source /etc/bashrc && /io/tools/build-wheels-dev.sh"
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment