File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -167,7 +167,9 @@ def shiftLastMode(self, tensor):
167
167
for i in range (len (data )):
168
168
for j in range (len (tensor .shape )):
169
169
resultCoords [j ][i ] = coords [j ][i ]
170
- resultValues [i ] = data [i ]
170
+ # resultValues[i] = data[i]
171
+ # TODO (rohany): Temporarily use a constant as the value.
172
+ resultValues [i ] = 2
171
173
resultCoords [- 1 ][i ] = (resultCoords [- 1 ][i ] + 1 ) % tensor .shape [- 1 ]
172
174
return sparse .COO (resultCoords , resultValues , tensor .shape )
173
175
@@ -183,7 +185,9 @@ def shiftLastMode(self, tensor):
183
185
for coord , val in dok .items ():
184
186
newCoord = list (coord [:])
185
187
newCoord [- 1 ] = (newCoord [- 1 ] + 1 ) % tensor .shape [- 1 ]
186
- result [tuple (newCoord )] = val
188
+ # result[tuple(newCoord)] = val
189
+ # TODO (rohany): Temporarily use a constant as the value.
190
+ result [tuple (newCoord )] = 2
187
191
if self .format == "csr" :
188
192
return scipy .sparse .csr_matrix (result )
189
193
elif self .format == "csc" :
You can’t perform that action at this time.
0 commit comments