how to use my Ann.net in Fannj

1 view
Skip to first unread message

Hoda Faregh

unread,
Dec 24, 2016, 6:06:25 AM12/24/16
to FannJ
hi,
I m amateur in using Fannj.
my goal is having a class and Function for my Ann in my project to send my data and get my result.
I created a .net Ann file that I Created with FanTool before.
Now what should i do in eclispse?how can I reach to my Ann class ?

Kyle Renfro

unread,
Dec 26, 2016, 3:08:38 PM12/26/16
to fa...@googlegroups.com
Hoda,

You need to instantiate an instance of Fann and pass in the path to your .net ann file as the only argument of the constructor.

Fann fann = new Fann( "/path/to/file/test.net" );

Once you have that, you need to send Fann some inputs as an array.    What this looks like will depend on how your trained your ANN.

float[] inputs = new float[]{ -1, 1, 0, 3 };

Pass the inputs to the fan run() method to have get the output.

float[] outputs = fann.run( inputs );

Close Fann when done.

fann.close();



Kyle Renfro
Senior Software Engineer



13284 Pond Springs Road, Suite 101
Austin, Texas 78729
P: (512) 459-8300 or toll free (800) 580-8300
Desk: 
(512) 334-0873
www.real-comp.com

--

---
You received this message because you are subscribed to the Google Groups "FannJ" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fannj+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages