Beispiel #1
0
    def __init__(self,
                 workflow,
                 title,
                 is_batch=False,
                 default_export_filename=''):
        self.export_op = None
        self._default_export_filename = default_export_filename

        self.__topLevelOperator = OpMultiLaneWrapper(
            OpTrackingBaseDataExport,
            parent=workflow,
            promotedSlotNames=set(['RawData', 'Inputs', 'RawDatasetInfo']))

        extra_serial_slots = [
            SerialSlot(self.topLevelOperator.SelectedPlugin),
            SerialSlot(self.topLevelOperator.SelectedExportSource),
            SerialDictSlot(self.topLevelOperator.AdditionalPluginArguments)
        ]
        self._serializers = [
            DataExportSerializer(self.topLevelOperator, title,
                                 extra_serial_slots)
        ]

        super(TrackingBaseDataExportApplet, self).__init__(workflow,
                                                           title,
                                                           isBatch=is_batch)
    def __init__(
        self,
        workflow,
        title,
        is_batch: bool = False,
        default_export_filename: str = "",
        pluginExportFunc: Optional[PluginExportCallable] = None,
    ):
        self.export_op = None
        self._default_export_filename = default_export_filename

        self.__topLevelOperator = OpMultiLaneWrapper(
            OpTrackingBaseDataExport,
            parent=workflow,
            promotedSlotNames=set(["RawData", "Inputs", "RawDatasetInfo"]))

        extra_serial_slots = [
            SerialSlot(self.topLevelOperator.SelectedPlugin),
            SerialSlot(self.topLevelOperator.SelectedExportSource),
            SerialDictSlot(self.topLevelOperator.AdditionalPluginArguments),
        ]
        self._serializers = [
            DataExportSerializer(self.topLevelOperator, title,
                                 extra_serial_slots)
        ]
        self._pluginExportFunc = pluginExportFunc

        super(TrackingBaseDataExportApplet, self).__init__(workflow,
                                                           title,
                                                           isBatch=is_batch)
 def __init__(self, operator, projectFileGroupName):
     slots = [
         SerialSlot(operator.Beta, selfdepends=True),
         SerialSlot(operator.SolverName, selfdepends=True)
     ]
     super(MulticutSerializer, self).__init__(projectFileGroupName,
                                              slots=slots)
    def __init__(self, operator, projectFileGroupName):
        slots = [
            SerialSlot(operator.MinValue, selfdepends=True),
            SerialSlot(operator.MaxValue, selfdepends=True)
        ]

        super(ThresholdMaskingSerializer, self).__init__(projectFileGroupName,
                                                         slots=slots)
Beispiel #5
0
    def __init__(self, operator, projectFileGroupName):
        slots = [
            SerialSlot(operator.ScalingFactor, selfdepends=True),
            SerialSlot(operator.Offset, selfdepends=True)
        ]

        super(DeviationFromMeanSerializer, self).__init__(projectFileGroupName,
                                                          slots=slots)
Beispiel #6
0
 def __init__(self, operator, groupName):
     self.TestSerialSlot = SerialSlot(operator.TestSlot)
     self.TestMultiSerialSlot = SerialSlot(operator.TestMultiSlot)
     self.TestSerialListSlot = SerialListSlot(operator.TestListSlot,
                                              selfdepends=True)
     slots = (self.TestSerialSlot, self.TestMultiSerialSlot,
              self.TestSerialListSlot)
     super(OpMockSerializer, self).__init__(groupName, slots)
 def __init__(self, topGroupName, topLevelOperator):
     slots = [
         SerialSlot(topLevelOperator.PatchSize),
         SerialSlot(topLevelOperator.HaloSize)
     ]
     super(FillMissingSlicesSerializer, self).__init__(topGroupName,
                                                       slots=slots)
     self._operator = topLevelOperator
 def __init__(self, operator, projectFileGroupName):
     slots = [SerialListSlot(operator.InputChannelIndexes, selfdepends=True),
              SerialSlot(operator.WatershedPadding, selfdepends=True),
              SerialSlot(operator.CacheBlockShape, selfdepends=True),
              SerialSlot(operator.SeedThresholdValue, selfdepends=True),
              SerialSlot(operator.MinSeedSize, selfdepends=True) ]
     
     super(VigraWatershedViewerSerializer, self).__init__(projectFileGroupName,
                                                          slots=slots)
Beispiel #9
0
    def __init__(self, operator, projectFileGroupName):
        self.topLevelOperator = operator
        slots = [
            SerialSlot(operator.ExportDirectory, default=''),
            SerialSlot(operator.Format, default=ExportFormat.H5),
            SerialSlot(operator.Suffix, default='_results'),
            SerialDatasetPath(operator.DatasetPath,
                              operator.Dirty,
                              name='datasetInfos',
                              subname='dataset{:>04}',),
        ]

        super(BatchIoSerializer, self).__init__(projectFileGroupName,
                                                slots=slots)
    def __init__(self, operator, projectFileGroupName, extraSerialSlots=[]):
        self.topLevelOperator = operator
        SerialRoiSlot = partial(SerialListSlot,
                                store_transform=lambda x: -1
                                if x is None else x,
                                transform=lambda x: None if x == -1 else x,
                                iterable=tuple)
        slots = [
            SerialRoiSlot(operator.RegionStart),
            SerialRoiSlot(operator.RegionStop),
            SerialSlot(operator.InputMin),
            SerialSlot(operator.InputMax),
            SerialSlot(operator.ExportMin),
            SerialSlot(operator.ExportMax),
            SerialDtypeSlot(operator.ExportDtype),
            SerialSlot(operator.OutputAxisOrder),
            SerialSlot(operator.OutputFilenameFormat),
            SerialSlot(operator.OutputInternalPath),
            SerialSlot(operator.OutputFormat),
        ]

        slots += extraSerialSlots

        super(DataExportSerializer, self).__init__(projectFileGroupName,
                                                   slots=slots)
Beispiel #11
0
    def __init__(self, operator, projectFileGroupName):
        self.predictionSlot = SerialPredictionSlot(
            operator.PredictionProbabilities,
            operator,
            name='Predictions',
            subname='predictions{:04d}',
        )

        slots = [
            SerialListSlot(
                operator.LabelNames,
            ),
            SerialListSlot(
                operator.LabelColors,
                transform=lambda x: tuple(x.flat),
            ),
            SerialListSlot(
                operator.PmapColors,
                transform=lambda x: tuple(x.flat),
            ),
            SerialBlockSlot(
                operator.LabelImages,
                operator.LabelInputs,
                operator.NonzeroLabelBlocks,
                name='LabelSets',
                subname='labels{:0}',
                selfdepends=False,
            ),
            self.predictionSlot,
            SerialBoxSlot(
                operator.opTrain.BoxConstraintRois,
                operator.opTrain,
                name='Rois',
                subname='rois{:04d}',
            ),
            SerialBoxSlot(
                operator.opTrain.BoxConstraintValues,
                operator.opTrain,
                name='Values',
                subname='values{:04d}',
            ),
            SerialSlot(
                operator.opTrain.Sigma,
                name='Sigma',
            ),
            SerialBoxSlot(
                operator.boxViewer.rois,
                operator.boxViewer,
                name='ViewRois',
                subname='viewrois{:04d}',
            ),
            SerialCountingSlot(
                operator.Classifier,
                operator.classifier_cache,
                name='CountingWrappers',
            ),
        ]

        super(CountingSerializer, self).__init__(projectFileGroupName, slots=slots)
        self.predictionSlot.progressSignal.subscribe(self.progressSignal)
Beispiel #12
0
 def __init__(self, operator, projectFileGroupName):
     slots = [
         SerialListSlot(operator.ChannelSelections),
         SerialSlot(operator.Threshold),
         SerialSlot(operator.MinSize),
         SerialSlot(operator.Sigma),
         SerialSlot(operator.Alpha),
         SerialSlot(operator.PixelPitch),
         SerialBlockSlot(
             operator.Superpixels,
             operator.SuperpixelCacheInput,
             operator.CleanBlocks,
             name="Superpixels",
             subname="superpixels{:03d}",
             selfdepends=False,
             shrink_to_bb=False,
             compression_level=1,
         ),
     ]
     super(WsdtSerializer, self).__init__(projectFileGroupName, slots=slots, operator=operator)
Beispiel #13
0
    def __init__(self, topLevelOperator, projectFileGroupName):
        slots = [
            SerialDictSlot(topLevelOperator.Parameters, selfdepends=True),
            SerialHdf5BlockSlot(topLevelOperator.OutputHdf5,
                                topLevelOperator.InputHdf5,
                                topLevelOperator.CleanBlocks,
                                name="CachedOutput"),
            SerialDictSlot(topLevelOperator.EventsVector,
                           transform=str,
                           selfdepends=True),
            SerialDictSlot(topLevelOperator.FilteredLabels,
                           transform=str,
                           selfdepends=True),
            SerialSlot(topLevelOperator.DivisionWeight),
            SerialSlot(topLevelOperator.DetectionWeight),
            SerialSlot(topLevelOperator.TransitionWeight),
            SerialSlot(topLevelOperator.AppearanceWeight),
            SerialSlot(topLevelOperator.DisappearanceWeight),
            SerialSlot(topLevelOperator.MaxNumObjOut)
        ]

        if 'MergerOutput' in topLevelOperator.outputs:
            slots.append(
                SerialHdf5BlockSlot(topLevelOperator.MergerOutputHdf5,
                                    topLevelOperator.MergerInputHdf5,
                                    topLevelOperator.MergerCleanBlocks,
                                    name="MergerCachedOutput"), )

        if 'CoordinateMap' in topLevelOperator.outputs:
            slots.append(
                SerialPickleableSlot(topLevelOperator.CoordinateMap, 1,
                                     pgmlink.TimestepIdCoordinateMap()))

        super(StructuredTrackingSerializer,
              self).__init__(projectFileGroupName, slots=slots)
Beispiel #14
0
    def __init__(self, operator, projectFileGroupName):
        slots = [
            SerialDictSlot(operator.Crops),
            SerialSlot(operator.MinValueT, selfdepends=True),
            SerialSlot(operator.MaxValueT, selfdepends=True),
            SerialSlot(operator.MinValueX, selfdepends=True),
            SerialSlot(operator.MaxValueX, selfdepends=True),
            SerialSlot(operator.MinValueY, selfdepends=True),
            SerialSlot(operator.MaxValueY, selfdepends=True),
            SerialSlot(operator.MinValueZ, selfdepends=True),
            SerialSlot(operator.MaxValueZ, selfdepends=True),
        ]

        super(CropSelectionSerializer, self).__init__(projectFileGroupName,
                                                      slots=slots)
Beispiel #15
0
 def __init__(self, operator, projectFileGroupName):
     slots = [
         SerialDictSlot(operator.FeatureNames),
         SerialEdgeLabelsDictSlot(operator.EdgeLabelsDict),
         SerialRagSlot(operator.Rag, operator.opRagCache,
                       operator.Superpixels),
         SerialCachedDataFrameSlot(operator.opEdgeFeaturesCache.Output,
                                   operator.opEdgeFeaturesCache,
                                   name="EdgeFeatures"),
         SerialClassifierSlot(operator.opClassifierCache.Output,
                              operator.opClassifierCache),
         SerialSlot(operator.TrainRandomForest),
     ]
     super().__init__(projectFileGroupName, slots=slots)
    def __init__(self, topLevelOperator, projectFileGroupName):
        slots = [
            SerialSlot(topLevelOperator.PatchWidth, selfdepends=True),
            SerialSlot(topLevelOperator.PatchHeight, selfdepends=True),
            SerialSlot(topLevelOperator.PatchOverlapVertical,
                       selfdepends=True),
            SerialSlot(topLevelOperator.PatchOverlapHorizontal,
                       selfdepends=True),
            SerialSlot(topLevelOperator.GridStartVertical, selfdepends=True),
            SerialSlot(topLevelOperator.GridStartHorizontal, selfdepends=True),
            SerialSlot(topLevelOperator.GridWidth, selfdepends=True),
            SerialSlot(topLevelOperator.GridHeight, selfdepends=True)
        ]

        super(PatchCreatorSerializer, self).__init__(projectFileGroupName,
                                                     slots=slots)
        self.topLevelOperator = topLevelOperator
    def __init__(self, operator, projectFileGroupName):
        slots = [
            SerialSlot(operator.CurOperator, selfdepends=True),
            SerialSlot(operator.MinSize, selfdepends=True),
            SerialSlot(operator.MaxSize, selfdepends=True),
            SerialSlot(operator.HighThreshold, selfdepends=True),
            SerialSlot(operator.LowThreshold, selfdepends=True),
            SerialSlot(operator.SingleThreshold, selfdepends=True),
            SerialDictSlot(operator.SmootherSigma, selfdepends=True),
            SerialSlot(operator.Channel, selfdepends=True),
            SerialHdf5BlockSlot(operator.OutputHdf5,
                                operator.InputHdf5,
                                operator.CleanBlocks,
                                name="CachedThresholdOutput")
        ]

        super(self.__class__, self).__init__(projectFileGroupName, slots=slots)
Beispiel #18
0
    def __init__(self, workflow, title, opCounting, isBatch=False):
        # Our operator is a subclass of the generic data export operator
        self._topLevelOperator = OpMultiLaneWrapper(
            OpCountingDataExport,
            parent=workflow,
            promotedSlotNames=set(['RawData', 'Inputs', 'RawDatasetInfo']))
        self._gui = None
        self._title = title
        self._serializers = [
            DataExportSerializer(
                self._topLevelOperator, title,
                [SerialSlot(self._topLevelOperator.CsvFilepath)])
        ]

        self.opCounting = opCounting

        # Base class init
        super(CountingDataExportApplet, self).__init__(workflow, title,
                                                       isBatch)
Beispiel #19
0
 def __init__(self, operator, projectFileGroupName):
     slots = [
         SerialSlot(operator.ChannelSelection),
         SerialSlot(operator.Pmin),
         SerialSlot(operator.MinMembraneSize),
         SerialSlot(operator.MinSegmentSize),
         SerialSlot(operator.SigmaMinima),
         SerialSlot(operator.SigmaWeights),
         SerialSlot(operator.GroupSeeds),
         SerialSlot(operator.PreserveMembranePmaps),
         SerialBlockSlot(operator.Superpixels,
                         operator.SuperpixelCacheInput,
                         operator.CleanBlocks,
                         name='Superpixels',
                         subname='superpixels{:03d}',
                         selfdepends=False,
                         shrink_to_bb=False,
                         compression_level=1)
     ]
     super(WsdtSerializer, self).__init__(projectFileGroupName,
                                          slots=slots,
                                          operator=operator)
