Package eu.scape_project.planning.model.scales

Examples of eu.scape_project.planning.model.scales.PositiveFloatScale


        if (scale instanceof PositiveIntegerScale) {
            PositiveIntegerScale s = (PositiveIntegerScale) scale;
            scaleUpperBound = s.getUpperBound();
        }
        if (scale instanceof PositiveFloatScale) {
            PositiveFloatScale s = (PositiveFloatScale) scale;
            scaleUpperBound = s.getUpperBound();
        }

        // At Range Scales lowerBound and upperBound have to be fetched
        if (scale instanceof IntRangeScale) {
            IntRangeScale s = (IntRangeScale) scale;
            scaleUpperBound = s.getUpperBound();
        }
        if (scale instanceof FloatRangeScale) {
            FloatRangeScale s = (FloatRangeScale) scale;
            scaleUpperBound = s.getUpperBound();
        }

        return scaleUpperBound;
    }
View Full Code Here


                PositiveIntegerScale s = (PositiveIntegerScale) scale;
                scaleLowerBound = 0;
                scaleUpperBound = s.getUpperBound();
            }
            if (scale instanceof PositiveFloatScale) {
                PositiveFloatScale s = (PositiveFloatScale) scale;
                scaleLowerBound = 0;
                scaleUpperBound = s.getUpperBound();
            }

            // At Range Scales lowerBound and upperBound have to be fetched
            if (scale instanceof IntRangeScale) {
                IntRangeScale s = (IntRangeScale) scale;
                scaleLowerBound = s.getLowerBound();
                scaleUpperBound = s.getUpperBound();
            }
            if (scale instanceof FloatRangeScale) {
                FloatRangeScale s = (FloatRangeScale) scale;
                scaleLowerBound = s.getLowerBound();
                scaleUpperBound = s.getUpperBound();
            }

            // get Transformer tresholds
            NumericTransformer nt = (NumericTransformer) transformer;
            double transformerT1 = nt.getThreshold1();
View Full Code Here

                if (MeasureConstants.IMAGE_CONTENT_IS_EQUAL.equals(measureUri)) {
                    mode = "equal";
                    scale = new BooleanScale();
                } else if (MeasureConstants.ABSOLUTE_ERROR_AE.equals(measureUri)) {
                    mode = "ae";
                    scale = new PositiveFloatScale();
                } else if (MeasureConstants.PEAK_ABSOLUTE_ERROR_PAE.equals(measureUri)) {
                    mode = "pae";
                    scale = new PositiveFloatScale();
                } else if (MeasureConstants.PEAK_SIGNAL_TO_NOISE_RATIO.equals(measureUri)) {
                    mode = "psnr";
                    scale = new PositiveFloatScale();
                } else if (MeasureConstants.MEAN_ABSOLUTE_ERROR.equals(measureUri)) {
                    mode = "mae";
                    scale = new PositiveFloatScale();
                } else if (MeasureConstants.MEAN_SQUARED_ERROR.equals(measureUri)) {
                    mode = "mse";
                    scale = new PositiveFloatScale();
                } else if (MeasureConstants.IMAGE_DISTANCE_RMSE.equals(measureUri)) {
                    mode = "rmse";
                    scale = new PositiveFloatScale();
                }

                if (mode != null) {
                    if (mode.equals("equal")) {
                        Double d = imageEvaluator.evaluate(tempDir.getAbsolutePath(), tempFiles.get(sample),
View Full Code Here

        numericTrans.setThreshold4(4d);
        numericTrans.setThreshold5(5d);
        leaf.setTransformer(numericTrans);

        // set scale
        PositiveFloatScale scale = new PositiveFloatScale();
        leaf.setScale(scale);

        // valueMap
        FloatValue v0 = new FloatValue();
        v0.setValue(0d);
View Full Code Here

        scales.add(new OrdinalScale());
        scales.add(new IntegerScale());
        scales.add(new IntRangeScale());
        scales.add(new FloatScale());
        scales.add(new FloatRangeScale());
        scales.add(new PositiveFloatScale());
        scales.add(new PositiveIntegerScale());
        scales.add(new FreeStringScale());

        for (Scale scale : scales) {
            scaleList.add(new SelectItem(scale.getClass().getCanonicalName(), scale.getDisplayName()));
View Full Code Here

                PositiveIntegerScale s = (PositiveIntegerScale) scale;
                scaleLowerBound = 0;
                scaleUpperBound = s.getUpperBound();
            }
            if (scale instanceof PositiveFloatScale) {
                PositiveFloatScale s = (PositiveFloatScale) scale;
                scaleLowerBound = 0;
                scaleUpperBound = s.getUpperBound();
            }

            // At Range Scales lowerBound and upperBound have to be fetched
            if (scale instanceof IntRangeScale) {
                IntRangeScale s = (IntRangeScale) scale;
                scaleLowerBound = s.getLowerBound();
                scaleUpperBound = s.getUpperBound();
            }
            if (scale instanceof FloatRangeScale) {
                FloatRangeScale s = (FloatRangeScale) scale;
                scaleLowerBound = s.getLowerBound();
                scaleUpperBound = s.getUpperBound();
            }

            // get Transformer thresholds
            NumericTransformer nt = (NumericTransformer) transformer;
            double transformerT1 = nt.getThreshold1();
View Full Code Here

        } else if ("FreeText".equalsIgnoreCase(scaleName)) {
            return new FreeStringScale();
        } else if ("Number".equalsIgnoreCase(scaleName)) {
            return new FloatScale();
        } else if ("PositiveNumber".equalsIgnoreCase(scaleName)) {
            return new PositiveFloatScale();
        } else if ("PositiveInteger".equalsIgnoreCase(scaleName)) {
            return new PositiveIntegerScale();
        } else if ("Ordinal".equalsIgnoreCase(scaleName)) {
            return new OrdinalScale();
        }
View Full Code Here

            }
        } catch (Exception e) {
            log.warn("invalid scale format, ignoring: "+TEXT,e);
        }
        //default behaviour: float scale and the TEXT as unit
        PositiveFloatScale v = new PositiveFloatScale();
        v.setUnit(TEXT);
        return v;
    }
View Full Code Here

        } catch (Exception e) {
          LoggerFactory.getLogger(PolicyNode.class).warn("invalid scale format, ignoring: "+getTEXT(),e);
        }

        //default behaviour: float scale and the TEXT as unit
        PositiveFloatScale v = new PositiveFloatScale();
        v.setUnit(getTEXT());
        return v;
    }
View Full Code Here

TOP

Related Classes of eu.scape_project.planning.model.scales.PositiveFloatScale

Copyright © 2018 www.massapicom. 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.