Comments (9)
@Rohan-cod okay now I understand why there were such changes but don't you think it is useless to have a temp variable made in memory not only just to give it away it next line but also to keep in memory until it is dumped
in short double memory usage will be there and unnecessary time will be used as it is been done at multiple places
and also as code reader it is confusing to see a variable been made and not been use later
like for example
if 'code' in j['valueCodeableConcept']['coding'][0]\
.keys(
):
t = j['valueCodeableConcept']['coding'][0]["code"]
od_componentvalue_codeable_concept["code"] = t
this looks much simpler to understand
if 'code' in j['valueCodeableConcept']['coding'][0].keys():
od_componentvalue_codeable_concept["code"] = j['valueCodeableConcept']['coding'][0]["code"]
from vcf2fhir.
You are absolutely correct @abhishek-jain-1999. If you have any other way to conform to the rule of having no more than 79 characters in a single line you can do that, but using od_componentvalue_codeable_concept["code"] = j['valueCodeableConcept']['coding'][0]["code"]
will cause the checks to fail.
from vcf2fhir.
@Rohan-cod Thanks for your response . Let me see if I am able to find another way to handle this issue
from vcf2fhir.
@rhdolin @srgothi92 please tell me if this cannot be considered as an issue or if there something relate to this code that I am not aware of
from vcf2fhir.
@abhishek-jain-1999, the code was od_componentvalue_codeable_concept["system"] = j['valueCodeableConcept']['coding'][0]["system"]
before and I changed it to
temp = j['valueCodeableConcept']['coding'][0]["system"]
od_componentvalue_codeable_concept["system"] = temp
because according to PEP 8 we can only have 79 characters in a line.
from vcf2fhir.
No Problem @abhishek-jain-1999
from vcf2fhir.
@abhishek-jain-1999, I figured out a way to do this. I missed it while I was changing the code
Changing the code from
if 'code' in j['valueCodeableConcept']['coding'][0]\
.keys(
):
t = j['valueCodeableConcept']['coding'][0]["code"]
od_componentvalue_codeable_concept["code"] = t
to
if 'code' in j['valueCodeableConcept']['coding'][0]\
.keys(
):
od_componentvalue_codeable_concept["code"] =\
j['valueCodeableConcept']['coding'][0]["code"]
and doing the same at other locations will help you remove most of the temporary variables.
Just an option. Completely up to you, if you want you can use my approach.
from vcf2fhir.
Nice work everyone, I really like the conversation that is happening in each issues and PR.
Contributors Cheers
from vcf2fhir.
Nice work everyone, I really like the conversation that is happening in each issues and PR.
Contributors Cheers
🍷
Cheers @srgothi92
from vcf2fhir.
Related Issues (20)
- Installation succeeds; "import vcf2fhir" fails HOT 2
- vcf2fhir fails to install HOT 2
- Question: how to scale up vcf2fhir HOT 3
- Getting Wheel error for command pip install vcf2fhir HOT 3
- Conversion not returning all variant entries HOT 4
- To resolve Resource Warning : unclosed file HOT 32
- GitHub Action to build and publish Python package to PyPI HOT 3
- Resource Warning due to the PyVCF3 library HOT 1
- Add genomic source class to variant observations HOT 4
- Error when conversion region wasn't studied HOT 1
- Support vcf2fhir on windows !
- conversion between 0-based and 1-based coordinate systems
- Extract simple variants based on conversion region HOT 1
- Deploy vcf2fhir on the bioconda channel
- Setup Dependabot for dependency updates
- Add Support for clinical annotations
- genetic variant assessment should be 'absent' when GT=0/0 HOT 3
- Add badges in Readme for higher visibility of project
- Create and add Project logo
- Incorrect output when ALT is a multi-valued list
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vcf2fhir.