[go: up one dir, main page]

CN102855310B - Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model - Google Patents

Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model Download PDF

Info

Publication number
CN102855310B
CN102855310B CN201210301835.1A CN201210301835A CN102855310B CN 102855310 B CN102855310 B CN 102855310B CN 201210301835 A CN201210301835 A CN 201210301835A CN 102855310 B CN102855310 B CN 102855310B
Authority
CN
China
Prior art keywords
type
root
segmentation model
designated
attribute
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN201210301835.1A
Other languages
Chinese (zh)
Other versions
CN102855310A (en
Inventor
黄建军
候兴哲
杨永加
慕福林
田野
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Electric Power Research Institute of State Grid Chongqing Electric Power Co Ltd
Original Assignee
Electric Power Research Institute of State Grid Chongqing Electric Power Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Electric Power Research Institute of State Grid Chongqing Electric Power Co Ltd filed Critical Electric Power Research Institute of State Grid Chongqing Electric Power Co Ltd
Priority to CN201210301835.1A priority Critical patent/CN102855310B/en
Publication of CN102855310A publication Critical patent/CN102855310A/en
Application granted granted Critical
Publication of CN102855310B publication Critical patent/CN102855310B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本发明涉及一种基于可扩展用户细分模型的有序用电数据转换方法及装置,用以解决用户用电信息采集系统档案数据到有序用电档案数据的自动转换问题。包括以下步骤:A导入初始用户的基于UML格式的细分模型,将有序用电管理系统里的主要对象表示为类、属性以及它们之间的关系;B对用户细分模型进行扩展;C将基于UML格式的用户细分模型转换为RDF Schema文档;D根据RDF Schema文档的定义,将用电信息采集系统档案数据转换为XML格式的有序用电管理系统档案模型交换文档;E有序用电管理系统引用RDF Schema文档对XML格式的有序用电管理档案数据进行解析,提取其中的信息。

The invention relates to a method and device for converting ordered power consumption data based on an extensible user subdivision model, which are used to solve the problem of automatic conversion from file data of a user power consumption information collection system to ordered power consumption file data. It includes the following steps: A. Import the UML-based subdivision model of the initial user, and express the main objects in the orderly power consumption management system as classes, attributes and the relationship between them; B. Extend the user subdivision model; C Convert the user segmentation model based on UML format into an RDF Schema document; D According to the definition of the RDF Schema document, convert the archive data of the electricity consumption information collection system into an XML format orderly power consumption management system archive model exchange document; Eorderly The power consumption management system refers to the RDF Schema document to analyze the orderly power consumption management file data in XML format and extract the information.

Description

基于可扩展用户细分模型的有序用电数据转换方法及装置Orderly power consumption data conversion method and device based on scalable user segmentation model

技术领域 technical field

本发明涉及电力系统数据转换领域,更具体的说,本发明涉及一种基于可扩展用户细分模型的有序用电数据转换方法及装置。The invention relates to the field of power system data conversion, and more specifically, the invention relates to a method and device for orderly power consumption data conversion based on an extensible user segmentation model.

背景技术 Background technique

随着电力系统向着高电压、大电网、高度自动化发展,以及电力工业市场化的推进,对企业级和行业级信息共享和应用集成的需求越来越迫切。各类自动化系统应用不断涌现,其数据转换需求覆盖了不同的层次,都要求方便、灵活的实现信息共享。With the development of the power system towards high voltage, large power grid, and high automation, and the marketization of the power industry, the demand for enterprise-level and industry-level information sharing and application integration is becoming more and more urgent. Various automation system applications are constantly emerging, and their data conversion requirements cover different levels, all of which require convenient and flexible information sharing.

在有序用电管理平台中,负荷控制的对象与电力用户用电信息采集系统的计量点并非直接对应,客户档案、计量档案也不完全相同。有序用电管理平台要实现多维度负荷数据分析,以实时全面掌握有序用电业务开展状况,为有序用电方案决策提供支撑,必须构建用户分类模型,实现专变用户细分,合理确定有序用电方案用户对象、负荷控制对象,以适应有序用电管理的深化应用。In the orderly power consumption management platform, the object of load control does not directly correspond to the metering point of the power user's electricity consumption information collection system, and the customer files and metering files are not exactly the same. In order to realize multi-dimensional load data analysis on the orderly power consumption management platform, to fully grasp the development status of orderly power consumption business in real time, and to provide support for the decision-making of orderly power consumption schemes, it is necessary to build a user classification model to achieve specific user segmentation and reasonable Determine the user object and load control object of the orderly power consumption plan to adapt to the deepening application of orderly power consumption management.

但用户细分模型只是一个抽象的模型,它既未定义模型数据库的规范,也未定义数据交换的格式。在工程中需要对用户细分模型的实现方式作出明确、可行的规定。But the user segmentation model is just an abstract model, which neither defines the specification of the model database nor the format of data exchange. In the project, it is necessary to make clear and feasible regulations on the realization of the user segmentation model.

同时,在后期有序用电管理平台运行过程中,用户细分模型可能会发生变化,为此需要一种支持用户细分模型扩展、能够实现有序用电数据自动转换的方法。At the same time, during the operation of the orderly power consumption management platform in the later period, the user segmentation model may change. For this reason, a method that supports the expansion of the user segmentation model and can realize the automatic conversion of orderly power consumption data is needed.

发明内容Contents of the invention

本发明的目的就是为解决上述问题,提出一种基于可扩展用户细分模型的有序用电数据转换方法,最终达到用户用电信息采集系统档案到有序用电档案的有效转换。The purpose of the present invention is to solve the above problems, and propose a method for converting ordered electricity consumption data based on an extensible user subdivision model, and finally achieve effective conversion from user electricity information collection system files to ordered electricity consumption files.

为实现上述目的,本发明采用如下技术方案:To achieve the above object, the present invention adopts the following technical solutions:

一种基于可扩展用户细分模型的有序用电数据转换方法,实现步骤如下:A sequential electricity consumption data conversion method based on an extensible user segmentation model, the implementation steps are as follows:

A导入初始用户的基于UML格式的细分模型,将有序用电管理系统里的主要对象表示为类、属性以及它们之间的关系;A imports the UML-based subdivision model of the initial user, and expresses the main objects in the ordered power consumption management system as classes, attributes and the relationship between them;

B对用户细分模型进行扩展;B expands the user segmentation model;

C将基于UML格式的用户细分模型转换为RDF Schema文档;C converts the UML-based user segmentation model into an RDF Schema document;

D根据RDF Schema文档的定义,将用电信息采集系统档案数据转换为XML格式的有序用电管理系统档案模型交换文档;D According to the definition of the RDF Schema document, the file data of the power consumption information collection system is converted into an orderly power consumption management system file model exchange document in XML format;

E有序用电管理系统引用RDF Schema文档对XML格式的有序用电管理档案数据进行解析,提取其中的信息。E The orderly power consumption management system refers to the RDF Schema document to analyze the orderly power consumption management file data in XML format and extract the information.

所述步骤B中对用户细分模型扩展主要通过定义不同的命名空间扩充新的类和属性完成,采用独立的命名空间,将用户细分模型的XML文档明确区分为用户细分模型标准的以及用户自定义的。In the step B, the expansion of the user segmentation model is mainly completed by defining different namespaces to expand new classes and attributes, using independent namespaces, and clearly distinguishing the XML documents of the user segmentation model into user segmentation model standards and user defined.

所述步骤C中用户细分模型转换过程为:The user segmentation model conversion process in the step C is:

C1.初始化,在用户细分模型中选择一个与其它类都有关联的类作为根元素,把它映射为RDF Schema的根∑={root},根的类型记为typeroot,Γ={typeroot},根的属性映射为typeroot下的子元素序列∑={{root},∑root},则根节点元素表示为{∑,Γ,typeroot,∑root};C1. Initialization, select a class related to other classes in the user segmentation model as the root element, and map it to the root of RDF Schema ∑={root}, the type of the root is recorded as type root , Γ={type root }, the attribute of the root is mapped to the sub-element sequence ∑={{root}, ∑ root } under type root , then the root node element is expressed as {∑, Γ, type root , ∑ root };

C2.对用户细分模型中的一个类映射成RDF Schema中的顶层元素i,记为εi,则∑={εi},它的类型映射为complexType,记为τ,则Γ={τ},类的属性类型映射为RDF Schema中已有的相同的数据类型,记为typeτ,则i元素节点表示为{∑,Γ,τ,typeτ};C2. Map a class in the user segmentation model to the top element i in the RDF Schema, denoted as ε i , then ∑={ε i }, its type is mapped to complexType, denoted as τ, then Γ={τ }, the attribute type of the class is mapped to the same data type existing in RDF Schema, which is recorded as type τ , and the i element node is expressed as {∑, Γ, τ, type τ };

C3.若类中存在在建数据类型或用户自定义的数据类型,则它的类型映射为simpleType,记为τ′,Γ={τ,τ′},其属性映射为restriction型的数据类型,记为typeτ′,并入节点元素i的集合中;C3. If there is a data type under construction or a user-defined data type in the class, its type mapping is simpleType, which is recorded as τ′, Γ={τ, τ′}, and its attribute mapping is a restriction data type. Recorded as type τ ′, merged into the set of node element i;

C4.若类的属性存在多重性,则它的类型映射为complexType,记为τ″,Γ={τ,τ″},其声明用唯一的(reg expτ″,typeτ″)序对表示,正则表达式reg expτ″表达了嵌套在元素中的子元素的数量范围,记为L(reg expτ″),每个复杂类型对应一个映射关系表,记为∑″,∑={{εi},∑″},并给出嵌套在复杂类型中子元素的类型,记为typeτ″,把所有的信息并入节点元素i的集合中;C4. If there is multiplicity in the attributes of the class, its type mapping is complexType, which is recorded as τ″, Γ={τ, τ″}, and its declaration is represented by a unique (reg exp τ ″, type τ ″) sequence pair , the regular expression reg exp τ ″ expresses the range of the number of sub-elements nested in the element, denoted as L(reg exp τ ″), each complex type corresponds to a mapping table, denoted as ∑ ″, ∑={ {ε i }, ∑″}, and give the type of sub-element nested in the complex type, denoted as type τ ″, merge all the information into the set of node element i;

C5.重复C2、C3、C4步骤,直至所有顶点都处理完;C5. Repeat steps C2, C3, and C4 until all vertices are processed;

C6.采用多态机制,通过多态列表,从父类那里得到所要继承的元素的属性,利用阻断和重命名来解决元素之间因继承而引发的冲突,利用元素和属性的引用来解决元素之间的引用。C6. Adopt the polymorphic mechanism, obtain the attributes of the elements to be inherited from the parent class through the polymorphic list, use blocking and renaming to resolve conflicts caused by inheritance between elements, and use element and attribute references to resolve References between elements.

所述步骤E中有序用电管理档案数据解析过程包括:In the step E, the orderly power consumption management file data analysis process includes:

E1.读取用户细分模型XML文件,获得Document对象;E1. Read the XML file of the user segmentation model to obtain the Document object;

根据路径读取所需解析的用户细分模型文件,读写XML文档主要依赖于org.dom4j.io包,使用SAXReader方式进行读取,Read the user segmentation model file that needs to be parsed according to the path. Reading and writing XML documents mainly depends on the org.dom4j.io package, and use SAXReader to read.

SAXReader reader=new SAXReader();SAXReader reader = new SAXReader();

Document document=reader.read(new File(cim.xml));Document document=reader.read(new File(cim.xml));

E2.根据路径取得所需类型的所有节点,并放到List中;E2. Obtain all nodes of the required type according to the path, and put them into the List;

E3.对某节点下所有子节点进行遍历,并取得某节点下的某属性名和属性值。E3. Traverse all child nodes under a certain node, and obtain a certain attribute name and attribute value under a certain node.

一种基于可扩展用户细分模型的有序用电数据转换方法用转换装置,该装置包括:A conversion device for an ordered power consumption data conversion method based on an extensible user segmentation model, the device comprising:

可视化模型编辑器,负责将用户多维细分模型进行展示,并供用户对已有模型通过拖、拽等操作方式进行扩展;The visual model editor is responsible for displaying the user's multi-dimensional subdivision model and allowing the user to expand the existing model by dragging and dropping;

模型转换器,主要负责将UML格式的用户细分模型转换为RDF Schema文档,RDF Schema的定义过程就是实用RDF Schema词汇表达用户多维细分模型的过程;The model converter is mainly responsible for converting the user segmentation model in UML format into an RDF Schema document. The definition process of RDF Schema is the process of expressing the user multi-dimensional segmentation model with RDF Schema vocabulary;

数据处理引擎,将用电信息采集系统档案数据转换为XML格式的有序用电管理系统档案数据;The data processing engine converts the file data of the power consumption information collection system into the file data of the orderly power consumption management system in XML format;

档案数据解析模块,基于用户细分模型RDF Schema文档将XML格式有序用电管理系统档案数据中有用数据解析出来供有序用电管理系统使用。The file data parsing module, based on the RDF Schema document of the user segmentation model, parses the useful data in the file data of the orderly power consumption management system in XML format for use by the orderly power use management system.

本发明的有益效果是:The beneficial effects of the present invention are:

1、通过用户细分模型为有序用电每个业务对象建立表征对象的事实指标体系,包括电量、负荷、损耗、电能质量等方面的指标,同时给出了一种明确、可行的用户细分模型在具体工程中的实现方式;1. Establish a factual index system for each business object of orderly power consumption through the user segmentation model, including indicators of electricity, load, loss, power quality, etc., and at the same time provide a clear and feasible user detail The implementation of sub-models in specific projects;

2、支持用户细分模型的扩展,本方法支持在后期有序用电管理平台使用过程中根据负荷控制实际情况对用户细分模型扩展;2. Support the expansion of the user segmentation model. This method supports the expansion of the user segmentation model according to the actual situation of load control during the use of the orderly power consumption management platform in the later stage;

3、可自动根据扩展后的用户细分模型将用电信息采集系统数据模型转换为有序用电数据模型。3. It can automatically convert the data model of the electricity consumption information collection system into an orderly electricity consumption data model according to the expanded user segmentation model.

附图说明 Description of drawings

图1为基于可扩展用户细分模型的有序用电数据转换方法总体流程图;Fig. 1 is an overall flow chart of an orderly power consumption data conversion method based on an extensible user segmentation model;

图2为用户细分模型转换流程图;Figure 2 is a flow chart of user segmentation model conversion;

图3为有序用电管理档案数据解析流程图;Fig. 3 is a flow chart of orderly power consumption management file data analysis;

图4为基于可扩展用户细分模型的有序用电数据转换装置;Fig. 4 is an orderly power consumption data conversion device based on an extensible user subdivision model;

图5为扩展后的用户细分模型图;Figure 5 is a diagram of the expanded user segmentation model;

图6为扩展的用户细分模型属性示例图。Fig. 6 is an example diagram of attributes of an extended user segmentation model.

具体实施方式 Detailed ways

下面结合附图和实施例对本发明进行进一步说明:The present invention will be further described below in conjunction with accompanying drawing and embodiment:

参考图1,是本发明一种基于可扩展用户细分模型的有序用电数据转换方法的流程图,包括以下步骤:Referring to Fig. 1, it is a flow chart of an orderly power consumption data conversion method based on an extensible user subdivision model of the present invention, including the following steps:

A.导入初始用户细分模型;A. Import the initial user segmentation model;

B.对用户细分模型进行扩展;B. Expand the user segmentation model;

C.将基于UML格式的用户细分模型转换为RDF Schema文档;C. Convert the UML-based user segmentation model into an RDF Schema document;

D.根据RDF Schema文档的定义,将用电信息采集系统档案数据转换为XML格式的有序用电管理系统档案模型交换文档;D. According to the definition of the RDF Schema document, the file data of the power consumption information collection system is converted into an orderly power consumption management system file model exchange document in XML format;

E.有序用电管理系统引用RDF Schema文档对XML格式的有序用电管理档案数据进行解析,提取其中的信息。E. The orderly power consumption management system refers to the RDF Schema document to analyze the orderly power consumption management file data in XML format and extract the information.

所述步骤A中导入的初始用户细分模型如下图5所示,有序用电用户细分模型中负控户、负控点为有序用电系统中定义并管理的档案信息。负控户包含两种情况:对于同一个营业账户由于营销业务需要而被划分为多个合同账户,在负控业务中需要管理的对象为该营业账户,则该营业账户可跟一个负控户对应;多个用户的计量设备安装在同一物理位置,现场仅安装了一个终端设备,在负控业务中如果这些用户能够作为统一的管理对象进行负荷控制管理,则这些用电客户应当作为统一的负控管理对象进行负荷控制,这些用电客户跟一个负控户对应。负控户可按照有序用电行业分类、轻/重工业分类、重点/非重点企业、是否高耗能、连续/非连续企业、军工/非军工企业、控制方式等维度进行细分,从而构建出用电客户的用户细分模型。The initial user segmentation model imported in step A is shown in Figure 5 below. The negative control households and negative control points in the orderly electricity consumption user segmentation model are the file information defined and managed in the orderly electricity consumption system. There are two situations for the negative control account: for the same business account is divided into multiple contract accounts due to marketing business needs, and the object to be managed in the negative control business is the business account, then the business account can be linked to a negative control account Corresponding; the metering equipment of multiple users is installed at the same physical location, and only one terminal device is installed on site. The load control management object performs load control, and these electricity customers correspond to a load control household. The negative control households can be subdivided according to the orderly power consumption industry classification, light/heavy industry classification, key/non-key enterprises, high energy consumption, continuous/non-continuous enterprises, military/non-military enterprises, control methods, etc., so as to construct Create a user segmentation model for electricity customers.

所述步骤B中用户细分模型扩展主要通过定义不同的命名空间扩充新的类和属性完成,由于采用了独立的命名空间,用户细分模型的XML文档可以明确的区分哪些内容是用户细分模型标准的,哪些是用户自定义的。在用户细分模型中,我们可以添加一个扩展的用户细分模型属性“厂休日”到负控户类。如果其他系统对这个扩展不感兴趣,这个用户化的标记可以被简单的忽略掉。如下图6所示,虚线框中标示的厂休日属性是后期扩展的新属性。In the step B, the expansion of the user segmentation model is mainly completed by defining different namespaces and expanding new classes and attributes. Due to the use of independent namespaces, the XML document of the user segmentation model can clearly distinguish which content is user segmentation Which models are standard and which are user-defined. In the user segmentation model, we can add an extended user segmentation model attribute "factory holiday" to the negative control household class. If other systems are not interested in this extension, this custom flag can simply be ignored. As shown in Figure 6 below, the factory holiday attribute marked in the dotted line box is a new attribute that was expanded later.

参考图2,所述步骤C中用户细分模型转换包括:With reference to Fig. 2, in the described step C, user subdivision model conversion includes:

C1.初始化,在用户细分模型中选择一个与其它类都有关联的类作为根元素,把它映射为RDF Schema的根∑={root},根的类型记为typeroot,Γ={typeroot},根的属性映射为typeroot下的子元素序列∑={{root},∑root},则根节点元素表示为{∑,Γ,typeroot,∑root};C1. Initialization, select a class related to other classes in the user segmentation model as the root element, and map it to the root of RDF Schema ∑={root}, the type of the root is recorded as type root , Γ={type root }, the attribute of the root is mapped to the sub-element sequence ∑={{root}, ∑ root } under type root , then the root node element is expressed as {∑, Γ, type root , ∑ root };

C2.对用户细分模型中的一个类映射成RDF Schema中的顶层元素i,记为εi,则∑={εi},它的类型映射为complexType,记为τ,则Γ={τ},类的属性类型映射为RDF Schema中已有的相同的数据类型,记为typeτ,则i元素节点表示为{∑,Γ,τ,typeτ};C2. Map a class in the user segmentation model to the top element i in the RDF Schema, denoted as ε i , then ∑={ε i }, its type is mapped to complexType, denoted as τ, then Γ={τ }, the attribute type of the class is mapped to the same data type existing in RDF Schema, which is recorded as type τ , and the i element node is expressed as {∑, Γ, τ, type τ };

C3.若类中存在在建数据类型或用户自定义的数据类型,则它的类型映射为simpleType,记为τ′,Γ={τ,τ′},其属性映射为restriction型的数据类型,记为typeτ′,并入节点元素i的集合中;C3. If there is a data type under construction or a user-defined data type in the class, its type mapping is simpleType, which is recorded as τ′, Γ={τ,τ′}, and its attribute mapping is a restriction data type. Recorded as type τ ′, merged into the set of node element i;

C4.若类的属性存在多重性,则它的类型映射为complexType,记为τ″,Γ={τ,τ″},其声明用唯一的(reg expτ″,typeτ″)序对表示,正则表达式reg expτ″表达了嵌套在元素中的子元素的数量范围,记为L(reg expτ″),每个复杂类型对应一个映射关系表,记为∑″,∑={{εi},∑″},并给出嵌套在复杂类型中子元素的类型,记为typeτ″,把所有的信息并入节点元素i的集合中;C4. If there is multiplicity in the attributes of the class, its type mapping is complexType, which is recorded as τ″, Γ={τ, τ″}, and its declaration is represented by a unique (reg exp τ ″, type τ ″) sequence pair , the regular expression reg exp τ ″ expresses the range of the number of sub-elements nested in the element, denoted as L(reg exp τ ″), each complex type corresponds to a mapping table, denoted as ∑ ″, ∑={ {ε i }, ∑″}, and give the type of sub-element nested in the complex type, denoted as type τ ″, merge all the information into the set of node element i;

C5.重复C2、C3、C4步骤,直至所有顶点都处理完;C5. Repeat steps C2, C3, and C4 until all vertices are processed;

C6.采用多态机制,通过多态列表,从父类那里得到所要继承的元素的属性,利用阻断和重命名来解决元素之间因继承而引发的冲突,利用元素和属性的引用来解决元素之间的引用。C6. Adopt the polymorphic mechanism, obtain the attributes of the elements to be inherited from the parent class through the polymorphic list, use blocking and renaming to resolve conflicts caused by inheritance between elements, and use element and attribute references to resolve References between elements.

经过转换得到的RDF Schema文档如下:The converted RDF Schema document is as follows:

<rdfs:Classrdf:ID=”负控户”><rdfs:Classrdf:ID="negative control account">

<rdfs:labelxml:lang=”zh-CN″>负控户</rdfs:label><rdfs:labelxml:lang="zh-CN">Responsible control account</rdfs:label>

<rdfs:subClassOfrdf:resource=”rdfs:Resource″/><rdfs:subClassOfrdf:resource="rdfs:Resource"/>

<rdfs:comment>负控户为有序用电管理系统中定义并管理的档案信息,负控户可对应营销系统中的一个或多个营业账户</rdfs:comment><rdfs:comment>The negative control account is the file information defined and managed in the orderly power consumption management system, and the negative control account can correspond to one or more business accounts in the marketing system</rdfs:comment>

<dw:stereotype>″″<dw:stereotype><dw:stereotype>″″<dw:stereotype>

</rdfs:Class></rdfs:Class>

<rdfs:Propertyrdf:ID=”负控户.负控户标识”><rdfs:Propertyrdf:ID="Negative Control Account. Negative Control Account ID">

<rdfs:labelxml:lang=”zh-CN″>负控户标识</rdfs:label><rdfs:labelxml:lang=”zh-CN”>Register ID</rdfs:label>

<rdfs:domainrdf:resource=”#负控户”/><rdfs:domainrdf:resource="# negative control account"/>

<rdfs:rangerdf:resource=”#负控户标识”/><rdfs:rangerdf:resource="# negative control user ID"/>

<rdfs:comment>″负控户在有序用电管理系统中的唯一标识”<rdfs:comment>"The unique identification of the negative control household in the orderly power consumption management system"

</rdfs:comment></rdf:Property></rdfs:comment></rdf:Property>

<rdfs:Propertyrdf:ID=”负控户.厂休日”><rdfs:Propertyrdf:ID="Responsible control household. Factory holiday">

<rdfs:labelxml:lang=″zh-CN″>厂休日</rdfs:label><rdfs:labelxml:lang=″zh-CN″>Factory Holidays</rdfs:label>

<rdfs:domainrdf:resource=”#负控户”/><rdfs:domainrdf:resource="# negative control account"/>

<rdfs:rangerdf:resource=”#厂休日”/><rdfs:rangerdf:resource="#factory holiday"/>

<rdfs:comment>″负控方案执行时根据负控户的厂休日将一周中的某一天或若干天选定为厂休日,并规定厂休日限电的开始时间,持续时间段”<rdfs:comment>"When implementing the negative control plan, select one or several days of the week as the factory holidays according to the factory holidays of the negative control households, and stipulate the start time and duration of power reduction on the factory holidays"

</rdfs:comment></rdf:Property></rdfs:comment></rdf:Property>

所述步骤D中转换后的有序用电管理档案为:The orderly power consumption management file converted in the step D is:

<dw:负控户rdf:ID=”_5”><dw: negative control account rdf: ID="_5">

<dw:负控户.负控户标识>11010000001</dw:负控户.负控户标识><dw: negative control account. negative control account ID>11010000001</dw: negative control account. negative control account ID>

<dw:负控户.负控户编号>1</dw:负控户.负控户编号><dw: negative control account. negative control account number>1</dw: negative control account. negative control account number>

<dw:负控户.负控户名称>XXXX客户</dw:负控户.负控户名称><dw: negative control account. negative control account name>XXXX customer</dw: negative control account. negative control account name>

<kz:负控户.厂休日>二、四</kz:负控户.厂休日><kz: Negative control households. Factory holidays> Two, four</kz: Negative control households. Factory holidays>

参考图3,所述步骤E中有序用电管理档案数据解析过程包括:With reference to Fig. 3, in the described step E, the orderly power consumption management file data parsing process includes:

E1.读取用户细分模型XML文件,获得Document对象;根据路径读取所需解析的用户细分模型文件,读写XML文档主要依赖于org.dom4j.io包,使用SAXReader方式进行读取,E1. Read the user segmentation model XML file to obtain the Document object; read the user segmentation model file that needs to be parsed according to the path, read and write XML documents mainly rely on the org.dom4j.io package, use SAXReader to read,

SAXReader reader=new SAXReader();SAXReader reader = new SAXReader();

Document document=reader.read(new File(cim.xml));Document document=reader.read(new File(cim.xml));

E2.根据路径取得所需类型的所有节点,并放到List中;E2. Obtain all nodes of the required type according to the path, and put them into the List;

E3.对某节点下所有子节点进行遍历,并取得某节点下的某属性名和属性值。E3. Traverse all child nodes under a certain node, and obtain a certain attribute name and attribute value under a certain node.

参考图4是一种基于可定制用户多维细分模型的有序用电档案转换装置,该装置包括:Referring to Fig. 4, it is an orderly power consumption file conversion device based on a customizable user multi-dimensional subdivision model, which includes:

可视化模型编辑器402,负责将用户多维细分模型进行展示,并供用户对已有模型通过拖、拽等操作方式进行扩展;The visual model editor 402 is responsible for displaying the user's multi-dimensional subdivision model, and allowing the user to expand the existing model through operations such as dragging and dropping;

模型转换器401,主要负责将UML格式的用户细分模型转换为RDF Schema文档,RDF Schema的定义过程就是实用RDF Schema词汇表达用户多维细分模型的过程;The model converter 401 is mainly responsible for converting the user segmentation model in UML format into an RDF Schema document. The definition process of RDF Schema is the process of expressing the user multi-dimensional segmentation model with RDF Schema vocabulary;

数据处理引擎403,将用电信息采集系统档案数据转换为XML格式的有序用电管理系统档案数据;The data processing engine 403 converts the file data of the power consumption information collection system into the file data of the orderly power consumption management system in XML format;

档案数据解析模块404,基于用户细分模型RDF Schema文档将XML格式有序用电管理系统档案数据中有用数据解析出来供有序用电管理系统使用。The file data parsing module 404, based on the RDF Schema document of the user segmentation model, parses the useful data in the file data of the orderly power consumption management system in XML format for use by the orderly power use management system.

Claims (2)

1., based on an ordered electric data transfer device for scalable user Segmentation Model, it is characterized in that, performing step is as follows:
A imports the Segmentation Model based on UML form of initial user, the main object in ordered electric management system is expressed as class, attribute and the relation between them;
B expands subscriber segmentation model; In described step B to subscriber segmentation model extension mainly through defining different NameSpaces and expand new class and attribute completing, adopt independently NameSpace, the XML document of subscriber segmentation model is clearly divided into subscriber segmentation model criteria and user-defined;
Subscriber segmentation model conversion based on UML form is RDF Schema document by C;
In described step C, subscriber segmentation model conversion process is:
C1. initialization, in subscriber segmentation model select one with all related class of other class as root element, it be mapped as RDF Schema root ∑={ root}, the type of root is designated as type root, Γ={ type root, the best property of attribute mapping of root is type rootunder daughter element sequence ∑={ { root}, ∑ root, then root node element representation is { ∑, Γ, type root, ∑ root;
C2. the class of in subscriber segmentation model is mapped to the top-level elements i in RDF Schema, is designated as ε i, then ∑={ ε i, its Type mapping is complexType, is designated as τ, then Γ={ τ }, and the attribute type of class is mapped as existing identical data type in RDF Schema, is designated as type τ, then i node element is expressed as { ∑, Γ, τ, type τ;
Building data type or custom data type if C3. exist in class, then its Type mapping is simpleType, is designated as τ ', and Γ={ τ, τ ' }, its best property of attribute mapping is the data type of restriction type, is designated as type τ ', be incorporated in the set of node elements i;
If C4. the attribute of class exists multiplicity, then its Type mapping is complexType, is designated as τ ", Γ={ τ, τ " }, unique (reg exp of its statement τ ", type τ ") ordered pair represents, regular expression reg exp τ "have expressed the quantitative range of the daughter element be nested in element, be designated as L (reg exp τ "), the corresponding mapping relations table of each complicated type, is designated as ∑ ", ∑={ { ε i, ∑ " }, and provide the type being nested in daughter element in complicated type, be designated as type τ ", all information is incorporated in the set of node elements i;
C5. C2, C3, C4 step is repeated, until all summits all process;
C6. adopt polymorphic mechanism, by polymorphic list, obtain the attribute of an element that will inherit from parent there, utilize blocking-up and rename to solve the conflict caused because of succession between element, utilize element and quoting of attribute to solve quoting between element;
D is according to the definition of RDF Schema document, and ordered electric management system record model power information acquisition system file data being converted to XML format exchanges document;
E ordered electric management system is quoted the ordered electric administer archive data of RDF Schema document to XML format and is resolved, and extracts information wherein;
In described step e, ordered electric administer archive Data Analysis process comprises:
E1. read subscriber segmentation model XML file, obtain Document object;
Read required subscriber segmentation model file of resolving according to path, read-write XML document depends on org.dom4j.io bag, uses SAXReader mode to read,
E2. obtain all nodes of required type according to path, and be put in List;
E3. child nodes all under certain node are traveled through, and certain attribute-name under obtaining certain node and property value.
2. based on an ordered electric DTU (Data Transfer unit) for scalable user Segmentation Model, it is characterized in that, this device comprises:
Import module: the Segmentation Model based on UML form importing initial user, is expressed as class, attribute and the relation between them by the main object in ordered electric management system;
Expansion module: subscriber segmentation model is expanded; In described expansion module to subscriber segmentation model extension mainly through defining different NameSpaces and expand new class and attribute completing, adopt independently NameSpace, the XML document of subscriber segmentation model is clearly divided into subscriber segmentation model criteria and user-defined;
First modular converter: be RDF Schema document by the subscriber segmentation model conversion based on UML form;
Described first modular converter comprises:
First map unit: initialization, in subscriber segmentation model select one with all related class of other class as root element, it be mapped as RDF Schema root ∑={ root}, the type of root is designated as type root, Γ={ type root, the best property of attribute mapping of root is type rootunder daughter element sequence ∑={ { root}, ∑ root, then root node element representation is { ∑, Γ, type root, ∑ root;
Second map unit: the class of in subscriber segmentation model is mapped to the top-level elements i in RDF Schema, is designated as ε i, then ∑={ ε i, its Type mapping is complexType, is designated as τ, then Γ={ τ }, and the attribute type of class is mapped as existing identical data type in RDF Schema, is designated as type τ, then i node element is expressed as { ∑, Γ, τ, type τ;
3rd map unit: building data type or custom data type if exist in class, then its Type mapping is simpleType, is designated as τ ', and Γ={ τ, τ ' }, its best property of attribute mapping is the data type of restriction type, is designated as type τ ', be incorporated in the set of node elements i;
4th map unit: if the attribute of class exists multiplicity, then its Type mapping is complexType, is designated as τ ", Γ={ τ, τ " }, unique (reg exp of its statement τ ", type τ ") ordered pair represents, regular expression reg exp τ "have expressed the quantitative range of the daughter element be nested in element, be designated as L (reg exp τ "), the corresponding mapping relations table of each complicated type, is designated as ∑ ", ∑={ { ε i, ∑ " }, and provide the type being nested in daughter element in complicated type, be designated as type τ ", all information is incorporated in the set of node elements i;
Repetitive: the work repeating the second map unit, the 3rd map unit, the 4th map unit, until all summits all process;
Conflict solving unit: adopt polymorphic mechanism, by polymorphic list, obtain the attribute of an element that will inherit from parent there, utilize blocking-up and rename to solve the conflict caused because of succession between element, utilize element and quoting of attribute to solve quoting between element;
Second modular converter: according to the definition of RDF Schema document, ordered electric management system record model power information acquisition system file data being converted to XML format exchanges document;
Parsing module: ordered electric management system is quoted the ordered electric administer archive data of RDF Schema document to XML format and resolved, extracts information wherein;
Described parsing module comprises:
File reading unit: read subscriber segmentation model XML file, obtain Document object;
Read required subscriber segmentation model file of resolving according to path, read-write XML document depends on org.dom4j.io bag, uses SAXReader mode to read,
Obtain node unit: all nodes obtaining required type according to path, and be put in List;
Traversal Unit: child nodes all under certain node are traveled through, and certain attribute-name under obtaining certain node and property value.
CN201210301835.1A 2012-08-23 2012-08-23 Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model Expired - Fee Related CN102855310B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210301835.1A CN102855310B (en) 2012-08-23 2012-08-23 Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210301835.1A CN102855310B (en) 2012-08-23 2012-08-23 Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model

Publications (2)

Publication Number Publication Date
CN102855310A CN102855310A (en) 2013-01-02
CN102855310B true CN102855310B (en) 2014-12-17

Family

ID=47401898

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210301835.1A Expired - Fee Related CN102855310B (en) 2012-08-23 2012-08-23 Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model

Country Status (1)

Country Link
CN (1) CN102855310B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104050516B (en) * 2014-06-19 2015-05-06 国家电网公司 Fair and orderly electricity utilization method based on user interaction ability
CN104156219A (en) * 2014-08-20 2014-11-19 国家电网公司 Electric power marketing and distributing model verifying method based on ontology technology
CN109918050B (en) * 2019-02-01 2021-10-26 上海交通大学 Software requirement description rule language and conversion method

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1482432A2 (en) * 2003-05-27 2004-12-01 Cognos Incorporated System and method of modelling of a multi-dimensional data source in an entity-relationship model
US7111018B1 (en) * 2000-10-30 2006-09-19 Margaret E Goodrich System and method for integrating electrical power grid and related data from various proprietary raw data formats into a single maintainable electrically connected database
CN101149748A (en) * 2007-10-29 2008-03-26 浙江大学 Editing Method of Semantic Mapping Information Between Ontology Schema and Relational Database Schema
CN101789042A (en) * 2010-01-29 2010-07-28 华东电网有限公司 Model increment comparing tool of common information model (CIM) of electric network enterprise
CN102542513A (en) * 2012-01-17 2012-07-04 上海交通大学 Body-based verification tool of power grid public information model and method thereof

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7111018B1 (en) * 2000-10-30 2006-09-19 Margaret E Goodrich System and method for integrating electrical power grid and related data from various proprietary raw data formats into a single maintainable electrically connected database
EP1482432A2 (en) * 2003-05-27 2004-12-01 Cognos Incorporated System and method of modelling of a multi-dimensional data source in an entity-relationship model
CN101149748A (en) * 2007-10-29 2008-03-26 浙江大学 Editing Method of Semantic Mapping Information Between Ontology Schema and Relational Database Schema
CN101789042A (en) * 2010-01-29 2010-07-28 华东电网有限公司 Model increment comparing tool of common information model (CIM) of electric network enterprise
CN102542513A (en) * 2012-01-17 2012-07-04 上海交通大学 Body-based verification tool of power grid public information model and method thereof

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于XMI的UML模型向OWL本体转换方案;陈振庆;《贺州学院学报》;20090930;第25卷(第3期);139-144 *

Also Published As

Publication number Publication date
CN102855310A (en) 2013-01-02

Similar Documents

Publication Publication Date Title
Maltese et al. Sustainability assessment through green BIM for environmental, social and economic efficiency
CN102750406B (en) Multi-version management method for model set and difference model-based power grid model
CN102542513B (en) Body-based verification tool of power grid public information model and method thereof
CN106570778B (en) A kind of method that data integration based on big data is calculated with line loss analyzing
CN102663103B (en) Configurable method for automatically generating database and accessing data
Corrado et al. Data structuring for the ontological modelling of urban energy systems: The experience of the SEMANCO project
CN102708161B (en) A Modeling Method of Data Logic Model Using Common Concept Set
CN107315768A (en) The distribution information interacting method and system mapped based on Heterogeneous Information model
CN106407216A (en) Clue tracing audition system developed on basis of semantic net construction path and construction method of clue tracing audition system
CN102043719A (en) Method for testing IEC61850 configuration description file
CN108446885A (en) A kind of automatic collecting method of review comment
CN102214243A (en) Version management system for x extensible business reporting language (XBRL) classification standard
CN104317864A (en) Automatic identification method of information model based on IEC61850 logical nodes
CN103455896A (en) Paperless assembling quality control method based on internet of things
CN104750496A (en) Automatic checking method for change influence degree of model
CN102855310B (en) Well-organized electricity utilization data conversion method and device based on extensible customer segmentation model
CN111666456B (en) Automatic net rack topology construction method based on multi-source distribution network
CN105005634B (en) A kind of pedigree bullet train modeling method based on meta-model
CN115168506A (en) A multi-platform distributed data integration method, system and storage medium
CN114792145A (en) Standard digital management maintenance system and method based on knowledge graph
CN113901233A (en) Query data repairing method, system, computer equipment and storage medium
Zhang et al. A system modeling process based on SysML to support data consistency across system requirement, function, and solution model layers
Giannoulis et al. Model-driven strategic awareness: From a unified business strategy meta-model (UBSMM) to enterprise architecture
CN108227644A (en) A kind of equipment replacement method, apparatus, storage medium and electronic device
McMorran et al. Addressing misconceptions about the common information model (CIM)

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20141217

Termination date: 20150823

EXPY Termination of patent right or utility model