当前位置: 首页>>代码示例>>Python>>正文


Python CubeList.merge方法代码示例

本文整理汇总了Python中iris.cube.CubeList.merge方法的典型用法代码示例。如果您正苦于以下问题:Python CubeList.merge方法的具体用法?Python CubeList.merge怎么用?Python CubeList.merge使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在iris.cube.CubeList的用法示例。


在下文中一共展示了CubeList.merge方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: test_combination_with_realization

# 需要导入模块: from iris.cube import CubeList [as 别名]
# 或者: from iris.cube.CubeList import merge [as 别名]
 def test_combination_with_realization(self):
     # => fp, rt, t: 8; realization: 2
     triples = ((0, 10, 1),
                (0, 10, 2),
                (0, 11, 1),
                (0, 11, 3),  # This '3' breaks the pattern.
                (1, 10, 1),
                (1, 10, 2),
                (1, 11, 1),
                (1, 11, 2))
     en1_cubes = [self._make_cube(*triple, realization=1) for
                  triple in triples]
     en2_cubes = [self._make_cube(*triple, realization=2) for
                  triple in triples]
     cubes = CubeList(en1_cubes) + CubeList(en2_cubes)
     cube, = cubes.merge()
     self.assertCML(cube, checksum=False)
开发者ID:SciTools,项目名称:iris,代码行数:19,代码来源:test_CubeList.py

示例2: test_orthogonal_with_realization

# 需要导入模块: from iris.cube import CubeList [as 别名]
# 或者: from iris.cube.CubeList import merge [as 别名]
 def test_orthogonal_with_realization(self):
     # => fp: 2; rt: 2; t: 2; realization: 2
     triples = ((0, 10, 1),
                (0, 10, 2),
                (0, 11, 1),
                (0, 11, 2),
                (1, 10, 1),
                (1, 10, 2),
                (1, 11, 1),
                (1, 11, 2))
     en1_cubes = [self._make_cube(*triple, realization=1) for
                  triple in triples]
     en2_cubes = [self._make_cube(*triple, realization=2) for
                  triple in triples]
     cubes = CubeList(en1_cubes) + CubeList(en2_cubes)
     cube, = cubes.merge()
     self.assertCML(cube, checksum=False)
开发者ID:SciTools,项目名称:iris,代码行数:19,代码来源:test_CubeList.py

示例3: test_combination_with_extra_triple

# 需要导入模块: from iris.cube import CubeList [as 别名]
# 或者: from iris.cube.CubeList import merge [as 别名]
 def test_combination_with_extra_triple(self):
     # => fp, rt, t, realization: 17
     triples = ((0, 10, 1),
                (0, 10, 2),
                (0, 11, 1),
                (0, 11, 2),
                (1, 10, 1),
                (1, 10, 2),
                (1, 11, 1),
                (1, 11, 2))
     en1_cubes = [self._make_cube(*triple, realization=1) for
                  triple in triples]
     # Add extra time triple on the end.
     en2_cubes = [self._make_cube(*triple, realization=2) for
                  triple in triples + ((1, 11, 3),)]
     cubes = CubeList(en1_cubes) + CubeList(en2_cubes)
     cube, = cubes.merge()
     self.assertCML(cube, checksum=False)
开发者ID:SciTools,项目名称:iris,代码行数:20,代码来源:test_CubeList.py

示例4: test_combination_with_extra_realization

# 需要导入模块: from iris.cube import CubeList [as 别名]
# 或者: from iris.cube.CubeList import merge [as 别名]
 def test_combination_with_extra_realization(self):
     # => fp, rt, t, realization: 17
     triples = ((0, 10, 1),
                (0, 10, 2),
                (0, 11, 1),
                (0, 11, 2),
                (1, 10, 1),
                (1, 10, 2),
                (1, 11, 1),
                (1, 11, 2))
     en1_cubes = [self._make_cube(*triple, realization=1) for
                  triple in triples]
     en2_cubes = [self._make_cube(*triple, realization=2) for
                  triple in triples]
     # Add extra that is a duplicate of one of the time triples
     # but with a different realisation.
     en3_cubes = [self._make_cube(0, 10, 2, realization=3)]
     cubes = CubeList(en1_cubes) + CubeList(en2_cubes) + CubeList(en3_cubes)
     cube, = cubes.merge()
     self.assertCML(cube, checksum=False)
开发者ID:SciTools,项目名称:iris,代码行数:22,代码来源:test_CubeList.py


注:本文中的iris.cube.CubeList.merge方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。