807a1bd887a930ed442aa4847240091073d281ba,core/eolearn/tests/test_eodata.py,TestEOPatch,test_check_dims,#TestEOPatch#,53

Before Change


        with self.assertRaises(ValueError):
            eop.add_feature(attr_type=FeatureType.LABEL, field="label", value=bands_3d)
        with self.assertRaises(ValueError):
            eop.add_feature(attr_type=FeatureType.SCALAR, field="scalar", value=bands_3d)
        with self.assertRaises(ValueError):
            eop.add_feature(attr_type=FeatureType.LABEL_TIMELESS, field="label_timeless", value=bands_2d)
        with self.assertRaises(ValueError):

After Change



        eop = EOPatch()
        for feature_type in FeatureType:
            if feature_type.is_spatial() and not feature_type.is_vector():
                with self.assertRaises(ValueError):
                    eop[feature_type][feature_type.value] = bands_2d

    def test_concatenate(self):
        eop1 = EOPatch()
        bands1 = np.arange(2*3*3*2).reshape(2, 3, 3, 2)
        eop1.add_feature(FeatureType.DATA, "bands", bands1)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: sentinel-hub/eo-learn
Commit Name: 807a1bd887a930ed442aa4847240091073d281ba
Time: 2018-07-20
Author: matej.aleksandrov@sinergise.com
File Name: core/eolearn/tests/test_eodata.py
Class Name: TestEOPatch
Method Name: test_check_dims


Project Name: biotite-dev/biotite
Commit Name: 8bd52393b1026d2b2e29dc1e102126d48563f3c4
Time: 2017-12-10
Author: patrick.kunzm@gmail.com
File Name: src/biotite/sequence/annotation.py
Class Name: Annotation
Method Name: __getitem__


Project Name: biotite-dev/biotite
Commit Name: be45f0a180703fbc30d7a37477066e5f4cf39e41
Time: 2018-02-04
Author: patrick.kunzm@gmail.com
File Name: src/biotite/sequence/annotation.py
Class Name: Annotation
Method Name: __add__