/// <summary> /// The deep copy constructor. /// </summary> /// <param name="source">The source instance.</param> public TNRNetClusterProbabilisticWeightsSettings(TNRNetClusterProbabilisticWeightsSettings source) : this(source.TrainingGroupWeight, source.TestingGroupWeight, source.SamplesWeight, source.NumericalPrecisionWeight, source.MisrecognizedFalseWeight, source.UnrecognizedTrueWeight) { return; }
//Constructors /// <summary> /// Creates an unitialized instance. /// </summary> /// <param name="networksCfg">The configuration of the cluster networks.</param> /// <param name="weightsCfg">The configuration of the macro-weights.</param> public TNRNetClusterProbabilisticSettings(TNRNetClusterProbabilisticNetworksSettings networksCfg, TNRNetClusterProbabilisticWeightsSettings weightsCfg ) { NetworksCfg = (TNRNetClusterProbabilisticNetworksSettings)networksCfg.DeepClone(); WeightsCfg = (TNRNetClusterProbabilisticWeightsSettings)weightsCfg.DeepClone(); Check(); return; }
/// <summary> /// Creates an initialized instance. /// </summary> /// <param name="elem">A xml element containing the configuration data.</param> public TNRNetClusterProbabilisticSettings(XElement elem) { //Validation XElement settingsElem = Validate(elem, XsdTypeName); //Parsing NetworksCfg = new TNRNetClusterProbabilisticNetworksSettings(settingsElem.Element("networks")); WeightsCfg = new TNRNetClusterProbabilisticWeightsSettings(settingsElem.Element("weights")); Check(); return; }