Commit 127f263f authored by H.G.A.G.Hathnapitiya's avatar H.G.A.G.Hathnapitiya

Add new file

parent 85d4374c
#!/usr/bin/env python
# coding: utf-8
# In[1]:
Day = int(input("Press Enter to continue..."))
# In[2]:
Day
# In[3]:
import pandas as pd
dataset = pd.read_excel("Plant_Life_Cycle_dataset3.xlsx")
# In[4]:
dataset["Days"] = dataset["Days"].fillna(0)
# In[5]:
dataset = dataset.astype({'Days':'int'})
# In[6]:
record = dataset.loc[dataset["Days"] == Day]
# In[7]:
record
# In[8]:
min_Height = record._get_value(Day-1,'min_Height')
max_Height = record._get_value(Day-1,"max_Height")
min_Leaves = record._get_value(Day-1,"min_Leaves")
max_Leaves = record._get_value(Day-1,"max_Leaves")
min_Area = record._get_value(Day-1,"min_Area")
max_Area = record._get_value(Day-1,"max_Area")
Remarks = record._get_value(Day-1,"Remarks")
# In[9]:
source = '7.jpeg'
# In[10]:
get_ipython().system('python NewdetectforIpynb.py --weight best.pt --source {source} --min_Height {min_Height} --max_Height {max_Height} --min_Leaves {min_Leaves} --max_Leaves {max_Leaves} --min_Area {min_Area} --max_Area {max_Area}')
# In[11]:
recommendation = pd.read_csv("test.csv")
# In[12]:
State = recommendation._get_value(0,"State")
recomnd1 = recommendation._get_value(0,"recommendation1")
recomnd2 = recommendation._get_value(0,"recommendation2")
print(f'State Of the Plant is -- {State}')
if len(str(recomnd2)) > 5:
print(f'Recommendation to the Plant is -- {recomnd2}')
if len(str(recomnd1)) > 5:
print(f'Recommendation to the Plant is -- {recomnd1}')
# In[ ]:
# In[ ]:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment