Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@YamLyubov
Copy link
Collaborator

@YamLyubov YamLyubov commented Sep 18, 2023

Adds:

  • PopulationalRandomMutationOptimizer
  • dag generator
  • lightweght histories loading for 'MultipleFitnessLines'

Fixes:

@aim-pep8-bot
Copy link
Collaborator

aim-pep8-bot commented Sep 18, 2023

Hello @YamLyubov! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2023-10-02 13:26:23 UTC

@pep8speaks
Copy link

pep8speaks commented Oct 2, 2023

Hello @YamLyubov! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2023-10-05 12:02:12 UTC

@codecov-commenter
Copy link

codecov-commenter commented Oct 2, 2023

Codecov Report

Merging #195 (b535c72) into main (a2cfbde) will decrease coverage by 0.59%.
The diff coverage is 29.41%.

@@            Coverage Diff             @@
##             main     #195      +/-   ##
==========================================
- Coverage   74.35%   73.76%   -0.59%     
==========================================
  Files         130      131       +1     
  Lines        7760     7826      +66     
==========================================
+ Hits         5770     5773       +3     
- Misses       1990     2053      +63     
Files Coverage Δ
golem/core/optimisers/optimizer.py 95.55% <100.00%> (+0.96%) ⬆️
golem/core/optimisers/populational_optimizer.py 95.65% <ø> (-0.65%) ⬇️
golem/visualisation/opt_history/fitness_box.py 90.32% <100.00%> (ø)
golem/visualisation/opt_history/fitness_line.py 40.22% <94.73%> (+5.07%) ⬆️
golem/core/optimisers/random/random_search.py 37.73% <11.11%> (-1.85%) ⬇️
...ore/optimisers/random/random_mutation_optimizer.py 51.35% <38.09%> (-19.24%) ⬇️
...visualisation/opt_history/multiple_fitness_line.py 0.00% <0.00%> (ø)

... and 3 files with indirect coverage changes

@YamLyubov YamLyubov marked this pull request as ready for review October 2, 2023 13:23
@YamLyubov YamLyubov force-pushed the graph-search-comparison branch from 254d37c to b535c72 Compare October 2, 2023 13:26
@YamLyubov YamLyubov requested a review from maypink October 2, 2023 13:29
node_types = ['X']
for graph_name, num_nodes in product(graph_names, graph_sizes):
experiment_id = f'Experiment [graph={graph_name} graph_size={num_nodes}]'
file_name = f'{optimizer_cls.__name__[:-9]}_{graph_name}_n{num_nodes}_iter{trial_iterations}'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

это так слово Optimizer вырезается? или почему именно 9

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Абсолютно точно)))



def generate_dag(n):
g = nx.gnp_random_graph(n, p=0.5, directed=True)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

там чел в комментах к этому решению писал, что на супер больших графах оно ломается. нам-то не принципиально, но пометку я бы оставила

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


class RandomMutationSearchOptimizer(RandomSearchOptimizer):
class PopulationalRandomMutationOptimizer(PopulationalOptimizer):
"""
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

я на написала побольше текста про то зачем такой оптимизатор и, например, где он был использован


def __init__(self,
historical_fitnesses: Dict[str, Sequence[Sequence[Union[float, Sequence[float]]]]],
metric_names,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

тип

self.log = default_log(self)

@staticmethod
def from_saved_histories(experiment_folders: List[str], root_path: os.PathLike):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

тип того, что возвращает

@YamLyubov YamLyubov requested a review from maypink October 5, 2023 12:04
# Required
version: 2

build:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

бтв кажется, оно уже заработало и без этого

@YamLyubov YamLyubov merged commit 423dbdb into main Oct 5, 2023
@YamLyubov YamLyubov deleted the graph-search-comparison branch October 5, 2023 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants