煤矿皮带跑偏监测识别算法对皮带状况进行实时监测,不用手动控制。煤矿皮带跑偏监测识别算法一旦监测到皮带跑偏或者其他异常情况时,应该马上开展警报,通知监督值班人员,并提醒负责人及时处置,并把警报截屏和视频储存到数据库系统系统中生成表格。根据时间段对告警记录和违规截图,方便进行事后轨迹回溯。
分布式TensorFlow训练甚多学习模型的理论。本小节将具体介绍如何使用TF在分布式集群中训练深度学习模型。TensorFlow集群通过一系列的任务(tasks)来执行TF计算图中的运算。一般来说,不同的任务跑在不同的机器上。当然,使用GPU时,不同任务可以使用用一太机器上的不同GPU。TF中的任务可以聚合成工作。每个工作可以包含一个或多个任务。当一个TF集群有多个任务的时候,需要使用tf.train.ClusterSpec来指定运行每一个人物的机器。
配置第一个任务集群
import tensorflow as tf
c = tf.constant('Hello ,this is the server1!')
#生成一个有两个人物的集群,一个任务跑在本地的2222端口,另一个跑在本地的2223端口
cluster = tf.train.ClusterSpec({"local":['localhost:2998','localhost2999']})
#通过上面生成的集群配置生成Server。并通过job_name和task_index指定当前启动的任务。
server = tf.train.Server(cluster,job_name='local',task_index=0)
#通过server.target生成会话来使用来使用TF集群中的资源。通过log_device_placement可以看到执行每一个操作的任务
sess = tf.Session(server.target,config=tf.ConfigProto(log_device_placement = True))
print(sess.run(c))
配置第二个任务,使用同样的集群配置
import tensorflow as tf
c = tf.constant('Hello ,this is the server2!')
#和第一个任务一样的集群配置
cluster = tf.train.ClusterSpec({"local":['localhost:2998','localhost2999']})
#指定task_index = 1,所以第二个任务是运行在2999端口上
server = tf.train.Server(cluster,job_name='local',task_index=0)
sess = tf.Session(server.target,config=tf.ConfigProto(log_device_placement = True))
print(sess.run(c))
皮带是皮带运输机牵引绳和运输的关键部件,广泛用于煤炭、开采、海港、电力安装工程、冶金行业、化工企业等领域。在使用中,因为皮带被废旧金属或铁矿砂等杂物或阻碍物刮伤,皮带老化,皮带输送机拼装调节不科学,一直也会导致皮带误差、撕破等诸多问题,危害皮带的安全运营。
# From Mr. Dinosaur
import os
def listdir(path, list_name): # 传入存储的list
for file in os.listdir(path):
file_path = os.path.join(path, file)
if os.path.isdir(file_path):
listdir(file_path, list_name)
else:
list_name.append(file_path)
list_name = []
path = 'D:/PythonProject/data/' # 文件夹路径
listdir(path, list_name)
print(list_name)
with open('./list.txt', 'w') as f: # 要存入的txt
write = ''
for i in list_name:
write = write + str(i) + '\n'
f.write(write)
煤矿皮带跑偏监测识别系统实时监控系统皮带的运送状况。当监测到皮带的不匀承载能力时,系统立即停止皮带的运送,相关人员将在第一时间到现场进行维护保养,以减少损失,进而进一步提高管控高效率,避免安全事故。