Beispiel #20
0
    def __init__(self, topGroupName, operator):
        serialSlots = [
            SerialDictSlot(operator.SelectedFeatures, transform=str),
            SerialListSlot(operator.LabelNames, transform=str),
            SerialListSlot(operator.LabelColors,
                           transform=lambda x: tuple(x.flat)),
            SerialListSlot(operator.PmapColors,
                           transform=lambda x: tuple(x.flat)),
            SerialDictSlot(operator.LabelInputs, transform=int),
            SerialClassifierSlot(operator.Classifier,
                                 operator.classifier_cache,
                                 name="ClassifierForests"),
            SerialDictSlot(operator.CachedProbabilities,
                           operator.InputProbabilities,
                           transform=int),
            SerialSlot(operator.MaxNumObj),
            SerialPickledValueSlot(operator.ExportSettings)
        ]

        super(ObjectClassificationSerializer, self).__init__(topGroupName,
                                                             slots=serialSlots,
                                                             operator=operator)
    def __init__(self, topGroupName, operator):
        self.VERSION = 1  # Make sure to bump the version in case you make any changes in the serialization
        serialSlots = [
            SerialDictSlot(operator.SelectedFeatures),
            SerialListSlot(operator.LabelNames),
            SerialListSlot(operator.LabelColors,
                           transform=lambda x: tuple(x.flat)),
            SerialListSlot(operator.PmapColors,
                           transform=lambda x: tuple(x.flat)),
            SerialDictSlot(operator.LabelInputs, transform=int),
            SerialClassifierSlot(operator.Classifier,
                                 operator.classifier_cache,
                                 name="ClassifierForests"),
            SerialDictSlot(operator.CachedProbabilities,
                           operator.InputProbabilities,
                           transform=int),
            SerialSlot(operator.MaxNumObj),
            SerialPickleableSlot(operator.ExportSettings, self.VERSION, None)
        ]

        super(ObjectClassificationSerializer, self).__init__(topGroupName,
                                                             slots=serialSlots,
                                                             operator=operator)
    def __init__(self, operator, projectFileGroupName):
        slots = [
            SerialSlot(operator.CurOperator, selfdepends=True),
            SerialSlot(operator.MinSize, selfdepends=True),
            SerialSlot(operator.MaxSize, selfdepends=True),
            SerialSlot(operator.HighThreshold, selfdepends=True),
            SerialSlot(operator.LowThreshold, selfdepends=True),
            SerialDictSlot(operator.SmootherSigma, selfdepends=True),
            SerialSlot(operator.Channel, selfdepends=True),
            SerialSlot(operator.CoreChannel, selfdepends=True),
            SerialBlockSlot(operator.CachedOutput,
                            operator.CacheInput,
                            operator.CleanBlocks,
                            name='CachedThresholdLabels',
                            subname='threshold{:03d}',
                            selfdepends=False,
                            shrink_to_bb=False,
                            compression_level=1)
        ]

        super(self.__class__, self).__init__(projectFileGroupName, slots,
                                             operator)
