Beispiel #1
0
 public override void Input(Floatarray v, int i)
 {
     v.Resize(data.Dim(1));
     for (int j = 0; j < v.Dim(0); j++)
     {
         v.UnsafePut1d(j, data[i, j]);
     }
 }
Beispiel #2
0
        public Floatarray AsArray()
        {
            Floatarray result = new Floatarray();

            result.Resize(Length());
            result.Fill(0f);
            for (int i = 0; i < _keys.Length(); i++)
            {
                result.UnsafePut1d(_keys.UnsafeAt1d(i), _values.UnsafeAt1d(i));
            }
            return(result);
        }
Beispiel #3
0
 public Floatarray AsArray()
 {
     Floatarray result = new Floatarray();
     result.Resize(Length());
     result.Fill(0f);
     for (int i = 0; i < _keys.Length(); i++)
         result.UnsafePut1d(_keys.UnsafeAt1d(i), _values.UnsafeAt1d(i));
     return result;
 }
Beispiel #4
0
 public override void Input(Floatarray v, int i)
 {
     v.Resize(data.Dim(1));
     for (int j = 0; j < v.Dim(0); j++)
         v.UnsafePut1d(j, data[i, j]);
 }