Author Topic: LiveView hacks (write speed improvement)  (Read 14801 times)

gabriielangel

  • New to the forum
  • *
  • Posts: 34
Re: LiveView hacks (write speed improvement)
« Reply #50 on: April 12, 2022, 03:03:58 PM »
Interesting. So 2.8k shows better results than 2.5k when it comes to pink frames.
So there's a shutter issue when +aewb i selected? And only with hdmi I suppose?

The shutter issue, when +aewb is selected, occurs with and without hdmi monitor. It does so at every resolution / preset, and I restarted the camera after each preset change to make sure.

Just so I can avoid having to test everything empirically, If I were to start with the 2.8k preset, and lower the resolution from there, regarding raw buffers and what is happening behind the scenes, should I theoretically get the same behavior as selecting the 2k preset, for example?

Also, what is the advantage of scanning the top part of the sensor, as opposed to scanning it dead center?

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #51 on: April 12, 2022, 03:12:14 PM »
Yes, reducing 2.8k preset should give good results. Not sure what's up with shutter. Will check later.

theBilalFakhouri

  • Developer
  • Hero Member
  • *****
  • Posts: 894
Re: LiveView hacks (write speed improvement)
« Reply #52 on: April 12, 2022, 03:23:50 PM »
1-aewbSuspend:
Calling this will disable aewb function (driver?), Side Effects:

-White Balance and Exposure settings will be locked, you will not able to change them, in our case only during RAW video recording. This alone gains ~7 MB/s .
-Shutter fine-tuning won't work properly, since this feature based on aewb task. Not sure if there is a workaround for that, didn't dig into it.

Updated the side effects for aewb hack. Shutter fine-tuning feature confirmed to not work properly with aewb hack. Tested on 5D3, 700D (me) and EOSM.
New custom build for 100D/SL1 is up:
https://www.magiclantern.fm/forum/index.php?topic=26511.msg239125#msg239125
Porting still work in progress!

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #53 on: April 12, 2022, 08:43:43 PM »
Could you share the fix?

theBilalFakhouri

  • Developer
  • Hero Member
  • *****
  • Posts: 894
Re: LiveView hacks (write speed improvement)
« Reply #54 on: April 12, 2022, 08:50:48 PM »
I don't have a fix, not sure if it fixable. Didn't look into it yet . .
New custom build for 100D/SL1 is up:
https://www.magiclantern.fm/forum/index.php?topic=26511.msg239125#msg239125
Porting still work in progress!

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #55 on: April 12, 2022, 08:52:07 PM »
Ok, I misunderstood  8).

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #56 on: April 12, 2022, 09:41:38 PM »
Just so I can avoid having to test everything empirically, If I were to start with the 2.8k preset, and lower the resolution from there, regarding raw buffers and what is happening behind the scenes, should I theoretically get the same behavior as selecting the 2k preset, for example?
Realizing height is probably causing corruption with hdmi out. 2.8k runs max 1190 height whereas 2.5k up t around 1400. Probably too much too handle for hdmi.

IDA_ML

  • Hero Member
  • *****
  • Posts: 1014
Re: LiveView hacks (write speed improvement)
« Reply #57 on: April 13, 2022, 06:55:32 PM »
Congratulations, Bilal, to your new amazing achievement!

I performed initial tests with your build: "crop_rec_4k.2022Apr07.700D115"

and it worked right ouf the box, even with Dual ISO !  The 1736x2928 provides continuous recording at 18 fps now, with a few corrupt frames now and then.  The shutter speed indicator seems to be broken though but I have to check with one of the other three builds to see if it works.  In the above build it shows some odd numbers like 1/92s or 1/170s in this and also other modes and these numbers do not change when you adjust the shutter speed dial.  In earlier builds this indicator used to work fine.  Also, I could't get the timelapse mode at 5208x2928 (1:1) working at frame rates higher than 2,5 fps.  Camera records just one frame and stops recording.

EDIT:

I kept testing with the build: "crop_rec_4k.2022Apr07.700D115_Shutter_Blanking_ISOless"

The shutter issue is gone now, Dual ISO works fine too.  With a slight underexposure, in the Full Width LV mode I get continuous recording at 1376x2306/12bit/24fps with a few corrupt frames.  The number of corrupt frames increases when I get closer to overexposure.  Dual ISO seems to produce less corrupt frames probably because it boosts the shadows and avoids crushing them. 

What is quite annoying is this box full of text that appears quite often on the screen after recording starts.  It goes away only upon turning camera off and on again.

I do have a question regarding resolutions in the 1x3 anamorphic modes.  Would it be possible to increase them in such manner that they take advantage of the 13 MB/s write speed improvement without ending up with corrupt frames?

I will illustrate what I mean with one example.  My favorite mode is the 1312x2214/10bit/24fps/16:9.  When I use it now, it gives me about 45.3 MB/s recording speed which is way lower than what the camera is up to, (83 MB/s according to your measurements on page 1).  Unfortunately, camera will only allow me to increase the horizontal but not the vertical resolution for the desired 16:9 aspect ratio.  Could this be fixed somehow?  I am asking because it appears that mostly the 2.35:1 aspect ratio benefits from the speed improvement.  I think a resolution of 1600x2700/10bit/24fps (16:9) or similar would be absolutely gorgeous.


ML700D

  • Member
  • ***
  • Posts: 148
Re: LiveView hacks (write speed improvement)
« Reply #58 on: April 14, 2022, 08:15:16 AM »
hi IDA_ML
for shutter problem you can use crop_rec_4k.2022Apr07.700D115_Shutter_Blanking_ISOless.zip build instead..



EOS 700D

IDA_ML

  • Hero Member
  • *****
  • Posts: 1014
Re: LiveView hacks (write speed improvement)
« Reply #59 on: April 14, 2022, 08:56:08 AM »
Yes, ML700D, I just edited my post. 

You are a big fan of Dual ISO, aren't you?  Well, I have very good news for you.  Your 700D creates miracles with Dual ISO 100/800 with the Full-res LV preset at 18 fps now: 1736x2928/10bit/18fps/1/33s.  You have to be very careful with exposure though.  Even slight over or underexposure will produce corrupt frames.   But once you get it right, you will enjoy a very clean and naturally looking image.  Just give it a try and report back! 

gabriielangel

  • New to the forum
  • *
  • Posts: 34
Re: LiveView hacks (write speed improvement)
« Reply #60 on: April 14, 2022, 11:30:19 PM »
I just edited Reply #48, for those who would like to know more about using the latest build with an hdmi monitor.

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #61 on: April 15, 2022, 05:13:29 AM »
Also, I noticed that every preset uses a different center (Those scan different parts of the sensor) and if I use the 2.5K Centered preset as a reference, the presets are often a little to the right, with the 5K preset scanning towards the lower portion of the sensor (Which at least give you a chance to get the eyes in better focus if filming a person when using an older lens).

It would be good to disclose the exact offset figures, as this would allow people to choose the right lens accordingly. Unless you use an ef-m 32mm f1.4 or, to a slightly lesser extent, ef-m 22mm f2; you don't get edge to edge sharpness. So, if you use a Helios or a c-mount lens, you will get uneven bokeh and vignetting, as those vintage lenses get softer and blurrier very quickly as soon as you deviate from the center. (Not too apparent if you do nature shots, but a lot more if you frame a subject off center.)
It is possible to alter offset with cmos registry. They are present in the crop rec submenu under advanced I believe. Don't emember exactly which two cmos regs but shouldn't ve too hard to find out.

SebastianC

  • New to the forum
  • *
  • Posts: 31
Re: LiveView hacks (write speed improvement)
« Reply #62 on: April 15, 2022, 03:28:21 PM »
Great!Danne!I reuse my 6d again to take 5k video!

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #63 on: April 15, 2022, 05:51:57 PM »
It's completely theBilalFakhouris work here 8).

ML700D

  • Member
  • ***
  • Posts: 148
Re: LiveView hacks (write speed improvement)
« Reply #64 on: April 15, 2022, 06:27:00 PM »
Yes, ML700D, I just edited my post. 

You are a big fan of Dual ISO, aren't you?  Well, I have very good news for you.  Your 700D creates miracles with Dual ISO 100/800 with the Full-res LV preset at 18 fps now: 1736x2928/10bit/18fps/1/33s.  You have to be very careful with exposure though.  Even slight over or underexposure will produce corrupt frames.   But once you get it right, you will enjoy a very clean and naturally looking image.  Just give it a try and report back!

nice.. ok, I will try it later, I'm big fan of Bilal's crop rec 4k 😁
could you give me mlv sample of that setting? I want to see.

thanks IDA_ML.
EOS 700D

IDA_ML

  • Hero Member
  • *****
  • Posts: 1014
Re: LiveView hacks (write speed improvement)
« Reply #65 on: April 15, 2022, 08:26:13 PM »
ML700D,

Unfortunately, I do not have that sample any more.  I filmed a scene outside throudh the window and got some of the room interior in the frame to capture a high-contrast/high dynamic range scene.  Then I examined the clip in MLVApp right from the card and was very pleased with the result.  Then I deleted the file since I did not needed it any more.  I just remember that, after adjusting the sliders, the histogram filled the entire area starting at 0 on the left and ending with 0 on the right without over or underexposure. 

mlrocks

  • Member
  • ***
  • Posts: 180
Re: LiveView hacks (write speed improvement)
« Reply #66 on: April 18, 2022, 07:29:21 AM »
I just tried the new small hacks on my 650D (more hacks with two hacks and one more hacks enabled). I don't know how to implement this on my 5d3 so I just skip it now.
On 650D, I tested two modes with SD card overclocking at 240 mhz with a Sandisk Extreme Pro 170MB/s 256 GB SD card.
1. UHD 1X3 14-bit 14-bit lossless, without dual ISO, with auto ettr, with waveform, with zebra, with magic zoom and focus, global on, the benchmark was about 68 MB/s. This mode is continuous even at ISO 1600, with a benchmark at 62 MB/s. So this mode is very robust and practical.
I did test global draw off without waveform, zebra, focus, magic zoom, the benchmark was about 71 MB/s.
2. Full frame 5.2k 1x3 10-bit 14-bit lossless global draw off without waveform, zebra, focus, magic zoom, the benchmark was 65 MB/s.
It seems that in both modes, the writing speed is about 5 MB/s better than before.

Update:
Turning off the more hacks and one hacks on 650D, the benchmark is still 68 MB/s in UHD 1X3 14bit/14bit lossless mode. So it seems no improvement? Not sure what happened. I checked the ML version is 4/7/2022.

Update:
In 650D's 5.2k 1x3 full APS-C sensor mode, I remembered that the 1-minute benchmark for the last ML version was about 60 MB/s with global draw on, with the current version, the 1-minute benchmark is 63.5 MB/s with global draw on, 67.5 MB/s with global draw off. So there is about 3 MB/s improvement for writing speed. However, activating the three small hacks does not improve further using the 1-minute benchmark test.
 

Danne

  • Developer
  • Hero Member
  • *****
  • Posts: 7297
Re: LiveView hacks (write speed improvement)
« Reply #67 on: April 18, 2022, 01:22:21 PM »
Recording with a preset isn't benchmarking. Recordings will probably show the same but the hacks will allow for longer or continuous shooting.

mlrocks

  • Member
  • ***
  • Posts: 180
Re: LiveView hacks (write speed improvement)
« Reply #68 on: April 18, 2022, 06:42:44 PM »
Recording with a preset isn't benchmarking. Recordings will probably show the same but the hacks will allow for longer or continuous shooting.

Thanks. Will try this.

5.2k 1x3 recording using the current ML version without hacks on, the recording time is 1-2 seconds with global draw on, 20 seconds with global draw off.
With the three hacks on, the recording time is more than 1 minutes with global draw on, most time indicator is orange, sometimes is red. Now it is already 7 minutes recording time. With global draw off, the indicator is green, the recording time is more than 1 minutes, manually terminated. So it is continuous.
So 1-minute benchmark does not reflect the true improvement. Thanks Dan and Bil. It is a great achievement.

I think that now 650D is an APS-C 5K raw camera with hardware compression ratio of 3. Although software compression may have better recovery with smart algorithms, 650D 5.2k 1x3 footage very possibly will stack against other raw cameras' 5K footage at a compression ratio of 12 or even 8 or 6.

Cheers,



Update
For an indoor relatively dark scene, ISO 1600:
1. 5.2k 1736x2214 1x3 10 bit 14bit lossless, global draw off, recording indicator mostly orange, sometimes green, recording speed 75 MB/s, 1-2% idle, recorded more than 10 minutes, manually terminated. I consider this continuous. With global draw on, the recording time is about 3 seconds. I think 1736x1950 AR 2.67 will be continuous with global draw on. Will test it later. Update: It is green, one minute recording, terminated manually. Continuous.
2. UHD 1X3 14 bit color depth 14 bit lossless, global draw off, recording indicator orange, recording speed 70 MB/s, idle time gradually increase from 100 ms to 900 ms after 5 minutes recording, manually terminated. I consider this continuous. With global draw on, it is continuous also.
3. 3K 1x1 10 bit color depth 14 bit lossless, AR 2.67, global draw off, recording indicator green, recording speed 72.5 MB/s, 2% idle, continuous. AR 2.4, recording indicator red to orange, recording speed 79 - 80 MB/s, 1% idle, more than 1 minutes, sometimes more than 5 minutes, scene dependent, stopped automatically.
Thus, all these three modes are robustly continuous even in challenging scenes. If the three hacks prove no serious side effects, these modes can be used in practice fairly stably.


