Module Import alias identifier Import alias Import alias Import alias Import alias Import alias Import alias Import alias Import alias Expr Call AttributeLoad NameLoad attr Str Str Expr Call AttributeLoad NameLoad attr Str Str FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Dict Str Str Str Str Str Num Str Num NameLoad Str For TupleStore NameStore NameStore NameLoad body If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str Call NameLoad NameLoad orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str NameLoad orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str NameLoad orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str NameLoad If CompareNotIn SubscriptLoad NameLoad Index Str ListLoad Str Str body Print Str Assign SubscriptStore NameLoad Index Str Str orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str NameLoad orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str Call NameLoad NameLoad orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str Call NameLoad NameLoad orelse If CompareIn NameLoad ListLoad Str body Assign SubscriptStore NameLoad Index Str NameLoad orelse If CompareIn NameLoad ListLoad Str body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareLtE SubscriptLoad NameLoad Index Str Num body Print Str Raise NameLoad If CompareLt SubscriptLoad NameLoad Index Str Num body Print Str Raise NameLoad If UnaryOpNot Call AttributeLoad NameLoad attr Str body Print Str Raise NameLoad If CompareNotIn SubscriptLoad NameLoad Index Str ListLoad Str Str body Print Str Raise NameLoad If CompareLtE SubscriptLoad NameLoad Index Str Num body Print Str Raise NameLoad If UnaryOpNot Call AttributeLoad NameLoad attr Str body Print Str Raise NameLoad If UnaryOpNot Call AttributeLoad NameLoad attr Str body Print Str Raise NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad BinOpMod Str TupleLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Str Expr Call AttributeLoad NameLoad attr BinOpAdd Call AttributeLoad Str attr ListComp Call AttributeLoad Str attr ListComp BinOpMod Str NameLoad comprehension NameStore NameLoad comprehension NameStore NameLoad Str Expr Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad BinOpMod Str TupleLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Str Expr Call AttributeLoad NameLoad attr BinOpAdd Call AttributeLoad Str attr ListComp Call AttributeLoad Str attr ListComp BinOpMod Str NameLoad comprehension NameStore NameLoad comprehension NameStore NameLoad Str Expr Call AttributeLoad NameLoad attr If SubscriptLoad NameLoad Index Str body Assign NameStore Call NameLoad BinOpMod Str TupleLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Str Expr Call AttributeLoad NameLoad attr BinOpAdd Call AttributeLoad Str attr ListComp Call AttributeLoad Str attr ListComp BinOpMod Str NameLoad comprehension NameStore NameLoad comprehension NameStore SubscriptLoad NameLoad Index Str Str Expr Call AttributeLoad NameLoad attr Assign NameStore Call NameLoad BinOpMod Str TupleLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Str Expr Call AttributeLoad NameLoad attr BinOpAdd Call AttributeLoad Str attr ListComp Call AttributeLoad Str attr ListComp BinOpMod Str NameLoad comprehension NameStore Call AttributeLoad NameLoad attr TupleLoad NameLoad NameLoad comprehension TupleStore NameStore NameStore Call NameLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Str Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args defaults body Expr Str Print Str Print BinOpMod Str SubscriptLoad AttributeLoad NameLoad attr Index Num Print Str Print Str Print Str Print Str Print Str Print Str Print Str Print Str Print Str decorator_list If CompareEq NameLoad Str body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Slice Num Assign NameStore Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str TryExcept body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad If UnaryOpNot NameLoad body Expr Call NameLoad Expr Call AttributeLoad NameLoad attr Num handlers ExceptHandler type AttributeLoad NameLoad attr body Print Str Expr Call NameLoad Expr Call AttributeLoad NameLoad attr Num Assign NameStore Call NameLoad NameLoad TryExcept body Expr Call NameLoad NameLoad handlers ExceptHandler type TupleLoad NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr Num If CompareEq SubscriptLoad NameLoad Index Str Str body Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str orelse If CompareEq SubscriptLoad NameLoad Index Str Str body Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad keyword AttributeLoad NameLoad attr keyword Str Assign TupleStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Expr Call NameLoad NameLoad NameLoad NameLoad NameLoad
N/A N/A numpy np N/A fastStructure N/A parse_bed N/A parse_str N/A random N/A getopt N/A sys N/A pdb N/A warnings N/A N/A N/A warnings filterwarnings ignore .*divide by zero.* N/A N/A N/A warnings filterwarnings ignore .*invalid value.* parseopts N/A N/A opts N/A N/A N/A 
    parses the command-line flags and options passed to the script
     N/A params N/A mintol prior cv full format 1e-06 simple 0 False bed N/A N/A opt arg opts N/A N/A N/A opt N/A -K N/A N/A N/A params N/A K N/A int arg N/A N/A N/A opt N/A --input N/A N/A N/A params N/A inputfile arg N/A N/A N/A opt N/A --output N/A N/A N/A params N/A outputfile arg N/A N/A N/A opt N/A --prior N/A N/A N/A params N/A prior arg N/A N/A N/A params N/A prior N/A simple logistic N/A N/A %s prior is not currently implemented, defaulting to the simple prior N/A N/A params N/A prior simple N/A N/A N/A opt N/A --format N/A N/A N/A params N/A format arg N/A N/A N/A opt N/A --cv N/A N/A N/A params N/A cv N/A int arg N/A N/A N/A opt N/A --tol N/A N/A N/A params N/A mintol N/A float arg N/A N/A N/A opt N/A --full N/A N/A N/A params N/A full True N/A N/A N/A opt N/A --seed N/A N/A N/A N/A N/A np random seed N/A int arg N/A N/A N/A random seed N/A int arg N/A params N/A checkopts N/A N/A params N/A N/A N/A 
    checks if some of the command-line options passed are valid.
    In the case of invalid options, an exception is always thrown.
     N/A N/A N/A params N/A mintol 0 N/A N/A a non-positive value was provided as convergence criterion N/A ValueError N/A N/A N/A params N/A cv 0 N/A N/A a negative value was provided for the number of cross-validations folds N/A ValueError N/A N/A N/A N/A params has_key K N/A N/A a positive integer should be provided for number of populations N/A KeyError N/A N/A N/A params N/A format N/A bed str N/A N/A %s data format is not currently implemented N/A ValueError N/A N/A N/A params N/A K 0 N/A N/A a negative value was provided for the number of populations N/A ValueError N/A N/A N/A N/A params has_key inputfile N/A N/A an input file needs to be provided N/A KeyError N/A N/A N/A N/A params has_key outputfile N/A N/A an output file needs to be provided N/A KeyError N/A write_output N/A N/A Q P other params N/A N/A N/A 
    write the posterior means and variational parameters
    to separate output files.
     N/A handle N/A open N/A %s.%d.meanQ N/A N/A params N/A outputfile N/A params N/A K w N/A N/A N/A handle write N/A N/A N/A join N/A N/A N/A join N/A N/A %.6f i N/A i q N/A q Q N/A N/A N/A handle close N/A handle N/A open N/A %s.%d.meanP N/A N/A params N/A outputfile N/A params N/A K w N/A N/A N/A handle write N/A N/A N/A join N/A N/A N/A join N/A N/A %.6f i N/A i p N/A p P N/A N/A N/A handle close N/A N/A params N/A full N/A N/A handle N/A open N/A %s.%d.varQ N/A N/A params N/A outputfile N/A params N/A K w N/A N/A N/A handle write N/A N/A N/A join N/A N/A N/A join N/A N/A %.6f i N/A i q N/A q N/A other N/A varQ N/A N/A N/A handle close N/A handle N/A open N/A %s.%d.varP N/A N/A params N/A outputfile N/A params N/A K w N/A N/A N/A handle write N/A N/A N/A join N/A N/A N/A join N/A N/A %.6f i N/A i N/A N/A np hstack N/A pb pg N/A N/A pb pg N/A zip N/A other N/A varPb N/A other N/A varPg N/A N/A N/A handle close N/A usage N/A N/A N/A N/A N/A 
    brief description of various flags and options for this script
     N/A 
