Git Product home page Git Product logo

genetic-cnn's People

Contributors

aaqibsaeed avatar aqibsaeed avatar darkonedic avatar shipxu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

genetic-cnn's Issues

Execution time

How much time does it take to execute? Cause it is taking too much time on my NVIDIA MX130 GPU.

The accuracy is always 0.101 .

what can i do to solve this?
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
gen nevals
0 20
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
1 6
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
2 8
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
('Accuracy: ', 0.101)
3 10

Same Accuracy

Hello,

thank you for your work and for the publication of the code.

I tried your genetic algorithm but I ran into one problem.
I uncommented the line to get accuracy values.
#print('Accuracy: ',score)

While running the process with the states and num_nodes you set:

STAGES = np.array(["s1","s2","s3"]) # S
NUM_NODES = np.array([3,4,5]) # K

I get always an accuracy value of 0.101 without any improvements after generations.

When I do changes to this and set:

STAGES = np.array(["s1"]) # S
NUM_NODES = np.array([3]) # K

it seems to work sometimes more as expected because of different accuracies but still with very bad ones
(e.g. 0.1946, 0.1018 etc. but again also some 0.101 values)
Furthermore one stage seems a little bit small. I also played with the TRAINING_EPOCHS and BATCH_SIZE, but nothing really changed.

I tried it with the latest versions of the libraries, and also with the older versions of the libraries released before the 12th of March 2017 (your last commit), but there are no differences with the accuracy.
pip freeze for the version with old libraries gives:

deap==1.0.1
numpy==1.16.4
protobuf==3.8.0
py-dag==2.5.0
scipy==0.19.0
six==1.12.0
tensorflow==1.0.1

Is this intended to work like this?
Assuming yes, there would be a bunch of different individuals with same accuracy, so the ranking may not be that meaningful.

Or am I doing something wrong or misunderstood this or are there other configurations I should consider?

Question of filter(kernel) size

Could the size of the filter(kernel) be larger than the size of the feature map?
In case of continue to add layers, it may end up with a larger filter than the size of the feature map.

I can't see the print results at last !

I can't see the print results at last !

print top-3 optimal solutions

best_individuals = tools.selBest(popl, k = 3)
for bi in best_individuals:
print(bi)
when I run it ,the result is nothing.
I need your help.Thanks.

Make special Setting for boosting performance on MNSIT

Hi, aqibsaeed,
I'm doing some research about NAS recently.
I noticed your implementation for GeneticCNN, which is awesome.
But I notice that the parameter setting in your Code is not suitable for MNIST(chanel is too small, and kernel size for pooling is very large), which leads to the result that the performance of it is not ineffective(accuracy stays in a low range).
So I forked your repo, and made some change for MNSIT.
Thank for your contribution.
Best,
ShipXu

dag.py : ind_nodes implementation has wrong code!!!

def ind_nodes(self, graph=None):
    """ Returns a list of all nodes in the graph with no dependencies. """
    if graph is None:
        graph = self.graph
    dependent_nodes = set(tuple(node) for dependents in graph.items() for node in dependents)
    return [node for node in graph.keys() if node not in dependent_nodes]

set(tuple(node) for dependents in graph.items() for node in dependents) : wrong code!!

corrected code (python 3 base):
dependent_nodes = set(node for dependents in iter(graph.values() )for node in dependents)

compare : py-dag:ind_nodes method

training using GA compares with BP

Hello! I read the paper, you said 'It would be very interesting to incorporate the genetic algorithm to training the network structure and weights simultaneously.' Considering the genetic algorithm is computationally expensive, is it the good method to training with GA compares with BP.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.