You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@systemml.apache.org by "Matthias Boehm (JIRA)" <ji...@apache.org> on 2017/10/10 20:25:00 UTC

[jira] [Updated] (SYSTEMML-1950) Multi-class Mlogreg fails w/ invalid generated code

     [ https://issues.apache.org/jira/browse/SYSTEMML-1950?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Matthias Boehm updated SYSTEMML-1950:
-------------------------------------
    Description: 
{code}
public final class TMP43 extends SpoofRowwise {
  public TMP43() {
    super(RowType.FULL_AGG, -1, false, 2);
  }
  protected void genexec(double[] a, int ai, SideInput[] b, double[] scalars, double[] c, int len, int rowIndex) {
    double[] TMP37 = LibSpoofPrimitives.vectMinusWrite(0, a, ai, len);
    double[] TMP38 = LibSpoofPrimitives.vectPowWrite(TMP37, 2, 0, TMP37.length);
    double TMP39 = LibSpoofPrimitives.vectSum(TMP38, 0, TMP38.length);
    c[0] += TMP39;
  }
  protected void genexec(double[] avals, int[] aix, int ai, SideInput[] b, double[] scalars, double[] c, int alen, int len, int rowIndex) {
    double[] TMP40 = LibSpoofPrimitives.vectMinusWrite(0, a, ai, len);
    double[] TMP41 = LibSpoofPrimitives.vectPowWrite(TMP40, 2, 0, TMP40.length);
    double TMP42 = LibSpoofPrimitives.vectSum(TMP41, 0, TMP41.length);
    c[0] += TMP42;
  }
}
{code}

which gives the following error

{code}
Caused by: org.codehaus.commons.compiler.CompileException: Line 19, Column 60: Unknown variable or type "a"
        at org.codehaus.janino.UnitCompiler.compileError(UnitCompiler.java:11004)
        at org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6017)
{code}

  was:
{code}
public final class TMP43 extends SpoofRowwise {
  public TMP43() {
    super(RowType.FULL_AGG, -1, false, 2);
  }
  protected void genexec(double[] a, int ai, SideInput[] b, double[] scalars, double[] c, int len, int rowIndex) {
    double[] TMP37 = LibSpoofPrimitives.vectMinusWrite(0, a, ai, len);
    double[] TMP38 = LibSpoofPrimitives.vectPowWrite(TMP37, 2, 0, TMP37.length);
    double TMP39 = LibSpoofPrimitives.vectSum(TMP38, 0, TMP38.length);
    c[0] += TMP39;
  }
  protected void genexec(double[] avals, int[] aix, int ai, SideInput[] b, double[] scalars, double[] c, int alen, int len, int rowIndex) {
    double[] TMP40 = LibSpoofPrimitives.vectMinusWrite(0, a, ai, len);
    double[] TMP41 = LibSpoofPrimitives.vectPowWrite(TMP40, 2, 0, TMP40.length);
    double TMP42 = LibSpoofPrimitives.vectSum(TMP41, 0, TMP41.length);
    c[0] += TMP42;
  }
}

{code}


> Multi-class Mlogreg fails w/ invalid generated code
> ---------------------------------------------------
>
>                 Key: SYSTEMML-1950
>                 URL: https://issues.apache.org/jira/browse/SYSTEMML-1950
>             Project: SystemML
>          Issue Type: Bug
>            Reporter: Matthias Boehm
>
> {code}
> public final class TMP43 extends SpoofRowwise {
>   public TMP43() {
>     super(RowType.FULL_AGG, -1, false, 2);
>   }
>   protected void genexec(double[] a, int ai, SideInput[] b, double[] scalars, double[] c, int len, int rowIndex) {
>     double[] TMP37 = LibSpoofPrimitives.vectMinusWrite(0, a, ai, len);
>     double[] TMP38 = LibSpoofPrimitives.vectPowWrite(TMP37, 2, 0, TMP37.length);
>     double TMP39 = LibSpoofPrimitives.vectSum(TMP38, 0, TMP38.length);
>     c[0] += TMP39;
>   }
>   protected void genexec(double[] avals, int[] aix, int ai, SideInput[] b, double[] scalars, double[] c, int alen, int len, int rowIndex) {
>     double[] TMP40 = LibSpoofPrimitives.vectMinusWrite(0, a, ai, len);
>     double[] TMP41 = LibSpoofPrimitives.vectPowWrite(TMP40, 2, 0, TMP40.length);
>     double TMP42 = LibSpoofPrimitives.vectSum(TMP41, 0, TMP41.length);
>     c[0] += TMP42;
>   }
> }
> {code}
> which gives the following error
> {code}
> Caused by: org.codehaus.commons.compiler.CompileException: Line 19, Column 60: Unknown variable or type "a"
>         at org.codehaus.janino.UnitCompiler.compileError(UnitCompiler.java:11004)
>         at org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6017)
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)