Author Topic: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread  (Read 850727 times)

Offline princess

  • Member
  • Posts: 65
  • Liked: 106
  • Likes Given: 25
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1540 on: 06/10/2014 10:37 PM »
One thing I have noticed is that as well as triple flips there are also quadruple flips. A quad flip is two flips right next to each other, a gap, and then two flips separated by one bit. I've included a zoom-in of one of the image files here, it shows a patch with only triple and quad flips.

Offline S.Paulissen

  • Full Member
  • ***
  • Posts: 378
  • Boston
  • Liked: 273
  • Likes Given: 425
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1541 on: 06/10/2014 11:00 PM »
One thing I have noticed is that as well as triple flips there are also quadruple flips. A quad flip is two flips right next to each other, a gap, and then two flips separated by one bit. I've included a zoom-in of one of the image files here, it shows a patch with only triple and quad flips.
The quad flip looks like two overlapping triple flips.  The first two flipped bits in a row are the beginning of two triple flip patterns.  The flip-fine-flip is the overlap between the two triple flips where the outer two flip and the inner one double flips, each triple flip correcting each other for that bit.

EDIT: wording change
« Last Edit: 06/10/2014 11:05 PM by Exclavion »
"An expert is a person who has found out by his own painful experience all the mistakes that one can make in a very narrow field." -Niels Bohr
Poster previously known as Exclavion going by his real name now.

Offline princess

  • Member
  • Posts: 65
  • Liked: 106
  • Likes Given: 25
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1542 on: 06/10/2014 11:07 PM »
The quad flip is two overlapping triple flips.  The first two flipped bits in a row are the beginning of two triple flip patterns.  The flip-fine-flip is the overlap between the two triple flips where the outer two flip and the inner one double flips, each triple flip correcting each other for that bit.

That makes so much sense, thanks for pointing that out - I hadn't realised that! So, whatever mechanism is causing that triple flip pattern can make two that overlap, that's interesting. What kind of mechanism could cause that pattern?

Offline S.Paulissen

  • Full Member
  • ***
  • Posts: 378
  • Boston
  • Liked: 273
  • Likes Given: 425
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1543 on: 06/10/2014 11:17 PM »
I was originally doubtful of my interpretation when I noticed that the triple flips were ALL green.  After looking at the full PNG you put up of a clean one, there are certainly quite a few red triple flips too.  It almost looks like 50%> are made up of triple flips but overlapping like crazy.

For random flips it sure seems unlikely that 75+% of flips are 1 to 0.  I can think of a few mechanisms it would be that way.  If the source is made up of mostly 1s the flip from 1 to 0 becomes proportionally more likely and it's still random. 

As for the mechanism for creating the triple pattern.... I have NO idea. 
"An expert is a person who has found out by his own painful experience all the mistakes that one can make in a very narrow field." -Niels Bohr
Poster previously known as Exclavion going by his real name now.

Offline Quialiss

  • Member
  • Posts: 75
  • Liked: 82
  • Likes Given: 29
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1544 on: 06/10/2014 11:26 PM »
One thing I have noticed is that as well as triple flips there are also quadruple flips. A quad flip is two flips right next to each other, a gap, and then two flips separated by one bit. I've included a zoom-in of one of the image files here, it shows a patch with only triple and quad flips.
The quad flip looks like two overlapping triple flips.  The first two flipped bits in a row are the beginning of two triple flip patterns.  The flip-fine-flip is the overlap between the two triple flips where the outer two flip and the inner one double flips, each triple flip correcting each other for that bit.

EDIT: wording change

Quickly looking to see if there are more of the double offsets..

Pattern                          occurrences
1000000000000011             7290          triple flip
11000000000000101           3263          triple +1 offset
101000000000001111         456           +2 offset
1001000000000011011       261            +3 offset
10001000000000110011     148            +4 offset

...and then they.. keep.. on.. going.  Continuing to find more of these in the more or less clean data.  Excuse me while I write up something to properly do this and see how many of the errors AREN'T triple flips. 


Offline S.Paulissen

  • Full Member
  • ***
  • Posts: 378
  • Boston
  • Liked: 273
  • Likes Given: 425
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1545 on: 06/10/2014 11:37 PM »
Unfortunately there are as many iterations of this as there are bits, n-12 times n.  Of course this number can be constrained to make it easier.  I'm sure you already realize this.

10000000000011000000
11000000000010100000
11100000000010010000
11110000000010001000
10110000000011101000
11010000000010111000
11111000000010000100
10111000000011100100
11011000000010110100
11101000000010011100
.... so on
"An expert is a person who has found out by his own painful experience all the mistakes that one can make in a very narrow field." -Niels Bohr
Poster previously known as Exclavion going by his real name now.

Offline princess

  • Member
  • Posts: 65
  • Liked: 106
  • Likes Given: 25
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1546 on: 06/11/2014 12:10 AM »
If the source is made up of mostly 1s the flip from 1 to 0 becomes proportionally more likely and it's still random. 

Yes, that's what we're seeing here. The MPEG4 encoder compresses each frame to a different size, but the TS stream must fit into a fixed bandwidth. If the MPEG4 frame is too small, the TS layer pads it with 0xff bytes (i.e. all 1s), and this padding nearly always occurs in a block at the end of a frame. So what you're seeing is where we have a huge block that we know should be all 1s, but some are flipped to 0s. That's why they mostly show up as green pixels.

But, as you noticed, there are other times when we can fix different areas, for example TS headers, timestamps, MPEG4 frame starts, things like that. In those areas we can detect if a 1 should be a 0 instead, and you get red pixels.

So as far as I can see, the flips are indeed random - it's just that we can detect flips far easier in the 0xff padding bytes, so we will have found proportionally far more of the "green" flips than the "red" ones. Even if they recovered the stage from the bottom of the sea and extracted the clean video so we could know every flip, there would still be more green flips than red because the raw stream contained lots more 1s than 0s (due to the presence of the padding bytes).

Offline Quialiss

  • Member
  • Posts: 75
  • Liked: 82
  • Likes Given: 29
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1547 on: 06/11/2014 01:12 AM »
Unfortunately there are as many iterations of this as there are bits, n-12 times n.  Of course this number can be constrained to make it easier.  I'm sure you already realize this.


Thus the need to pause and write up a quick tool to generate the patterns.   ;D .... which I haven't quite gotten around to writing yet, too many other things to do tonight.  However, the stats on only two overlapping 'triple flips' are of note.  I'll get back to this tomorrow with 3+ overlapping flips and pull out the stats on the probability of each of the flips, but for now:

bits involved in a known flip pattern, total flips in the chunk, chunks as per princess's last set of images with 188 byte width. 

668 out of 5404 identified in chunk 0
1623 out of 16571 identified in chunk 900
158 out of 2639 identified in chunk 1800
45 out of 497 identified in chunk 2700
319 out of 2002 identified in chunk 3600
62 out of 67 identified in chunk 4500
11 out of 45 identified in chunk 5400
28 out of 137 identified in chunk 6300
93 out of 983 identified in chunk 7200
178 out of 724 identified in chunk 8100
35 out of 80 identified in chunk 9000
192 out of 702 identified in chunk 9900
9 out of 154 identified in chunk 10800
169 out of 1363 identified in chunk 11700
58 out of 277 identified in chunk 12600
180 out of 663 identified in chunk 13500
9 out of 150 identified in chunk 14400
168 out of 2499 identified in chunk 15300
0 out of 22 identified in chunk 16200
12 out of 17 identified in chunk 17100
7 out of 15 identified in chunk 18000
544 out of 5693 identified in chunk 18900
0 out of 3314 identified in chunk 19800   ---will double check tomorrow to see if it's a bug in my script
13 out of 127 identified in chunk 20700
15 out of 95 identified in chunk 21600
------
10.39 % identified patterns

Offline Adaptation

  • Full Member
  • *
  • Posts: 160
  • Liked: 39
  • Likes Given: 38
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1548 on: 06/11/2014 05:39 AM »
I would postulate that the paired sets of disjointed bit flips where originally conjoined as the signal traveled through the air but the endianness during transmission differed from recording.  You may notice that the distance between the middles of the pairs of bit flip areas is about 16 pixels, that would imply 128 bit registers in the transmission and receiving equipment which is quite reasonable.

If my hypothesis is correct you should be able divide the stream into 128 bit sections, reverse the order within each section while maintaining the order from section to section.  Once done nearly all the disjointed bit flips should be conjoined and it should make it far easer to visualize meaningful patterns in the noise and predict areas where a bit flip is likely.  There is no reason to assume that the start of the 128 bit chucks will align with the start of a ts packet, but I do think it likely that they are byte aligned.

