Hi,
I'm running STRUCTURE 2.3.4 on an ubuntu server (Ubuntu 14.04.5 LTS, id_like = Debian) via commandline, attempting to infer ancestry of (hybridised) descendants from known ancestry groups (an Australian mammal)
Strategy was to infer population of origin for a group of ancestors (worked fine), then (in a second structure run) use these predefined ancestor groups to assign admixture proportions to descendants. (i.e. the USEPOPINFO model)
Data setup for second step was 3 ancestral populations (coded 1-3) with POPFLAG set to 1, followed by other individuals with POPFLAG set to 0.
During this second step, at random points within the first 20k iterations, runs will abor with the error message "error in '[path]/structure': munmap_chunk(): invalid pointer: 0x08735ba8 ***" [or similar pointer]
How do I avoid this? Is it an issue at my end, or something wrong with the USEPOPINFO feature? (either in terms of my system or elsewhere).
Example main parameters:
#define MAXPOPS 3
#define BURNIN 10000
#define NUMREPS 100000
#define INFILE 2012.sort.str.txt
#define OUTFILE 2012_results
#define NUMINDS 56
#define NUMLOCI 14522
#define ONEROWPERIND 1
#define LABEL 1
#define POPDATA 1
#define POPFLAG 1
#define LOCDATA 0
#define PHENOTYPE 0
#define EXTRACOLS 0
#define MARKERNAMES 0
#define RECESSIVEALLELES 0
#define MAPDISTANCES 0
Example extra parameters
#define NOADMIX 0
#define USEPOPINFO 1
#define MIGRPRIOR 0
#define LOCPRIOR 0
#define FREQSCORR 1
#define ONEFST 0
#define INFERALPHA 1
#define INFERLAMBDA 0
#define LAMBDA 0.25
#define GENSBACK 4
#define PFROMPOPFLAGONLY 1
#define LOCISPOP 1
#define PRINTLAMBDA 0
#define RANDOMIZE 0
#define INTERMEDSAVE 10
(note that randomize is set to zero as I am running these parallel on a cluster and using a python script to assign a unique seed to each sample).
Data mockup (some individuals given with 2 loci)
(no column labels supplied (dealt with in main parameters)... columns are (1) individuals, (2) population label, (3) popflag, (4,5) allele 1 (onerowperindv is on), (6,7) allele 2, etc. )
8714 1 1 100 100 120 120
8738 1 1 100 100 120 120
279 1 1 -9 -9 120 120
7331 2 1 100 100 120 110
7343 2 1 100 100 120 120
8391 2 1 -9 -9 110 110
932 3 1 130 130 120 120
933 3 1 130 130 120 120
703 3 1 100 100 120 120
8895 4 0 100 100 120 120
981 4 0 100 100 120 120
8661 5 0 100 100 120 120
Implementation
Server: Ubuntu version 14.04.5 ("LTS, Trusty Tahr")
ID=ubuntu
ID_LIKE=debian
Structure version is 2.3.4.
SLURM version is 2.6.5
Python3 version is 3.6.3 (recently installed - default for OS 3.4)
I am running a series of structure jobs in parallel on a slurm system via the srun command (srun job1 & srun job2 & srun job3; wait) format. These various sruns (carrying the structure process) abort at different times (in response to structure crashing) with the message, srun: error: master: task 0: Aborted (core dumped)
I am open to this being a filesize issue: however, I have successfully completed a structure run with different inference parameters (admix, not locprior model) without core dump on a much larger file, so suspect a model-specific issue...
STRUCTURE initially wasn't recognized on my operating system as it is 32 bit - I dealt with this via sudo apt-get install then the libraries lib32z1, lib32ncurses5, & lib32bz2-1.0
Lambda is set to 0.25 based on prior inference (I'm using SNPs, thinned, with singletons removed)
My rationale for using the settings that given in the Manual (page 11, under the heading, "USEPOPINFO model: pre-specify the population of origin of some individuals to assist ancestry estimation for individuals of unknown origin") with the goal of classifying individuals of unknown origin based on a prior set of individuals of known origin (groups 1-3).