本文整理汇总了Python中GenomeBase.GenomeBase.copy方法的典型用法代码示例。如果您正苦于以下问题:Python GenomeBase.copy方法的具体用法?Python GenomeBase.copy怎么用?Python GenomeBase.copy使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GenomeBase.GenomeBase
的用法示例。
在下文中一共展示了GenomeBase.copy方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: copy
# 需要导入模块: from GenomeBase import GenomeBase [as 别名]
# 或者: from GenomeBase.GenomeBase import copy [as 别名]
def copy(self, g):
""" Copy the contents to the destination g
:param g: the GTreeGP genome destination
"""
GenomeBase.copy(self, g)
GTreeBase.copy(self, g)
示例2: copy
# 需要导入模块: from GenomeBase import GenomeBase [as 别名]
# 或者: from GenomeBase.GenomeBase import copy [as 别名]
def copy(self, g):
""" Copy genome to 'g'
Example:
>>> genome_origin.copy(genome_destination)
:param g: the destination G1DList instance
"""
GenomeBase.copy(self, g)
G1DBase.copy(self, g)
示例3: copy
# 需要导入模块: from GenomeBase import GenomeBase [as 别名]
# 或者: from GenomeBase.GenomeBase import copy [as 别名]
def copy(self, g):
""" Copy genome to 'g'
Example:
>>> genome_origin.copy(genome_destination)
:param g: the destination G1DList instance
"""
GenomeBase.copy(self, g)
g.listSize = self.listSize
g.genomeList = self.genomeList[:]
示例4: copy
# 需要导入模块: from GenomeBase import GenomeBase [as 别名]
# 或者: from GenomeBase.GenomeBase import copy [as 别名]
def copy(self, g):
""" Copy genome to 'g'
Example:
>>> genome_origin.copy(genome_destination)
:param g: the destination G2DCartesian instance
"""
GenomeBase.copy(self, g)
g.expressionNodes = self.expressionNodes.copy()
g.reevaluate = self.reevaluate
g.nodes = copy.deepcopy(self.nodes)
示例5: copy
# 需要导入模块: from GenomeBase import GenomeBase [as 别名]
# 或者: from GenomeBase.GenomeBase import copy [as 别名]
def copy(self, g):
""" Copy genome to 'g'
Example:
>>> genome_origin.copy(genome_destination)
:param g: the destination G2DList instance
"""
GenomeBase.copy(self, g)
g.height = self.height
g.width = self.width
for i in xrange(self.height):
g.genomeList[i] = self.genomeList[i][:]
示例6: copy
# 需要导入模块: from GenomeBase import GenomeBase [as 别名]
# 或者: from GenomeBase.GenomeBase import copy [as 别名]
def copy(self, g):
""" Copy genome to 'g'
Example:
>>> g1 = G1DBinaryString(2)
>>> g1.append(0)
>>> g1.append(1)
>>> g2 = G1DBinaryString(2)
>>> g1.copy(g2)
>>> g2[1]
1
:param g: the destination genome
"""
GenomeBase.copy(self, g)
G1DBase.copy(self, g)