A tone equalizer in darktable ?

Wow! Great news! Thank you so much for your work. I am very excited about this functionality!

Why do you need these input/output circles? I mean, why do you do additional programming work with creating information in circles when the results are immediately visible on the image?

In Viveza the point is very simple:

Viveza%20point

You can either increase or decrease the given value. What happens with the corresponding action can be seen immediately on the image.

The answer is not simple. There is no masking inside the module, it’s just a bench of band-pass filters, isolating exposure bands, exactly like your Hi-Fi amplifier equalizer isolate frequencies and let you set a separate gain for each of them. It’s a simple exposure compensation, but with a correction that varies depending on the input exposure of the pixel. The actual correction is smooth over the exposure range, constructed by interpolation of the different bands gains (it’s the curve you see on the equalizer view), so there is no discontinuity between bands and gaps and stuff.

TL;DR : a mask is a spatial 2D subset of the picture, triggering lots of bounds problems and transition issues, this equalizer deals with pictures as 1D exposures series and applies a gain on them.

Then, if you want, you can use it in combination with the regular masking options to create 2D masks, isolating objects, foreground, luminance ranges, etc. With the guided filters, it should work way better than the current shadows/highlights module (and display none of its saturation artifacts).

Actually, no. It works in RGB on the three channels, but since it applies the same linear correction upon them, it retains the original chromaticity.

Because you don’t know what -6 EV looks like, so I find it helpful to have both the exposure value and the corresponding shade of grey as a preview. Many other things come later in dt’s pixelpipe, so the actual image does not represent the raw output of the module.

1 Like

That’s what I said, or meant to say. From a user point of view since the chromaticity is not changed it “works” only on lightness. Or I missed your point.

Ah, fair enough. Lightness usually refers to one channel of HSL space, so that’s what I understood.

I added a guided filter in the module, instead of the planned laplacian pyramid, in order to preserve the local contrast. It’s faster and simpler, and easier to control too.

So let’s see a well exposed image (from Anna Simon, used for her workshop at LGM2019) with filmic set up to get no blown highlights and bright enough midtones:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-24-15

The picture arguably lacks some crunch because the subject doesn’t pop out enough from the background. So, let’s enable the tone equalizer in its naïve mode, to perform a dodging and burning:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-24-44

The contrast has improved on the subject, but on the background too, which is quite disturbing. We would like to treat the subject as one single exposure blob, but showing the luminance mask used to compute the exposure compensation (new feature, by the way), here is what we get:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-40-22

To isolate the subject from the background, we need to use an edge-aware surface blur to decompose the image into piece-wise smooth exposures areas. That’s where the guided filter comes in handy:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-25-02

And here is the result:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-24-51

Working from that starting point, we can fine-tune the masking:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-25-24
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-25-36

To check the robustness to halos (which are the pest of the shadows/highlights module), let’s use a much contrasted picture:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-50-32

Let’s enable the naïve tone equalizer:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-50-43

A lot of local contrast is lost in the sky. Using the guided filter, we can revert that:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-58-16

Comparison with the current shadows/highlights output (with bilateral filter):
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2013-51-27

A bit of color-grading with color balance, and you are good to go:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2014-05-41

Notice the relatively short stack of modules:
Capture%20d%E2%80%99%C3%A9cran%20de%202019-07-12%2014-07-58
Life is too short to loose it on computers. Shoot longer, post-process faster, enjoy more.

16 Likes

27 posts were split to a new topic: Exposure Fusion and Intel Neo drivers

Interactivity is coded folks ! Hover a region of the picture with the cursor, scroll up to increase the exposure in this area, or down to decrease it, and enjoy :slight_smile:

24 Likes

Thanks for this cool feature, works fine. Now I have to invest some time in trying to get the best out of the masking/guided filter feature …

don’t hesitate to display the mask (last icon in masking tab) in order to understand what it is doing. General rule is : the sharper the mask, the more you might destroy local contrast. So the trade-off is to find the parameters that makes the mask piece-wise smooth while also following edges.

For example, I find that good smoothing diameters lie between 6-25 ( of the largest image dimension), depending on the size of the features to mask. Small feathering factors (1-2) make the filter behave like a simple box blur. Increase it, and it follow edges more closely, but you might loose the smoothness inside surfaces and make details appear in the mask (thus disappear after the exposure equalization). To alleviate that effect, you can increase the mask quantization to 0.5 or 1 EV, but that’s not always suitable if you got blur/bokeh in your pictures. The mask iterations help refining the mask contours, but will cost some performance and they will remove contrast in the mask (so you need to boost it in the mask pre-processing).

