Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix random FEDOT results with set seed #1143

Merged
merged 16 commits into from
Aug 22, 2023
Merged

Fix random FEDOT results with set seed #1143

merged 16 commits into from
Aug 22, 2023

Conversation

kasyanovse
Copy link
Collaborator

FEDOT with set seed return the same pipeline for different compose processes for now.

@kasyanovse kasyanovse linked an issue Aug 14, 2023 that may be closed by this pull request
@aim-pep8-bot
Copy link

aim-pep8-bot commented Aug 14, 2023

Hello @kasyanovse! 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-08-22 13:17:20 UTC

@codecov
Copy link

codecov bot commented Aug 14, 2023

Codecov Report

Merging #1143 (cc20ab7) into master (0eb258b) will decrease coverage by 0.17%.
Report is 3 commits behind head on master.
The diff coverage is 49.01%.

@@            Coverage Diff             @@
##           master    #1143      +/-   ##
==========================================
- Coverage   78.48%   78.32%   -0.17%     
==========================================
  Files         130      130              
  Lines        9323     9350      +27     
==========================================
+ Hits         7317     7323       +6     
- Misses       2006     2027      +21     
Files Changed Coverage Δ
fedot/core/data/multi_modal.py 85.43% <0.00%> (ø)
..._implementations/models/ts_implementations/cgru.py 26.00% <0.00%> (-3.11%) ⬇️
fedot/core/operations/evaluation/custom.py 53.84% <33.33%> (-0.33%) ⬇️
fedot/core/operations/evaluation/text.py 60.43% <42.85%> (-0.48%) ⬇️
...t/core/repository/pipeline_operation_repository.py 96.96% <66.66%> (ø)
fedot/api/api_utils/presets.py 87.50% <100.00%> (ø)
...ore/operations/evaluation/evaluation_interfaces.py 85.84% <100.00%> (ø)
fedot/core/operations/evaluation/gpu/clustering.py 51.35% <100.00%> (ø)
fedot/core/operations/evaluation/gpu/common.py 46.93% <100.00%> (ø)
...mentations/data_operations/categorical_encoders.py 98.00% <100.00%> (ø)
... and 5 more

... and 1 file with indirect coverage changes

assert np.allclose(fedot.history.all_historical_fitness, old_fedot.history.all_historical_fitness)
assert np.isclose(np.sum(np.abs(fedot.forecast(test) - old_fedot.forecast(test))), 0)

old_fedot = fedot
Copy link
Collaborator

Choose a reason for hiding this comment

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

А тут не нужно deecopy? Мы же потом меняем fedot.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Мне кажется нет. Когда вызываем конструктор федота, то он в fedot просто ссылку на новый инстанс запишет, а ссылка на старый останется в old_fedot.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Может добавить тогда ветку теста, где seed меняется и проверка идет на то результаты не идентичны?
Для уверенности.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

В работе.

fedot/utilities/random.py Outdated Show resolved Hide resolved
@nicl-nno nicl-nno mentioned this pull request Aug 22, 2023
4 tasks
@kasyanovse kasyanovse merged commit 09da40c into master Aug 22, 2023
6 checks passed
@kasyanovse kasyanovse deleted the bugfix-1128 branch October 19, 2023 09:50
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.

FEDOT does not reproduce results
4 participants