{"id":37612430,"url":"https://github.com/bressanmarcos/cimrdf.py","last_synced_at":"2026-01-16T10:24:54.764Z","repository":{"id":62562200,"uuid":"270211544","full_name":"bressanmarcos/cimrdf.py","owner":"bressanmarcos","description":"Generate Python data structures from CIM RDF profiles, parse and serialize CIM-compliant information objects, according to IEC 61970-501 standard.","archived":false,"fork":false,"pushed_at":"2020-11-07T20:53:58.000Z","size":86,"stargazers_count":7,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-05T07:30:58.852Z","etag":null,"topics":["cim","cim-rdf","information-model","parse","rdf","xml"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bressanmarcos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-06-07T06:10:40.000Z","updated_at":"2024-04-28T07:45:45.000Z","dependencies_parsed_at":"2022-11-03T15:30:47.706Z","dependency_job_id":null,"html_url":"https://github.com/bressanmarcos/cimrdf.py","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/bressanmarcos/cimrdf.py","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bressanmarcos%2Fcimrdf.py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bressanmarcos%2Fcimrdf.py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bressanmarcos%2Fcimrdf.py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bressanmarcos%2Fcimrdf.py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bressanmarcos","download_url":"https://codeload.github.com/bressanmarcos/cimrdf.py/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bressanmarcos%2Fcimrdf.py/sbom","scorecard":{"id":252444,"data":{"date":"2025-08-11","repo":{"name":"github.com/bressanmarcos/cimrdf.py","commit":"66804b00efeb41aeb5b086e5cf6fb6c452b9fdb6"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.7,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v2.1 not signed: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/32119380","Warn: release artifact v2.0 not signed: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/30937672","Warn: release artifact v1.0 not signed: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/28213834","Warn: release artifact v0.2 not signed: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/27568884","Warn: release artifact v0.1 not signed: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/27568904","Warn: release artifact v2.1 does not have provenance: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/32119380","Warn: release artifact v2.0 does not have provenance: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/30937672","Warn: release artifact v1.0 does not have provenance: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/28213834","Warn: release artifact v0.2 does not have provenance: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/27568884","Warn: release artifact v0.1 does not have provenance: https://api.github.com/repos/bressanmarcos/cimrdf.py/releases/27568904"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-17T08:49:56.914Z","repository_id":62562200,"created_at":"2025-08-17T08:49:56.915Z","updated_at":"2025-08-17T08:49:56.915Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28478049,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T06:30:42.265Z","status":"ssl_error","status_checked_at":"2026-01-16T06:30:16.248Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cim","cim-rdf","information-model","parse","rdf","xml"],"created_at":"2026-01-16T10:24:54.565Z","updated_at":"2026-01-16T10:24:54.747Z","avatar_url":"https://github.com/bressanmarcos.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cimrdf.py - An open source tool to handle CIM RDF (IEC 61970-501) documents in Python\nGenerate Python data structures from CIM RDF profiles, parse and serialize CIM-compliant information objects, according to IEC 61970-501 standard.\n\nWith it, it is possible to convert a CIM RDF document in XML format to a Python module (.py) containing a class structure. This module can be used later to create, serialize, read and export RDF / XML documents that follow the semantics of the original RDFS document used during its generation.\n\nThe utility applies the specifications of the IEC 61970-501 standard for the treatment of RDF documents. I tried to develop it in a way that made its use as simple as possible at the time of development.\n\nIf you want to contribute to the project (new features, code refactoring, test coverage ...), don't hesitate to open a new pull request.\n\n## Installing\n\n```bash\n$ pip install cimrdf.py\n```\nor\n```bash\n$ git clone https://github.com/bressanmarcos/cimrdf.py.git\n$ cd cimrdf.py\n$ python setup.py install \n```\n\n## Using\n1. Create your CIM RDF artifact with your preferred utils\n2. Convert it into Python data structures with:\n```\ncimrdfpy input-rdfs.xml output.py\n```\n\n## Creating CIM RDF instances\n3. Use the generated classes from output.py to create your instances\n```python\nfrom output import *\n\nei = EquivalentInjection()\nei.mRID = 'EquivalentNW243'\nt = Terminal()\nt.sequenceNumber = 1\n# This next command reciprocally associates the `t` Terminal to `ei` EquivalentInjection,\nt.ConductingEquipment = ei\n# but only if this association is well-defined in the RDFS document (inverseRoleName property).\n\nt1 = Terminal(sequenceNumber=1)\nt2 = Terminal()\nt2.sequenceNumber = 2\ns = Switch(mRID='SW12', normalOpen=True)\n# All attributes with multiplicity greater than 1 are represented as lists\ns.add_Terminals(t1)\n# A special function `add_{attribute_name}` is generated to insert a single item into the list\ns.add_Terminals(t2)\n\ncn = ConnectivityNode()\ncn.mRID = 'Node23'\n# List-type attributes may also be declared in the following way:\ncn.Terminals = [t1, t] \n```\n\n4. Create a new document instance with all objects\n```python\nnew_doc = DocumentCIMRDF()\nnew_doc.add_recursively(ei)\n# \u003e\u003e All other linked objects will be automatically inserted into the document\n```\nThe available methods for the `DocumentCIMRDF` class are:\n  * **new_doc.dump()**: Pretty-Print the document to stdout. Debug purposes only.\n  * **new_doc.pack()**: Generate the document's ElementTree (xml.etree.ElementTree) instance.\n  * **new_doc.tostring()**: Get the XML stringified version of the document.\n  * **new_doc.tofile()**: Save the XML stringified version of the document to a file.\n  * **new_doc.add_recursively( ... )**: (Recommended) Insert one or a list of elements into the document including its linked elements.\n  * **new_doc.add_elements( ... )**: (Advanced users only) Insert one or a list of elements into the document.\n  \n## Parsing CIM RDF instances\n5. Use proper functions to parse a file or a string.\n```python\nnew_doc = DocumentCIMRDF()\nnew_doc.fromstring(rdfstring)\nprint(new_doc.resources)\n# \u003e\u003e [list of instances]\n```\nThe available functions are:\n  * **new_doc.fromstring(rdfstring)**: Get list of instances from CIM RDF string.\n  * **new_doc.fromfile(filename)**: Get list of instances from CIM RDF file.\n\nAfter being inserted or parsed from a string/file, the elements are stored and accessible from the `new_doc.resources` attribute.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbressanmarcos%2Fcimrdf.py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbressanmarcos%2Fcimrdf.py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbressanmarcos%2Fcimrdf.py/lists"}