Closed petrelharp closed 1 month ago
Running this python script:
import stdpopsim import tskit import numpy as np species = stdpopsim.get_species("HomSap") model = species.get_demographic_model("OutOfAfrica_3G09") contig = species.get_contig("chr17", mutation_rate=model.mutation_rate, genetic_map="HapMapII_GRCh38", left=0, right=40000000.0) dfe = species.get_dfe("Gamma_K17") exons = species.get_annotations("ensembl_havana_104_exons") exon_intervals = exons.get_chromosome_annotations("chr17") contig.add_dfe(intervals=exon_intervals, DFE=dfe) engine = stdpopsim.get_engine("slim") samples = {"YRI": 100, "CHB": 100, "CEU": 100} ts = engine.simulate(model, contig, samples, slim_scaling_factor=50, seed=123)
results in a "slim crashed" sort of error; asking it to please output the SLiM script (here: script.txt) and running that in SLiM results in
1: Starting burn-in... 1461: {dbg(self.source); p0.setSubpopulationSize(246);} 1525: {dbg(self.source); p = sim.addSubpopSplit(1,42,0); p.name = 'CEU';} 1525: {dbg(self.source); p0.setMigrationRates(1, 0.0125);} 1525: {dbg(self.source); p1.setMigrationRates(0, 0.0125);} 1620: {dbg(self.source); p = sim.addSubpopSplit(2,10,1); p.name = 'CHB';} 1620: {dbg(self.source); p1.setSubpopulationSize(20);} 1620: {dbg(self.source); p0.setMigrationRates(1, 0.0015);} 1620: {dbg(self.source); p0.setMigrationRates(2, 0.00095);} 1620: {dbg(self.source); p1.setMigrationRates(0, 0.0015);} 1620: {dbg(self.source); p1.setMigrationRates(2, 0.0048);} 1620: {dbg(self.source); p2.setMigrationRates(0, 0.00095);} 1620: {dbg(self.source); p2.setMigrationRates(1, 0.0048);} 1621: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1621: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1622: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1622: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1623: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1623: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1624: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1624: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1625: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1625: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1626: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1626: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1627: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1627: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1628: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1628: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1629: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1629: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1630: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1630: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1631: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1631: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1632: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1632: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1633: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1633: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1634: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1634: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1635: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1635: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1636: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1636: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1637: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(20*exp(0.2*gx))); p1.setSubpopulationSize(size);} 1637: {dbg(self.source); gx=community.tick-1620; size=asInteger(round(10*exp(0.275*gx))); p2.setSubpopulationSize(size);} 1637: {dbg(self.source); inds=p0.sampleIndividuals(100); sim.treeSeqRememberIndividuals(inds);} 1637: {dbg(self.source); inds=p1.sampleIndividuals(100); sim.treeSeqRememberIndividuals(inds);} 1637: {dbg(self.source); inds=p2.sampleIndividuals(100); sim.treeSeqRememberIndividuals(inds);} double free or corruption (!prev) Aborted
Running the script in SLiMgui crashes my OS (well, just the window manager, actually). There seems to be a memory error somewhere. This is with
$ slim -v SLiM version 4.2.2, built May 28 2024 11:17:11 Git commit SHA-1: 7dc12178b00ee83de3461616981e1e087fe88624
Running this python script:
results in a "slim crashed" sort of error; asking it to please output the SLiM script (here: script.txt) and running that in SLiM results in
Running the script in SLiMgui crashes my OS (well, just the window manager, actually). There seems to be a memory error somewhere. This is with