<filename>AS2SegsMapper.py

import sys
import logging
from argparse import ArgumentParser, RawTextHelpFormatter

from lib.Seg2EventMapper import generateEventsSegsIOE



description = \
    "Description:\n\n" + \
    "This subcommand Maps alternative splicing events to their respective " + \
    "inclusion/exclusion segments"
parser = ArgumentParser(description=description, formatter_class=RawTextHelpFormatter,
                        add_help=False)
parser.add_argument("-fa", "--segments-file", help="specify segments FASTA file",
                    required=True)
parser.add_argument("-ioe", "--events-file", help="specify events annotation file (.ioe file generated by SUPPA)",
                    required=True)
parser.add_argument("-o", "--output-dir", help="specify output path", required=True)


def main():
    args = parser.parse_args()

    generateEventsSegsIOE(args.segments_file, args.events_file, args.output_dir)

    logger.info("Done")
    
if __name__ == '__main__':
    main()

<filename>AS2SegsMapper.py

import sys
import logging
from argparse import ArgumentParser, RawTextHelpFormatter

from lib.Seg2EventMapper import generateEventsSegsIOE



description = \
    "Description:\n\n" + \
    "This subcommand Maps alternative splicing events to their respective " + \
    "inclusion/exclusion segments"
parser = ArgumentParser(description=description, formatter_class=RawTextHelpFormatter,
                        add_help=False)
parser.add_argument("-fa", "--segments-file", help="specify segments FASTA file",
                    required=True)
parser.add_argument("-ioe", "--events-file", help="specify events annotation file (.ioe file generated by SUPPA)",
                    required=True)
parser.add_argument("-o", "--output-dir", help="specify output path", required=True)


def main():
    args = parser.parse_args()

    generateEventsSegsIOE(args.segments_file, args.events_file, args.output_dir)

    logger.info("Done")
    
if __name__ == '__main__':
    main()
