Definition at line 33 of file Model.java.
Public Member Functions | |
Model () throws JetWebException | |
Model (ResultSearchPattern pattern) throws JetWebException | |
Model (int newmodelId) throws JetWebException | |
boolean | store () throws JetWebException |
boolean | retrieve () throws JetWebException |
int | getId () |
Date | getDate () |
Vector< RunSeries > | getRunSeries (MCProcessType proc) throws JetWebException |
RunSeriesCollection | getRunSeriesCollection () |
void | setRunSeriesCollection (RunSeriesCollection rsc) |
void | setId (int id) |
boolean | predicts (DataPlot plot) throws JetWebException |
void | zero (MCProcessType proc) |
void | addAllRunSeries () throws JetWebException |
Enumeration< Match > | getNonMatchingParameters () |
Vector< PDF > | getProtonPDFList () |
getProtonPDF (int i) throws JetWebException | |
getProtonPDF () throws JetWebException | |
Vector< PDF > | getPhotonPDFList () |
getPhotonPDF (int i) throws JetWebException | |
getPhotonPDF () throws JetWebException | |
Vector< Generator > | getGeneratorList () |
Generator | getGenerator (int i) throws JetWebException |
Generator | getGenerator () throws JetWebException |
void | setGenerator (Generator gen) |
String | getDescription () |
ResultSearchPattern | setDescription (String description) |
Double | getPthat () throws JetWebException |
Object | clone () |
boolean | matches (RunSeries runSeries) throws JetWebException |
boolean | matches (Model model) throws JetWebException |
boolean | matches (ResultSearchPattern pattern) throws JetWebException |
void | dumpParms () |
String | getParms () |
void | setSoftDefaults () throws JetWebException |
void | setDefaults () throws JetWebException |
Vector< Model > | getConsistentModels () throws JetWebException |
Static Public Member Functions | |
List< Model > | getModels (final ResultSearchPattern pattern, final String sort) throws JetWebException |
Protected Attributes | |
String | description_ |
Vector< Generator > | generatorList |
Vector< PDF > | protonpdfList |
Vector< PDF > | photonpdfList |
Vector< Match > | notMatching = new Vector<Match>() |
Package Functions | |
private< T1, T2 > boolean | compare (String name, HashMap< T1, T2 > map1, HashMap< T1, T2 > map2, Generator gen) |
Private Member Functions | |
void | setFrom (ResultSearchPattern pattern) throws JetWebException |
Private Attributes | |
Integer | modelId = -1 |
int | runSeriesCollectionId |
RunSeriesCollection | runSeriesCollection |
|
Build an empty Model. Definition at line 42 of file Model.java. 00042 {
00043
00044 // Make a Model.
00045 super();
00046
00047 }
|
|
Build a model from a ResultSearchPattern. Any variables not specified will be set to their default values. The modelId is not set. I
Definition at line 57 of file Model.java. References RunSeriesCollection.add(), RunSeriesCollection.getId(), Model.runSeriesCollection, Model.setFrom(), and ResultSearchPattern.setSoftDefaults(). 00057 { 00058 00059 // Make a Model. 00060 super(); 00061 00062 // Reset any of the parameters from the pattern which were set 00063 // (nulls & blanks are ignored). 00064 00065 setFrom(pattern); 00066 00067 // Set the remaining unset parameters to default values. 00068 setSoftDefaults(); 00069 00070 Vector<Model> existingModels = pattern.getConsistentModels(); 00071 00072 HashMap<Integer, RunSeriesCollection> existingRSCs = 00073 new HashMap<Integer, RunSeriesCollection>(); 00074 00075 for(Model model: existingModels){ 00076 00077 if(this.matches(model)){ 00078 00079 RunSeriesCollection rsc = model.getRunSeriesCollection(); 00080 00081 if(!existingRSCs.containsKey(rsc.getId())){ 00082 existingRSCs.put(rsc.getId(), rsc); 00083 } 00084 } 00085 } 00086 00087 Vector<RunSeriesCollection> compatibleRSCs = 00088 new Vector<RunSeriesCollection>(); 00089 00090 for(Map.Entry<Integer, RunSeriesCollection> entry: 00091 existingRSCs.entrySet()){ 00092 boolean compatible = true; 00093 for(RunSeries rs: entry.getValue().getRunSeriesList()){ 00094 if(compatible){ 00095 compatible = rs.matches(this); 00096 00097 } 00098 } 00099 00100 if(compatible){ 00101 compatibleRSCs.add(entry.getValue()); 00102 } 00103 00104 } 00105 00106 if(compatibleRSCs.size()==0){ 00107 00108 // Add a new runSeriesCollection for this model. 00109 runSeriesCollection = new RunSeriesCollection(); 00110 00111 }else if(compatibleRSCs.size()==1){ 00112 runSeriesCollection = compatibleRSCs.get(0); 00113 00114 }else{ 00115 //shouldn't ever get here I think! 00116 runSeriesCollection = new RunSeriesCollection(); 00117 00118 for(RunSeriesCollection rsc: compatibleRSCs){ 00119 for(RunSeries rs: rsc.getRunSeriesList()){ 00120 runSeriesCollection.add(rs); 00121 } 00122 } 00123 } 00124 00125 if(pattern instanceof RunSeries){ 00126 runSeriesCollection.add((RunSeries)pattern); 00127 } 00128 00129 }
|
|
Build a model from the DB.
Definition at line 138 of file Model.java. References RunSeriesCollection.getId(), Model.modelId, Model.retrieve(), and Model.runSeriesCollection. 00138 { 00139 super(); 00140 System.out.println("Making new Model by id = "+newmodelId); 00141 modelId=newmodelId; 00142 retrieve(); 00143 00144 System.out.println("rsc Id = "+runSeriesCollection.getId()); 00145 00146 }
|
|
Find all the runseries which are consistent with this model and add them to it.
Definition at line 275 of file Model.java. References RunSeriesCollection.add(), RunSeriesCollection.getId(), and Model.runSeriesCollection. Referenced by JobUtils.doJobRequest(), and JobUtils.updateJobs(). 00275 { 00276 00277 // Loop over all valid processTypes (i.e. those which can be 00278 // generated solo, in a single run series. 00279 Vector<MCProcessType> procList = MCProcessType.getAll(true); 00280 00281 for (MCProcessType proc : procList){ 00282 00283 Vector<RunSeries> rsList = DBManager.getConsistentRunSeries(proc,this); 00284 00285 //System.out.println("Model: rsList = " + rsList); 00286 00287 System.out.println("model.addAllRunSeries(): rsc Id = "+ 00288 runSeriesCollection.getId()); 00289 00290 for (RunSeries runSeries : rsList) { 00291 System.out.println("Model.addAllRunSeries(): Adding runseries " 00292 + runSeries.getId()); 00293 runSeriesCollection.add(runSeries); 00294 00295 System.out.println("model.addAllRunSeries(): now rsc Id = "+ 00296 runSeriesCollection.getId()); 00297 00298 } 00299 } 00300 }
|
|
Definition at line 216 of file ResultSearchPattern.java. References ResultSearchPattern.generatorList, ResultSearchPattern.notMatching, ResultSearchPattern.photonpdfList, ResultSearchPattern.protonpdfList, and ResultSearchPattern.ResultSearchPattern(). 00216 { 00217 ResultSearchPattern newPattern = new ResultSearchPattern(); 00218 newPattern.generatorList = 00219 (this.generatorList==null) ? null : 00220 new Vector<Generator>(this.generatorList); 00221 newPattern.protonpdfList = 00222 (this.protonpdfList==null) ? null : 00223 new Vector<PDF>(this.protonpdfList); 00224 newPattern.photonpdfList = 00225 (this.photonpdfList==null) ? null : 00226 new Vector<PDF>(this.photonpdfList); 00227 newPattern.notMatching = 00228 (this.notMatching==null) ? null : 00229 new Vector<Match>(this.notMatching); 00230 00231 return newPattern; 00232 }
|
|
Definition at line 307 of file ResultSearchPattern.java. References ResultSearchPattern.notMatching. 00308 { 00309 00310 boolean match = true; 00311 00312 for(Map.Entry<T1, T2> entry: map1.entrySet()){ 00313 T1 key = entry.getKey(); 00314 boolean inModel = true; 00315 if(key instanceof Integer){ 00316 inModel = gen.inModel(name, (Integer)key); 00317 } 00318 if(inModel && map2.containsKey(key)){ 00319 T2 val1 = map2.get(key); 00320 T2 val2 = entry.getValue(); 00321 00322 if(val1!=null && val2 !=null && 00323 !Match.compare(val1, val2)){ 00324 match = false; 00325 if(!match){ 00326 //if(val1 instanceof Double){ 00327 // val1 = (T2)JetWebConfig.getFormat().format(val1); 00328 // val2 = (T2)JetWebConfig.getFormat().format(val2); 00329 //} 00330 System.out.println("Failed comparison on " + 00331 name + ": " + key + "." + 00332 val1 + "!=" + val2); 00333 00334 notMatching.add 00335 (new Match(name+":"+key.toString(), val1, val2)); 00336 } 00337 } 00338 } 00339 } 00340 00341 return match; 00342 }
|
|
Writes all the parameters to standard output. Definition at line 550 of file ResultSearchPattern.java. References ResultSearchPattern.getParms(). Referenced by JobRequest.main(). 00550 { 00551 00552 System.out.println(getParms()); 00553 00554 }
|
|
Return all models consistent with this pattern. Reimplemented in RunSeries. Definition at line 616 of file ResultSearchPattern.java. Referenced by Fit.getFits(). 00616 { 00617 return DBManager.getConsistentModels(this); 00618 }
|
|
Return the last date that anything was added for this model.
Definition at line 206 of file Model.java. References RunSeriesCollection.getDate(), and Model.runSeriesCollection. Referenced by DBFitManager.fill(), and Model.getModels(). 00206 { 00207 return runSeriesCollection.getDate(); 00208 }
|
|
Return a description of this model. Definition at line 175 of file ResultSearchPattern.java. 00175 {
00176 return description_;
00177 }
|
|
Gets a generator
Reimplemented in RunSeries. Definition at line 188 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.getPthat(), and ResultSearchPattern.matches(). 00188 { 00189 return getGenerator(0); 00190 }
|
|
Gets a generator
Reimplemented in RunSeries. Definition at line 147 of file ResultSearchPattern.java. References ResultSearchPattern.generatorList. Referenced by Searcher.doGet(), JobUtils.doJobRequest(), HTMLJobWriter.getDescription(), HTMLWriter.listHiddenPars(), JobRequest.main(), JobUtils.makeCards(), ServletUtils.makePattern(), ResultSearchPattern.matches(), and HTMLFitWriter.writeVerbose(). 00147 { 00148 if (generatorList!=null) { 00149 try { 00150 return (Generator)generatorList.elementAt(i); 00151 } catch (ArrayIndexOutOfBoundsException a){ 00152 throw new JetWebException(a,"Index was "+i+":"); 00153 } 00154 } else { 00155 return null; 00156 } 00157 }
|
|
Gets list of generators
Reimplemented in RunSeries. Definition at line 138 of file ResultSearchPattern.java. References ResultSearchPattern.generatorList. Referenced by Searcher.doGet(), ResultSearchPattern.getParms(), HTMLModelWriter.listNonDefaults(), ServletUtils.makePattern(), RunSeries.RunSeries(), ResultSearchPattern.setDefaults(), and ResultSearchPattern.setSoftDefaults(). 00138 { 00139 if (generatorList==null) { generatorList = new Vector<Generator>(); } 00140 return generatorList; 00141 }
|
|
Return the unique ID of this model
Implements Storeable. Definition at line 184 of file Model.java. References RunSeriesCollection.getId(), and Model.modelId. Referenced by DBFitManager.fill(), Fit.Fit(), DBManager.getConsistentModels(), HTMLModelWriter.listDifferences(), HTMLModelWriter.listNonDefaults(), Model.store(), Fit.store(), and HTMLFitWriter.writeVerbose(). 00184 { 00185 00186 00187 if(modelId.equals(-1)){ 00188 try{ 00189 modelId = -2; 00190 modelId = DBManager.getId(this); 00191 }catch(JetWebException err){ 00192 System.out.println(err.getMessage()); 00193 } 00194 } 00195 if(modelId<0) modelId=-1; 00196 return(modelId); 00197 00198 }
|
|
Returns a list of models matching a given ResultSearchPattern and sorted by sort.
Definition at line 332 of file Model.java. References ResultSearchPattern.compare(), Model.getDate(), and ResultSearchPattern.getPthat(). 00333 { 00334 00335 List<Model> list = new ArrayList<Model>(); 00336 00337 System.out.println("Model: Looking for models for "+pattern.getGenerator()); 00338 00339 // Build a list of Models which are consistent with this ResultSearchPattern 00340 list.addAll(pattern.getConsistentModels()); 00341 00342 //sort the fitList according to the "sort" input 00343 Comparator listSort = new Comparator() { 00344 public int compare(Object o1, Object o2) { 00345 Model m1 = (Model)o1; 00346 Model m2 = (Model)o2; 00347 int sortResult=0; 00348 try { 00349 if (sort.equals(HTMLUtils.PTHAT)){ 00350 sortResult = m2.getPthat().compareTo(m1.getPthat()); 00351 00352 } else if (sort.equals(HTMLUtils.DATE)){ 00353 sortResult = m1.getDate().compareTo(m2.getDate()); 00354 00355 /* 00356 00357 } else if (sort.equals(HTMLUtils.CHI2ALL)){ 00358 CutBand band1 = (CutBand)j1.bands.get(CutBand.ALL); 00359 CutBand band2 = (CutBand)j2.bands.get(CutBand.ALL); 00360 sortResult = (new Double(band2.getChi2Total()/band2.getDOFTotal())) 00361 .compareTo((new Double(band1.getChi2Total()/band1.getDOFTotal()))); 00362 } else if (sort.equals(HTMLUtils.CHI2HIGH)){ 00363 CutBand band1 = (CutBand)j1.bands.get(CutBand.HI); 00364 CutBand band2 = (CutBand)j2.bands.get(CutBand.HI); 00365 sortResult = (new Double(band2.getChi2Total()/band2.getDOFTotal()) ) 00366 .compareTo((new Double(band1.getChi2Total()/band1.getDOFTotal()))); 00367 } else if (sort.equals(HTMLUtils.CHI2LOW)){ 00368 CutBand band1 = (CutBand)j1.bands.get(CutBand.LO); 00369 CutBand band2 = (CutBand)j2.bands.get(CutBand.LO); 00370 sortResult = (new Double(band2.getChi2Total()/band2.getDOFTotal()) ) 00371 .compareTo((new Double(band1.getChi2Total()/band1.getDOFTotal()))); 00372 } else if (sort.equals(HTMLUtils.CHI2SHAPE)){ 00373 CutBand band1 = (CutBand)j1.bands.get(CutBand.SHAPE); 00374 CutBand band2 = (CutBand)j2.bands.get(CutBand.SHAPE); 00375 sortResult = (new Double(band2.getChi2Total()/band2.getDOFTotal()) ) 00376 .compareTo((new Double(band1.getChi2Total()/band1.getDOFTotal()))); 00377 } else if (sort.equals(HTMLUtils.CHI2CHARM)){ 00378 CutBand band1 = (CutBand)j1.bands.get(CutBand.CHARM); 00379 CutBand band2 = (CutBand)j2.bands.get(CutBand.CHARM); 00380 sortResult = (new Double(band2.getChi2Total()/band2.getDOFTotal()) ) 00381 .compareTo((new Double(band1.getChi2Total()/band1.getDOFTotal()))); 00382 00383 } else if (sort.equals(HTMLUtils.CHI2ALLEP)){ 00384 CutBand band1 = (CutBand)j1.bands.get(CutBand.ALL); 00385 CutBand band2 = (CutBand)j2.bands.get(CutBand.ALL); 00386 sortResult = (new Double(band2.getChi2Ep()/band2.getDOFEp())) 00387 .compareTo((new Double(band1.getChi2Ep()/band1.getDOFEp()))); 00388 } else if (sort.equals(HTMLUtils.CHI2HIGHEP)){ 00389 CutBand band1 = (CutBand)j1.bands.get(CutBand.HI); 00390 CutBand band2 = (CutBand)j2.bands.get(CutBand.HI); 00391 sortResult = (new Double(band2.getChi2Ep()/band2.getDOFEp()) ) 00392 .compareTo((new Double(band1.getChi2Ep()/band1.getDOFEp()))); 00393 } else if (sort.equals(HTMLUtils.CHI2LOWEP)){ 00394 CutBand band1 = (CutBand)j1.bands.get(CutBand.LO); 00395 CutBand band2 = (CutBand)j2.bands.get(CutBand.LO); 00396 sortResult = (new Double(band2.getChi2Ep()/band2.getDOFEp()) ) 00397 .compareTo((new Double(band1.getChi2Ep()/band1.getDOFEp()))); 00398 } else if (sort.equals(HTMLUtils.CHI2SHAPEEP)){ 00399 CutBand band1 = (CutBand)j1.bands.get(CutBand.SHAPE); 00400 CutBand band2 = (CutBand)j2.bands.get(CutBand.SHAPE); 00401 sortResult = (new Double(band2.getChi2Ep()/band2.getDOFEp()) ) 00402 .compareTo((new Double(band1.getChi2Ep()/band1.getDOFEp()))); 00403 } else if (sort.equals(HTMLUtils.CHI2CHARMEP)){ 00404 CutBand band1 = (CutBand)j1.bands.get(CutBand.CHARM); 00405 CutBand band2 = (CutBand)j2.bands.get(CutBand.CHARM); 00406 sortResult = (new Double(band2.getChi2Ep()/band2.getDOFEp()) ) 00407 .compareTo((new Double(band1.getChi2Ep()/band1.getDOFEp()))); 00408 00409 } else if (sort.equals(HTMLUtils.CHI2ALLEE)){ 00410 CutBand band1 = (CutBand)j1.bands.get(CutBand.ALL); 00411 CutBand band2 = (CutBand)j2.bands.get(CutBand.ALL); 00412 sortResult = (new Double(band2.getChi2Ee()/band2.getDOFEe())) 00413 .compareTo((new Double(band1.getChi2Ee()/band1.getDOFEe()))); 00414 } else if (sort.equals(HTMLUtils.CHI2HIGHEE)){ 00415 CutBand band1 = (CutBand)j1.bands.get(CutBand.HI); 00416 CutBand band2 = (CutBand)j2.bands.get(CutBand.HI); 00417 sortResult = (new Double(band2.getChi2Ee()/band2.getDOFEe()) ) 00418 .compareTo((new Double(band1.getChi2Ee()/band1.getDOFEe()))); 00419 } else if (sort.equals(HTMLUtils.CHI2LOWEE)){ 00420 CutBand band1 = (CutBand)j1.bands.get(CutBand.LO); 00421 CutBand band2 = (CutBand)j2.bands.get(CutBand.LO); 00422 sortResult = (new Double(band2.getChi2Ee()/band2.getDOFEe()) ) 00423 .compareTo((new Double(band1.getChi2Ee()/band1.getDOFEe()))); 00424 } else if (sort.equals(HTMLUtils.CHI2SHAPEEE)){ 00425 CutBand band1 = (CutBand)j1.bands.get(CutBand.SHAPE); 00426 CutBand band2 = (CutBand)j2.bands.get(CutBand.SHAPE); 00427 sortResult = (new Double(band2.getChi2Ee()/band2.getDOFEe()) ) 00428 .compareTo((new Double(band1.getChi2Ee()/band1.getDOFEe()))); 00429 } else if (sort.equals(HTMLUtils.CHI2CHARMEE)){ 00430 CutBand band1 = (CutBand)j1.bands.get(CutBand.CHARM); 00431 CutBand band2 = (CutBand)j2.bands.get(CutBand.CHARM); 00432 sortResult = (new Double(band2.getChi2Ee()/band2.getDOFEe()) ) 00433 .compareTo((new Double(band1.getChi2Ee()/band1.getDOFEe()))); 00434 00435 } else if (sort.equals(HTMLUtils.CHI2ALLPP)){ 00436 CutBand band1 = (CutBand)j1.bands.get(CutBand.ALL); 00437 CutBand band2 = (CutBand)j2.bands.get(CutBand.ALL); 00438 sortResult = (new Double(band2.getChi2Pp()/band2.getDOFPp())) 00439 .compareTo((new Double(band1.getChi2Pp()/band1.getDOFPp()))); 00440 } else if (sort.equals(HTMLUtils.CHI2HIGHPP)){ 00441 CutBand band1 = (CutBand)j1.bands.get(CutBand.HI); 00442 CutBand band2 = (CutBand)j2.bands.get(CutBand.HI); 00443 sortResult = (new Double(band2.getChi2Pp()/band2.getDOFPp()) ) 00444 .compareTo((new Double(band1.getChi2Pp()/band1.getDOFPp()))); 00445 } else if (sort.equals(HTMLUtils.CHI2LOWPP)){ 00446 CutBand band1 = (CutBand)j1.bands.get(CutBand.LO); 00447 CutBand band2 = (CutBand)j2.bands.get(CutBand.LO); 00448 sortResult = (new Double(band2.getChi2Pp()/band2.getDOFPp()) ) 00449 .compareTo((new Double(band1.getChi2Pp()/band1.getDOFPp()))); 00450 } else if (sort.equals(HTMLUtils.CHI2SHAPEPP)){ 00451 CutBand band1 = (CutBand)j1.bands.get(CutBand.SHAPE); 00452 CutBand band2 = (CutBand)j2.bands.get(CutBand.SHAPE); 00453 sortResult = (new Double(band2.getChi2Pp()/band2.getDOFPp()) ) 00454 .compareTo((new Double(band1.getChi2Pp()/band1.getDOFPp()))); 00455 } else if (sort.equals(HTMLUtils.CHI2CHARMPP)){ 00456 CutBand band1 = (CutBand)j1.bands.get(CutBand.CHARM); 00457 CutBand band2 = (CutBand)j2.bands.get(CutBand.CHARM); 00458 sortResult = (new Double(band2.getChi2Pp()/band2.getDOFPp()) ) 00459 .compareTo((new Double(band1.getChi2Pp()/band1.getDOFPp()))); 00460 */ 00461 00462 } 00463 } catch (NumberFormatException e){ 00464 System.out.println("Model: number format exception in sorting of results by " 00465 + sort); 00466 } catch (JetWebException e1){ 00467 System.out.println("Model: JetWebException thrown " 00468 + sort); 00469 e1.printStackTrace(System.out); 00470 } catch (NullPointerException e2){ 00471 System.out.println("Model:NullPointerException in sorting of results by " 00472 + sort); 00473 e2.printStackTrace(System.out); 00474 } 00475 return -1*sortResult; 00476 } 00477 }; 00478 00479 Collections.sort(list,listSort); 00480 return list; 00481 00482 }
|
|
Returns enumeration of Match objects - results of matching this pattern with another Definition at line 60 of file ResultSearchPattern.java. References ResultSearchPattern.notMatching. 00060 { 00061 return notMatching.elements(); 00062 }
|
|
Writes all the parameters to a String.
Definition at line 561 of file ResultSearchPattern.java. References ResultSearchPattern.getGeneratorList(), ResultSearchPattern.getPhotonPDFList(), ResultSearchPattern.getProtonPDFList(), and PDF.toString(). Referenced by ResultSearchPattern.dumpParms(). 00561 { 00562 00563 StringBuffer b = new StringBuffer("----------------------------"); 00564 00565 b.append("\nGenerator "+this.getGeneratorList()); 00566 b.append("\nPhoton "+this.getPhotonPDFList()); 00567 b.append("\nProton "+this.getProtonPDFList()); 00568 return b.toString(); 00569 00570 }
|
|
Gets photon particle density function
Reimplemented in RunSeries. Definition at line 129 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.matches(). 00129 { 00130 return getPhotonPDF(0); 00131 }
|
|
Gets photon particle density function
Definition at line 112 of file ResultSearchPattern.java. References ResultSearchPattern.photonpdfList. Referenced by HTMLJobWriter.getDescription(), and HTMLWriter.listHiddenPars(). 00112 { 00113 00114 if (photonpdfList!=null && i<photonpdfList.size()) { 00115 try { 00116 return photonpdfList.elementAt(i); 00117 } catch (ArrayIndexOutOfBoundsException a){ 00118 throw new JetWebException(a,"Index was "+i+":"); 00119 } 00120 } else { 00121 return null; 00122 } 00123 }
|
|
Gets a list of photon particle density functions
Reimplemented in RunSeries. Definition at line 103 of file ResultSearchPattern.java. References ResultSearchPattern.photonpdfList. Referenced by ResultSearchPattern.getParms(), JobRequest.main(), FileDownloader.makeCards(), ServletUtils.makePattern(), RunSeries.RunSeries(), ResultSearchPattern.setDefaults(), and ResultSearchPattern.setSoftDefaults(). 00103 { 00104 if (photonpdfList==null) { photonpdfList = new Vector<PDF>(); } 00105 return photonpdfList; 00106 }
|
|
Gets proton particle density function
Reimplemented in RunSeries. Definition at line 94 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.matches(). 00094 { 00095 return getProtonPDF(0); 00096 }
|
|
Gets proton particle density function
Definition at line 78 of file ResultSearchPattern.java. References ResultSearchPattern.protonpdfList. Referenced by HTMLJobWriter.getDescription(), and HTMLWriter.listHiddenPars(). 00078 { 00079 if (protonpdfList!=null && i < protonpdfList.size()) { 00080 try { 00081 return protonpdfList.elementAt(i); 00082 } catch (ArrayIndexOutOfBoundsException a){ 00083 throw new JetWebException(a,"Index was "+i+":"); 00084 } 00085 } else { 00086 return null; 00087 } 00088 }
|
|
Gets a list of proton particle density functions
Reimplemented in RunSeries. Definition at line 69 of file ResultSearchPattern.java. References ResultSearchPattern.protonpdfList. Referenced by ResultSearchPattern.getParms(), JobRequest.main(), FileDownloader.makeCards(), ServletUtils.makePattern(), RunSeries.RunSeries(), ResultSearchPattern.setDefaults(), and ResultSearchPattern.setSoftDefaults(). 00069 { 00070 if (protonpdfList==null) { protonpdfList = new Vector<PDF>(); } 00071 return protonpdfList; 00072 }
|
|
Gets PTHAT, the cutoff which seperates hard from soft scatters. In general this corresponds to a different parameter in each different generator, and should be provided by the generator class eventually. If its worth it... yes it is needed for the plotswitches.
Definition at line 200 of file ResultSearchPattern.java. References ResultSearchPattern.getGenerator(). Referenced by Fit.getFits(), and Model.getModels(). 00200 { 00201 return getGenerator().getPthat(); 00202 }
|
|
Gets a list of all runSeries matching a given process type.
Definition at line 216 of file Model.java. References RunSeriesCollection.getRunSeriesList(), and Model.runSeriesCollection. Referenced by JobUtils.doJobRequest(), Fit.getChi2(), and HTMLFitWriter.writeVerbose(). 00217 { 00218 if(runSeriesCollection==null){ 00219 return new Vector<RunSeries>(); 00220 } 00221 00222 return runSeriesCollection.getRunSeriesList(proc); 00223 }
|
|
Gets the runseries collection.
Definition at line 230 of file Model.java. Referenced by FittedPlot.getMCProcessType(). 00230 {
00231 return runSeriesCollection;
00232 }
|
|
Checks whether this pattern is consistent with a ResultSearchPattern. An unspecified attribute on EITHER pattern will match ANY value of the attribute on the other pattern.
Definition at line 382 of file ResultSearchPattern.java. References ResultSearchPattern.matches(). 00382 { 00383 return matches(pattern,null); 00384 }
|
|
Checks whether this pattern is consistent with a Model. An unspecified attribute on EITHER pattern will match ANY value of the attribute on the other pattern.
Definition at line 369 of file ResultSearchPattern.java. References ResultSearchPattern.matches(). 00369 { 00370 return matches(model,null); 00371 }
|
|
Checks whether this pattern is consistent with a runseries. An unspecified attribute on EITHER pattern will match ANY value of the attribute on the other pattern.
Definition at line 355 of file ResultSearchPattern.java. Referenced by DBManager.getConsistentModels(), DBManager.getConsistentRunSeries(), and ResultSearchPattern.matches(). 00355 { 00356 return matches(runSeries,runSeries.getMCProcessType()); 00357 }
|
|
Returns true if there is any predicted data available for this plot using this model. Definition at line 248 of file Model.java. References RunSeriesCollection.contains(), and Model.runSeriesCollection. 00248 { 00249 return runSeriesCollection.contains(plot); 00250 }
|
|
Populate the object in memory from the database. Return true if the information retrieved is up to date. Implements Storeable. Definition at line 174 of file Model.java. Referenced by Model.Model(). 00174 { 00175 DBManager.selectFromDB(this); 00176 return true; 00177 }
|
|
Set all parameters to their default values. Definition at line 597 of file ResultSearchPattern.java. References ResultSearchPattern.generatorList, ResultSearchPattern.getGeneratorList(), ResultSearchPattern.getPhotonPDFList(), and ResultSearchPattern.getProtonPDFList(). Referenced by Searcher.doGet(), HTMLModelWriter.listNonDefaults(), and JobRequest.main(). 00597 { 00598 00599 getProtonPDFList().clear(); 00600 getProtonPDFList().add(JetWebConfig.defaultProtonPDF); 00601 00602 getPhotonPDFList().clear(); 00603 getPhotonPDFList().add(JetWebConfig.defaultPhotonPDF); 00604 00605 // Default generator 00606 getGeneratorList().clear(); 00607 Generator gen = Generator.Maker(); 00608 gen.setDefaults(); 00609 generatorList.add(gen); 00610 00611 }
|
|
Definition at line 179 of file ResultSearchPattern.java. References ResultSearchPattern.description_. Referenced by ServletUtils.makePattern(). 00179 { 00180 description_ = description; 00181 return this; 00182 }
|
|
Definition at line 304 of file Model.java. References RunSeriesCollection.add(). Referenced by Model.Model(). 00304 { 00305 00306 generatorList = new Vector<Generator>(); 00307 protonpdfList = new Vector<PDF>(); 00308 photonpdfList = new Vector<PDF>(); 00309 00310 Generator gen = pattern.getGenerator(); 00311 PDF protPDF = pattern.getProtonPDF(); 00312 PDF photPDF = pattern.getPhotonPDF(); 00313 00314 if(gen!=null) generatorList.add(pattern.getGenerator()); 00315 if(protPDF!=null) protonpdfList.add(pattern.getProtonPDF()); 00316 if(photPDF!=null) photonpdfList.add(pattern.getPhotonPDF()); 00317 00318 description_ = pattern.getDescription(); 00319 00320 }
|
|
Clear the list, then add the input Generator to it. Reimplemented in RunSeries. Definition at line 162 of file ResultSearchPattern.java. References ResultSearchPattern.generatorList. Referenced by Searcher.doGet(). 00162 { 00163 if (generatorList==null){ 00164 generatorList = new Vector<Generator>(); 00165 } else { 00166 generatorList.clear(); 00167 } 00168 generatorList.add(gen); 00169 }
|
|
Definition at line 241 of file Model.java. References Model.modelId. 00241 { 00242 modelId=id; 00243 }
|
|
Sets the runseries collection. Definition at line 237 of file Model.java. References Model.runSeriesCollection. 00237 { 00238 runSeriesCollection = rsc; 00239 }
|
|
Set any parameters which are not set to their default values. Definition at line 576 of file ResultSearchPattern.java. References ResultSearchPattern.getGeneratorList(), ResultSearchPattern.getPhotonPDFList(), and ResultSearchPattern.getProtonPDFList(). Referenced by Searcher.doGet(), JetWebLogReader.fillLog(), and Model.Model(). 00576 { 00577 00578 if (getProtonPDFList().size()==0) 00579 getProtonPDFList().add(JetWebConfig.defaultProtonPDF); 00580 if (getPhotonPDFList().size()==0) 00581 getPhotonPDFList().add(JetWebConfig.defaultPhotonPDF); 00582 00583 // Default generator 00584 if (getGeneratorList().size()==0) { 00585 // add a default generator 00586 Generator gen = Generator.Maker(); 00587 gen.setDefaults(); 00588 getGeneratorList().add(gen); 00589 } else { 00590 for (Generator gen : generatorList) 00591 gen.setSoftDefaults(); 00592 } 00593 }
|
|
Note that once stored, Models cannot be changed. So if you try to store a Model which has an ID which exists in the DB, this method will NOT change the database or the Model, but will simply return false. The ID of the Model will be set by this method, if it was not set already. The runSeriesCollection ID will also be set, if possible. Implements Storeable. Definition at line 159 of file Model.java. References RunSeriesCollection.getId(), Model.getId(), Model.runSeriesCollection, and RunSeriesCollection.store(). Referenced by JobUtils.doJobRequest(), JobUtils.getNewData(), and JobUtils.updateJobs(). 00159 { 00160 00161 // First the runSeriesCollection. 00162 System.out.println("Model: storing rsc for model "+getId()); 00163 00164 System.out.println("model.store(): rsc id = "+runSeriesCollection.getId()); 00165 00166 DBManager.selectId(runSeriesCollection); 00167 boolean added = DBManager.addToDB(this); 00168 runSeriesCollection.store(); 00169 return added; 00170 00171 }
|
|
Remove all data from the RunSeries which match the given process type. Definition at line 256 of file Model.java. References RunSeries.getLogFiles(), RunSeriesCollection.getRunSeriesList(), and Model.runSeriesCollection. 00256 { 00257 00258 Enumeration<RunSeries> rsList = runSeriesCollection.getRunSeriesList(proc).elements(); 00259 while (rsList.hasMoreElements()){ 00260 RunSeries rs = rsList.nextElement(); 00261 Enumeration<LogFile> logs = rs.getLogFiles().elements(); 00262 JobUtils.moveLogs(logs,"run/edit"); 00263 DBManager.zero(rs); 00264 } 00265 }
|
|
Definition at line 35 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.setDescription(). |
|
List of generators. Definition at line 40 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.clone(), ResultSearchPattern.getGenerator(), ResultSearchPattern.getGeneratorList(), RunSeries.RunSeries(), ResultSearchPattern.setDefaults(), and ResultSearchPattern.setGenerator(). |
|
Definition at line 35 of file Model.java. Referenced by Model.getId(), Model.Model(), and Model.setId(). |
|
Vector of Match objects - contains differences between this pattern and another. Definition at line 54 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.clone(), ResultSearchPattern.compare(), ResultSearchPattern.getNonMatchingParameters(), and ResultSearchPattern.matches(). |
|
List of Photon Particle Density Functions Definition at line 48 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.clone(), ResultSearchPattern.getPhotonPDF(), ResultSearchPattern.getPhotonPDFList(), and RunSeries.RunSeries(). |
|
List of Proton Particle Density Functions Definition at line 44 of file ResultSearchPattern.java. Referenced by ResultSearchPattern.clone(), ResultSearchPattern.getProtonPDF(), ResultSearchPattern.getProtonPDFList(), and RunSeries.RunSeries(). |
|
Definition at line 37 of file Model.java. Referenced by Model.addAllRunSeries(), Model.getDate(), Model.getRunSeries(), Model.Model(), Model.predicts(), Model.setRunSeriesCollection(), Model.store(), and Model.zero(). |
|
Definition at line 36 of file Model.java. |
Generated Wed Jan 17 09:14:27 GMT 2007