# Go to the root directoy of the project and install the build by typing :
sudo python3 setup.py install
# Using the package :
## import by typing :
from bmiankdos import BMICalc
## Create instance and pass the json file :
obj = BMICalc('<your_path_to_json_file>')
## Call the driver method :
obj.driver_method()
## Print table :
print(obj._out[0])
## Print Conclusions:
print(obj.__out[1])
# Go to the root directoy of the project and install the requirements :
sudo pip3 install -r requirements.txt
# For testing the file, go to root directory and type :
python3 -m pytest bmiankdos/tests
# For running the file, go to root directory and type :
python3 -m bmiankdos.module
The idea was to parse a very large JSON file . I was looking for some library that could stream the json file something like StreamingHttpResponse in Django for streaming large files . I came across this package called ijson which works efficiently with large JSON files by leveraging generator iterators and yield expressions to avoid loading the entire structure in memory at once.
Using ijson library we can process very large JSON files .