AForge.Fuzzy.InferenceSystem.SetInput C# (CSharp) Метод

SetInput() публичный Метод

Sets a numerical input for one of the linguistic variables of the Database.
The variable indicated in /// was not found in the database.
public SetInput ( string variableName, float value ) : void
variableName string Name of the .
value float Numeric value to be used as input.
Результат void
        public void SetInput( string variableName, float value )
        {
            this.database.GetVariable( variableName ).NumericInput = value;
        }

Usage Example

Пример #1
0
        private byte Modify(InferenceSystem system, int[] windowData, byte center)
        {
            for (int i = 0; i < windowSize*windowSize - 1; i++)
            {
                system.SetInput(String.Format("IN{0}", i), windowData[i]);
            }

            int x = center + (byte) system.Evaluate("OUT");
            if (x < 0)
            {
                return 0;
            }

            if (x > 255)
            {
                return 255;
            }

            return (byte) x;
        }
All Usage Examples Of AForge.Fuzzy.InferenceSystem::SetInput