Here is how you can use this script
 N/A N/A Usage: python %s N/A N/A sys argv N/A 0 N/A 	 -K <int> (number of populations) N/A 	 --input=<file> (/path/to/input/file) N/A 	 --output=<file> (/path/to/output/file) N/A 	 --tol=<float> (convergence criterion; default: 10e-6) N/A 	 --prior={simple,logistic} (choice of prior; default: simple) N/A 	 --cv=<int> (number of test sets for cross-validation, 0 implies no CV step; default: 0) N/A 	 --format={bed,str} (format of input file; default: bed) N/A 	 --full (to output all variational parameters; optional) N/A 	 --seed=<int> (manually specify seed for random number generator; optional) N/A N/A N/A __name__ __main__ N/A N/A argv N/A N/A sys argv N/A 1 N/A smallflags K: N/A bigflags N/A prior= tol= input= output= cv= seed= format= full N/A N/A N/A N/A opts args N/A N/A getopt getopt argv smallflags bigflags N/A N/A opts N/A N/A N/A usage N/A N/A N/A sys exit 2 N/A N/A N/A N/A getopt GetoptError N/A N/A Incorrect options passed N/A N/A usage N/A N/A N/A sys exit 2 N/A params N/A parseopts opts N/A N/A N/A N/A checkopts params N/A N/A N/A N/A ValueError KeyError N/A N/A N/A N/A sys exit 2 N/A N/A N/A params N/A format bed N/A N/A G N/A N/A parse_bed load N/A params N/A inputfile N/A N/A N/A N/A params N/A format str N/A N/A G N/A N/A parse_str load N/A params N/A inputfile N/A G N/A N/A np require G dtype N/A np uint8 requirements C N/A N/A Q P other N/A N/A fastStructure infer_variational_parameters G N/A params N/A K N/A params N/A outputfile N/A params N/A mintol N/A params N/A prior N/A params N/A cv N/A N/A write_output Q P other params