I would like to test the tone equalizer, but it doesn’t compile on Windows, with MinGW64. I get a lot of errors
error: the call requires ‘ifunc’, which is not supported by this target
Any clue?

I think it’s the multi-archs building that fails. Basically, the vectorized functions are compiled once for every SSE/AVX generation, then the program is supposed to select the variant that suits the best the CPU in use. Not sure if it’s supported on Windows.

Aurélien,
I can compile the Tone Equalizer branch just fine under Ubuntu, and on Windows I can compile the darktable master brach equally well.
Is it the first time the multi-archs building is used in DT in Tone Equalizer?
Just trying to figure out.
Marco

yes.

Nice to have the editing point interactive now. But could you please add a modifier, like CTRL? I constantly keep changing the tone curve when I actually want to zoom in/out.

EDIT: Another issue (which is a general one): I also get the error message that the tone equalizer needs to be after distortion module. Now I run darktable localized (German), but the message appears in English and I have to guess how the devs translated “distortion tool”.

1 Like

You can hit “A” then scroll to zoom, as in the retouch module and mask painting.

Not much I can do here, the module will not be translated until it is merged in master, and you will need to see that with the translator.

The Module must be after ‚Drehung‘

I googled around and it seems that Function Multi Versioning (FMV) is only supported in Linux. Not easy to find detailed info, though, so I might not be 100% correct.
In case, using FMV would break compatibility with Windows and OSX.
Does anyone know more on the issue ? Are there alternative ways to optimize the code ?
Marco

ok thanks, I can just add a compiler check in the macro and disable it in MS.

Edit: there is already a check :

#if __has_attribute(target_clones)
#define __DT_CLONE_TARGETS__ __attribute__((target_clones("default", "sse2", "sse3", "sse4.1", "sse4.2", "popcnt", "avx", "avx2", "avx512f", "fma4")))
#else
#define __DT_CLONE_TARGETS__
#endif

so it should be enabled only if the compiler supports it.

Nope.
Here is the compilator output

