Exemple #1
0
    def _defineParams(self, form):    
        #ProtMonitor._defineParams(self, form)
        form.addSection(label='Input')

        form.addParam('inputProtocol', params.PointerParam,
                      label="Input protocols", important=True,
                      pointerClass='ProtCTFFind, XmippProtCTFMicrographs',
                      help="this protocol will be monitorized")
        form.addParam('samplingInterval', params.IntParam,default=60,
                      label="Sampling Interval (sec)",
                      pointerClass='EMProtocol',
                      help="Take one sample each SamplinInteval seconds")

        form.addParam('maxDefocus', params.FloatParam,default=40000,
              label="Raise Alarm if maximum defocus (A) >",
              help="Raise alarm if defocus is greater than given value")
        form.addParam('minDefocus', params.FloatParam,default=1000,
              label="Raise Alarm if minimum defocus (A) <",
              help="Raise alarm if defocus is smaller than given value")
        form.addParam('astigmatism', params.FloatParam,default=2000,
              label="Raise Alarm if astigmatism (A) >",
              help="Raise alarm if astigmatism is greater than given value")

        form.addParam('monitorTime', params.FloatParam, default=300,
              label="Total Logging time (min)",
              help="Log during this interval")

        ProtMonitor._sendMailParams(self, form)
    def _defineParams(self, form):
        ProtMonitor._defineParams(self, form)

        form.addParam('transferMethod',
                      params.EnumParam,
                      default=0,
                      choices=['scp', 'bbcp'],
                      label='Transfer method')

        form.addParam('compress',
                      params.BooleanParam,
                      default=True,
                      label='Compress before transfer?')

        form.addParam('destinationHost',
                      params.StringParam,
                      default=None,
                      label='Destination host')

        form.addParam('destinationDirectory',
                      params.StringParam,
                      default=None,
                      label='Destination directory')

        form.addParam('destinationUser',
                      params.StringParam,
                      default=None,
                      label='Destination user name')
    def _defineParams(self, form):
        # ProtMonitor._defineParams(self, form)
        form.addSection(label='Input')

        form.addParam('inputProtocol', params.PointerParam,
                      label="Input protocol", important=True,
                      pointerClass='XmippProtMovieGain',
                      help="This protocol will be monitorized")

        form.addParam('stddevValue', params.FloatParam, default=0.04,
                      label="Raise Alarm if residual gain standard "
                            "deviation >",
                      help="Raise alarm if residual gain standard deviation "
                           "is greater than given value")
        form.addParam('ratio1Value', params.FloatParam, default=1.15,
                      label="Raise Alarm if the ratio between the 97.5 and "
                            "2.5 percentiles >",
                      help="Raise alarm if the ratio between the 97.5 and "
                           "2.5 percentiles is greater than given value")
        form.addParam('ratio2Value', params.FloatParam, default=4.5,
                      label="Raise Alarm if the ratio between the maximum "
                            "gain value and the 97.5 percentile >",
                      help="Raise alarm if the ratio between the maximum "
                           "gain value and the 97.5 percentile is greater "
                           "than given value")

        form.addParam('monitorTime', params.FloatParam, default=300,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        form.addParam('samplingInterval', params.IntParam, default=60,
                      label="Sampling Interval (sec)",
                      pointerClass='EMProtocol',
                      help="Take one sample each SamplinInteval seconds")
        ProtMonitor._sendMailParams(self, form)
    def _defineParams(self, form):
        ProtMonitor._defineParams(self, form)
        form.addParam('cpuAlert', params.FloatParam, default=101,
                      label="Raise Alarm if CPU > XX%",
                      help="Raise alarm if memory allocated is greater "
                           "than given percentage")
        form.addParam('memAlert', params.FloatParam, default=101,
                      label="Raise Alarm if Memory > XX%",
                      help="Raise alarm if cpu allocated is greater "
                           "than given percentage")
        form.addParam('swapAlert', params.FloatParam, default=101,
                      label="Raise Alarm if Swap > XX%",
                      help="Raise alarm if swap allocated is greater "
                           "than given percentage")

        form.addParam('monitorTime', params.FloatParam, default=300,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        ProtMonitor._sendMailParams(self, form)
        group = form.addGroup('GPU')
        group.addParam('doGpu', params.BooleanParam, default=False,
                       label="Check GPU",
                       help="Set to true if you want to monitor the GPU")
        group.addParam('gpusToUse', params.StringParam, default='0',
                       label='Which GPUs to use:', condition='doGpu',
                       help='Providing a list of which GPUs '
                            '(0,1,2,3, etc). Default is monitor GPU 0 only')

        group = form.addGroup('GPU')
        group.addParam('doGpu', params.BooleanParam, default=False,
                       label="Check GPU",
                       help="Set to true if you want to monitor the GPU")
        group.addParam('gpusToUse', params.StringParam, default='0',
                       label='Which GPUs to use:', condition='doGpu',
                       help='Providing a list of which GPUs '
                            '(0,1,2,3, etc). Default is monitor GPU 0 only')

        group = form.addGroup('NETWORK')
        group.addParam('doNetwork', params.BooleanParam, default=False,
                       label="Check Network",
                       help="Set to true if you want to monitor the Network")
        group.addParam('netInterfaces', params.EnumParam,
                       choices=self.nifsNameList,
                       default=1,  # usually 0 is the loopback
                       label="Interface", condition='doNetwork',
                       help="Name of the network interface to be checked")

        group = form.addGroup('Disk')
        group.addParam('doDiskIO', params.BooleanParam, default=False,
                       label="Check Disk IO",
                       help="Set to true if you want to monitor the Disk "
                            "Access")
    def _defineParams(self, form):
        # ProtMonitor._defineParams(self, form)
        form.addSection(label='Input')

        form.addParam('inputProtocol',
                      params.PointerParam,
                      label="Input protocol",
                      important=True,
                      pointerClass='XmippProtMovieGain',
                      help="This protocol will be monitorized")

        form.addParam('stddevValue',
                      params.FloatParam,
                      default=0.04,
                      label="Raise Alarm if residual gain standard "
                      "deviation >",
                      help="Raise alarm if residual gain standard deviation "
                      "is greater than given value")
        form.addParam('ratio1Value',
                      params.FloatParam,
                      default=1.15,
                      label="Raise Alarm if the ratio between the 97.5 and "
                      "2.5 percentiles >",
                      help="Raise alarm if the ratio between the 97.5 and "
                      "2.5 percentiles is greater than given value")
        form.addParam('ratio2Value',
                      params.FloatParam,
                      default=4.5,
                      label="Raise Alarm if the ratio between the maximum "
                      "gain value and the 97.5 percentile >",
                      help="Raise alarm if the ratio between the maximum "
                      "gain value and the 97.5 percentile is greater "
                      "than given value")

        form.addParam('monitorTime',
                      params.FloatParam,
                      default=300,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        form.addParam('samplingInterval',
                      params.IntParam,
                      default=60,
                      label="Sampling Interval (sec)",
                      pointerClass='EMProtocol',
                      help="Take one sample each SamplinInteval seconds")
        ProtMonitor._sendMailParams(self, form)
    def _defineParams(self, form):
        #ProtMonitor._defineParams(self, form)
        form.addSection(label='Input')

        form.addParam('inputProtocol',
                      params.PointerParam,
                      label="Input protocols",
                      important=True,
                      pointerClass='ProtCTFFind, XmippProtCTFMicrographs',
                      help="this protocol will be monitorized")
        form.addParam('samplingInterval',
                      params.IntParam,
                      default=60,
                      label="Sampling Interval (sec)",
                      pointerClass='EMProtocol',
                      help="Take one sample each SamplinInteval seconds")

        form.addParam(
            'maxDefocus',
            params.FloatParam,
            default=40000,
            label="Raise Alarm if maximum defocus (A) >",
            help="Raise alarm if defocus is greater than given value")
        form.addParam(
            'minDefocus',
            params.FloatParam,
            default=1000,
            label="Raise Alarm if minimum defocus (A) <",
            help="Raise alarm if defocus is smaller than given value")
        form.addParam(
            'astigmatism',
            params.FloatParam,
            default=2000,
            label="Raise Alarm if astigmatism (A) >",
            help="Raise alarm if astigmatism is greater than given value")

        form.addParam('monitorTime',
                      params.FloatParam,
                      default=300,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        ProtMonitor._sendMailParams(self, form)
Exemple #7
0
    def _defineParams(self, form):    
        ProtMonitor._defineParams(self, form)
        form.addParam('cpuAlert', params.FloatParam,default=101,
              label="Raise Alarm if CPU > XX%",
              help="Raise alarm if memory allocated is greater "
                   "than given percentage")
        form.addParam('memAlert', params.FloatParam,default=101,
              label="Raise Alarm if Memory > XX%",
              help="Raise alarm if cpu allocated is greater "
                   "than given percentage")
        form.addParam('swapAlert', params.FloatParam,default=101,
              label="Raise Alarm if Swap > XX%",
              help="Raise alarm if swap allocated is greater "
                   "than given percentage")

        form.addParam('monitorTime', params.FloatParam,default=300,
              label="Total Logging time (min)",
              help="Log during this interval")

        ProtMonitor._sendMailParams(self, form)
 def __init__(self, **kwargs):
     ProtMonitor.__init__(self, **kwargs)
     self._runIds = pwobj.CsvList(pType=int)
Exemple #9
0
    def _defineParams(self, form):
        ProtMonitor._defineParams(self, form)

        form.addSection('MovieGain Monitor')
        form.addParam('stddevValue', params.FloatParam, default=0.04,
                      label="Raise Alarm if residual gain standard "
                            "deviation >",
                      help="Raise alarm if residual gain standard deviation "
                           "is greater than given value")
        form.addParam('ratio1Value', params.FloatParam, default=1.15,
                      label="Raise Alarm if the ratio between the 97.5 "
                            "and 2.5 percentiles >",
                      help="Raise alarm if the ratio between the 97.5 "
                           "and 2.5 percentiles is greater than given value")
        form.addParam('ratio2Value', params.FloatParam, default=4.5,
                      label="Raise Alarm if the ratio between the maximum "
                            "gain value and the 97.5 percentile >",
                      help="Raise alarm if the ratio between the maximum "
                           "gain value and the 97.5 percentile is greater "
                           "than given value")

        form.addSection('CTF Monitor')
        form.addParam('maxDefocus', params.FloatParam, default=40000,
                      label="Raise Alarm if maximum defocus (A) >",
                      help="Raise alarm if defocus is greater than given "
                           "value")
        form.addParam('minDefocus', params.FloatParam, default=1000,
                      label="Raise Alarm if minimum defocus (A) <",
                      help="Raise alarm if defocus is smaller than given "
                           "value")
        form.addParam('astigmatism', params.FloatParam, default=1000,
                      label="Raise Alarm if astigmatism >",
                      help="Raise alarm if astigmatism (defocusU-defocusV)is greater than given "
                           "value")

        form.addParam('monitorTime', params.FloatParam, default=30000,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        form.addSection('System Monitor')
        form.addParam('cpuAlert', params.FloatParam, default=101,
                      label="Raise Alarm if CPU > XX%",
                      help="Raise alarm if memory allocated is greater "
                           "than given percentage")

        form.addParam('memAlert', params.FloatParam, default=101,
                      label="Raise Alarm if Memory > XX%",
                      help="Raise alarm if cpu allocated is greater "
                           "than given percentage")
        form.addParam('swapAlert', params.FloatParam, default=101,
                      label="Raise Alarm if Swap > XX%",
                      help="Raise alarm if swap allocated is greater "
                           "than given percentage")

        group = form.addGroup('GPU')
        group.addParam('doGpu', params.BooleanParam, default=False,
                       label="Check GPU",
                       help="Set to true if you want to monitor the GPU")
        group.addParam('gpusToUse', params.StringParam, default='0',
                       label='Which GPUs to use:', condition='doGpu',
                       help='Provide a list of GPUs '
                            '(e.g. "0 1 2 3"). Default is to monitor GPU 0 only')
        group = form.addGroup('NETWORK')
        group.addParam('doNetwork', params.BooleanParam, default=False,
                       label="Check Network",
                       help="Set to true if you want to monitor the Network")
        group.addParam('netInterfaces', params.EnumParam,
                       choices=self.nifsNameList,
                       default=1,  # usually 0 is the loopback
                       label="Interface", condition='doNetwork',
                       help="Name of the network interface to be checked")

        group = form.addGroup('Disk')
        group.addParam('doDiskIO', params.BooleanParam, default=False,
                       label="Check Disk IO",
                       help="Set to true if you want to monitor the Disk "
                            "Acces")

        form.addSection('Mail settings')
        ProtMonitor._sendMailParams(self, form)

        form.addSection('HTML Report')
        form.addParam('publishCmd', params.StringParam, default='',
                      label="Publish command",
                      help="Specify a command to publish the template. "
                           "You can use the special token %(REPORT_FOLDER)s "
                           "that will be replaced with the report folder. "
                           "For example: \n"
                           "rsync -avL %(REPORT_FOLDER)s "
                           "scipion@webserver:public_html/")
Exemple #10
0
 def __init__(self, **kwargs):
     ProtMonitor.__init__(self, **kwargs)
     self.reportDir = ''
     self.reportPath = ''
    def _defineParams(self, form):
        ProtMonitor._defineParams(self, form)
        form.addParam('cpuAlert',
                      params.FloatParam,
                      default=101,
                      label="Raise Alarm if CPU > XX%",
                      help="Raise alarm if memory allocated is greater "
                      "than given percentage")
        form.addParam('memAlert',
                      params.FloatParam,
                      default=101,
                      label="Raise Alarm if Memory > XX%",
                      help="Raise alarm if cpu allocated is greater "
                      "than given percentage")
        form.addParam('swapAlert',
                      params.FloatParam,
                      default=101,
                      label="Raise Alarm if Swap > XX%",
                      help="Raise alarm if swap allocated is greater "
                      "than given percentage")

        form.addParam('monitorTime',
                      params.FloatParam,
                      default=300,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        ProtMonitor._sendMailParams(self, form)
        group = form.addGroup('GPU')
        group.addParam('doGpu',
                       params.BooleanParam,
                       default=False,
                       label="Check GPU",
                       help="Set to true if you want to monitor the GPU")
        group.addParam('gpusToUse',
                       params.StringParam,
                       default='0',
                       label='Which GPUs to use:',
                       condition='doGpu',
                       help='Providing a list of which GPUs '
                       '(0,1,2,3, etc). Default is monitor GPU 0 only')

        group = form.addGroup('GPU')
        group.addParam('doGpu',
                       params.BooleanParam,
                       default=False,
                       label="Check GPU",
                       help="Set to true if you want to monitor the GPU")
        group.addParam('gpusToUse',
                       params.StringParam,
                       default='0',
                       label='Which GPUs to use:',
                       condition='doGpu',
                       help='Providing a list of which GPUs '
                       '(0,1,2,3, etc). Default is monitor GPU 0 only')

        group = form.addGroup('NETWORK')
        group.addParam('doNetwork',
                       params.BooleanParam,
                       default=False,
                       label="Check Network",
                       help="Set to true if you want to monitor the Network")
        group.addParam(
            'netInterfaces',
            params.EnumParam,
            choices=self.nifsNameList,
            default=1,  # usually 0 is the loopback
            label="Interface",
            condition='doNetwork',
            help="Name of the network interface to be checked")

        group = form.addGroup('Disk')
        group.addParam('doDiskIO',
                       params.BooleanParam,
                       default=False,
                       label="Check Disk IO",
                       help="Set to true if you want to monitor the Disk "
                       "Access")
 def __init__(self, **kwargs):
     ProtMonitor.__init__(self, **kwargs)
     self.dataBase = 'log.sqlite'
     self.tableName = 'log'
 def __init__(self, **kwargs):
     ProtMonitor.__init__(self, **kwargs)
     self.dataBase = 'log.sqlite'
     self.tableName = 'log'
    def _defineParams(self, form):
        ProtMonitor._defineParams(self, form)

        form.addSection('CTF Monitor')
        form.addParam(
            'maxDefocus',
            params.FloatParam,
            default=40000,
            label="Raise Alarm if maximum defocus (A) >",
            help="Raise alarm if defocus is greater than given value")
        form.addParam(
            'minDefocus',
            params.FloatParam,
            default=1000,
            label="Raise Alarm if minimum defocus (A) <",
            help="Raise alarm if defocus is smaller than given value")
        form.addParam(
            'astigmatism',
            params.FloatParam,
            default=0.2,
            label="Raise Alarm if astigmatism >",
            help="Raise alarm if astigmatism is greater than given value")

        form.addParam('monitorTime',
                      params.FloatParam,
                      default=30000,
                      label="Total Logging time (min)",
                      help="Log during this interval")

        form.addSection('System Monitor')
        form.addParam('cpuAlert',
                      params.FloatParam,
                      default=101,
                      label="Raise Alarm if CPU > XX%",
                      help="Raise alarm if memory allocated is greater "
                      "than given percentage")

        form.addParam('memAlert',
                      params.FloatParam,
                      default=101,
                      label="Raise Alarm if Memory > XX%",
                      help="Raise alarm if cpu allocated is greater "
                      "than given percentage")
        form.addParam('swapAlert',
                      params.FloatParam,
                      default=101,
                      label="Raise Alarm if Swap > XX%",
                      help="Raise alarm if swap allocated is greater "
                      "than given percentage")

        form.addSection('Mail settings')
        ProtMonitor._sendMailParams(self, form)

        form.addSection('HTML Report')
        form.addParam(
            'publishCmd',
            params.StringParam,
            default='',
            label="Publish command",
            help="Specify a command to publish the template. "
            "You can use the special token %(REPORT_FOLDER)s "
            "that will be replaced with the report folder. "
            "For example: \n"
            "rsync -av %(REPORT_FOLDER)s scipion@webserver:public_html/")
 def __init__(self, **kwargs):
     ProtMonitor.__init__(self, **kwargs)
     self._runIds = pwobj.CsvList(pType=int)
 def _defineParams(self, form):
     ProtMonitor._defineParams(self, form)