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

Fixed data storing #152

Merged
merged 3 commits into from
Mar 22, 2024
Merged

Fixed data storing #152

merged 3 commits into from
Mar 22, 2024

Conversation

hammannr
Copy link
Collaborator

If toy data is already assigned to the model, it will be converted to alea.utils.ReadOnlyDict. So far, this type was not supported by the builtin model.store_data() method, which is changed with this PR.

Now you can:

model = ...
model.data = model.generate_data()
model.store_data(file_name, [model.data])

@hammannr hammannr added the enhancement New feature or request label Mar 21, 2024
@hammannr hammannr requested a review from dachengx March 21, 2024 15:54
@coveralls
Copy link

coveralls commented Mar 21, 2024

Pull Request Test Coverage Report for Build 8378431339

Details

  • 6 of 8 (75.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.03%) to 91.87%

Changes Missing Coverage Covered Lines Changed/Added Lines %
alea/utils.py 4 6 66.67%
Totals Coverage Status
Change from base Build 8358317933: -0.03%
Covered Lines: 1503
Relevant Lines: 1636

💛 - Coveralls

Copy link
Collaborator

@dachengx dachengx left a comment

Choose a reason for hiding this comment

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

Thanks @hammannr . Looks good to me. Please add a test to make sure that the previously ignored usage case is supported after this PR.

@hammannr hammannr requested a review from dachengx March 22, 2024 10:30
@dachengx dachengx merged commit daffbd9 into main Mar 22, 2024
6 of 7 checks passed
@dachengx dachengx deleted the fix_store_data branch March 22, 2024 23:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants