Hi Gerald,
I was just solving same problem this weekend (Garradd at M71).
In theory, problem is simple (but not automated in PI).
1) You need to have all pictures registered on stars, so comet movement between frames is linear.
2) You need to measure distance of the comet between two frames (ideally first one and last one)
3) Knowing time of each shot (from image metadata), you can easily compute position of the comet on each frame using simple linear interpolation.
4) You need to shift each picture by corresponding offset in x and y.
This is how I did it:
1) I simply registered all frames with StarAlignment
2) I took first and last frame and using DynamicAlignment, I measured distance of the comet (simply by selecting comet core on each frame and reading dx and dy from the dialog.
3) Now the tricky part. I'm using DSLR, so I needed to extract time of the exposure for each frame (DSLR Exif metadata). I do not know any way how to get it in PixInsight (and even if readed from RAW file, they will be lost in FIT conversion, calibration and registration process). So, I used DeepSkyStacker to get the data. I simply opened all RAW files in DeepSkyStacker, selected all data from file table (right-bottom) and Ctrl+C copied them to clipboard. Two columns of the table were interesting - name of the file and time of the exposure.
Pasting the table to Excel and knowing comet pixel distance between first and the last frame, I easily computed dx and dy for each frame. I used the frame in the middle as reference one.
4) Then I wrote simple script in PixInsight to load each star-registered picture, shift it using Image.translate(dx, dy) method and save it under new name. Array of dx and dy values was simply copy-pasted from Excel (thus hardcoded in the script).
Here is my single-purpose script with hardcoded data:
var files = new Array("CRW_2749",
"CRW_2750",
"CRW_2751",
"CRW_2752",
"CRW_2753",
"CRW_2754",
"CRW_2755",
"CRW_2757",
"CRW_2758",
"CRW_2759",
"CRW_2760",
"CRW_2768",
"CRW_2769",
"CRW_2770",
"CRW_2771",
"CRW_2773",
"CRW_2774",
"CRW_2775",
"CRW_2776",
"CRW_2778",
"CRW_2779",
"CRW_2780",
"CRW_2782",
"CRW_2783",
"CRW_2784",
"CRW_2785",
"CRW_2786",
"CRW_2787",
"CRW_2788",
"CRW_2789",
"CRW_2790",
"CRW_2791"
);
var dx = new Array(-61.60326087,
-56.68478261,
-52.5,
-49.02173913,
-45.57065217,
-42.0923913,
-38.64130435,
-33.99456522,
-30.51630435,
-27.06521739,
-23.58695652,
-10.02717391,
-6.684782609,
-3.342391304,
0,
4.211956522,
7.554347826,
10.89673913,
14.23913043,
20.73369565,
24.07608696,
27.41847826,
33.28804348,
36.63043478,
39.97282609,
43.31521739,
46.6576087,
50,
53.3423913,
56.68478261,
60.05434783,
63.39673913
);
var dy = new Array(-6.012478261,
-5.532434783,
-5.124,
-4.784521739,
-4.447695652,
-4.108217391,
-3.771391304,
-3.317869565,
-2.978391304,
-2.641565217,
-2.302086957,
-0.978652174,
-0.652434783,
-0.326217391,
0,
0.411086957,
0.737304348,
1.063521739,
1.38973913,
2.023608696,
2.349826087,
2.676043478,
3.248913043,
3.575130435,
3.901347826,
4.227565217,
4.553782609,
4.88,
5.206217391,
5.532434783,
5.861304348,
6.187521739
);
var numFiles = files.length;
var path = "F:/astrofoto/110826_Garrad_M71/"
for (var i = 0; i < numFiles; i++)
{
var sourceName = "r_debayer_c_"+files[i]+".fit";
var sourceWindow = ImageWindow.open(path+sourceName);
var sourceView = sourceWindow[0].mainView;
sourceView.beginProcess();
sourceView.image.translate(dx[i], dy[i]);
sourceView.endProcess();
sourceWindow[0].saveAs(path+"cs_"+sourceName, false, false, false, false);
sourceWindow[0].forceClose();
gc();
}
There could be improvements to this workflow. I assume if one have FITs instead of RAWs, you can read time of the exposure directly from the script (just guessing, I'm not sure).
The script can also be easily reused (with little modification) to take integrated star-free comet image and subtract it from each of the original frames with corresponding shift, leaving comet-free images to be stacked separately and then combined with the integrated comet image (I did it).
Here is my result:

Not as good I as hoped - due to unexpected problems with autoguider, I had to resort to manual guiding (what a terrible experience) and star size far from ideal.
hope it helps,
Zbynek