News for hackers. Stuff that matters.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by photoGrant on Saturday December 09, 2023 @02:40AM (#38579617)
digital cameras carried on planes in the early days had cosmic ray issues too. So they sent them by boat. Hell. The ones today do. This is a weird article though. A lot of cameras compensate for dead pixels and cosmic rays.

It should also have been designed in every camera to have unique file names. It’s ridiculous they all don’t.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @02:43AM (#38579634)
If you use a Sony A7 series camera, every month, the camera will take a picture upon shutting it off, which it uses to remove dead pixels/hot pixels - you can hear it, actually.

If ever you have a pixel die or get stuck, you can also manually set the date a couple months ahead and turn it off - it will most likely be fixed when it turns back on.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by photoGrant on Saturday December 09, 2023 @03:17AM (#38579812)
A manual sensor clean in most cameras does this. If mirrorless, leave the cap on
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @03:20AM (#38579840)
It's not about dust on the sensor, it's actually software that maps dead pixels to fill them in every time you take a picture (as well as dark frame offsetting, presumably)
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by photoGrant on Saturday December 09, 2023 @03:31AM (#38579896)
Again… the manual sensor clean action action does both. Granted I mean the manual ‘automatic’
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @10:23AM (#38582612)
Ah okay, I was confused on what you meant by manual sensor cleaning, to me that means (on a DSLR also locking the mirror up) and swabbing out the dust.

On a Sony E-mount camera, the ultrasonic sensor cleaning doesn't do pixel remapping, only the date trick (or the menu option on electronic shutter models) works to trigger it manually.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by KennyBlanken on Saturday December 09, 2023 @03:19AM (#38579831)
Many cameras have a menu option to trigger a dark frame calibration. Been a thing for a long, long time.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by hef19898 on Saturday December 09, 2023 @03:39AM (#38579941)
I can do it on my Nikon D700, so yeah, quite an old feature. Very usefull so!
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by xattt on Saturday December 09, 2023 @08:55AM (#38581933)
I trump you with my Canon 30D that also had this feature.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by mschuster91 on Saturday December 09, 2023 @02:58AM (#38579710)
> If you use a Sony A7 series camera, every month, the camera will take a picture upon shutting it off

So THAT is that mysterious click-clack of the shutter that randomly appears on my A7S2. I've been putting off sending it in for repair, but now I can completely avoid that. Many thanks!

Do you happen to have a link to some documentation for it?

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by kuschku on Saturday December 09, 2023 @03:37AM (#38579933)
Funny, on the FX30 it's actually exposed as a setting with a proper description.

Maybe because the FX30 lacks the physical shutter, and instead relies on you putting a lens cao on? If so, I'd expect the A9iii to have the message too.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by frostburg on Saturday December 09, 2023 @07:22AM (#38581368)
I would assume so, it's the same on my Sigma fp L.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by strogonoff on Sunday December 10, 2023 @07:15AM (#38591028)
Does fp L automatically offset raw values in DNG/CinemaDNG files in accordance with the latest dark frame, or is it only applied to JPEG output?
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by frostburg on Tuesday December 12, 2023 @07:23PM (#38620898)
Sorry, I only saw this question now. It does get applied to raws but I think in a non-destructive way.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by strogonoff on Thursday December 14, 2023 @12:18AM (#38638077)
Thanks for the info.

I think if you can see hot pixels when looking at the raw before demosaicing then the dark frame is not applied (which makes sense, since a DNG is supposed to be more or less a sensor snapshot).

If you do not see them after you processed the raw, I think that would just be your software filtering outliers as best it can, since it would have no way of knowing about the dark frame. I doubt it embeds the dark frame in every DNG, would take up extra space and I am not sure the format even supports that, so likely it just keeps the latest dark frame in memory and applies as part of internal pipeline.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @03:15AM (#38579803)
As far as I know, there's no official documentation for it, but people noticed that it happened every month and that it would fix dead pixels (for example: https://www.4kshooters.net/2015/12/01/an-easy-trick-to-fix-d...)

I personally used this trick twice to fix dead pixels on my camera, so I can attest to that.

For cameras without a mechanical shutter, there is instead an option to do it in the menu, for example : (https://helpguide.sony.net/ilc/2010/v1/en/contents/TP0003229...)

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by lakpan on Saturday December 09, 2023 @09:21AM (#38582114)
So, wait. The camera can fix dead pixels but only does so once a month? Dead pixels are dead easy to detect by the sensor, why don’t they do it immediately? Way to ruin a bunch of photos between cleanups…
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by yakubin on Saturday December 09, 2023 @10:40AM (#38582767)
Every photo taken shortens the life of a sensor.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by riversflow on Saturday December 09, 2023 @11:51AM (#38583410)
To add to this, with those particular cameras(it’s the frame I shoot on), you’re encouraged by the form factor and ergonomics to turn them off when idle to get the most out of the smallish battery, they boot in like 1s. A battery is good for ~350 shutter pulls, I don’t want to use one of those every time I think about taking a picture.

Also, a dead pixel is not a ruined photo, it’s a minor inconvenience in editing at worst. And every photo I take on a FF is getting edited, the gorgeous RAW output is what I’m there for.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by lakpan on Saturday December 09, 2023 @06:36PM (#38587354)
> minor inconvenience

Do you have software that automatically fixes this issue in all the pictures at once? Because as a non-professional I can only think of a very manual approach.

On my old phone, dust made its way into one of the cameras and now all of those photos are forever ruined (or until I find a way to somewhat automate this fixing)

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @09:01PM (#38588308)
Any real photo editor will allow you to batch a patch heal operations. Lightroom, Photoshop, GIMP, Darktable, etc... all support this.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @12:26PM (#38583715)
That's not really true, it's only a problem for the shutter. The sensor doesn't really break.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by yakubin on Saturday December 09, 2023 @12:33PM (#38583775)
You’re right. I misremembered. The term is “shutter life”. Same result though.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by wtallis on Saturday December 09, 2023 @12:40PM (#38583841)
Not the same result: we're talking about taking a picture without opening the shutter.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by yakubin on Saturday December 09, 2023 @01:11PM (#38584159)
Given that shutter sounds are produced, I'd guess the shutter is opened[1]:

> During this time, shutter sounds will be produced.

[1]: <https://helpguide.sony.net/ilc/2010/v1/en/contents/TP0003229...>

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by dghlsakjg on Saturday December 09, 2023 @03:38PM (#38585815)
The shutter is actually being closed. On mirrorless cameras the shutter is by default open so that viewfinder framing can be accomplished, then it quickly closes, opens for the photo, and ends closed before opening again to act as a viewfinder.

In the case of a reference photo it is closing, not opening, taking a read of the sensor, then opening again.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gruez on Saturday December 09, 2023 @12:43PM (#38583871)
Do mirrorless cameras even have physical shutters? Or is it all digital?
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by yakubin on Saturday December 09, 2023 @01:07PM (#38584126)
Most do. Some, like Nikon Z8 and Z9, don't.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @01:28PM (#38584314)
Older ones do, because the readout speed of sensors was not fast enough. Cameras with stacked or global shutters generally don't, because it's no longer an advantage. In between, it's a choice you can make whether or not to use the shutter.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by dghlsakjg on Saturday December 09, 2023 @03:45PM (#38585892)
Yeah, but that’s like saying your mechanic shouldn’t take test drives because every mile driven shortens the life of the car.

The shutter, which is replaceable, is normally rated, for 200k-1mm actuations MTBF.

Even taking a reference photo every day won’t truly impact shutter life.

Anecdotally: I have a 20 year old Canon 1D that is 50% over it’s rated shutter life, and that camera was used for photojournalism (used HARD) for most of its life.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by caseyohara on Saturday December 09, 2023 @08:13PM (#38588030)
Most (all?) mirrorless cameras these days have an electronic shutter too, so it's not like it would put any extra miles on the mechanical shutter.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by dghlsakjg on Saturday December 09, 2023 @10:44PM (#38588843)
You need to have perfect dark to take the reference image, so even on the mirrorless ones you end up having to close the mechanical shutter to get it done.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @12:24PM (#38583700)
Sometime dead pixels are not a fully on-off affair, so taking a dark frame is really needed, and you don't want to be doing that too often because then the camera is not usable then.

It sucks, but it is what it is, and it's not too difficult to batch remove dead pixels - if you even notice them.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by yakubin on Saturday December 09, 2023 @10:41AM (#38582780)
Does it affect RAW photos or only JPEGs?
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @12:25PM (#38583708)
It affects RAW photos, too. You also have similar artifacts sometime from on-sensor phase detection pixels.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by CarVac on Saturday December 09, 2023 @03:50PM (#38585952)
It's just them performing dark frame subtraction at short shutter speeds too, not just long ones.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by somemirth on Saturday December 09, 2023 @02:59AM (#38579720)
It’s a poorly written and badly explained article. The first comment does a great job of explaining why, and how the new “firmware” actually works
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by Pixie_Dust on Saturday December 09, 2023 @03:37AM (#38579932)
> It’s a poorly written and badly explained article ..

And the title is erroneous. The firmware used the noise reduction circuits to disguise the effects of cosmic rays on the sensor.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by jakeinspace on Saturday December 09, 2023 @10:40AM (#38582765)
Hey, us embedded programmers never get credit. It’s nice once in a while to steal some from EEs.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by KennyBlanken on Saturday December 09, 2023 @03:18AM (#38579824)
The noise reduction they're referring to is dark frame subtraction used for thermal noise and defective hot pixel removal (the latter is what the ISS has to worry about.) Numerous cameras from other companies allow for forcing that on at any speed via menu options, not just slower shutter speeds.

I had this feature available on an early 2010's Olympus. They called it "Noise Reduction" (not "noise filter", that's different) and it could be set to off, normal, or "on." On makes it behave like this "special" Nikon firmware, always performing the dark frame subtraction. "Normal" applies some logic based on shutter speed and ISO, and off turns it off completely. Manual dark-frame calibration was also available via the menus.

I'm not sure why Nikon is tooting their horn so loudly about adding (only for people in the ISS) what's been available to earthbound users of other camera systems via a menu item for a decade?

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by hef19898 on Saturday December 09, 2023 @03:41AM (#38579959)
I guess the difference is some better algorithms to identify cosmic ray issues and the like, as oppossed to simple noise reduction.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by wdfx on Saturday December 09, 2023 @05:27AM (#38580567)
Exactly - if you think about the automatic dead/hot pixel removal, the camera is going to assume these errors are always in the same location on the image, and maintain a mapping of where they are.

If instead in space these errors are caused by cosmic rays and can affect any part of the image randomly, and for a limited time only, then this requires a different algorithm, otherwise the camera will eventually be painting out the entire image as different areas get affected.

That all said, I know nothing of the details of these camera firmwares, and they may be doing other things instead. But, I suspect it is not as simple as some comments in this thread suggest... because nothing ever is.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by KennyBlanken on Saturday December 09, 2023 @09:38PM (#38588501)
"Noise reduction" is not dark frame subtraction.

What they are very clearly describing is dark frame subtraction, as they repeatedly mention damage from cosmic rays. Things are not helped by this being a press release munged up by a writer.

"Noise reduction" is where the camera's image processor applies smoothing over different channels as part of all the other processing it does, such as vignette correction, chromatic diffraction compensation, and remapping for lens distortion.

Some but not all of this is bypassed when doing RAW images. RAW processors (especially from the camera manufacturer) typically apply similar corrections automatically, but you have varying degrees of control over this. They're usually better quality due to more computational capabilities, and faster software development cycle vs stuff baked into the camera's ASICs or firmware.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by malfist on Saturday December 09, 2023 @07:34AM (#38581440)
Dark frame subtraction cannot remove cosmic rays. It removes things the camera sees in the dark at the time of dark frame capture.

This is things like dead pixels, hot pixels and amp glow.

If a cosmic ray was removed by a dark frame, two cosmic rays would have had to happen, one during dark frame and one during the actual capture. They'd have had to be the same intensity and hit the same pixels. This is probably never going to happen.

As for who this is for? You and I may benefit too with less cosmic ray noise in our photos. We still see them, though we have a lot more information in our photos. You can see them too if you take dark frames yourself. Even if you put your camera in the freezer to avoid most other noises you'll see them

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by davidmurdoch on Saturday December 09, 2023 @10:09AM (#38582499)
What's the freezer thing about?
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by dekhn on Saturday December 09, 2023 @11:43AM (#38583335)
there are several sources of pixel noise, some of which are temperature dependent. Making the sensor cold reduces the temperature-dependent pixel noise background.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by davidmurdoch on Saturday December 09, 2023 @12:43PM (#38583868)
So less sensor noise, but all your lenses are foggy now. Haha
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by malfist on Saturday December 09, 2023 @01:13PM (#38584183)
Well, for dark frames the lense cap is on. The idea is that you're taking a totally black photo.

Freezer, along with being cold is also a big metal box that will help deflect some rays

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by dekhn on Saturday December 09, 2023 @06:18PM (#38587212)
It's not the lens, it's the sensor that's kept cold- in practice, people taking low-noise shots would use something like this: https://amscope.com/products/mt5800-ccd

If you put it in a freezer, you can use desiccant or other strategies to avoid moisture-fogging. Or just wait til everything reaches equilibrium?

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by causi on Saturday December 09, 2023 @05:44AM (#38580678)
I wish there was good software for hot pixel removal in normal digital cameras. Sure you can photoshop pictures one by one, but if you have the same set of bad pixels on every shot and need to remove them in batches? Nothing will do that as far as I know.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by lm28469 on Saturday December 09, 2023 @08:39AM (#38581825)
I'm pretty sure you can do that in photoshop batch actions for a good 15 years
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by terramex on Saturday December 09, 2023 @09:22AM (#38582128)
I once used astrophotography tool DeepSkyStacker for that.

Loaded all my photos as light frames, prepared and loaded a dark frame, turned off alignement, post-processing etc and turned on "Create a calibrated file for each light frame". It subtracted given dark frame from every photo and exported them to 16-bit TIFFs.

It can be used from command line if you want to automate it more or make custom GUI. Windows only unfortunately, but it is open source.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by sudosysgen on Saturday December 09, 2023 @12:32PM (#38583771)
If you use Lightroom, make a 1 pixel patch around the hot pixels, and then copy/paste the edits. Basically every other image editing software is also going to allow a similar workflow.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gsich on Saturday December 09, 2023 @07:42AM (#38581496)
Nikon should fix file numbering in general.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by mikewarot on Saturday December 09, 2023 @02:18PM (#38584923)
The file numbering system is unique enough that you're not going to have the same file and folder name together, and you can set the prefix, iirc.

My photos are in /photos/yyyy/yyyymmdd/nikon1xx/dscnxxxx.jpg and I've been using this system since 1997

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gsich on Saturday December 09, 2023 @06:33PM (#38587331)
No it's not unique enough.

D750 has this naming scheme: DSC_4203.jpg (or nef). Which obviously wraps at 9999.

Z7 has SZ7_1234.jpg - still not better.

Several subfolders don't count, it's the same folder that is important.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by mikewarot on Saturday December 09, 2023 @06:59PM (#38587527)
The D5100 creates a new folder when it wraps.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gsich on Saturday December 09, 2023 @10:02PM (#38588632)
Yes. On camera it's not an issue. The issue comes when you want to store more than 10000 pictures (or even a subset who happen to have the same numbering) in the same folder. But I already wrote that subfolders don't count.

To quote Ken Rockwell:

>File numbers have three programmable letters (good), but then an underscore and only 4 digits, so it only can make 10,000 shots before file names repeat. At 120 FPS it's trivially easy to make more than 10,000 shots in just a half hour of shooting sports, and now you have to keep all those images in separate folders because you can't put two files with the same name in the same folder. Nikon needs to replace the underscore with a digit so we have at least five digits in our file numbers. Even LEICA's pokey LEICA M9 of 2009 uses seven digits in their file names to prevent duplicates, and that camera barely worked at 1 FPS.

It's an arbitrary restriction in the camera software. It needs to be fixed.

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by mikewarot on Sunday December 10, 2023 @12:27AM (#38589372)
Many file systems struggle with a large number of files in a single folder. It's a relatively new problem to have.

A few lines of python or a shell script are required to rename them on import

I can see how it is annoying, though. It is, after all, the first of the 2 biggest problems of computer science:

  Naming
  Cache invalidation
  Off by one errors
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gsich on Sunday December 10, 2023 @06:46AM (#38590910)
10000 is not many. It's not even a power of 2 so there is no technical reason for that number. The fact that Nikon (according to the article) is able to provide a fixed firmware is proof enough.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by mikewarot on Sunday December 10, 2023 @11:53AM (#38592889)
If you put more than 10,000 files in a single folder on a host system, you may have trouble, depending on the file system. Here's a good example of why from [1]

  This isn't really a very big deal with newer filesystems such as XFS and ext4, but on older or misconfigured filesystems it can be a serious problem.

  With older Linux filesystems such as ext3, a directory is just an unordered list of files.

  That it is unordered is important, because it means that the only way for the system to find a file in a directory is to search it from the beginning to the end.

  If a directory contains 3,000 files, it will take an average of 1,500 comparisons to find a random file in the directory. But if the directory contains 300,000 files, it will take an average of 150,000 comparisons to find a random file in that directory.

  In either case, if the directory entry is not already cached in RAM, it must be loaded from disk, which would add a significant amount of time to the file access, proportionate to the size of the directory. Obviously a small dentry can be loaded faster than a large one.

  Thus, it is much faster when you use a more hierarchical directory structure to separate large numbers of files into unique directories.
[1] https://serverfault.com/questions/736872/why-there-shouldnt-...
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gsich on Monday December 11, 2023 @06:57AM (#38599819)
So not a problem. See XFS and ext4 as you wrote. I don't care about legacy filesystems. Neither should Nikon. Besides, even if Nikon stores them in different folders, they could keep the numbering. Not reset it to 0. Best of all worlds.

Also, this issue could also arise even with 2 pictures you want to store in the same folder. (Although renaming is easier ofc then)

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by hypercube33 on Sunday December 10, 2023 @03:09AM (#38589995)
This. Shooting multiple cameras sucks out of the box.

I also hate the d4 not supporting nvme cf cards or even snapbridge via firmware

Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by ISL on Saturday December 09, 2023 @10:44AM (#38582801)
I wish every manufacturer had an option for unique, nonrepeating, filenames!
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by gsich on Monday December 11, 2023 @09:35AM (#38600969)
Nikon does not - in general. It's only for this special usecase unfortunateley.
Re:Nikon Makes Special Firmware for Astronauts to Block Cosm... by COGlory on Saturday December 09, 2023 @01:32PM (#38584342)
We do a very similar thing for X-Ray rejection from electron microscope cameras.