Beispiel #23
0
 def __init__(self, operator, projectFileGroupName):
     super(NanshePostprocessingSerializer, self).__init__(projectFileGroupName,
                                                         slots=[SerialSlot(operator.SignificanceThreshold, selfdepends=True),
                                                                SerialListSlot(operator.WaveletTransformScale, selfdepends=True),
                                                                SerialSlot(operator.NoiseThreshold, selfdepends=True),
                                                                SerialSlot(operator.AcceptedRegionShapeConstraints_MajorAxisLength_Min, selfdepends=True),
                                                                SerialSlot(operator.AcceptedRegionShapeConstraints_MajorAxisLength_Min_Enabled, selfdepends=True),
                                                                SerialSlot(operator.AcceptedRegionShapeConstraints_MajorAxisLength_Max, selfdepends=True),
                                                                SerialSlot(operator.AcceptedRegionShapeConstraints_MajorAxisLength_Max_Enabled, selfdepends=True),
                                                                SerialSlot(operator.MinLocalMaxDistance, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Area_Min, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Area_Min_Enabled, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Area_Max, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Area_Max_Enabled, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Eccentricity_Min, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Eccentricity_Min_Enabled, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Eccentricity_Max, selfdepends=True),
                                                                SerialSlot(operator.AcceptedNeuronShapeConstraints_Eccentricity_Max_Enabled, selfdepends=True),
                                                                SerialSlot(operator.AlignmentMinThreshold, selfdepends=True),
                                                                SerialSlot(operator.OverlapMinThreshold, selfdepends=True),
                                                                SerialSlot(operator.Fuse_FractionMeanNeuronMaxThreshold, selfdepends=True),
                                                                SerialBlockSlot(operator.Output,
                                                                                operator.CacheInput,
                                                                                operator.CleanBlocks, selfdepends=True)])
    def __init__(self, topLevelOperator, projectFileGroupName):
        self.VERSION = 1  # Make sure to bump the version in case you make any changes in the serialization
        try:
            slots = [
                SerialDictSlot(topLevelOperator.Parameters, selfdepends=True),
                SerialDictSlot(topLevelOperator.FilteredLabels,
                               transform=str,
                               selfdepends=True),
                SerialPickleableSlot(topLevelOperator.ExportSettings,
                                     version=self.VERSION),
                SerialPickleableSlot(topLevelOperator.HypothesesGraph,
                                     version=self.VERSION),
                SerialPickleableSlot(topLevelOperator.LearningHypothesesGraph,
                                     version=self.VERSION),
                SerialPickleableSlot(topLevelOperator.ResolvedMergers,
                                     version=self.VERSION),
                SerialSlot(topLevelOperator.DivisionWeight),
                SerialSlot(topLevelOperator.DetectionWeight),
                SerialSlot(topLevelOperator.TransitionWeight),
                SerialSlot(topLevelOperator.AppearanceWeight),
                SerialSlot(topLevelOperator.DisappearanceWeight),
                SerialSlot(topLevelOperator.MaxNumObjOut),
            ]
        except:
            slots = [
                SerialDictSlot(topLevelOperator.Parameters, selfdepends=True),
                SerialDictSlot(topLevelOperator.FilteredLabels,
                               transform=str,
                               selfdepends=True),
                SerialPickleableSlot(topLevelOperator.ExportSettings,
                                     version=self.VERSION),
                SerialPickleableSlot(topLevelOperator.ResolvedMergers,
                                     version=self.VERSION),
                SerialSlot(topLevelOperator.DivisionWeight),
                SerialSlot(topLevelOperator.DetectionWeight),
                SerialSlot(topLevelOperator.TransitionWeight),
                SerialSlot(topLevelOperator.AppearanceWeight),
                SerialSlot(topLevelOperator.DisappearanceWeight),
                SerialSlot(topLevelOperator.MaxNumObjOut),
            ]

        super(StructuredTrackingSerializer,
              self).__init__(projectFileGroupName,
                             slots=slots,
                             operator=topLevelOperator)
 def __init__(self, projectFileGroupName, operator):
     super().__init__(projectFileGroupName, [SerialSlot(operator.ServerId)])
Beispiel #26
0
    def __init__(self, topLevelOperator, projectFileGroupName):

        if WITH_HYTRA:
            slots = [ SerialDictSlot(topLevelOperator.Parameters, selfdepends=True),
                      SerialDictSlot(topLevelOperator.EventsVector, transform=str, selfdepends=True),
                      SerialDictSlot(topLevelOperator.FilteredLabels, transform=str, selfdepends=True),
                      SerialPickledValueSlot(topLevelOperator.ExportSettings),
                      SerialPickledValueSlot(topLevelOperator.HypothesesGraph),
                      SerialPickledValueSlot(topLevelOperator.ResolvedMergers),
                      SerialSlot(topLevelOperator.DivisionWeight),
                      SerialSlot(topLevelOperator.DetectionWeight),
                      SerialSlot(topLevelOperator.TransitionWeight),
                      SerialSlot(topLevelOperator.AppearanceWeight),
                      SerialSlot(topLevelOperator.DisappearanceWeight),
                      SerialSlot(topLevelOperator.MaxNumObjOut)
            ]
        else:
            try:
                import pgmlink
            except:
                import pgmlinkNoIlpSolver as pgmlink

            slots = [ SerialDictSlot(topLevelOperator.Parameters, selfdepends=True),
                        SerialHdf5BlockSlot(topLevelOperator.OutputHdf5,
                                         topLevelOperator.InputHdf5,
                                         topLevelOperator.CleanBlocks,
                                         name="CachedOutput"),
                        SerialDictSlot(topLevelOperator.EventsVector, transform=str, selfdepends=True),
                        SerialDictSlot(topLevelOperator.FilteredLabels, transform=str, selfdepends=True),
                        SerialSlot(topLevelOperator.DivisionWeight),
                        SerialSlot(topLevelOperator.DetectionWeight),
                        SerialSlot(topLevelOperator.TransitionWeight),
                        SerialSlot(topLevelOperator.AppearanceWeight),
                        SerialSlot(topLevelOperator.DisappearanceWeight),
                        SerialSlot(topLevelOperator.MaxNumObjOut)
            ]

            if 'MergerOutput' in topLevelOperator.outputs:
                slots.append(SerialHdf5BlockSlot(topLevelOperator.MergerOutputHdf5,
                                         topLevelOperator.MergerInputHdf5,
                                         topLevelOperator.MergerCleanBlocks,
                                         name="MergerCachedOutput"),
                              )


            if 'CoordinateMap' in topLevelOperator.outputs:
                slots.append(SerialPickleableSlot(topLevelOperator.CoordinateMap, 1, pgmlink.TimestepIdCoordinateMap()))

        super(StructuredTrackingSerializer, self ).__init__(projectFileGroupName, slots=slots, operator=topLevelOperator)
Beispiel #27
0
 def __init__(self, operator: "OpCarving", groupName):
     super().__init__(groupName, slots=[SerialSlot(operator.ObjectPrefix)])
     self._o = operator
Beispiel #28
0
 def __init__(self, operator, projectFileGroupName):
     super(NansheDictionaryLearningSerializer,
           self).__init__(projectFileGroupName,
                          slots=[
                              SerialSlot(operator.Ord, selfdepends=True),
                              SerialSlot(operator.K, selfdepends=True),
                              SerialSlot(operator.Gamma1, selfdepends=True),
                              SerialSlot(operator.Gamma2, selfdepends=True),
                              SerialSlot(operator.NumThreads,
                                         selfdepends=True),
                              SerialSlot(operator.Batchsize,
                                         selfdepends=True),
                              SerialSlot(operator.NumIter,
                                         selfdepends=True),
                              SerialSlot(operator.Lambda1,
                                         selfdepends=True),
                              SerialSlot(operator.Lambda2,
                                         selfdepends=True),
                              SerialSlot(operator.PosAlpha,
                                         selfdepends=True),
                              SerialSlot(operator.PosD, selfdepends=True),
                              SerialSlot(operator.Clean, selfdepends=True),
                              SerialSlot(operator.Mode, selfdepends=True),
                              SerialSlot(operator.ModeD, selfdepends=True),
                              SerialBlockSlot(operator.Output,
                                              operator.CacheInput,
                                              operator.CleanBlocks,
                                              selfdepends=True)
                          ])
Beispiel #29
0
 def __init__(self, operator, projectFileGroupName):
     super(NanshePreprocessingSerializer, self).__init__(
         projectFileGroupName,
         slots=[
             SerialSlot(operator.ToRemoveZeroedLines, selfdepends=True),
             SerialListSlot(operator.ErosionShape, selfdepends=True),
             SerialListSlot(operator.DilationShape, selfdepends=True),
             SerialSlot(operator.ToExtractF0, selfdepends=True),
             SerialSlot(operator.HalfWindowSize, selfdepends=True),
             SerialSlot(operator.WhichQuantile, selfdepends=True),
             SerialSlot(operator.TemporalSmoothingGaussianFilterStdev,
                        selfdepends=True),
             SerialSlot(operator.SpatialSmoothingGaussianFilterStdev,
                        selfdepends=True),
             SerialSlot(operator.TemporalSmoothingGaussianFilterWindowSize,
                        selfdepends=True),
             SerialSlot(operator.SpatialSmoothingGaussianFilterWindowSize,
                        selfdepends=True),
             SerialSlot(operator.BiasEnabled, selfdepends=True),
             SerialSlot(operator.Bias, selfdepends=True),
             SerialSlot(operator.ToWaveletTransform, selfdepends=True),
             SerialListSlot(operator.Scale, selfdepends=True),
             SerialBlockSlot(operator.CacheOutput,
                             operator.CacheInput,
                             operator.CleanBlocks,
                             selfdepends=True)
         ])