PDA

View Full Version : Thoughts on a RAM buffer.



I Bloom
03-15-2007, 08:15 PM
I've been giving some thought to the issue of not being able to overcrank the RED camera at 4K without an expensive raw output and storage. When this first became clear to me it was a big downer. I guess I was missing the bigger picture and the bright side which was that the camera is doing 4K wavelet compression in camera and that 27mb/s 4K footage is going to become a very viable and managable origination format just like DVCPro HD is now which is really exciting.

At the same time I'm the type of shooter who likes to overcrank things just a little bit all the time, I often film my MOS shots in the gray area between 24 and 36 fps wear the audience isn't quiet sure whether its slow motion or just a very graceful world. And so I've done some thinking about the red and 4K and here are some thoughts:

1. Renting extra equipment to overcrank isn't a solution that I relish. Neither is being tethered just for those shots. The solution to overcrank some shots is often a very subtle one, it happens sometimes in the spur of the moment and often (definitely) is not neccessarily something that is decided in preproduction. So it would be better instead to have an onboard way of doing this. So that the operator can just make it happen.

2. But switching to 2K windowed is an unattractive tradeoff, at least in theory, maybe we'll all see 2K windowed cut with 4K and all think its beautiful and just fine.

3. But some limitations on overcranked shots would be ok. Often slow motion shots don't last that long, its still useful to have the overcranking option even if these takes can only be say 30 seconds long.

So one solution, and this is something I'm sure the RED team has already thought about but I'd like to just open up some discussion, is some kind of RAM drive (the fast kind of RAM that looses all its data when you cut the power) that attaches to the camera instead of flash memory or an optical port and this drive is essentially a buffer, that stores as much RAW data as possible and then feeds it back to a hard drive at a slower rate (this is of course how the Phantom cameras work). This would be better still if it fead the RAW data back through the compression algorithm and then wrote it to the hard drive as Redcode compressed. Having this buffer attached to the camera could essentially make it like a RED-Highspeed body akin to a highspeed film body.

But there are a lot of technical issues with this, first off is capacity. Lets say it's reasonable that a highspeed module could have 8GB of RAM storage. Then by my math you could store about 25 seconds of RED raw uncompressed (323mb/s) before the buffer would need to be purged. That amount of capacity might be useful enough to create a large enough market to make developing and producing such a buffer worthwhile for RED, but maybe it might be too limiting for the relative cost of all that RAM and the added infrastructure to make it work.