Update:

For a scene composed of several tree with dense green leaves, a parking lot with several cars, a gate with iron fences
during the sunny noon at ISO 100
using a EFS lens 10-18 IS at 10 mm, IS on, AF off
UHD 1X3 14 bit color depth 14 bit lossless LJ92 compression records at 80 MB/s.
With global draw always on, the recording time is about 3 seconds. However, if push the info button to enter the user interface 2, where I typically change the shutter speed here, the indicator is orange to green, continuous recording. It is almost like with global draw off.
Thus,
I rate the Canon 650D ML as a raw news camera with the following specs:
14 bit 4K raw with a hardware compression ratio of 3
35mm/4-3 sensor size
continuous at ISO 100
If using a preset to reserve high dynamic range in MLV App, the dr may reach 12 stops.
This Canon 650D ML is an Arri Amira mini disguised, at the cost of 1%.

The same setting at late evening, needs ISO 1600, F 4.5, shutter speed 30, still a little bit dark. The writing speed is about 72 MB/s for 14 bit color depth.

Therefore, 14 bit UHD 1X3 AR 16-9 is usable most of the time in the user interface 2. For some extreme cases like late afternoon when the writing speed is over 82 MB/s, 12 bit can be used, which cuts the writing speed to 75 MB/s, and continuous.

Personally I settle on 12 bit color depth UHD 1X3 AR 16-9. This bit rate generates 75 MB/s peak data stream, plus 5 MB/s global draw, still less than the current 82 MB/s limit. I like the global draw very much and want to operate everything in user interface 1 with global draw on.

Update
The same set up as above, 12 bit UHD, handheld, 90 seconds footage, processed in MLV App with default setting, export to mp4. The footage has no first frame corruption, no pink or corrupted frame in duration. The dynamic range is good. The sharpness is acceptable. It seems to me that 650D UHD 1X3 12 bit mode can be used for run and gone news shooting safely.

Update

The same set up as above

1. 5.2K 1X3 1736X2272 10 bit 24 fps
AR 2.35, writing speed 78 MB/s, continuous global draw off, <3 seconds global draw on;
AR 2.39, writing speed 74 MB/s, continuous global draw off, 10-30 seconds global draw on;
AR 2.67, writing speed 65 MB/s, continuous global draw on.

2. 3X3 720 P 50 FPS 10 bit
AR 2.39, 1736x698,  writing speed 68 MB/s, continuous global draw off, 10-30 seconds global draw on.


Update

The same set up as above.

1. 1280 1x1 mode, 1920x1280 1X1 14 bit 24 fps, writing speed 65 MB/s, continuous global draw on.

2. 1440 1x1 mode, 1920x1440 1X1 12 bit 24 fps, writing speed 65 MB/s, continuous global draw on.

3. 2.5k 1x1 mode, 1920x1280 1X1 10 bit 30 fps, writing speed 65 MB/s, 10 seconds global draw on.


Update

3x3 60 fps 1736x586 mode, 14 bit lossless, writing speed 64 MB/s, 4 seconds, global draw on; 12 bit lossless, writing speed 56 MB/s, 4 seconds, global draw on; 11 bit lossless, writing speed 50 MB/s, 18 seconds, global draw on. Seems this mode is not optimized enough. But in real world, 10 seonds of slow motion in 24 fps is enough.

3x3 24 fps 1736x976 mode, 14 bit lossless, writing speed 44 MB/s, green, global draw on.

3x3 30 fps 1736x976 mode, 14 bit lossless, writing speed 55 MB/s, green, global draw on.
If the traditional setting of AR 16-9 plus 30 fps is required, this mode is the only way to go. The operation in this mode is very convenient and reliable, pushing set button to do auto ettr, pushing zoom in to have 5x 10x high resolution enlargement, pushing zoom out to have low resolution magic zoom during video recording, pushing info button to access 4 different user interfaces. 

gabriielangel

  • New to the forum
  • *
  • Posts: 34
Re: LiveView hacks (write speed improvement)
« Reply #69 on: April 19, 2022, 10:00:07 PM »

I think that now 650D is an APS-C 5K raw camera with hardware compression ratio of 3. Although software compression may have better recovery with smart algorithms, 650D 5.2k 1x3 footage very possibly will stack against other raw cameras' 5K footage at a compression ratio of 12 or even 8 or 6.


