KNN_CUDA
KNN_CUDA copied to clipboard
Different results on two machines
Hi, thanks for this nice code. I run the code on two machines with the same pytorch version but got garbage values on one of them. Here is the set up:
Scripts: "usage" code in README of this repo
Installed version: from wheel (pip install --upgrade https://github.com/unlimblue/KNN_CUDA/releases/download/0.2/KNN_CUDA-0.2-py3-none-any.whl
)
Machine 1: ubuntu 18.04, cuda v10.2, pytorch 1.6, -> correct output
Machine 2: ubuntu 16.04, cuda v10.0, pytorch 1.6 -> garbage index values (I also tried installing different versions of pytorch but still got the same issue; my other pytorch programs run well except this knn library.) I printed the variable "index" as pasted below. Do you have any ideas on what's going on?
Machine 2:
tensor([[[ -1, -1, -1,
..., -1, -1,
-1],
[ -1, -1, -1,
..., -1, -1,
-1],
[ -1, -1, -1,
..., -1, -1,
-1],
...,
[ -1, -1, -1,
..., -1, -1,
-1],
[ -1, -1, -1,
..., -1, -1,
-1],
[ -1, -1, -1,
..., -1, -1,
-1]],
[[4560212790653850923, 4385109108599773638, 4539781021335135641,
..., 4552507945725153031, 4467969490273823527,
4555503938839987080],
[4527787114719055848, 4556316804309686223, 4534072825070445695,
..., 4552348649693819283, 4533275679189113331,
4483555479890554383],
[4562775632003721729, 4528184811509715919, 4552001152472330583,
..., 4451450101164596537, 4556437827884244415,
4559683203991082491],
...,
[4428997558332013486, 4528136922583232319, 4505665198454270765,
..., 4514513655722470987, 4427321559007193229,
4572016331446892113],
[4540002401118072591, 4515891300847022717, 4567732483807323467,
..., 4561912098760733256, 4524539243270015060,
4545294715666961219],
[4550572719365322347, 4555429734674496991, 4462524691513447989,
..., 4558719421936112988, 4417843081580486006,
4560779683374828111]],
[[4524885151333570137, 4570974737453442935, 4524505304391978847,
..., 4568269500748931951, 4547937155639755763,
4573691463162923215],
[4385235140116876363, 4556292340203989631, 4549933155768138143,
..., 4521370467934493310, 4497950853081565862,
4511383337524847055],
[4531957948864993931, 4566138410997582573, 4541674831339067650,
..., 4572222515649073941, 4574741067275049843,
4574737029985634623],
...,
[4325151640023634381, 4559356528791404093, 4548008357609298229,
..., 4521944516080974893, 4533951561020062046,
4508178295497776974],
[4563772068707258853, 4554457624647942639, 4518589253252396359,
..., 4542205186758473335, 4504470536112506323,
4554523754281842146],
[4564284565684452947, 4559604168007808551, 4545535551674424326,
..., 4523459832088762118, 4562578935380986469,
4292368051514102399]],
...,
[[4524885151333570110, 4570974737453442908, 4524505304391978820,
..., 4568269500748931924, 4547937155639755736,
4573691463162923188],
[4385235140116876336, 4556292340203989604, 4549933155768138116,
..., 4521370467934493283, 4497950853081565835,
4511383337524847028],
[4531957948864993904, 4566138410997582546, 4541674831339067623,
..., 4572222515649073914, 4574741067275049816,
4574737029985634596],
...,
[4325151640023634354, 4559356528791404066, 4548008357609298202,
..., 4521944516080974866, 4533951561020062019,
4508178295497776947],
[4563772068707258826, 4554457624647942612, 4518589253252396332,
..., 4542205186758473308, 4504470536112506296,
4554523754281842119],
[4564284565684452920, 4559604168007808524, 4545535551674424299,
..., 4523459832088762091, 4562578935380986442,
4292368051514102372]],
[[4524885151333570109, 4570974737453442907, 4524505304391978819,
..., 4568269500748931923, 4547937155639755735,
4573691463162923187],
[4385235140116876335, 4556292340203989603, 4549933155768138115,
..., 4521370467934493282, 4497950853081565834,
4511383337524847027],
[4531957948864993903, 4566138410997582545, 4541674831339067622,
..., 4572222515649073913, 4574741067275049815,
4574737029985634595],
...,
[4325151640023634353, 4559356528791404065, 4548008357609298201,
..., 4521944516080974865, 4533951561020062018,
4508178295497776946],
[4563772068707258825, 4554457624647942611, 4518589253252396331,
..., 4542205186758473307, 4504470536112506295,
4554523754281842118],
[4564284565684452919, 4559604168007808523, 4545535551674424298,
..., 4523459832088762090, 4562578935380986441,
4292368051514102371]],
[[4524885151333570108, 4570974737453442906, 4524505304391978818,
..., 4568269500748931922, 4547937155639755734,
4573691463162923186],
[4385235140116876334, 4556292340203989602, 4549933155768138114,
..., 4521370467934493281, 4497950853081565833,
4511383337524847026],
[4531957948864993902, 4566138410997582544, 4541674831339067621,
..., 4572222515649073912, 4574741067275049814,
4574737029985634594],
...,
[4325151640023634352, 4559356528791404064, 4548008357609298200,
..., 4521944516080974864, 4533951561020062017,
4508178295497776945],
[4563772068707258824, 4554457624647942610, 4518589253252396330,
..., 4542205186758473306, 4504470536112506294,
4554523754281842117],
[4564284565684452918, 4559604168007808522, 4545535551674424297,
..., 4523459832088762089, 4562578935380986440,
4292368051514102370]]], device='cuda:0')
Hi @WilliamKRobert @unlimblue did you guys find any fix to this solution? I built it from source as well however i face the same problem.
For reference, i am running this on an RTX 3080 Ti/