Now we get into some speculation: What I know about software gives me some good guesses but without the hard data, (and we're not going to ever get the hard data, this is all proprietary stuff) but what if the camera could instead start the work of compressing the footage (within the limitations of the processor) say to 150mb/s and then complete the work once the buffer was full, then would a full minute of capacity make the buffer a viable thing. Perhaps its not possible to break the compression task into stages or its not possible for the camera to regurgitate footage in the way I've described without a complete redesign, who knows! (Graeme probably knows, but he's not saying)

In any case in the spirit of helping make this thing better I'm hoping to open this up for discussion just to see what people think and how important this is to them. Most likely the Red Two camera will run at 4 times the speed and do 4K compressed at 120fps and we'll never think of it again but until then this is really about being worried about limitations on creativity and little tradeoffs for quality.

Ian Bloom
http://www.ianbloom.com

Jeff Kilgroe
03-15-2007, 10:17 PM
We have another thread on this RAM buffer idea somewhere around here. It kinda ended with a "hey, that would be nice" sort of agreement, but nothing else. This does sound like a solution that could cross into third-party territory or perhaps RED could eventually provide such a solution. Instead of the RAW/Optical port, you could have the RAM buffer module.

If you want to overcrank 4K at the full 60fps, you can figure that's going to require about 1GB/sec throughput. You'll need 32GB of RAM if you want to do shots / takes of 30 seconds. I would think it's do-able. Shooting 2K up to 120fps should take about half of that.

I Bloom
03-15-2007, 10:53 PM
If you want to overcrank 4K at the full 60fps, you can figure that's going to require about 1GB/sec throughput. You'll need 32GB of RAM if you want to do shots / takes of 30 seconds. I would think it's do-able. Shooting 2K up to 120fps should take about half of that.

You're thinking in terms of recording time. I'm thinking in terms of playback time. I'm assuming the RAM buffer could take as much as the camera can dish out in terms of throughput. Its really about what you end up with in the end.

I guess what I'm saying that I think is different than a straight RAM buffer is to try and use the RAM strictly to finish the process where the compression encoder can't keep up with the frame rate. So essentially the compressor realizes its out of time and takes the work it has already completed and sends it to the buffer along with the work it hasn't completed. You end up with partially compressed data in the buffer that might (emphasis on might) allow you to save more space on the buffer and record more. However the more I think about the nature of this kind of compression the more I think its not feasable, but worth brainstorming at least. Most likely the redcode compressor does a wavelet transform first and then starts getting rid of bits it doesn't need and the real work is in the transform so there is no compression till the end. Often the image is sectioned off into squares of 8x8 pixels and each square is compressed individually, meaning a good portion of the image could be compressed while part not.... I just find this stuff interesting thats all.

In software there is always a trade off between computing time and storage space. If we had the option give this camera more straight RAM maybe it could do some things we weren't expecting.

Anyway, I know its just dreaming. I used to write 3D rendering engines for video games, there is a lot of crossover. In another life I'd be writing firmware for cameras.

Ian Bloom

Tom Lowe
03-16-2007, 02:12 AM
That sounds like a good idea. Maybe aim for 32GBs. It would be expensive, but 30 seconds of overcranking at a time is better than nothing.

Charles Perkins
03-16-2007, 03:01 AM
I believe Graeme has said before, that is not the speed of the drive that is the bottle neck in over cranking at 4K, but the speed of the processor. It just can’t keep up with the data being produced.

david farland
03-16-2007, 03:43 AM
I feel there's a 50% chance that RED 1 will have onboard 2K@120fps (raw=380MB/s) as REDCODE is currently producing onboard 4K@30fps (raw=380MB/s).

....see Jim's comment here (http://www.reduser.net/forum/showthread.php?t=904&page=4) (post #36 in answer to post #35)

either way 120fps is 2K windowed, raw or otherwise.

If there was a problem with Redflash/drive needing to handle a bit more than 27MB/s for 2K@120 then I suspect REDRAM could handle this, particularly as this stuff is getting faster...see here (http://www.dailytech.com/article.aspx?newsid=5688).

I understand that the bottleneck may not be the size of the frame to be compressed but the number of compression cycles!

Cheers,

Dave

I Bloom
03-16-2007, 07:40 AM
Are we confusing RED-RAM with RAM here. I think when we talk about REAL ram, the kind that you install in your computer, it seems clear that real ram can probably take as much data as any computer (or digital camera can create) thats why the Phantom can overcrank so much. So you are right, the bottleneck is in the compression implementation, which I assume runs on a microprocessor and possibly some dedicated additional hardware.

Its interesting though when you start talking about software, and this is RED's in-camera compression software we are talking about, we're in a gray area called optimization where its possible to write two different programs that acheive the same exact task and one is much more efficient and faster than the other. This is very true of the compression programs we use to compress video in our computers today. So maybe its possible that overcranking in 4K compressed might someday become a feature just from a firmware upgrade.

IB

JD Holloway
03-16-2007, 08:14 AM
While I feel that RED 2 could definitely be ready for this sort of upgrade (processors will be that much faster; multiple processors) I know you're not the only one that will miss these features in RED 1. Hopefully RED 1 owners will be able to upgrade to this feature set in the future. Then again maybe 2K is "good enough" for now. Now if it was a firmware upgrade, or (low cost) third party add on.....that would be sweet!

MikeCurtis
03-16-2007, 09:48 AM
...or another option - from that original 4K frame, you can record a downsampled 1080p60 RGB. The chart here:
http://red.com/formatoptions.htm
...indicates Redcode 60fps max. Now, exactly what you're recording that onto isn't stated. But if they want to have the ability to record onboard 1080p60 to deliver a 1080i60 (via HD-SDI or Redcine processing), then they'll HAVE to support that. So you can get an unprocessed 1080p60 RGB instead of 4K onboard...that ain't bad. Considering the tiny, tiny percentage of jobs that will finish on 4K instead of 1920x1080 or less, you'll be fine...and if you CAN afford a 4K finish, you can afford the high speed port option stuff probably too...

-mike

Tom Lowe
03-16-2007, 04:00 PM
I believe Graeme has said before, that is not the speed of the drive that is the bottle neck in over cranking at 4K, but the speed of the processor. It just can’t keep up with the data being produced.

If I understand correctly, I think what is being suggested here would be fast-enough RAM onboard to record more or less uncompressed 4K @ 60fps footage (300MB/s?) to RAM and then slowly feed it out to the processor to be compressed to 27MB/s onboard the camera at the processor's own pace. Once compressed, it would be written to the RED Drive and cleared from the RAM buffer.

In other words, you shoot 30 seconds worth of 4K @ 60fps straight to the RAM buffer. Then the camera starts churning away and compressing it to the harddrive at 27MB/s. This might mean you shoot for 30 seconds overcranked, then have to spend two or three minutes allowing the camera to compress and dump the RAM buffer before you can shoot another 30 seconds of 4K @ 60fps, and so on. Is that right, guys?

Thom Steinhoff
03-16-2007, 04:24 PM
In other words, you shoot 30 seconds worth of 4K @ 60fps straight to the RAM buffer. Then the camera starts churning away and compressing it to the harddrive at 27MB/s. This might mean you shoot for 30 seconds overcranked, then have to spend two or three minutes allowing the camera to compress and dump the RAM buffer before you can shoot another 30 seconds of 4K @ 60fps, and so on. Is that right, guys?

Looking back at and old Mike calculation...

http://www.hdforindies.com/2005/12/more-thoughts-on-red-camera

... I agree that 60fps is about a gig/second. So, 30 seconds would be about right for 32 gig of highspeed Ram assuming you had a bus fast enough to push it through. Also, asuming it would be relatively easy to divert the Redcoder from the array to a Ram buffer, I would think the "Exhale" could just take normal speed 30FPS, so 1 Minute.

Inhale: 30 seconds, Exhale 60 seconds...

But all of this is purely theoretical right along with theories such as "If I won the lottery..." or "If I had a time machine..." there is FLASH memory and then there is RAM memory. With true RAM the camera would need a bus capabible of handling the 32 Gig of Ram--To give you an idea of where that is in current computers, the current Mac pro supports up to 16 gig of highspeed ram.

Maybe I'm completely wrong and I'm just making their eventual announcement all the more sweeter--but in my opinion, I don't think this solution is possible on the current camera.

Let me rephrase this as a Red Inspiration: I think this is "Impossible!"

Jeff Kilgroe
03-16-2007, 04:37 PM
Tom,

I think that sums it up and letting the camera process the RAM buffer contents to write out to an onboard storage option would make the most sense. The 27MB/s figure is only relevant to 4K REDCODE RAW at 24fps. We don't know specs yet on the actual transfer speeds of the RED DRIVE, RED RAM, and FLASH options. They're SATA interface based, which is a max throughput of 150MB/s or 300MB/s for SATA "II".

Even though it would require additional time for the camera to process the contents of a RAM buffer into REDCODE RAW, I think that would take far less time than trying to slowly transfer full compressed RAW data to an onboard storage device. And would be more efficient as well... You would still get the same number of 4K REDCODE RAW frames on a RED DRIVE with this method at about 68MB for 60 frames instead of the approximate of 900MB for every 60 frames of uncompressed RAW.

Tom Lowe
03-16-2007, 04:45 PM
Let me rephrase this as a Red Inspiration: I think this is "Impossible!"

Ahahaha.. Trying some reverse psychology on them... :biggrin:

Andreas Fernbrant
03-16-2007, 05:37 PM
In other words, you shoot 30 seconds worth of 4K @ 60fps straight to the RAM buffer. Then the camera starts churning away and compressing it to the harddrive at 27MB/s. This might mean you shoot for 30 seconds overcranked, then have to spend two or three minutes allowing the camera to compress and dump the RAM buffer before you can shoot another 30 seconds of 4K @ 60fps, and so on. Is that right, guys?


This is exactly the thing I've been pushing for the last posts I've made.
I'd say 5-10 seconds is about all I'd ever need. And I'd be glad if it was
in 2K windowed mode at 120fps.