Coder Social home page Coder Social logo

abc's People

Contributors

andaviaco avatar

Stargazers

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

Watchers

 avatar  avatar

abc's Issues

Some issues that are not consistent to the original paper

Hello! First of all, thank the writer who really offered us a useful and efficient template of the artificial bee colony. But unfortunately, there are some little issues that are not correct after I confirmed the procedure proposed in the original paper in 2005. So here are the work I did to fix the code, mainly in "swarm.py":

  1. During updating the positions of employed and onlooker bees, the fitness should be updated at the same time, which is missed in your code.
   def set_solution(self, food_source, new_solution):
        # greedy strategy is applied
        if np.array_equal(new_solution, food_source.solution):
            food_source.trials += 1
        else:
            food_source.solution = new_solution
            food_source.fitness = self.fitness(new_solution)
            food_source.trials = 0
        return food_source
  1. An issue that a dude once pointed out is that one bee may go beyond the search range, which can be solved by a simple function under the NumPy frame-- numpy.clip() to constraint the agents inside the borders.
  2. In "employed_bee_satge" and "onlooker_bee_stage" you, unfortunately, missed the return of function "set_solutions", which makes the optimal solution is not satble and far away from the actual one.

Hoped it will be helpful!

Cleanup non issue

When my account was compromised a spam issue was created in this repo. I sincerely apologize. Cleaning up such issues via script.

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.