java.lang.IllegalArgumentException: Trying to select column 2 but only 1 present.

JIRA | Kevin Normoyle | 3 years ago
  1. 0

    (note below that the test tries a bunch of built-in functions before failing on my defined function) (also note: I had taken the function stuff, from a test that passed with ddply? so I would have thought any function thing that worked with ddply should work with apply) test is cd testdir_single_jvm_fvec python test_exec2_apply_phrases.py [13:04:26] Kevin Normoyle: in exec now..this error message for apply doesn't seem right ..the ,2, means to apply to columns..not col index? [13:04:27] Kevin Normoyle: exec_query parameters: {'str': 'apply(r.hex, 2, func1)'} rjson: { "error": "Trying to select column 2 but only 1 present.", "response": { "h2o": "pytest-kevin-7637", "node": "/192.168.1.41:54321", "status": "error", "time": 5 } } rjson error in exec_query: Trying to select column 2 but only 1 present. ERROR 01:03:50.243 # Session ERRR WATER: + java.lang.IllegalArgumentException: Trying to select column 2 but only 1 present. + at water.fvec.Frame.deepSlice(Frame.java:715) + at water.exec.ASTSlice.exec(AST.java:253) + at water.exec.ASTApply.exec(AST.java:202) [13:04:48] Kevin Normoyle: func1=function(x){max(x[,1])} [13:05:17] Kevin Normoyle: it's odd, because this worked [13:05:17] Kevin Normoyle: apply(r.hex, 2, xorsum) r.hex is /home/0xdiag/datasets/standard/covtype.shuffled.10pct.data here's the full set of commands before it fails 2014-05-09 13:03:46.762348 -- Start http://192.168.1.41:54321/2/Exec2.json?str=r.hex 2014-05-09 13:03:46.984209 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func1=function(x){max(x[,1])} 2014-05-09 13:03:47.005495 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func2=function(x){a=3;nrow(x[,1])*a} 2014-05-09 13:03:47.024754 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func3=function(x){apply(x[,1],2,sum)/nrow(x[,1])} 2014-05-09 13:03:47.040000 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func4=function(x) { mean( x[,1]) } 2014-05-09 13:03:47.050574 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func5=function(x) { sd( x[,1]) } 2014-05-09 13:03:47.062865 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func1) 2014-05-09 13:03:47.458992 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func2) 2014-05-09 13:03:47.765131 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func3) 2014-05-09 13:03:48.640795 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func4) 2014-05-09 13:03:49.081796 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func5) 2014-05-09 13:03:49.580472 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, nrow) 2014-05-09 13:03:49.599351 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, ncol) 2014-05-09 13:03:49.610492 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, length) 2014-05-09 13:03:49.620602 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, is.factor) 2014-05-09 13:03:49.632485 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, any.factor) 2014-05-09 13:03:49.641372 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, any.na) 2014-05-09 13:03:49.651279 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, isTRUE) 2014-05-09 13:03:49.661540 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, min.na.rm) 2014-05-09 13:03:49.670715 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, max.na.rm) 2014-05-09 13:03:49.680448 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, min) 2014-05-09 13:03:49.688731 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, max) 2014-05-09 13:03:49.699732 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, xorsum) 2014-05-09 13:03:49.781740 -- Start http://192.168.1.41:54321/2/Exec2.json?str=r.hex=i.hex 2014-05-09 13:03:50.016202 -- Start http://192.168.1.41:54321/2/Exec2.json?str=r.hex 2014-05-09 13:03:50.199763 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func1=function(x){max(x[,2])} 2014-05-09 13:03:50.206929 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func2=function(x){a=3;nrow(x[,2])*a} 2014-05-09 13:03:50.214895 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func3=function(x){apply(x[,2],2,sum)/nrow(x[,2])} 2014-05-09 13:03:50.223202 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func4=function(x) { mean( x[,2]) } 2014-05-09 13:03:50.232555 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func5=function(x) { sd( x[,2]) } 2014-05-09 13:03:50.239210 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func1)

    JIRA | 3 years ago | Kevin Normoyle
    java.lang.IllegalArgumentException: Trying to select column 2 but only 1 present.
  2. 0

    (note below that the test tries a bunch of built-in functions before failing on my defined function) (also note: I had taken the function stuff, from a test that passed with ddply? so I would have thought any function thing that worked with ddply should work with apply) test is cd testdir_single_jvm_fvec python test_exec2_apply_phrases.py [13:04:26] Kevin Normoyle: in exec now..this error message for apply doesn't seem right ..the ,2, means to apply to columns..not col index? [13:04:27] Kevin Normoyle: exec_query parameters: {'str': 'apply(r.hex, 2, func1)'} rjson: { "error": "Trying to select column 2 but only 1 present.", "response": { "h2o": "pytest-kevin-7637", "node": "/192.168.1.41:54321", "status": "error", "time": 5 } } rjson error in exec_query: Trying to select column 2 but only 1 present. ERROR 01:03:50.243 # Session ERRR WATER: + java.lang.IllegalArgumentException: Trying to select column 2 but only 1 present. + at water.fvec.Frame.deepSlice(Frame.java:715) + at water.exec.ASTSlice.exec(AST.java:253) + at water.exec.ASTApply.exec(AST.java:202) [13:04:48] Kevin Normoyle: func1=function(x){max(x[,1])} [13:05:17] Kevin Normoyle: it's odd, because this worked [13:05:17] Kevin Normoyle: apply(r.hex, 2, xorsum) r.hex is /home/0xdiag/datasets/standard/covtype.shuffled.10pct.data here's the full set of commands before it fails 2014-05-09 13:03:46.762348 -- Start http://192.168.1.41:54321/2/Exec2.json?str=r.hex 2014-05-09 13:03:46.984209 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func1=function(x){max(x[,1])} 2014-05-09 13:03:47.005495 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func2=function(x){a=3;nrow(x[,1])*a} 2014-05-09 13:03:47.024754 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func3=function(x){apply(x[,1],2,sum)/nrow(x[,1])} 2014-05-09 13:03:47.040000 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func4=function(x) { mean( x[,1]) } 2014-05-09 13:03:47.050574 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func5=function(x) { sd( x[,1]) } 2014-05-09 13:03:47.062865 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func1) 2014-05-09 13:03:47.458992 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func2) 2014-05-09 13:03:47.765131 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func3) 2014-05-09 13:03:48.640795 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func4) 2014-05-09 13:03:49.081796 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func5) 2014-05-09 13:03:49.580472 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, nrow) 2014-05-09 13:03:49.599351 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, ncol) 2014-05-09 13:03:49.610492 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, length) 2014-05-09 13:03:49.620602 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, is.factor) 2014-05-09 13:03:49.632485 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, any.factor) 2014-05-09 13:03:49.641372 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, any.na) 2014-05-09 13:03:49.651279 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, isTRUE) 2014-05-09 13:03:49.661540 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, min.na.rm) 2014-05-09 13:03:49.670715 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, max.na.rm) 2014-05-09 13:03:49.680448 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, min) 2014-05-09 13:03:49.688731 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, max) 2014-05-09 13:03:49.699732 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, xorsum) 2014-05-09 13:03:49.781740 -- Start http://192.168.1.41:54321/2/Exec2.json?str=r.hex=i.hex 2014-05-09 13:03:50.016202 -- Start http://192.168.1.41:54321/2/Exec2.json?str=r.hex 2014-05-09 13:03:50.199763 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func1=function(x){max(x[,2])} 2014-05-09 13:03:50.206929 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func2=function(x){a=3;nrow(x[,2])*a} 2014-05-09 13:03:50.214895 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func3=function(x){apply(x[,2],2,sum)/nrow(x[,2])} 2014-05-09 13:03:50.223202 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func4=function(x) { mean( x[,2]) } 2014-05-09 13:03:50.232555 -- Start http://192.168.1.41:54321/2/Exec2.json?str=func5=function(x) { sd( x[,2]) } 2014-05-09 13:03:50.239210 -- Start http://192.168.1.41:54321/2/Exec2.json?str=apply(r.hex, 2, func1)

    JIRA | 3 years ago | Kevin Normoyle
    java.lang.IllegalArgumentException: Trying to select column 2 but only 1 present.
  3. 0
    samebug tip
    Properties of subclasses may have to be referenced in a different way. More on this here: https://goo.gl/FvnBXb
    via goo.gl
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0
    samebug tip
    Some bots are sending malformed HTTP requests to your site. Try to find their IP addresses in the access logs and ask them to fix the bots or blacklist them.

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.IllegalArgumentException

      Trying to select column 2 but only 1 present.

      at water.fvec.Frame.deepSlice()
    2. water.fvec
      Frame.deepSlice
      1. water.fvec.Frame.deepSlice(Frame.java:715)
      1 frame
    3. water.exec
      ASTApply.exec
      1. water.exec.ASTSlice.exec(AST.java:253)
      2. water.exec.ASTApply.exec(AST.java:202)
      2 frames