Retrieves the size of the file-like object.

    Returns:
      int: size of the file-like object data.

    Raises:
      IOError: if the file-like object has not been opened.
      OSError: if the file-like object has not been opened.
8616
def get_size(self):
    
    if not self._is_open:
      raise IOError('Not opened.')

    if not hasattr(self._file_object, 'get_size'):
      if not self._size:
        current_offset = self.get_offset()
        self.seek(0, os.SEEK_END)
        self._size = self.get_offset()
        self.seek(current_offset, os.SEEK_SET)
      return self._size

    return self._file_object.get_size()
1026045
def get_readable_filesize(size):
	
	if(size < 1024):
		return str(size)+' bytes'
	temp = size/1024.0
	level = 1
	while(temp >= 1024 and level< 3):
		temp = temp/1024
		level += 1
	if(level == 1):
		return str(round(temp,2))+' KB'
	elif(level == 2):
		return str(round(temp,2))+' MB'
	else:
		return str(round(temp,2))+' GB'
409738
def _get_file_size(self):
        
        file_size = retry(self._retry_count)(_get_content_length)(
            self._session, self.url, self._timeout
        )
        file_size = int(file_size)
        if file_size == 0:
            with io.open(self._file_path, 'a', encoding='utf-8'):
                pass
        return file_size
532029
def length(self):
        

        if not self.__length:
            self.__length = self.__get_length()

        return self.__length
228789
def GetByteSize(self):
    
    if self._byte_size is None and self.members:
      self._byte_size = 0
      for member_definition in self.members:
        byte_size = member_definition.GetByteSize()
        if byte_size is None:
          self._byte_size = None
          break

        self._byte_size = max(self._byte_size, byte_size)

    return self._byte_size
940275
def get_data_length(self):
        # type: () -> int
        '''
        
        '''
        if not self._initialized:
            raise pycdlibexception.PyCdlibInternalError('Directory Record not yet initialized')
        if self.inode is not None:
            return self.inode.get_data_length()
        return self.data_length
672
def get_size(objects):
    """"""
    res = 0
    for o in objects:
        try:
            res += _getsizeof(o)
        except AttributeError:
            print("IGNORING: type=%s; o=%s" % (str(type(o)), str(o)))
    return res
708728
def get_size(self):
    
    if not self._is_open:
      raise IOError('Not opened.')

    if self._decoded_stream_size is None:
      self._decoded_stream_size = self._GetDecodedStreamSize()

    return self._decoded_stream_size
973437
def _GetUncompressedStreamSize(self):
    
    self._file_object.seek(0, os.SEEK_SET)

    self._decompressor = self._GetDecompressor()
    self._uncompressed_data = b''

    compressed_data_offset = 0
    compressed_data_size = self._file_object.get_size()
    uncompressed_stream_size = 0

    while compressed_data_offset < compressed_data_size:
      read_count = self._ReadCompressedData(self._COMPRESSED_DATA_BUFFER_SIZE)
      if read_count == 0:
        break

      compressed_data_offset += read_count
      uncompressed_stream_size += self._uncompressed_data_size

    return uncompressed_stream_size
678616
def fileSize(f):
    ''''''
    offset = f.tell()

    f.seek(0, 2)
    size = f.tell()

    f.seek(offset)  # return to the previous position in the file
    return size
496309
def size(self):
        
        tot = 0
        for p in self.__iter__(overPath=True):
            tot += os.path.getsize(p)
        return tot
961683
def get_file_size(filename):
    
    if filename is None:
        return float(0)
    if type(filename) is list:
        return float(sum([get_file_size(x) for x in filename]))
    try:
        total_bytes = sum([float(os.stat(f).st_size)
                           for f in filename.split(" ") if f is not ''])
    except OSError:
        # File not found
        return 0.0
    else:
        return float(total_bytes) / (1024 ** 3)
132120
def size(filename, format='decimal'):
    '''
    

    '''
    if isinstance(filename, file):
        filename = filename.name

    return filesize(os.stat(filename)[stat.ST_SIZE], format)
302307
def size(self):
        
        size = self._backend._vispy_get_size()
        return (size[0] // self._px_scale, size[1] // self._px_scale)
1136973
def size(self):
    
    if self._size is None:
      self._size = 0
      for csv_file in self.files:
        self._size += sum(1 if line else 0 for line in _util.open_local_or_gcs(csv_file, 'r'))

    return self._size
793841
def Size(self):
        
        scriptsize = 0
        if self.Script is not None:
            scriptsize = self.Script.Size()
        return s.uint32 + s.uint256 + s.uint256 + s.uint32 + s.uint32 + s.uint64 + s.uint160 + 1 + scriptsize
1032424
def getsize(self, key=None):
        
        if key is None:
            return os.path.getsize(self.filename)
        return hdf5.ByteCounter.get_nbytes(
            h5py.File.__getitem__(self.hdf5, key))