Index: /trunk/magic/remove/src/streaksremove.c
===================================================================
--- /trunk/magic/remove/src/streaksremove.c	(revision 20942)
+++ /trunk/magic/remove/src/streaksremove.c	(revision 20943)
@@ -16,4 +16,5 @@
 
     psLibInit(NULL);
+    psTimerStart("STREAKSREMOVE");
 
     pmConfig *config = parseArguments(argc, argv);
@@ -61,8 +62,11 @@
         // if no skycells are provided sfiles->exciseAll is set to true
 
+        psTimerStart("COMPUTE_WARPED_PIXELS");
         if (! computeWarpedPixels(sfiles) ) {
             // we have no choice to excise all pixels
             exciseAll = true;
         }
+        psF64 cwp_t = psTimerClear("COMPUTE_WARPED_PIXELS");
+        printf("time to compute warped pixels: %f\n", cwp_t);
     }
     
@@ -81,4 +85,6 @@
     do {
         bool exciseImageCube = false;
+
+        psTimerStart("PROCESS_COMPONENT");
 
         // read the images and copy the data from the inputs to the outputs
@@ -95,17 +101,20 @@
             // Identify pixels to mask because of streaks
 
+            psTimerStart("GET_STREAK_PIXELS");
+
             StreakPixels *pixels = getStreakPixels(sfiles, streaks);
 
-            // XXX: 
-            // 
-            // PFS: Need to get mask weight for PM_MASK_DETECTOR.  Is this stored
-            // in a config somewhere?  Not sure how to properly set the maskValue.
-
+            printf("time to get streak pixels: %f\n", psTimerClear("GET_STREAK_PIXELS"));
 
             if (checkNonWarpedPixels) {
+                psTimerStart("EXCISE_NON_WARPED");
+
                 exciseNonWarpedPixels(sfiles, maskStreak);
+
+                printf("time to excise non warped pixels: %f\n", psTimerClear("EXCISE_NON_WARPED"));
             }
             
             if (sfiles->inImage->image) {
+                psTimerStart("REMOVE_STREAKS");
                 for (int i = 0; i < psArrayLength (pixels); ++i) {
                     PixelPos *pixelPos = psArrayGet (pixels, i);
@@ -120,4 +129,5 @@
                     }
                 }
+                printf("time to remove streak pixels: %f\n", psTimerClear("REMOVE_STREAKS"));
             } else { 
                 // this component contains an image cube, excise it completely
@@ -130,8 +140,12 @@
         writeImages(sfiles, exciseImageCube);
 
+        printf("time to process component %d: %f\n", sfiles->extnum, psTimerClear("PROCESS_COMPONENT"));
     } while (streakFilesNextExtension(sfiles));
 
+
+    psTimerStart("CLOSE_IMAGES");
     // close all files
     closeImages(sfiles);
+    printf("time to close images: %f\n", psTimerClear("CLOSE_IMAGES"));
 
     // NOTE: from here on we can't just quit if something goes wrong.
@@ -175,4 +189,6 @@
     }
 #endif  // REPLACE, REMOVE
+    printf("time to run streaksremove: %f\n", psTimerClear("STREAKSREMOVE"));
+
     // nebServerFree(ourNebServer);
     psFree(config);
@@ -183,4 +199,5 @@
     //  PAU
     fprintf(stderr, "Found %d leaks at %s\n", psMemCheckLeaks (0, NULL, NULL, false), "streaksremove");
+
 
     return 0;
