Examples of Measurement


Examples of eu.planets_project.pp.plato.model.measurement.Measurement

        ExecutionFootprintList performance = p.getList();
        //log.debug(performance.toString());
       
        for (MeasurableProperty property: getMeasurableProperties()) {
            if (!property.getName().startsWith("machine:")) {
                Measurement m = new Measurement();
                m.setProperty(property);
                PositiveFloatValue v = (PositiveFloatValue) property.getScale().createValue();

                if (property.getName().equals(MigrationResult.MIGRES_USED_TIME)) {
                    v.setValue(performance.getTotalCpuTimeUsed());
                }
                if (property.getName().equals(MigrationResult.MIGRES_MEMORY_GROSS)) {
                    v.setValue(performance.getMaxVirtualMemory());
                }
                if (property.getName().equals(MigrationResult.MIGRES_MEMORY_NET)) {
                    v.setValue(performance.getMaxResidentSize());
                }


                if (property.getName().equals("performance:averageResidentSize")) {
                    v.setValue(performance.getAverageResidentSize());
                } else if (property.getName().equals("performance:averageSharedMemory")) {
                    v.setValue(performance.getAverageSharedMemory());
                } else if (property.getName().equals("performance:averageVirtualMemory")) {
                    v.setValue(performance.getAverageVirtualMemory());
                } else if (property.getName().equals("performance:maxResidentSize")) {
                    v.setValue(performance.getMaxResidentSize());
                } else if (property.getName().equals("performance:maxSharedMemory")) {
                    v.setValue(performance.getMaxSharedMemory());
                } else if (property.getName().equals("performance:maxVirtualMemory")) {
                    v.setValue(performance.getMaxVirtualMemory());
                } else if (property.getName().equals("performance:totalCpuTimeUsed")) {
                    v.setValue(performance.getTotalCpuTimeUsed());
                }
                m.setValue(v);
                result.getMeasurements().put(property.getName(), m);
            }
        }
       
    }
View Full Code Here

Examples of eu.planets_project.pp.plato.model.measurement.Measurement

    protected void collectData(ToolConfig config, long time, MigrationResult result) {
        super.collectData(config, time, result);
        double totalTime = new Jip_Parser().getTotalTime(makeJIPOutFilename(time)+".txt");
       
        for (MeasurableProperty property: getMeasurableProperties()) {
            Measurement m = new Measurement();
            m.setProperty(property);
            PositiveFloatValue v = (PositiveFloatValue) property.getScale().createValue();
            if (property.getName().equals("performance:totalTimeInJava")) {
                v.setValue(totalTime);
            }
//            if (property.getName().equals(MigrationResult.MIGRES_USED_TIME)) {
//                v.setValue(totalTime);
//            }

            m.setValue(v);
            result.getMeasurements().put(property.getName(), m);
        }
    }
View Full Code Here

Examples of eu.scape_project.planning.model.measurement.Measurement

        }
        MigrationResult result = service.migrate(digitalObject.getData().getData(), action.getUrl(), settings);
        setResultName(result, digitalObject);

        long duration = (System.nanoTime() - start) / (1000000);
        service.addExperience(result.getFeedbackKey(), action.getUrl(), new Measurement("roundtripTimeMS", new Double(
            duration)));
        return result;
    }
View Full Code Here

Examples of moa.core.Measurement

    @Override
    public void getModelDescription(StringBuilder out, int indent) {}

    @Override
    protected Measurement[] getModelMeasurementsImpl() {
        return new Measurement[]{new Measurement("ensemble size",
                    this.ensemble != null ? this.ensemble.size() : 0)};
    }
View Full Code Here

Examples of org.jmol.modelset.Measurement

  private void setColor(short colix) {
    if (bsColixSet == null)
      bsColixSet = new BitSet();
      if (bsSelected == null)
        this.colix = colix;
    Measurement mt;
    for (int i = measurements.size(); --i >= 0; )
      if ((mt = (Measurement) measurements.get(i)) != null
          && (bsSelected != null && bsSelected.get(i) || bsSelected == null
              && (colix == Graphics3D.INHERIT_ALL || mt.getColix() == Graphics3D.INHERIT_ALL))) {
        mt.setColix(colix);
        bsColixSet.set(i);
      }
  }
View Full Code Here

Examples of org.jmol.modelset.Measurement

 
  private void toggle(Measurement m) {
    rangeMinMax[0] = Float.MAX_VALUE;
    //toggling one that is hidden should be interpreted as DEFINE
    int i = find(m);
    Measurement mt;
    if (i >= 0 && !(mt = (Measurement) measurements.get(i)).isHidden()) // delete it and all like it
      define(i, mt, true, false, false);
    else // define OR turn on if measureAllModels
      define(-1, m, false, true, false);
    setIndices();
View Full Code Here

Examples of org.jmol.modelset.Measurement

  private void toggleOn(int[] indices) {
    rangeMinMax[0] = Float.MAX_VALUE;
    //toggling one that is hidden should be interpreted as DEFINE
    bsSelected = new BitSet();
    define(Integer.MIN_VALUE, new Measurement(modelSet, indices, null, defaultTickInfo), false, true, true);
    setIndices();
    reformatDistances();
  }
View Full Code Here

Examples of org.jmol.modelset.Measurement

    setIndices();
  }

  private void delete(Object value) {
    if (value instanceof int[]) {
      define(Integer.MIN_VALUE, new Measurement(modelSet, (int[])value, null, null), true, false, false);
      return;
    }
    if ((value instanceof Integer))
      deleteMeasurement(((Integer)value).intValue());  
  }
View Full Code Here

Examples of org.jmol.modelset.Measurement

      ((Measurement) measurements.get(i)).setHidden(false);
      if (doSelect)
        bsSelected.set(i);
      return;
    }
    Measurement measureNew = new Measurement(modelSet, m, value, colix,
        strFormat, measurementCount);
    measurements.add(measureNew);
    viewer.setStatusMeasuring("measureCompleted", measurementCount++,
        measureNew.toVector().toString(), measureNew.getValue());
  }
View Full Code Here

Examples of org.jmol.modelset.Measurement

    }
    return info;
  }
 
  private Hashtable getInfo(int index) {
    Measurement m = (Measurement) measurements.get(index);
    int count = m.getCount();
    Hashtable info = new Hashtable();
    info.put("index", new Integer(index));
    info.put("type", (count == 2 ? "distance" : count == 3 ? "angle"
        : "dihedral"));
    info.put("strMeasurement", m.getString());
    info.put("count", new Integer(count));
    info.put("value", new Float(m.getValue()));
    TickInfo tickInfo = m.getTickInfo();
    if (tickInfo != null) {
      info.put("ticks", tickInfo.ticks);
      if (tickInfo.scale != null)
        info.put("tickScale", tickInfo.scale);
      if (tickInfo.tickLabelFormats != null)
        info.put("tickLabelFormats", tickInfo.tickLabelFormats);
      if (!Float.isNaN(tickInfo.first))
        info.put("tickStart", new Float(tickInfo.first));
    }
    List atomsInfo = new ArrayList();
    for (int i = 1; i <= count; i++) {
      Hashtable atomInfo = new Hashtable();
      int atomIndex = m.getAtomIndex(i);
      atomInfo.put("_ipt", new Integer(atomIndex));
      atomInfo.put("coord", Escape.escape(m.getAtom(i)));
      atomInfo.put("atomno", new Integer(atomIndex < 0 ? -1 : atoms[atomIndex].getAtomNumber()));
      atomInfo.put("info", (atomIndex < 0 ? "<point>" : atoms[atomIndex].getInfo()));
      atomsInfo.add(atomInfo);
    }
    info.put("atoms", atomsInfo);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.