By hardware compression ratio of 3, do you mean subjectively?
1x3 Binning isn't exactly compression. What you lose is mostly sharpness (And detail resolution), because every 3  horizontal pixels are combined into one. (But every line is scanned, thus, vertical resolution is relatively untouched)

mlrocks

  • Member
  • ***
  • Posts: 180
Re: LiveView hacks (write speed improvement)
« Reply #70 on: April 20, 2022, 01:09:39 AM »
By hardware compression ratio of 3, do you mean subjectively?
1x3 Binning isn't exactly compression. What you lose is mostly sharpness (And detail resolution), because every 3  horizontal pixels are combined into one. (But every line is scanned, thus, vertical resolution is relatively untouched)

I think so. Hardware binning loses information permanently. Software compression may recover some information by smart codec and algorithms. However, heavy software compression will lose information. This is very often seen on commercial camcorders, the in-camcorder codec is so heavy that the footage is not so great, but the through hd sdi or hdmi to external recorder the uncompressed stream has much better quality. Software codec at compression ratio of 6 and above will have certain loss of information.

mlrocks

  • Member
  • ***
  • Posts: 180
Re: LiveView hacks (write speed improvement)
« Reply #71 on: April 20, 2022, 01:24:07 AM »
By hardware compression ratio of 3, do you mean subjectively?
1x3 Binning isn't exactly compression. What you lose is mostly sharpness (And detail resolution), because every 3  horizontal pixels are combined into one. (But every line is scanned, thus, vertical resolution is relatively untouched)

REDCODE is a mathematically lossy codec, meaning that decompression does not fully restore the original image data captured by the camera. Red claims the codec is "visually lossless", suggesting that the information loss is not visible to the naked eye when images are viewed.
https://www.dpreview.com/forums/thread/3091209#forum-post-39762774
https://www.afcinema.com/IMG/pdf/2/c/e/955-0001_v31.6.16_rev-a_red_cs_red_one_operation_guide.pdf

The highest Redcode on Red One is Redcode 42, 42 MB/s. It was a great achievement at the time. Now 650D ML can do 80 MB/s, equal to Redcode 80. Hehe.

mlrocks

  • Member
  • ***
  • Posts: 180
Re: LiveView hacks (write speed improvement)
« Reply #72 on: April 20, 2022, 02:37:59 AM »
By hardware compression ratio of 3, do you mean subjectively?
1x3 Binning isn't exactly compression. What you lose is mostly sharpness (And detail resolution), because every 3  horizontal pixels are combined into one. (But every line is scanned, thus, vertical resolution is relatively untouched)


Let us take a look using 650D's UHD versus the original Red One Classic as an example.
650D UHD 1x3 12 bit generates about 70-80 MB/s for a typical complex scene. Red One's RedCode 28 generates 28 MB/s no matter the scene complexity. RedCode 28 has a compression ratio of 8. 650D in UHD mode has a sensor size of 4-3, close to Red One's super 35mm sensor size. 650D's data files are about 2 to 3 times larger than RedCode 28. Certainly Red's patented codec is very good and keeps more information than 650D's simple and dumb un-stretching algorithms (we can see it as a hardware-software combined codec, although lossy and may not be efficient). But still the final footage may be very close, simply due to the much bigger data size of the 650D files.
Some one who has Black Magic's 4k cameras or the original Red One cameras can do this kind of comparison. I know BMPCC 4K or 6K has raw compression ratio to the 12.
"REDCODE range is 2:1 to 22:1. Default is 8:1. For maximum available REDCODE values, see the DSMC Media Operation Guide."
http://docs.red.com/955-0154_v7.0/REDRAVENOperationGuide/en-us/Content/4_Basic_Menus/REDCODE.htm
https://www.provideocoalition.com/red_one_geekery_real_world_info_on_redcode/

gabriielangel

  • New to the forum
  • *
  • Posts: 34
Re: LiveView hacks (write speed improvement)
« Reply #73 on: April 20, 2022, 04:08:53 AM »
@mlrocks , This is very interesting. Did you have a chance to compare the output of the 650D to that of the eos-m? As the 650D is quite affordable, it could be interesting.

mlrocks

  • Member
  • ***
  • Posts: 180
Re: LiveView hacks (write speed improvement)
« Reply #74 on: April 20, 2022, 05:36:38 AM »
@mlrocks , This is very interesting. Did you have a chance to compare the output of the 650D to that of the eos-m? As the 650D is quite affordable, it could be interesting.

I do not have EOS M any more.
Theoretically, EOS M is the same as 650D/700D, just different body and flange distance. But I did not compare both ML versions side by side.