Assuming I am correct looking for patterns in the errors without correcting for this is similar to looking for patterns in a deck of cards that have been shuffled. 
« Last Edit: 06/11/2014 05:49 AM by Adaptation »

Offline princess

  • Member
  • Posts: 65
  • Liked: 106
  • Likes Given: 25
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1549 on: 06/11/2014 07:17 AM »
You may notice that the distance between the middles of the pairs of bit flip areas is about 16 pixels, that would imply 128 bit registers in the transmission and receiving equipment which is quite reasonable.

I'm not sure where you get the 128 bit figure from - these images are just visualisations of the raw bitstream where 1 pixel corresponds to 1 bit. The triple flips we're finding are a pattern within a 16 bit range, and there appears to be no obvious alignment to them.

Offline Sohl

  • Full Member
  • **
  • Posts: 238
  • Liked: 73
  • Likes Given: 209
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1550 on: 06/11/2014 12:49 PM »
I would postulate that the paired sets of disjointed bit flips where originally conjoined as the signal traveled through the air but the endianness during transmission differed from recording. 

 ???

How would endianness make any difference here?  I'd assume MPEG-4 is a stream of bits (no fundamental endianness) wrapped in the transport stream (TS) framework.  You either get the bits as they come or you don't.

I speculate that the receiver front-end was not able to effectively filter out large electro-magnetic noise spikes, and that an extra electrical impulse "rang" in the RF-front end circuit long enough to alter the bit sampling process.  But who knows? :o

While knowing the mechanism would be nice, if a majority of the corruption follows a predictable pattern, it will be possible to correct much of it without knowing the source.

Offline Okie_Steve

  • Full Member
  • **
  • Posts: 265
  • Oklahoma
  • Liked: 71
  • Likes Given: 101
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1551 on: 06/11/2014 01:13 PM »
How would endianness make any difference here?  I'd assume MPEG-4 is a stream of bits (no fundamental endianness) wrapped in the transport stream (TS) framework.  You either get the bits as they come or you don't.
Communications is frequently done with blocks and shift registers and tend to be "little endian" bit streams in my experience. Think about a Uart set for N81 as an example. Sending a byte of 0x40 (01000000) would present bits on the wire  as 0 (start bit)  0 0 0 0 0 0 1 0 1 (stop bit) in temporal order from left to right of this line. Without knowing anything about the encoder, transmission protocol, packet size and equipment it is all speculation though.

Offline SwissCheese

  • Full Member
  • *
  • Posts: 164
  • Liked: 249
  • Likes Given: 80
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1552 on: 06/11/2014 01:39 PM »
I just corrected most of part 3 (frames 47-60). I won't be able to do anything more until Sunday or Monday, going for a small holiday trip :)

So on my side frames 42-46 remain to be checked, as well as ~10 p-frames in part 4. I-frames 241 and 281 could also have smoother colors.

Otherwise it's maybe time to generate the full series of images forming the video (in jpg so it does not take too much space) and ask people to comment them (say where something looks wrong), so we can check again those frames.

Offline cscott

  • Senior Member
  • *****
  • Posts: 2636
  • Liked: 1839
  • Likes Given: 658
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1553 on: 06/11/2014 02:04 PM »
How would endianness make any difference here?  I'd assume MPEG-4 is a stream of bits (no fundamental endianness) wrapped in the transport stream (TS) framework.  You either get the bits as they come or you don't.
Communications is frequently done with blocks and shift registers and tend to be "little endian" bit streams in my experience. Think about a Uart set for N81 as an example. Sending a byte of 0x40 (01000000) would present bits on the wire  as 0 (start bit)  0 0 0 0 0 0 1 0 1 (stop bit) in temporal order from left to right of this line. Without knowing anything about the encoder, transmission protocol, packet size and equipment it is all speculation though.

The fact that we're seeing the exact same triple flip pattern irregardless of where in the byte the flips start indicates that we've got the endianness right.

Offline cscott

  • Senior Member
  • *****
  • Posts: 2636
  • Liked: 1839
  • Likes Given: 658
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1554 on: 06/11/2014 02:24 PM »
I speculate that the receiver front-end was not able to effectively filter out large electro-magnetic noise spikes, and that an extra electrical impulse "rang" in the RF-front end circuit long enough to alter the bit sampling process.  But who knows? :o

