Пример #1
0
 /// <summary>
 /// Create a SQL neural data set.
 /// </summary>
 /// <param name="sql">The SQL to execute.</param>
 /// <param name="inputSize">The size of the input data being read.</param>
 /// <param name="idealSize">The size of the ideal output data being read.</param>
 /// <param name="connectString">The connection string.</param>
 public SQLMLDataSet(String sql, int inputSize,
                     int idealSize, String connectString)
 {
     IDataSetCODEC codec = new SQLCODEC(sql, inputSize, idealSize, connectString);
     var load = new MemoryDataLoader(codec) {Result = this};
     load.External2Memory();
 }
Пример #2
0
 public SQLMLDataSet(string sql, int inputSize, int idealSize, string connectString)
 {
     MemoryDataLoader loader2;
     if ((((uint) idealSize) + ((uint) inputSize)) >= 0)
     {
         IDataSetCODEC codec = new SQLCODEC(sql, inputSize, idealSize, connectString);
         loader2 = new MemoryDataLoader(codec) {
             Result = this
         };
     }
     loader2.External2Memory();
 }
Пример #3
0
 public CSVMLDataSet(string filename, int inputSize, int idealSize, bool headers, CSVFormat format, bool expectSignificance)
 {
     this._xb41a802ca5fde63b = filename;
     this._x7e648b416c264559 = inputSize;
     if (-2 != 0)
     {
         this._x08b9e0820ab2b457 = idealSize;
     }
     this._x5786461d089b10a0 = format;
     this._x94e6ca5ac178dbd0 = headers;
     IDataSetCODEC codec = new CSVDataCODEC(filename, format, headers, inputSize, idealSize, expectSignificance);
     MemoryDataLoader loader2 = new MemoryDataLoader(codec) {
         Result = this
     };
     loader2.External2Memory();
 }
        /// <summary>
        /// Construct this data set using a comma as a delimiter.
        /// </summary>
        /// <param name="filename">The CSV filename to read.</param>
        /// <param name="inputSize">The number of columns that make up the input set.</param>
        /// <param name="idealSize">The number of columns that make up the ideal set.</param>
        /// <param name="headers">True if headers are present on the first line.</param>
        /// <param name="format">The format to use.</param>
        public CSVMLDataSet(String filename, int inputSize,
                            int idealSize, bool headers, CSVFormat format, bool expectSignificance)
        {
            _filename = filename;
            _inputSize = inputSize;
            _idealSize = idealSize;
            _format = format;
            _headers = headers;

            IDataSetCODEC codec = new CSVDataCODEC(filename, format, headers, inputSize, idealSize, expectSignificance);
            var load = new MemoryDataLoader(codec) {Result = this};
            load.External2Memory();
        }
Пример #5
0
 /// <summary>
 /// Load CSV to memory.
 /// </summary>
 /// <param name="filename">The CSV file to load.</param>
 /// <param name="input">The input count.</param>
 /// <param name="ideal">The ideal count.</param>
 /// <param name="headers">True, if headers are present.</param>
 /// <param name="format">The loaded dataset.</param>
 /// <param name="expectSignificance">The loaded dataset.</param>
 /// <returns></returns>
 public static IMLDataSet LoadCSV2Memory(String filename, int input, int ideal, bool headers, CSVFormat format, bool expectSignificance)
 {
     IDataSetCODEC codec = new CSVDataCODEC(filename, format, headers, input, ideal, expectSignificance);
     var load = new MemoryDataLoader(codec);
     IMLDataSet dataset = load.External2Memory();
     return dataset;
 }