frag_pele/PlopRotTemp_S_2017/PlopRotTemp.py
def replace_vdwr_from_library(rotamer_library):
  """
    Check if the rotamer library 
    contains any vdw radius= 0
    and replace them by 0.5000
  """
  found = False
  lines = []
  radius_vdw_info, start_index, end_index = parse_nonbonded(rotamer_library)
  for i, rdw_line in enumerate(radius_vdw_info):
    NBOND_info = rdw_line.split()
    rdw = float(NBOND_info[1])/2.0
    epsilon = float(NBOND_info[2])
    
    if(rdw == 0):
      warnings.warn("Van der Waals of atom {} = 0 changed to default 0.5".format(NBOND_info[0]))
      NBOND_info[1] = DEFAULT_RADIUS_VDW
      found = True
    if(epsilon == 0):
      warnings.warn("Epsilon of atom {} = 0 changed to default 0.5".format(NBOND_info[0]))
      NBOND_info[2] = DEFAULT_EPSILON
      found = True
    lines.append(NBOND_info)

  if found:
    rvdw_change(rotamer_library, lines, start_index, end_index)

    Check if the rotamer library 
    contains any vdw radius= 0
    and replace them by 0.5000
  
Check if the rotamer library
contains any vdw radius= 0
and replace them by 0.5000
Check if the rotamer library contains any vdw radius = 0 and replace them by 0 . 5000
def replace_vdwr_from_library(rotamer_library):
  found = False
  lines = []
  radius_vdw_info, start_index, end_index = parse_nonbonded(rotamer_library)
  for i, rdw_line in enumerate(radius_vdw_info):
    NBOND_info = rdw_line.split()
    rdw = float(NBOND_info[1])/2.0
    epsilon = float(NBOND_info[2])
    if(rdw == 0):
      warnings.warn("Van der Waals of atom {} = 0 changed to default 0.5".format(NBOND_info[0]))
      NBOND_info[1] = DEFAULT_RADIUS_VDW
      found = True
    if(epsilon == 0):
      warnings.warn("Epsilon of atom {} = 0 changed to default 0.5".format(NBOND_info[0]))
      NBOND_info[2] = DEFAULT_EPSILON
      found = True
    lines.append(NBOND_info)
  if found:
    rvdw_change(rotamer_library, lines, start_index, end_index)
def replace_vdwr_from_library ( rotamer_library ) : found = False lines = [ ] radius_vdw_info , start_index , end_index = parse_nonbonded ( rotamer_library ) for i , rdw_line in enumerate ( radius_vdw_info ) : NBOND_info = rdw_line . split ( ) rdw = float ( NBOND_info [ 1 ] ) / 2.0 epsilon = float ( NBOND_info [ 2 ] ) if ( rdw == 0 ) : warnings . warn ( "Van der Waals of atom {} = 0 changed to default 0.5" . format ( NBOND_info [ 0 ] ) ) NBOND_info [ 1 ] = DEFAULT_RADIUS_VDW found = True if ( epsilon == 0 ) : warnings . warn ( "Epsilon of atom {} = 0 changed to default 0.5" . format ( NBOND_info [ 0 ] ) ) NBOND_info [ 2 ] = DEFAULT_EPSILON found = True lines . append ( NBOND_info ) if found : rvdw_change ( rotamer_library , lines , start_index , end_index )
Check if the rotamer library
contains any vdw radius= 0
and replace them by 0.5000
Check if the rotamer library contains any vdw radius = 0 and replace them by 0 . 5000
"""
    Check if the rotamer library 
    contains any vdw radius= 0
    and replace them by 0.5000
  """
rotamer_library