It's most likely *not* an analog effect.  My best guess is that it is an artifact of deliberate interleaving, which is done to spread out the effects of burst noise.  See https://en.wikipedia.org/wiki/Forward_error_correction#Interleaving
This interacts with the specific error correction code in use.   If there are N+1 errors and the ECC is only able to correct N, the uncorrected error might end up with a certain pattern; see https://en.wikipedia.org/wiki/Burst_error-correcting_code#Convolutional_interleaver for something which could look roughly like our pattern.

I haven't figured out the exact coding system that would produce this pattern, but here's a strawman: consider an error correcting code which operates on groups of three bits and adds a fourth parity bit.  The three bit input is interleaved as in our triple flip pattern.  If the received parity bit doesn't match the parity of the three received data bits, the three bits are flipped (which also flips the parity, so it now matches and the output is "correct").  Now, as is, this is a pretty poor ECC! But in a hand-wavy way it might help visualize how the ECC fixups might lead to specific patterns of bit flips.

Offline princess

  • Member
  • Posts: 65
  • Liked: 106
  • Likes Given: 25
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1555 on: 06/11/2014 03:03 PM »
The fact that we're seeing the exact same triple flip pattern irregardless of where in the byte the flips start indicates that we've got the endianness right.

Interestingly I generated the images big-endian, which is the opposite of RS-232. In other words, a byte with value 0x0f would be output as 00001111. So in my bitflip images, the first pixel in a line represents the most significant bit of the first byte.

Offline saliva_sweet

  • Full Member
  • ****
  • Posts: 508
  • Liked: 380
  • Likes Given: 1249
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1556 on: 06/11/2014 03:24 PM »
For anyone working on the flip patterns the posts by ajmartin should be required reading. He's posted 4 times on this forum, first of them is 3 weeks old by now and I highly recommend reading all of them. Cos I'm getting a sense we're going in circles here.

http://forum.nasaspaceflight.com/index.php?topic=34597.msg1201383#msg1201383
http://forum.nasaspaceflight.com/index.php?topic=34597.msg1209887#msg1209887
http://forum.nasaspaceflight.com/index.php?topic=34597.msg1210893#msg1210893
http://forum.nasaspaceflight.com/index.php?topic=34597.msg1210927#msg1210927

Offline cscott

  • Senior Member
  • *****
  • Posts: 2636
  • Liked: 1839
  • Likes Given: 658
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1557 on: 06/11/2014 03:31 PM »
Interestingly I generated the images big-endian, which is the opposite of RS-232. In other words, a byte with value 0x0f would be output as 00001111. So in my bitflip images, the first pixel in a line represents the most significant bit of the first byte.

Yes, the MPEG TS is big-endian.  "Network byte order".  (See http://www.itu.int/rec/T-REC-H.222.0-199507-S/en which states on page 7 that it is msb first.)

Offline Sohl

  • Full Member
  • **
  • Posts: 238
  • Liked: 73
  • Likes Given: 209
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1558 on: 06/11/2014 05:16 PM »
It's most likely *not* an analog effect.  My best guess is that it is an artifact of deliberate interleaving, which is done to spread out the effects of burst noise.  [ref. to Forward Error Correction]

Sure, instances of failed FEC could plausibly do this.  Too bad someone at SpaceX has not been able to help specify any kind of FEC methods used in the RF link.

Offline cscott

  • Senior Member
  • *****
  • Posts: 2636
  • Liked: 1839
  • Likes Given: 658
Re: SpaceX Falcon 9 v1.1 CRS-3 Splashdown Video Repair Task Thread
« Reply #1559 on: 06/11/2014 05:33 PM »
It's most likely *not* an analog effect.  My best guess is that it is an artifact of deliberate interleaving, which is done to spread out the effects of burst noise.  [ref. to Forward Error Correction]

Sure, instances of failed FEC could plausibly do this.  Too bad someone at SpaceX has not been able to help specify any kind of FEC methods used in the RF link.

I'm not sure it's strictly necessary: I think the discovery of the consistent triple flip pattern is the bit that's relevant to us.  I don't think we really need to waste brain cycles reverse engineering it further when the effect is so clear.

Tags: