FMV GP tool error; FMV calculate corner coordinates

1416
5
Jump to solution
10-28-2016 12:39 AM
MichalGasiorowski
New Contributor III

I have one remark and one question regarding FMV geoprocessing tools.

Remark:

I have 64-bit background geoprocessing intalled and enabled (ArcMap 10.4, FMV 1.3.1, Win 7 64bit). With this settings FMV geoprocessing tools returs error: "ERROR 000816: The tool is not valid." Only after I disable background geoprocessing, FMV GP tools work. Maybe worth checking?

Question:

I've got a video from sample acquisition which is almost suitable for FMV.

The aircraft positions are displayed as well as the frame centers. However, the frame outlines are not.

I thought about using Video Multiplexer to calculate corner coordinates but I don't have an external metadata file.

What should be the workflow to calculate missing corner coordinates?

0 Kudos
1 Solution

Accepted Solutions
JeffLiedtke
Occasional Contributor II

Michal,

I appreciate your follow up, especially since I had a misconception.  I had the impression that the metadata was displayed on the video during playing only, and was not encoded in the video stream - which is not an unusual occurrence.  However, it sounds like your metadata is indeed encoded in the video stream, and if this is true, the workflow you outline is correct. An added step is that you need to strip the metadata from your video before you can multiplex it into a MISB-compliant format the FMV Add-In can utilize.  Let me summarize the workflow to be clear.

1) Start playing your video, then display the video metadata table that shows metadata values as the video plays.  This sets up the environment.  Stop playing the video.

2) In the metadata display window, select Record and navigate to an output directory and assign a name to the CSV metadata file to be created.

3) In the video player, go back to the very beginning of the video (00:00:00:00).  Play the video which will also record the associated metadata at the same time and write the data to a metadata file on disk.

4) Strip the metadata from your video. Download and/or open VLC Media Player (free download). In VLC, main toolbar in the Media tab, choose Convert/Save. This opens a dialog; select your video on disk, then select Convert. This flips the dialog window to the Convert parameters, choose a video format and write to disk location. This process will export the video data to another disk file without metadata.

5) Review your metadata CSV file – open in MS Excel. You can either map your metadata field names using the Video_Multiplexer_MISB_Field_Mapping_Template.csv, or change the names of your metadata fields to be the MISB tag names.

6) The time stamp needs to be in UNIX time, use the converter at http://www.epochconverter.com/ to make sure your time is UNIX time in microseconds (16 digits). Convert the first time stamp and the last time stamp, then subtract the first timestamp from the last timestamp to get the total time range of your metadata.  This should match the length of your video as a check.

7) In Excel, divide the total time range in (6) above by the number of metadata records to get the average increment change. Then in the second record in your metadata table, add this increment change to the first timestamp value to get the proper timestamp value for the 2nd record. Select the first 2 cells in the timestamp column (one containing the beginning UNIX timestamp and the 2nd contains the incremental value added to the first value) and drag this formula all the way to your last record. All the timestamp records should be incremented properly.

8) Create a new column in your spreadsheet, and copy all the timestamp values computed by the formula into this new column as a value. Then delete the timestamp computed by the formula column and retain the UNIX timestamp written as values column.

9) Excel insists on storing large numbers in scientific notation. When you save your updated csv file, make sure it is saved with the UNIX timestamp column [format cells] saved as a number with zero decimal places.

10) Use the FMV GP tool Video Multiplexer with the inputs being the new VLC video, the metadata csv file and the Video_Multiplexer_MISB_Field_Mapping_Template.csv.

 

If you do not have video frame corner coordinates, nor the required sensor attitude info, you will only be able to display the ground track of the sensor on the map.

 

If you have the sensor location and the center of the video frame on the ground (in map projected space), I can see how the video frame could be computed using the Field of View and trigonometry, but that requires the talents of someone well versed in coordinate mathematics and is beyond the scope of this workaround.

All the Best!

Jeff

View solution in original post

5 Replies
MichalGasiorowski
New Contributor III

JLiedtke-esristaff‌, any hints on my question?

0 Kudos
JeffLiedtke
Occasional Contributor II

Michal,

Thanks for the heads up regarding the 64-bit background processing issue with the FMV geoprocessing tools.  This is a known issue but we don't have a solution for it yet.

Regarding the necessary parameters to compute the 4 corners of the video frame - the sensor orientation parameters are needed to compute the transform between the video frame and the map display.  It sounds like you have the sensor position displayed on the video, but this information would need to output to a csv file along with the time stamp to see the sensor position displayed on the map as a ground track.   Additionally, the attitude parameters are also needed, including heading, pitch, roll, altitude and field of view.  We don't have a work-around if these required parameters are not provided in a CSV. 

Regards,

Jeff

0 Kudos
MichalGasiorowski
New Contributor III

Thanks for answer. Not a good news.

I thought about the following approach:

- use Extract Metadata from Video to obtain feature classes with metadata,

- convert metadata to CSV,

- possibly prepare fields mapping

- and then using Multiplexer.

Do you think it's worth trying?

0 Kudos
JeffLiedtke
Occasional Contributor II

Michal,

I appreciate your follow up, especially since I had a misconception.  I had the impression that the metadata was displayed on the video during playing only, and was not encoded in the video stream - which is not an unusual occurrence.  However, it sounds like your metadata is indeed encoded in the video stream, and if this is true, the workflow you outline is correct. An added step is that you need to strip the metadata from your video before you can multiplex it into a MISB-compliant format the FMV Add-In can utilize.  Let me summarize the workflow to be clear.

1) Start playing your video, then display the video metadata table that shows metadata values as the video plays.  This sets up the environment.  Stop playing the video.

2) In the metadata display window, select Record and navigate to an output directory and assign a name to the CSV metadata file to be created.

3) In the video player, go back to the very beginning of the video (00:00:00:00).  Play the video which will also record the associated metadata at the same time and write the data to a metadata file on disk.

4) Strip the metadata from your video. Download and/or open VLC Media Player (free download). In VLC, main toolbar in the Media tab, choose Convert/Save. This opens a dialog; select your video on disk, then select Convert. This flips the dialog window to the Convert parameters, choose a video format and write to disk location. This process will export the video data to another disk file without metadata.

5) Review your metadata CSV file – open in MS Excel. You can either map your metadata field names using the Video_Multiplexer_MISB_Field_Mapping_Template.csv, or change the names of your metadata fields to be the MISB tag names.

6) The time stamp needs to be in UNIX time, use the converter at http://www.epochconverter.com/ to make sure your time is UNIX time in microseconds (16 digits). Convert the first time stamp and the last time stamp, then subtract the first timestamp from the last timestamp to get the total time range of your metadata.  This should match the length of your video as a check.

7) In Excel, divide the total time range in (6) above by the number of metadata records to get the average increment change. Then in the second record in your metadata table, add this increment change to the first timestamp value to get the proper timestamp value for the 2nd record. Select the first 2 cells in the timestamp column (one containing the beginning UNIX timestamp and the 2nd contains the incremental value added to the first value) and drag this formula all the way to your last record. All the timestamp records should be incremented properly.

8) Create a new column in your spreadsheet, and copy all the timestamp values computed by the formula into this new column as a value. Then delete the timestamp computed by the formula column and retain the UNIX timestamp written as values column.

9) Excel insists on storing large numbers in scientific notation. When you save your updated csv file, make sure it is saved with the UNIX timestamp column [format cells] saved as a number with zero decimal places.

10) Use the FMV GP tool Video Multiplexer with the inputs being the new VLC video, the metadata csv file and the Video_Multiplexer_MISB_Field_Mapping_Template.csv.

 

If you do not have video frame corner coordinates, nor the required sensor attitude info, you will only be able to display the ground track of the sensor on the map.

 

If you have the sensor location and the center of the video frame on the ground (in map projected space), I can see how the video frame could be computed using the Field of View and trigonometry, but that requires the talents of someone well versed in coordinate mathematics and is beyond the scope of this workaround.

All the Best!

Jeff

View solution in original post

MichalGasiorowski
New Contributor III

Jeff,

Thank you so much for your time and super detailed explanation.

Finally I was able to generate a video with data frame on the ground. However, I had to select "Calculate corner coordinates..." option.

This is very strange because my original exported metadata already contains corner coordinates and the CSV file structure is almost the same as FVM sample video Cheyenne.

0 Kudos