use of org.apache.sysml.runtime.instructions.cp.CPOperand in project incubator-systemml by apache.
the class MatrixReshapeSPInstruction method parseInstruction.
public static MatrixReshapeSPInstruction parseInstruction(String str) throws DMLRuntimeException {
String[] parts = InstructionUtils.getInstructionPartsWithValueType(str);
InstructionUtils.checkNumFields(parts, 5);
String opcode = parts[0];
CPOperand in1 = new CPOperand(parts[1]);
CPOperand in2 = new CPOperand(parts[2]);
CPOperand in3 = new CPOperand(parts[3]);
CPOperand in4 = new CPOperand(parts[4]);
CPOperand out = new CPOperand(parts[5]);
if (!opcode.equalsIgnoreCase("rshape"))
throw new DMLRuntimeException("Unknown opcode while parsing an MatrixReshapeInstruction: " + str);
else
return new MatrixReshapeSPInstruction(new Operator(true), in1, in2, in3, in4, out, opcode, str);
}
Aggregations