Coder Social home page Coder Social logo

Comments (9)

PawelDabrowski83 avatar PawelDabrowski83 commented on August 29, 2024 1

Added checkboxes in first message of this topic.

from genalgo.

PawelDabrowski83 avatar PawelDabrowski83 commented on August 29, 2024

One case where we can use calculateFitness is if we want to check Gene fitness without modyfing state of the object. For example we have multiple variants of Evaluator interface and want to compare fitness values calculated by them.

But I would argue that it is only a theoretical exercise, because value spread between 0-1 in each Evaluator impl. can be different and sometimes result 0.85 may indicate close match, and on another implementation the same result can indicate very weak match.

from genalgo.

KamilKamilS avatar KamilKamilS commented on August 29, 2024

I have created docs in this way that Evaluator has a private method calculateFitness() only to calculate fitness and return a float. and setFitness() which is a public method and uses calculated fitness from the previous method and set I to a given gene. So I want just to split setFitness() method into two methods first calculate and then setFitness() method.

from genalgo.

KamilKamilS avatar KamilKamilS commented on August 29, 2024

But maybe it is not needed because the method setFitness() that you have created is not so complex and maybe it can stay as it is now implemented

from genalgo.

PawelDabrowski83 avatar PawelDabrowski83 commented on August 29, 2024

I was looking at our current diagram, which states that both methods are public, marked with plus sign.

from genalgo.

KamilKamilS avatar KamilKamilS commented on August 29, 2024

Ok right my bad. Docs have no info about private method

from genalgo.

PawelDabrowski83 avatar PawelDabrowski83 commented on August 29, 2024

Before advancing this issue, we might resolve #70

from genalgo.

KamilKamilS avatar KamilKamilS commented on August 29, 2024

Additionally, I noticed that currently docs don't have a diagram with the evaluator. So updated diagram need to be added.

from genalgo.

PawelDabrowski83 avatar PawelDabrowski83 commented on August 29, 2024
  • Update Evaluator description
  • Update class names
  • Update diagram
  • Update style for consistency (blockquote)

from genalgo.

Related Issues (20)

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.