Hack Forums
[C] how to code a neural net - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [C] how to code a neural net (/showthread.php?tid=5914340)



how to code a neural net - p9ck4d - Dec 1, 2018

I've been modding neural nets (only yolov3 for speed), but how do i make one??

I've can detect 100% similar models or a resized one inside input( bitmaps), but how do i generalize it?

Like if something isn't 100% exact?

Im using C++


RE: how to code a neural net - 6577657534735 - Dec 1, 2018

learn what a neural net is

learn common methods of implementing them

i'm interpreting this as that you have some existing neural net code you want to modify

to do this, do those first 2 steps, then learn this codebase.

after that it should be obvious. if it isn't, repeat these steps


RE: how to code a neural net - 0xDEAD10CC - Dec 2, 2018

There's a lot of papers on the subject, it all comes down to training and evaluation, and you also need datasets that you use for training and evaluation (but those should be separate). If you want to start off with something quick, use tensorflow: https://www.tensorflow.org/guide/extend/cc


RE: how to code a neural net - jammy47 - Dec 6, 2018

tensorflow, i totally agree.


RE: how to code a neural net - iTHX - Dec 11, 2018

I suppose you have a correct answer by now so sorry for doing this lol.
This is basically a neural network:

Code
if(){
    if(){
        if(){
            if(){
                if(){
                    if(){
                        if(){
                            if(){
                                if(){
                                    if(){
                                        if(){
                                            if(){
                                                if(){
                                                    if(){
                                                        if(){
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}



RE: how to code a neural net - 0xDEAD10CC - Dec 11, 2018

(Dec 11, 2018 03:16 PM)iTHX Wrote:  I suppose you have a correct answer by now so sorry for doing this lol.
This is basically a neural network:

Code
if(){
    if(){
        if(){
            if(){
                if(){
                    if(){
                        if(){
                            if(){
                                if(){
                                    if(){
                                        if(){
                                            if(){
                                                if(){
                                                    if(){
                                                        if(){
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}

Not really. It's more based on calculus, and other algebra with matrices of numeric values; biases and weights that are tweaked over test data, and utilized to calculate the probability of a result in a variety of ways that are tailored to certain topics (i.e. dynamic speech recognition vs linear classification tasks like image recognition).


RE: how to code a neural net - iTHX - Dec 12, 2018

(Dec 11, 2018 11:12 PM)0xDEAD10CC Wrote:  Not really. It's more based on calculus, and other algebra with matrices of numeric values; biases and weights that are tweaked over test data, and utilized to calculate the probability of a result in a variety of ways that are tailored to certain topics (i.e. dynamic speech recognition vs linear classification tasks like image recognition).

i learned alot from those 3 lines


RE: how to code a neural net - iTHX - Dec 12, 2018

(Dec 11, 2018 11:12 PM)0xDEAD10CC Wrote:  Not really. It's more based on calculus, and other algebra with matrices of numeric values; biases and weights that are tweaked over test data, and utilized to calculate the probability of a result in a variety of ways that are tailored to certain topics (i.e. dynamic speech recognition vs linear classification tasks like image recognition).

i learned alot from those 3 lines


RE: how to code a neural net - 0xDEAD10CC - Dec 12, 2018

this is about the best introductory video explanation I've seen yet:






RE: how to code a neural net - Gorzoid - Dec 13, 2018

(Dec 11, 2018 11:12 PM)0xDEAD10CC Wrote:  Not really. It's more based on calculus, and other algebra with matrices of numeric values; biases and weights that are tweaked over test data, and utilized to calculate the probability of a result in a variety of ways that are tailored to certain topics (i.e. dynamic speech recognition vs linear classification tasks like image recognition).

Completeley agree but I think you missed the dudes joke. It's a common programming meme to say that AI is just a whole bunch of if statements.


RE: how to code a neural net - realsunjester - Dec 13, 2018

I hear some people are actually moving into Go to Rust for this, https://github.com/jackm321/RustNN