Search in sources :

Example 1 with ParameterKeyPath

use of gov.sandia.n2a.parms.ParameterKeyPath in project n2a by frothga.

the class FixedParameterSpacePanel method updateDetailsPanelFromTable.

protected void updateDetailsPanelFromTable(JTable tblParamSets) {
    int col = tblParamSets.getSelectedColumn();
    int row = tblParamSets.getSelectedRow();
    int run = (Integer) mdlParamSets.getValueAt(row, 0);
    if (col == -1 || row == -1) {
        pnlParamDetails.clearLeft("No Cell Selected");
    } else {
        pnlParamDetails.clearLeft();
        pnlParamDetails.addLeft("Run #", run, false, false, true);
        if (col > 0) {
            ParameterKeyPath P = (ParameterKeyPath) mdlParamSets.getParam(col);
            pnlParamDetails.addLeft("Parameter", P.toHtml(), false, true, true);
            pnlParamDetails.addLeft("Value", mdlParamSets.getValueAt(row, col), true, false, false);
        }
    }
}
Also used : ParameterKeyPath(gov.sandia.n2a.parms.ParameterKeyPath)

Example 2 with ParameterKeyPath

use of gov.sandia.n2a.parms.ParameterKeyPath in project n2a by frothga.

the class ParameterSpecGroupPanel method getParameterSpecGroup.

public ParameterSpecGroup getParameterSpecGroup() {
    ParameterSpecGroup group = new ParameterSpecGroup(validCardinality);
    for (ParameterSpecPanel pnlSpec : specPanels.keySet()) {
        // TODO: hierarchical?
        Object paramKey = pnlSpec.getParamBundle().getParameter().getKey();
        List<ParameterDomain> domains = pnlSpec.getParamBundle().getDomains();
        ParameterKeyPath keyPath = new ParameterKeyPath();
        for (ParameterDomain domain : domains) {
            keyPath.add(domain.getName());
        }
        keyPath.add(paramKey);
        ParameterSpecification spec = pnlSpec.getSpecification();
        group.add(keyPath, spec);
    }
    return group;
}
Also used : ConstantParameterSpecification(gov.sandia.umf.platform.ensemble.params.specs.ConstantParameterSpecification) ParameterSpecification(gov.sandia.n2a.parms.ParameterSpecification) UniformParameterSpecification(gov.sandia.umf.platform.ensemble.params.specs.UniformParameterSpecification) EvenSpacingParameterSpecification(gov.sandia.umf.platform.ensemble.params.specs.EvenSpacingParameterSpecification) ParameterKeyPath(gov.sandia.n2a.parms.ParameterKeyPath) ParameterDomain(gov.sandia.n2a.parms.ParameterDomain) ParameterSpecGroup(gov.sandia.umf.platform.ensemble.params.groups.ParameterSpecGroup)

Example 3 with ParameterKeyPath

use of gov.sandia.n2a.parms.ParameterKeyPath in project n2a by frothga.

the class ParameterSpecPanel method constructParamLabelText.

private Object constructParamLabelText() {
    ParameterKeyPath P = new ParameterKeyPath();
    for (ParameterDomain domain : bundle.getDomains()) {
        P.add(domain.getName());
    }
    P.add(bundle.getParameter().getKey());
    return "<html>" + P.toHtml(true) + "</html>";
}
Also used : ParameterKeyPath(gov.sandia.n2a.parms.ParameterKeyPath) ParameterDomain(gov.sandia.n2a.parms.ParameterDomain)

Aggregations

ParameterKeyPath (gov.sandia.n2a.parms.ParameterKeyPath)3 ParameterDomain (gov.sandia.n2a.parms.ParameterDomain)2 ParameterSpecification (gov.sandia.n2a.parms.ParameterSpecification)1 ParameterSpecGroup (gov.sandia.umf.platform.ensemble.params.groups.ParameterSpecGroup)1 ConstantParameterSpecification (gov.sandia.umf.platform.ensemble.params.specs.ConstantParameterSpecification)1 EvenSpacingParameterSpecification (gov.sandia.umf.platform.ensemble.params.specs.EvenSpacingParameterSpecification)1 UniformParameterSpecification (gov.sandia.umf.platform.ensemble.params.specs.UniformParameterSpecification)1