Skip to content

Clarify documentation on population metadata with initial_state #925

Closed

Description

@grahamgower
>>> msprime.__version__
'0.7.5.dev95+ng022fdb2'
>>> ts = msprime.simulate(end_time=0.2, population_configurations=[msprime.PopulationConfiguration(sample_size=10, metadata="foo")])
>>> ts.population(0)
{'id': 0, 'metadata': b'"foo"'}
>>> ts2 = msprime.simulate(from_ts=ts, population_configurations=[msprime.PopulationConfiguration(metadata="bar")])
>>> ts2.population(0)
{'id': 0, 'metadata': b'"foo"'}

Activity

  1. jeromekelleher commented on Mar 25, 2020

    @jeromekelleher
    Member

    Hmm - should it though? It's not clear to me that a ts transforming program should clobber existing metadata. Ideally, I guess, the program should add to the metadata, if it needs to. However, we don't have the infrastructure in place in tskit to enable this yet.

    I think we should handle this at the stdpopsim side for now, until we have decided what the right protocol is in general for passing through metadata.

    (@grahamgower, would you mind linking back to the stdpopsim issue where we hit this problem please? I've lost track of where things are!)

  2. jeromekelleher commented on Mar 25, 2020

    @jeromekelleher
    Member

    Linking to tskit-dev/tskit#57 for reference, and cc'ing @benjeffery.

  3. jeromekelleher commented on Mar 25, 2020

    @jeromekelleher
    Member

    ah, here is the stdpopsim issue: popsim-consortium/stdpopsim#438

    Please ignore the request above Graham.

  4. grahamgower commented on Mar 25, 2020

    @grahamgower
    MemberAuthor

    Hmm - should it though? It's not clear to me that a ts transforming program should clobber existing metadata.

    Yeah, I think an argument can be made for both cases. Either way, a note in the docs is probably warranted.

  5. changed the title [-]simulate with `from_ts` does not update population metadata[/-] [+]Clarify documentation on population metadata with ``initial_state``[/+] on Mar 9, 2021
  6. added this to the Release 1.0 milestone on Mar 9, 2021
  7. jeromekelleher commented on Mar 12, 2021

    @jeromekelleher
    Member

    Related to #1528 (fix should also close this)

  8. added 2 commits that reference this issue on Mar 17, 2021
    3d8c0f8
    91ae2c3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions