[ https://issues.apache.org/jira/browse/SYSTEMML-1373?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15898156#comment-15898156 ]
Nakul Jindal commented on SYSTEMML-1373: ---------------------------------------- Opened [PR 415|https://github.com/apache/incubator-systemml/pull/415] > Inconsistent printing in toString method for Infinity and NaN > ------------------------------------------------------------- > > Key: SYSTEMML-1373 > URL: https://issues.apache.org/jira/browse/SYSTEMML-1373 > Project: SystemML > Issue Type: Bug > Components: Runtime > Reporter: Niketan Pansare > Assignee: Nakul Jindal > Priority: Minor > > The issue can be reproduced using the following DML script: > {code} > X = matrix(seq(1, 9), rows=3, cols=3) > #X[1,2] = X[1,2] / sum(X == 10) > X[1,2] = 0 / 0 > for(i in 1:nrow(X)) { > print(">" + as.scalar(X[i,1]) + " " + as.scalar(X[i,2]) + " " + > as.scalar(X[i,3])) > } > print(toString(X)) > {code} > For NaN, it produces following output: > {code} > >1.0 NaN 3.0 > >4.0 5.0 6.0 > >7.0 8.0 9.0 > 1.000 � 3.000 > 4.000 5.000 6.000 > 7.000 8.000 9.000 > {code} > For Infinity, it produces following output: > {code} > >1.0 Infinity 3.0 > >4.0 5.0 6.0 > >7.0 8.0 9.0 > 1.000 ∞ 3.000 > 4.000 5.000 6.000 > 7.000 8.000 9.000 > {code} -- This message was sent by Atlassian JIRA (v6.3.15#6346)