Hi,

you asked for a multipage design doc, which I'll try to put on the wiki, so
I am going to rant here a bit :

2014-12-16 6:13 GMT+12:00 Ivan Vučica <i...@vucica.net>:
>
> On Sun, Dec 14, 2014 at 8:10 AM, Johan Ceuppens <enrytheer...@gmail.com>
> wrote:
>>
>> I am making a fuzzy networks driver for graphical display. I still need
>> to think out the design apart from the logic e.g. which machine learning I
>> will implement such as a fuzzy set parser with NSString.
>>
>> The OpalFuzzyDB is a dictionary in the form of tuples with ("extremely",
>> SEL), this can then be asked to the backend in the form of e.g. "paint not
>> extremely" if the mouse moves and so on.
>>
>
> Can you clarify what does "fuzzy networks driver for graphical display"
> mean?
>
>
For information on fuzzy networks I send you to google. I'll try to explain
what I am doing with them.

I apologize for stuffing this into opal albeit the code has its own
directory named fuzzy and is fully portable objc without dependencies, not
even invocations for the functors in it.

X11, Xquartz paint in synchronised or asynchronised modes, for that I send
you to the Xlib programming manual and X11 man pages.

The only thing my words "fuzzy networks driver for graphical display" mean
is to 'bypass' or alleviate the updating in X11. In event catching e.g. you
do XSelectInput(0) and no events pass to GS so there is no mouse input, no
mapping of the windows etc. Here you can insert the fuzzy logic system with
nodes, canvas and human interface parser of the fuzzy ruleset systems. Note
that you _can_ catch events with e.g. XSelectInput and that these catched
events can be performed using machine learning and that you have to draw
Views and all components on the screen in a view or what not, these things
can also be managed with machine learning in this case a fuzzy set or
network.

The fuzzy paint node, does painting in between things for example, you can
paint and idle the painting algorithm for a second, this is all in a fuzzy
ruleset.

Here's an example of the implementation, which you can call from C :
See comments in the code :
void makePaintRules(OpalFuzzyPaintRuleSystem* sys)
{
        /*sys contains a canvas called _painter and adds here a rule
          which redraws the screen, this method is paintOn: with the
          canvas as an argument. There are 3 adapters inside sys : self,
painter  and parser
        */
        [sys addRule:"paint extremely fast" : paintOn:];

        /* f is a functor object which contains the "extremely" reasoning
fuzzy function, implemented as return (x*x*x); where x is initialized to
0.0 thereunder. You change the x not the threshold in sys, so if you have a
threshold of 0.001, f(x)==0 < threshold, and the rule gets matched by sys.
The fuzzy parser of rules is now still simple. I mean the non-fuzzy
function part.
        */
        OpalFuzzyFunction *f = [OpalFuzzyFunctionExtremely new];
        [f x:.0];
        [sys addFunction:"paint extremely" : f];
        /* here's the same thing the paint thread of e.g. Xquartz event
handling sleeps for 1 second */
        [sys addRule:"paint not for 1 second" : paintIdle1SecondOn:];
        f = [OpalFuzzyFunctionIdle new];
        [f x:.0];
        [sys addFunction:"paint not for 1 second" : f];
}


How does this relate to Core Graphics APIs (of which Opal is an
> implementation of), or to the gnustep-back backend that uses Opal to draw
> content to the screen?
>
>
Again, opal might not be the right place but AI can be used to alleviate
opal too. Ask and ye shall receive :-)


> Are you certain this should live at this layer of the architecture of a
> GNUstep app?
>
>> This type of fuzzy logic would be useful for AI or perhaps in some layout
>>> solver. I'm unsure how it helps a graphics library  (Opal) or an interface
>>> to a graphics library (Opal backend inside gnustep-back)?
>>>
>>>
>> It'll be OK, don;t worry. :-)
>>
>
> "Don't worry" is what worries me :-)
>
> Keep in mind that it is very useful to be able to explain your designs to
> others. Currently, I don't really know what you're doing, so I'd really
> like to read more about your plans. Even if that means reading multiple
> page designdoc.
>


I will make such a document if I find the time, I have wiki access at
wiki.gnustep.org, I'll put it there if I can find a page for it.


> Without a clearer explanation, I don't think anyone can tell whether what
> you've started makes sense or not.
>
> Currently, I have a feeling you know what you're doing, but may be trying
> to stuff it into the wrong place.
>
>
>

Indeed, it needs to be in the event catching of X11 and update the screen
with e.g. the fuzzy paint node (See the mail titled Fuzzy Paint Node.)

Another node would be the mouse node or the same machine learning for Gorm,
text analysing, natural language processing in GNUMail etc. An API can be
provided, probably in ObjC.


> Can you clarify why you believe this should live in the Opal backend, what
> is the relationship of your changes to the Core Graphics API, why this is
> universally useful to a large number of GNUstep apps, why can't this live
> as an independent library, etc?
>

In opal or CoreGraphics you can use the updating with my AI.
It can be put in its own library but I dared not to work that out.

HTH,
`Enry

> --
> Ivan Vučica
> i...@vucica.net
>
_______________________________________________
Gnustep-dev mailing list
Gnustep-dev@gnu.org
https://lists.gnu.org/mailman/listinfo/gnustep-dev

Reply via email to