/books/genetic-algorithms-in-elixir
Active Threads:
Latest Threads About This Book
@seanmor5
130 trillion paths should be 1.3 trillion paths.
Quite a lot paths as well, but still, it’s a two-order magnitude error.
New
With AI set to play a big role in our industry Elixir users are lucky to have Nx, so we’re running our Nx related book club on Genetic Al...
New
@seanmor5
In chapter 4 of p1.0 (page 89 of 262 in the epub version), the code for the avg termination criterion looks like this:
def te...
New
Should this section of text on page 134:
Finally, test your problem with uniform reinsertion. To do this, take the same
approach you to...
New
At the bottom of page 128 the reader is instructed to add the following:
soln = Genetic.run(Schedule)
IO.write("\n")
IO.inspec...
New
In the flip function this line of code:
%Chromosomes{genes: genes, size: chromosome.size}
should be
%Chromosome{genes: genes, size: ch...
New
@seanmor5
Should the following line of code in fitness_function:
|> Kernel.-(Enum.at(chromosome.genes), j)
be:
|> Kernel.-(Enum...
New
@seanmor5
In the repair_helper function on page 104 the following line:
if MapSet.size(chromosome) >= k do
should be:
if MapSet.si...
New
@seanmor5
On page 77, the following text:
“Change run to look like this:”
should be “Change evolve to look like this”
and lower on th...
New
@seanmor5
In the paragraph about Optimizing Cargo Loads, I think there is the word project incorrectly used, and it should be probably p...
New
Most Active This Week
Most Active This Month
Most Active This Year
Most Active Last Three Years
@seanmor5
Genetic.run call on page 30 doesn’t match function signature defined on page 28.
Page 28
def run(genotype, fitness_function,...
New
After creating the Chromosome type and updating the one_max script, the size attribute isn’t carried through. I realised that in both cro...
New
Provided source code has some problems when dealing with the reinsertions.
scripts/schedule.exs example has a default reinsertion strat...
New
Hi, the use of ^^^ is now deprecated
So, from this
$ iex
iex(1)> use Bitwise
Bitwise
iex(2)> key = 2491717835680677893
24917...
New
def fitness_function(chromosome) do
chromosome
|> Enum.map(fn {roi, risk} -> 2 * roi - risk end)
|> Enum.sum()
end
sh...
New
I just started to implement Tournament selection with duplicates and used one-max to do a test drive. On a population size of 100 and k=3...
New
Not sure if I’m doing something wrong here, but it seems that this piece of code will throw errors:
def fitness_function(chromosome) do
...
New
There is a small error on page 159.
The text says:
[…] you’ll decrease the population size to 5
But the code shows the population si...
New
The average_tiger function is written like so in the book:
def average_tiger(population) do
genes = Enum.map(population, & &am...
New
The function for calculating the mean fitness of the tiger population is missing the part were we divide the sum of the fitness of the po...
New
repair_chromosome should not pass the Enum (i.e., chromosome) to repair_helper. Rather, it should pass the set genes.
Change:
def repa...
New
On page 151, the id for each new Chromosome struct is set via a default value like:
defmodule Types.Chromosome do
@enforce_keys :genes...
New
@seanmor5
In the code example on page 49, the fitness_function suddenly switches to using charlists instead of the previously used strin...
New
With AI set to play a big role in our industry Elixir users are lucky to have Nx, so we’re running our Nx related book club on Genetic Al...
New
@seanmor5
In the paragraph about Optimizing Cargo Loads, I think there is the word project incorrectly used, and it should be probably p...
New
Book Info
Publisher:
Pragmatic Bookshelf
Are you this book's author? To be notified of all posts made about it, sign up an account then click here, then select 'watching' from the bell icon in the top right corner.
Get money off!
The Pragmatic Bookshelf
35% off any eBook
Simply use coupon code "devtalk.com" at checkout. See full details here.