test_data.py 文件源码

python
阅读 26 收藏 0 点赞 0 评论 0

项目:psyplot 作者: Chilipp 项目源码 文件源码
def test_from_dataset_04_exact_selection(self):
        """Test the from_dataset creation method with selected names"""
        variables, coords = self._from_dataset_test_variables
        ds = xr.Dataset(variables, coords)
        l = self.list_class.from_dataset(ds, ydim=2, method=None,
                                         name=['v0', 'v2'])
        self.assertEqual(len(l), 2)
        self.assertEqual(set(l.names), {'v0', 'v2'})
        for arr in l:
            self.assertEqual(arr.ydim, 2,
                             msg="Wrong ydim slice for " + arr.name)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号