[ 56%] Building C object src/iop/CMakeFiles/toneequal.dir/introspection_toneequal.c.obj
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:83,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:413:20: error: the call requires 'ifunc', which is not supported by this target
  413 | static inline void fast_guided_filter(float *const restrict image,
      |                    ^~~~~~~~~~~~~~~~~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:613:9: error: the call requires 'ifunc', which is not supported by this target
  613 | #pragma omp parallel for simd schedule(static) default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:725:9: error: the call requires 'ifunc', which is not supported by this target
  725 | #pragma omp parallel for simd default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:698:9: error: the call requires 'ifunc', which is not supported by this target
  698 | #pragma omp parallel for default(none) schedule(simd:static) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:1252:9: error: the call requires 'ifunc', which is not supported by this target
 1252 | #pragma omp parallel sections
      |         ^~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:27,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:83,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/sse.h:30:9: error: the call requires 'ifunc', which is not supported by this target
   30 | #pragma omp parallel for simd default(none) \
      |         ^~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:99,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:401:11: error: the call requires 'ifunc', which is not supported by this target
  401 |   #pragma omp parallel sections
      |           ^~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:880:9: error: the call requires 'ifunc', which is not supported by this target
  880 | #pragma omp parallel for simd default(none) schedule(static) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:559:9: error: the call requires 'ifunc', which is not supported by this target
  559 | #pragma omp parallel for default(none) schedule(static) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:852:9: error: the call requires 'ifunc', which is not supported by this target
  852 | #pragma omp parallel for simd default(none) \
      |         ^~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:85,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:308:1: error: the call requires 'ifunc', which is not supported by this target
  308 |       LOOP(pixel_rgb_geomean);
      | ^
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:305:1: error: the call requires 'ifunc', which is not supported by this target
  305 |       LOOP(pixel_rgb_norm_power);
      | ^
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:302:1: error: the call requires 'ifunc', which is not supported by this target
  302 |       LOOP(pixel_rgb_norm_2);
      | ^
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:299:1: error: the call requires 'ifunc', which is not supported by this target
  299 |       LOOP(pixel_rgb_norm_1);
      | ^
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:296:1: error: the call requires 'ifunc', which is not supported by this target
  296 |       LOOP(pixel_rgb_value);
      | ^
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:293:1: error: the call requires 'ifunc', which is not supported by this target
  293 |       LOOP(pixel_rgb_lightness);
      | ^
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:85,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:290:1: error: the call requires 'ifunc', which is not supported by this target
  290 |       LOOP(pixel_rgb_mean);
      | ^
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:83,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:355:9: error: the call requires 'ifunc', which is not supported by this target
  355 | #pragma omp parallel for simd default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:336:9: error: the call requires 'ifunc', which is not supported by this target
  336 | #pragma omp parallel for simd default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:98:9: error: the call requires 'ifunc', which is not supported by this target
   98 | #pragma omp parallel for simd collapse(2) default(none) schedule(static) aligned(in, out:64) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:298:9: error: the call requires 'ifunc', which is not supported by this target
  298 | #pragma omp parallel for default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:269:9: error: the call requires 'ifunc', which is not supported by this target
  269 | #pragma omp parallel for default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:207:9: error: the call requires 'ifunc', which is not supported by this target
  207 | #pragma omp parallel for default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:169:9: error: the call requires 'ifunc', which is not supported by this target
  169 | #pragma omp parallel for default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:402:9: error: the call requires 'ifunc', which is not supported by this target
  402 | #pragma omp parallel for simd default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:390:9: error: the call requires 'ifunc', which is not supported by this target
  390 | #pragma omp parallel for simd default(none) \
      |         ^~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:379:9: error: the call requires 'ifunc', which is not supported by this target
  379 | #pragma omp parallel for simd default(none) \
      |         ^~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:1236:19: error: the call requires 'ifunc', which is not supported by this target
 1236 | static inline int radial_approximation(float A[(CHANNELS + 1) * PIXEL_CHAN],
      |                   ^~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:918:6: error: the call requires 'ifunc', which is not supported by this target
  918 | void process(struct dt_iop_module_t *self, dt_dev_pixelpipe_iop_t *piece, const void *const ivoid,
      |      ^~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:893:20: error: the call requires 'ifunc', which is not supported by this target
  893 | static inline void apply_toneequalizer(const float *const restrict in,
      |                    ^~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:864:20: error: the call requires 'ifunc', which is not supported by this target
  864 | static inline void apply_exposure(const float *const restrict in, float *const restrict out,
      |                    ^~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:836:20: error: the call requires 'ifunc', which is not supported by this target
  836 | static inline void display_luminance_mask(const float *const restrict luminance,
      |                    ^~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:716:21: error: the call requires 'ifunc', which is not supported by this target
  716 | static inline float flat_pseudo_norm(const float *const restrict image, const size_t num_elem)
      |                     ^~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:681:20: error: the call requires 'ifunc', which is not supported by this target
  681 | static inline void compute_log_histogram(const float *const restrict luminance,
      |                    ^~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:628:20: error: the call requires 'ifunc', which is not supported by this target
  628 | static inline void compute_luminance_mask(const float *const restrict in, float *const restrict luminance,
      |                    ^~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:601:13: error: the call requires 'ifunc', which is not supported by this target
  601 | static void compute_lut_correction(struct dt_iop_toneequalizer_gui_data_t *g,
      |             ^~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:581:14: error: the call requires 'ifunc', which is not supported by this target
  581 | static float pixel_correction(const float exposure,
      |              ^~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:550:20: error: the call requires 'ifunc', which is not supported by this target
  550 | static inline void compute_correction(const float *const restrict luminance,
      |                    ^~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:540:14: error: the call requires 'ifunc', which is not supported by this target
  540 | static float gaussian_func(const float radius, const float denominator)
      |              ^~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:527:14: error: the call requires 'ifunc', which is not supported by this target
  527 | static float gaussian_denom(const float sigma)
      |              ^~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:481:14: error: the call requires 'ifunc', which is not supported by this target
  481 | static float get_luminance_from_buffer(const float *const buffer,
      |              ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:99,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:374:19: error: the call requires 'ifunc', which is not supported by this target
  374 | static inline int pseudo_solve(float *const restrict A,
      |                   ^~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:355:19: error: the call requires 'ifunc', which is not supported by this target
  355 | static inline int transpose_dot_vector(float *const restrict A, // input
      |                   ^~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:335:19: error: the call requires 'ifunc', which is not supported by this target
  335 | static inline int transpose_dot_matrix(float *const restrict A, // input
      |                   ^~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:268:19: error: the call requires 'ifunc', which is not supported by this target
  268 | static inline int solve_hermitian(const float *const restrict A,
      |                   ^~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:239:19: error: the call requires 'ifunc', which is not supported by this target
  239 | static inline int triangular_ascent_safe(const float *const restrict L,
      |                   ^~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:220:19: error: the call requires 'ifunc', which is not supported by this target
  220 | static inline int triangular_ascent_fast(const float *const restrict L,
      |                   ^~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:191:19: error: the call requires 'ifunc', which is not supported by this target
  191 | static inline int triangular_descent_safe(const float *const restrict L,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:172:19: error: the call requires 'ifunc', which is not supported by this target
  172 | static inline int triangular_descent_fast(const float *const restrict L,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:124:19: error: the call requires 'ifunc', which is not supported by this target
  124 | static inline int choleski_decompose_safe(const float *const restrict A,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/choleski.h:99:19: error: the call requires 'ifunc', which is not supported by this target
   99 | static inline int choleski_decompose_fast(const float *const restrict A,
      |                   ^~~~~~~~~~~~~~~~~~~~~~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:85,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:280:20: error: the call requires 'ifunc', which is not supported by this target
  280 | static inline void luminance_mask(const float *const restrict in, float *const restrict out,
      |                    ^~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:230:13: error: the call requires 'ifunc', which is not supported by this target
  230 | static void pixel_rgb_geomean(const float *const restrict image,
      |             ^~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:200:13: error: the call requires 'ifunc', which is not supported by this target
  200 | static void pixel_rgb_norm_power(const float *const restrict image,
      |             ^~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:177:13: error: the call requires 'ifunc', which is not supported by this target
  177 | static void pixel_rgb_norm_2(const float *const restrict image,
      |             ^~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:153:13: error: the call requires 'ifunc', which is not supported by this target
  153 | static void pixel_rgb_norm_1(const float *const restrict image,
      |             ^~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:136:13: error: the call requires 'ifunc', which is not supported by this target
  136 | static void pixel_rgb_lightness(const float *const restrict image,
      |             ^~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:119:13: error: the call requires 'ifunc', which is not supported by this target
  119 | static void pixel_rgb_value(const float *const restrict image,
      |             ^~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:95:13: error: the call requires 'ifunc', which is not supported by this target
   95 | static void pixel_rgb_mean(const float *const restrict image,
      |             ^~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/luminance_mask.h:84:14: error: the call requires 'ifunc', which is not supported by this target
   84 | static float linear_contrast(const float pixel, const float fulcrum, const float contrast)
      |              ^~~~~~~~~~~~~~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:83,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:368:20: error: the call requires 'ifunc', which is not supported by this target
  368 | static inline void quantize(const float *const restrict image,
      |                    ^~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:349:20: error: the call requires 'ifunc', which is not supported by this target
  349 | static inline void apply_linear_blending_w_geomean(float *const restrict image,
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:330:20: error: the call requires 'ifunc', which is not supported by this target
  330 | static inline void apply_linear_blending(float *const restrict image,
      |                    ^~~~~~~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:257:20: error: the call requires 'ifunc', which is not supported by this target
  257 | static inline void box_average(float *const restrict in,
      |                    ^~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:151:20: error: the call requires 'ifunc', which is not supported by this target
  151 | static inline void variance_analyse(const float *const restrict guide, // I
      |                    ^~~~~~~~~~~~~~~~
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:92:20: error: the call requires 'ifunc', which is not supported by this target
   92 | static inline void interpolate_bilinear(const float *const restrict in, const size_t width_in, const size_t height_in,
      |                    ^~~~~~~~~~~~~~~~~~~~
In file included from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/fast_guided_filter.h:27,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/iop/toneequal.c:83,
                 from C:/msys64/home/marco/darktable-2.7-equalizer/darktable/build/src/iop/introspection_toneequal.c:77:
C:/msys64/home/marco/darktable-2.7-equalizer/darktable/src/common/sse.h:22:20: error: the call requires 'ifunc', which is not supported by this target
   22 | static inline void dt_simd_memcpy(const float *const restrict in,
      |                    ^~~~~~~~~~~~~~
make[2]: *** [src/iop/CMakeFiles/toneequal.dir/build.make:68: src/iop/CMakeFiles/toneequal.dir/introspection_toneequal.c.obj] Error 1
make[1]: *** [CMakeFiles/Makefile2:3455: src/iop/CMakeFiles/toneequal.dir/all] Error 2
make: *** [Makefile:152: all] Error 2

If you remove the __DT_CLONE_TARGETS__ decorator in these functions, does that solve the issue ?