# Path: alis/almsgs.py
# class Colors:
# class msgs:
#     def disable(self):
#     def __init__(self):
#     def alisheader(self, prognm, verbose=2):
#     def signal_handler(self, signalnum, handler):
#     def error(self, msg, verbose=None):
#     def info(self, msg, verbose=None):
#     def warn(self, msg, verbose=None):
#     def test(self, msg, verbose=None):
#     def bug(self, msg, verbose=None):
#     def work(self, msg, verbose=None):
#     def input(self):
#     def newline(self,verbose=None):
#     def indent(self,verbose=None):


import numpy as np
import matplotlib
from matplotlib import pyplot as plt
from matplotlib import ticker
from alis import almsgs
    from matplotlib.backends.backend_pdf import PdfPages
    from alis import alsave
                else: pgcnt = panppg
                tnumone = 0
                for i in range(pgcnt):
                    sp = snpid[snips_done+i]
                    sn = tpltlst[sp]
                    while subids[sp][sn] == 0:
                        snips_done += 1
                        tnumone += 1
                        lesspg += 1
                        tpltlst[sp] += 1
                        sn = tpltlst[sp]
                        # If the snip number has gone beyond the array size, go to the next specid.
                        if sn == np.size(subids[sp]):
                            if snips_done+i == np.size(snpid): break
                            sp = snpid[snips_done+i]
                            sn = tpltlst[sp]
#							print pg, sp, sn
#							print tpltlst
#							print pg, i, sp, sn, snips_done, len(subids), len(subids[sp])
                            # If the next snip for the next specid is a single plot, don't break.
                            if subids[sp][sn] != 0: break # Otherwise, break the while loop
                    tpltlst[sp] += 1
                snips_done += pgcnt
                subpnl_done += pgcnt
                numone += tnumone
                panels_left -= panppg
        panels_left=numsub
        subpnl_done=0
        snips_done=0
        numone = 0

# Path: alis/almsgs.py
# class Colors:
# class msgs:
#     def disable(self):
#     def __init__(self):
#     def alisheader(self, prognm, verbose=2):
#     def signal_handler(self, signalnum, handler):
#     def error(self, msg, verbose=None):
#     def info(self, msg, verbose=None):
#     def warn(self, msg, verbose=None):
#     def test(self, msg, verbose=None):
#     def bug(self, msg, verbose=None):
#     def work(self, msg, verbose=None):
#     def input(self):
#     def newline(self,verbose=None):
#     def indent(self,verbose=None):


# Path: alis/alplot.py
import numpy as np
import matplotlib
from matplotlib import pyplot as plt
from matplotlib import ticker
from alis import almsgs
    from matplotlib.backends.backend_pdf import PdfPages
    from alis import alsave

                else: pgcnt = panppg
                tnumone = 0
                for i in range(pgcnt):
                    sp = snpid[snips_done+i]
                    sn = tpltlst[sp]
                    while subids[sp][sn] == 0:
                        snips_done += 1
                        tnumone += 1
                        lesspg += 1
                        tpltlst[sp] += 1
                        sn = tpltlst[sp]
                        # If the snip number has gone beyond the array size, go to the next specid.
                        if sn == np.size(subids[sp]):
                            if snips_done+i == np.size(snpid): break
                            sp = snpid[snips_done+i]
                            sn = tpltlst[sp]
#							print pg, sp, sn
#							print tpltlst
#							print pg, i, sp, sn, snips_done, len(subids), len(subids[sp])
                            # If the next snip for the next specid is a single plot, don't break.
                            if subids[sp][sn] != 0: break # Otherwise, break the while loop
                    tpltlst[sp] += 1
                snips_done += pgcnt
                subpnl_done += pgcnt
                numone += tnumone
                panels_left -= panppg
        panels_left=numsub
        subpnl_done=0
        snips_done=0
        numone = 0

        pgs = 0