仅在Windows OS中使用python流IP摄像机视频的指令
import org.apache.spark.sql.Row
val data = a.rdd.zip(lst.rdd).map { case (l, r) => Row.fromSeq(l.toSeq ++ r.toSeq) }
import org.apache.spark.sql.types.StructType
val schema = StructType(a.schema.fields ++ lst.schema.fields)
val solution = spark.createDataFrame(data, schema)
scala> solution.show
+-------+--------+----+----------+-----+
|dept_no|emp_name| sal| date|value|
+-------+--------+----+----------+-----+
| 10| MILLER|1300|2017-11-03| 10|
| 30| Martin|1250|2017-11-21|Susan|
+-------+--------+----+----------+-----+
答案 0 :(得分:0)
此错误意味着cap.read()无法捕获视频/帧。该问题最有可能是线路上限= cv2.VideoCapture('http://admin:***** @ 198.168.1。***')。确保根据文档正确配置了摄像机的IP地址和计算机的IP地址。