Skip to content

Commit 0263d4b

Browse files
[Andrew Polyakov] Change fuzzing of NDArrayValueProvider shape
1 parent b2a5f2b commit 0263d4b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

utbot-python/src/main/kotlin/org/utbot/python/fuzzing/provider/NDArrayValueProvider.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@ class NDArrayValueProvider(
4343
PythonTree.NDArrayNode(
4444
emptyMap<Int, PythonTree.PythonTreeNode>().toMutableMap(), // Generate new Python IntNode
4545
((it.first().tree as PythonTree.ListNode).items as Map<Int, PythonTree.PrimitiveNode>).values.map { node ->
46-
abs(node.repr.take(3).toInt()) % 7 // TODO: Fix this
46+
abs(node.repr.take(2).toInt())
4747
}
4848
), "%var% = ${type.pythonTypeRepresentation()}"
4949
)
5050
},
5151
modify = sequence {
52-
yield(Routine.Call((0 until 10000). map{param[1]}.toFuzzed()) { instance, arguments ->
52+
yield(Routine.Call((0 until 10000).map { param[1] }.toFuzzed()) { instance, arguments ->
5353
val obj = instance.tree as PythonTree.NDArrayNode
5454
(0 until obj.dimensions.fold(1, Int::times)).map {
5555
obj.items[it] = arguments.get(it).tree

0 commit comments

Comments
 (0)