public class PrototypeEntryGenerator extends BaseEntryGenerator
Usage: <site info> -site <order> <spacing>
<elements...> [-site <...>]
Note: You must define the "-site" information for each site in the prototype
in the order they are listed in the "site info" file.
PrototypeDataset
Modifier and Type | Field and Description |
---|---|
protected java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Integer,java.lang.Double>> |
AllowedMixing
Allowed mixing on each site.
|
protected java.util.List<java.util.Set<java.lang.Integer>> |
SiteElements
Lists of possible elements on each site
|
protected PrototypeSiteInformation |
SiteInfo
Description of sites on prototype
|
Constructor and Description |
---|
PrototypeEntryGenerator() |
Modifier and Type | Method and Description |
---|---|
void |
defineSitePossibilities(int index,
int order,
double spacing,
java.util.Collection<java.lang.String> possibSiteElements)
Define the possible compositions for each site.
|
static java.util.List<java.util.List<CompositionEntry>> |
generateCombinations(java.util.List<java.util.Set<java.lang.Integer>> possibleElements,
java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Integer,java.lang.Double>> generationSettings)
Generate all possible combinations of compositions generated using
a list of settings.
|
boolean |
isSet()
Check whether this generator is ready to go.
|
java.util.Iterator<BaseEntry> |
iterator() |
java.lang.String |
printUsage()
Print out required format for options.
|
void |
setOptions(java.util.List<java.lang.Object> Options)
Set any options for this object.
|
void |
setSiteInfo(PrototypeSiteInformation info)
Define the information about the sites in the prototype.
|
addEntriesToDataset, generateEntries, train
protected PrototypeSiteInformation SiteInfo
protected final java.util.List<java.util.Set<java.lang.Integer>> SiteElements
protected final java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Integer,java.lang.Double>> AllowedMixing
public void setOptions(java.util.List<java.lang.Object> Options) throws java.lang.Exception
Options
Options
- Array of options as Objects - can be null
java.lang.Exception
- if problem with inputspublic void setSiteInfo(PrototypeSiteInformation info)
info
- Definition for the prototypepublic java.lang.String printUsage()
Options
public void defineSitePossibilities(int index, int order, double spacing, java.util.Collection<java.lang.String> possibSiteElements) throws java.lang.Exception
index
- Index of siteorder
- Maximum number of elements on sitesspacing
- Spacing between elements in at%possibSiteElements
- Abbreviations of possible elements for each sitejava.lang.Exception
public boolean isSet()
public java.util.Iterator<BaseEntry> iterator()
public static java.util.List<java.util.List<CompositionEntry>> generateCombinations(java.util.List<java.util.Set<java.lang.Integer>> possibleElements, java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Integer,java.lang.Double>> generationSettings)
possibleElements
- Possible elements on each sitegenerationSettings
- Order of mixing to have on each site, and
desired spacing