private void ImportImage(PicesDataBase threadConn, String fileName ) { String rootName = OSservices.GetRootName(fileName); String picesRootName = sipperFileName + "_" + rootName; PicesDataBaseImage dbi = threadConn.ImageLoad(picesRootName); if (dbi != null) { return; } PicesRaster r = new PicesRaster(fileName); r = r.Padded(2); PicesFeatureVector fv = new PicesFeatureVector(r, picesRootName, null, runLog); fv.ExampleFileName = picesRootName; int imageId = 0; bool successful = false; uint centroidRow = (uint)(0.5f + fv.CentroidRow); uint centroidCol = (uint)(0.5f + fv.CentroidCol); if ((centroidRow < 0) || (centroidRow > r.Height)) { centroidRow = (uint)(r.Height / 2); } if ((centroidCol < 0) || (centroidCol > r.Width)) { centroidCol = (uint)(r.Width / 2); } threadConn.ImageInsert(r, picesRootName, sipperFileName, 0, 0, 0, (uint)r.Height, (uint)r.Width, (uint)fv.OrigSize, 3, extractionLogEntryId.LogEntryId, extractionLogEntryId.LogEntryId, centroidRow, centroidCol, unknownClass, 1.0f, null, 0.0f, null, 0.0f, // depth, 0.0f, // Image Size null, ref imageId, ref successful ); if (successful) { threadConn.FeatureDataInsertRow(sipperFileName, fv); } else { RunLogAddMsg("RootName[" + rootName + "] Failed: " + threadConn.LastErrorDesc() + "\n"); } } /* ImportImage */