Hi,
Sorry. I may misunderstand your previous mail.
I will continue to analyze it and try to find the root cause.
Thanks.
Yan Wang
yan.wang
From: johannes hanika
Date: 2017-02-22 19:00
To: yan.wang
CC: darktable-dev
Subject: Re: Re: [darktable-dev] Darktable on Beignet
hi,
sorry, i don't think your patch is okay.
if gmin == 0.0 that means there should be at least one element in
gval[.] == 0.0. this should, regardless of gmax, evaluate (gval[g] <=
thold) as true. if that is not the case there is something else wrong
in the control flow.
-jo
On Wed, Feb 22, 2017 at 10:40 AM, yan.wang <[email protected]> wrote:
> Hi,
> Thanks for your replying.
> I add printf into this kernel for dump gmin and gmax in this case on my
> platform.
> And I find that gmin has the value "0.00000" but gamx is 0.04.
> But thold = gmin + (gmax * 0.5f). if gmin = 0.0f, it may cause thold has
> only gmax / 2.
> I think it may cause if (gval[g] <= thold) section will not be entered
> because float caluclation may not be used equaltion comparation prcisionlly.
> I am not familiar with the algorithm of demosaic.
> If my patch is OK, could you please merge it and remove beignet from
> black list?
> Thanks.
>
> Yan Wang
>
> ________________________________
> yan.wang
>
>
> From: johannes hanika
> Date: 2017-02-22 17:11
> To: yan.wang
> CC: darktable-dev
> Subject: Re: Re: [darktable-dev] Darktable on Beignet
> hi,
>
> thanks for looking into this!
>
> /0 is not nice in any case.. but i doubt your fix is the best we can
> do. num should be incremented whenever a value is smaller than or
> equal to a threshold, which is chosen based on the min and max of
> these very values. the case num==0 should really never happen (and
> it's not safeguarded in the cpu code path either).
>
> at least the one case of the one gval[g] that is == gmin, the case
> if(gval[g] <= thold) should trigger, no? the edge case being
> gmin=gmax=thold which should be covered by the == case. maybe
> something in the computation of these min and max went wrong?
>
> cheers,
> jo
>
> On Wed, Feb 22, 2017 at 8:39 AM, yan.wang <[email protected]> wrote:
>> Hi, Roman,
>> I debugged darktable on beignet on my Skylake and Chrry View platfrom
>> by
>> your DNG and XMP files.
>> I use the latest beignet master.
>> The result seems some wrong with CPU version but is also different
>> with
>> screenshot result of bugzilla.
>> Please review my attached screenshot file.
>> For this issue, I found that it is related with the OCL kernel named
>> with vng_interpolate() in demosaic_vng.cl.
>> In this kernel, variable named with "num" may be zero and cause
>> dividing
>> zero error.
>> After modify it like my attached patch, this issue will disappear.
>> I haven't compared OCL kernel and CPU version.
>> So I am not sure whether "num == 0" is right.
>> I also will check the processing flow of "dividing zero" in Beignet.
>> Thanks.
>>
>> ________________________________
>> yan.wang
>>
>>
>> From: Roman Lebedev
>> Date: 2017-02-16 19:37
>> To: yan.wang
>> CC: darktable-dev
>> Subject: Re: [darktable-dev] Darktable on Beignet
>> On Thu, Feb 16, 2017 at 11:11 AM, yan.wang <[email protected]>
>> wrote:
>>> Hi,
>>> I am Beignet devloper from Intel.
>> Hi.
>>
>>> Just I found Beignet is pushed into the blacklist of darktable
>>> because
>>> of one bug.
>>> http://www.darktable.org/2016/12/darktable-2-2-0rc3-released/
>>> I want to fix it but I don't know how to reproduce it.
>> In this particular case, i blacklisted it because of
>> https://redmine.darktable.org/issues/11358
>>
>> To reproduce, i guess you'd need
>> https://redmine.darktable.org/attachments/download/2799/CRW_9672.DNG
>> and
>> https://redmine.darktable.org/attachments/download/2803/CRW_9672.DNG.xmp
>>
>> Disable blacklist (echo "opencl_disable_drivers_blacklist=true >>
>> ~/.config/darktable/darktablerc")
>> Start dt
>> Import image
>> Select it (highlight the image, click on it once)
>> In right sidepanel, in "History stack" module, click on "load sidecar
>> file", and select that XMP.
>>
>> Maybe this particular issue is already fixed, maybe it is not.
>>
>>> Who could help me?
>>> Thanks.
>>>
>>> ________________________________
>>> yan.wang
>> Roman.
>>
>>>
>>>
>>> ___________________________________________________________________________
>>> darktable developer mailing list to unsubscribe send a mail to
>>> [email protected]
>>
>>
>>
>> ___________________________________________________________________________
>> darktable developer mailing list to unsubscribe send a mail to
>> [email protected]
___________________________________________________________________________
darktable developer mailing list
to unsubscribe send a mail to [email protected]
___________________________________________________________________________
darktable developer mailing list
to unsubscribe send a mail to [email protected]