code: def binaryFiles(self, path, minPartitions=None):
          
          minPartitions = minPartitions or self.defaultMinPartitions
          return RDD(self._jsc.binaryFiles(path, minPartitions), self,
                     PairDeserializer(UTF8Deserializer(), NoOpSerializer()))
docs: .. note:: Experimental
  
          Read a directory of binary files from HDFS, a local file system
          (available on all nodes), or any Hadoop-supported file system URI
          as a byte array. Each file is read as a single record and returned
          in a key-value pair, where the key is the path of each file, the
          value is the content of each file.
  
          .. note:: Small files are preferred, large file is also allowable, but
              may cause bad performance.