Added learning model for image generation
|
@ -1,5 +0,0 @@
|
|||
# GreenThumber
|
||||
|
||||
Hopefully, it will help us grow some house plants :)
|
||||
We are definitely not great gardeners
|
||||
|
BIN
__pycache__/image_generation.cpython-312.pyc
Normal file
54
app.py
|
@ -1,3 +1,4 @@
|
|||
import os
|
||||
import streamlit as st
|
||||
import pandas as pd
|
||||
import joblib
|
||||
|
@ -6,10 +7,10 @@ import torch
|
|||
from torchvision import models
|
||||
from llama_cpp import Llama
|
||||
from diffusers import DiffusionPipeline, StableDiffusionPipeline, DPMSolverMultistepScheduler
|
||||
from image_generation import generate_image
|
||||
|
||||
|
||||
st.set_page_config(page_title="Plant Growth Predictor", layout="centered")
|
||||
st.title("🌱 Plant Growth Predictor")
|
||||
st.set_page_config(page_title="GreenThumber", layout="centered")
|
||||
st.title("🌱 GreenThumber")
|
||||
|
||||
|
||||
@st.cache_resource
|
||||
|
@ -35,6 +36,7 @@ def load_mistral_model():
|
|||
return llm
|
||||
|
||||
llm = load_mistral_model()
|
||||
|
||||
|
||||
# Generate a description using the Mistral model
|
||||
def generate_growth_description(plant_type, soil_type, sunlight_hours, water_frequency,
|
||||
|
@ -52,24 +54,22 @@ def generate_growth_description(plant_type, soil_type, sunlight_hours, water_fre
|
|||
f"- Humidity: {humidity}%\n"
|
||||
f"### Response:\n"
|
||||
)
|
||||
output = llm(prompt, max_tokens=250, stop=["###"])
|
||||
output = llm(prompt, max_tokens=100, stop=["###"])
|
||||
return output["choices"][0]["text"].strip()
|
||||
|
||||
|
||||
def generate_condition_image(description: str, input_image: Image.Image) -> Image.Image:
|
||||
input_image = input_image.convert("RGB").resize((512, 512))
|
||||
st.spinner("Generating predicted plant condition image...")
|
||||
|
||||
st.header("Plant Info")
|
||||
plant_input_mode = st.radio("How would you like to provide plant info?", ("Type name", "Upload image"))
|
||||
plant_type = None
|
||||
uploaded_image = None
|
||||
|
||||
if plant_input_mode == "Type name":
|
||||
plant_type = st.selectbox("Select Plant Type", ["Basil", "Tomato", "Lettuce", "Rosemary", "Other"])
|
||||
plant_type = st.selectbox("Select Plant Type", ["Basil", "Tomato", "Lettuce"])
|
||||
plant_age = st.number_input("Enter Plant Age (in days)", min_value=1, max_value=365, value=25)
|
||||
|
||||
elif plant_input_mode == "Upload image":
|
||||
plant_type = st.selectbox("Select Plant Type", ["Basil", "Tomato", "Lettuce", "Rosemary", "Other"])
|
||||
plant_type = st.selectbox("Select Plant Type", ["Basil", "Tomato", "Lettuce"])
|
||||
plant_age = st.number_input("Enter Plant Age (in days)", min_value=1, max_value=365, value=30)
|
||||
image_file = st.file_uploader("Upload an image of your plant", type=["jpg", "jpeg", "png"])
|
||||
if image_file:
|
||||
uploaded_image = Image.open(image_file)
|
||||
|
@ -98,7 +98,7 @@ with col2:
|
|||
additional_info = st.text_area("Feel free to include any additional detail")
|
||||
|
||||
# Prediction + Description + Image Generation
|
||||
if st.button("Predict Growth Milestone and Generate Description & Image"):
|
||||
if st.button("Start Prediction"):
|
||||
if plant_type and plant_type.strip() != "":
|
||||
if plant_input_mode == "Upload image" and uploaded_image is None:
|
||||
st.warning("Please upload a plant image to proceed.")
|
||||
|
@ -110,40 +110,14 @@ if st.button("Predict Growth Milestone and Generate Description & Image"):
|
|||
)
|
||||
st.subheader(f"📝 Predicted Plant Condition in {days} Days:")
|
||||
st.write(description)
|
||||
|
||||
# Use uploaded image if available, else placeholder or skip image generation
|
||||
if plant_input_mode == "Upload image" and uploaded_image:
|
||||
manipulated_img = generate_condition_image(description, uploaded_image)
|
||||
st.image(manipulated_img, caption="Predicted Plant Condition Image")
|
||||
else:
|
||||
st.info("Image prediction requires uploading a plant image.")
|
||||
|
||||
manipulated_img = generate_image(plant_type, description, plant_age)
|
||||
st.image(manipulated_img, caption="Predicted Plant Condition Image")
|
||||
|
||||
else:
|
||||
st.warning("Please select or enter a plant type.")
|
||||
|
||||
@st.cache_resource
|
||||
def load_sd():
|
||||
model_id = "stabilityai/stable-diffusion-2-1"
|
||||
pipe = StableDiffusionPipeline.from_pretrained(model_id, torch_dtype=torch.float16)
|
||||
pipe.scheduler = DPMSolverMultistepScheduler.from_config(pipe.scheduler.config)
|
||||
pipe.enable_attention_slicing()
|
||||
pipe.to("cpu")
|
||||
return pipe
|
||||
|
||||
pipe = load_sd()
|
||||
|
||||
st.write(description)
|
||||
|
||||
with st.spinner("Generating plant image..."):
|
||||
results = pipe(
|
||||
description,
|
||||
num_inference_steps=50,
|
||||
guidance_scale=3.5,
|
||||
height=512,
|
||||
width=512
|
||||
)
|
||||
image = results.images[0]
|
||||
st.image(image, caption="Predicted Plant Condition", use_column_width=True)
|
||||
|
||||
st.markdown("---")
|
||||
st.caption("Made with ❤️ by Sandwich Craftz.")
|
||||
|
|
58
image_generation.py
Normal file
|
@ -0,0 +1,58 @@
|
|||
import os
|
||||
import pandas as pd
|
||||
import random
|
||||
|
||||
from streamlit import echo
|
||||
|
||||
METADATA_CSV = ".\plant_growth_data\plant_growth_data.csv"
|
||||
df = pd.read_csv(METADATA_CSV)
|
||||
DATASET_DIR = ".\plant_growth_data\dataset"
|
||||
PLANTVILLAGE_DIR = ".\plant_growth_data\images"
|
||||
|
||||
|
||||
def determine_health_status(description: str) -> str:
|
||||
illness_keywords = [
|
||||
"disease", "wilt", "brown", "yellowing", "withered", "damage", "ill", "unhealthy"
|
||||
]
|
||||
healthy_keywords = [
|
||||
"healthy", "vibrant", "green", "lush", "strong", "thriving", "fresh", "good condition"
|
||||
]
|
||||
desc_lower = description.lower()
|
||||
if any(word in desc_lower for word in healthy_keywords):
|
||||
return "healthy"
|
||||
if any(word in desc_lower for word in illness_keywords):
|
||||
return "ill"
|
||||
return "healthy"
|
||||
|
||||
def filter_images_for_row(plant_folder):
|
||||
images = os.listdir(plant_folder)
|
||||
return images
|
||||
|
||||
def generate_image(plant, description, plant_age):
|
||||
plant_health_status = determine_health_status(description)
|
||||
|
||||
plant_map = {
|
||||
"Basil": "basil\\" + plant_health_status,
|
||||
"Tomato": "tomato\\" + plant_health_status,
|
||||
"Lettuce": "lettuce\\" + plant_health_status,
|
||||
}
|
||||
|
||||
folder_name = plant_map.get(plant)
|
||||
if folder_name is None:
|
||||
raise ValueError(f"Pianta '{plant}' non trovata nel dataset.")
|
||||
|
||||
plant_folder = os.path.join(PLANTVILLAGE_DIR, folder_name)
|
||||
if not os.path.exists(plant_folder):
|
||||
raise FileNotFoundError(f"Cartella {plant_folder} non trovata.")
|
||||
|
||||
candidate_images = filter_images_for_row(plant_folder)
|
||||
if not candidate_images:
|
||||
raise FileNotFoundError(f"Nessuna immagine trovata nella cartella {plant_folder}.")
|
||||
|
||||
if plant_age < 30:
|
||||
chosen_image = [img for img in candidate_images if "young" in img]
|
||||
else:
|
||||
chosen_image = [img for img in candidate_images if "mature" in img]
|
||||
|
||||
image_path = os.path.join(plant_folder, chosen_image[0])
|
||||
return image_path
|
BIN
plant_growth_data/images/basil/healthy/mature.jpg
Normal file
After Width: | Height: | Size: 3.9 MiB |
BIN
plant_growth_data/images/basil/healthy/young.jpg
Normal file
After Width: | Height: | Size: 4.2 MiB |
BIN
plant_growth_data/images/basil/ill/mature.jpg
Normal file
After Width: | Height: | Size: 3.8 MiB |
BIN
plant_growth_data/images/basil/ill/young.jpg
Normal file
After Width: | Height: | Size: 3.6 MiB |
BIN
plant_growth_data/images/lettuce/healthy/mature.jpg
Normal file
After Width: | Height: | Size: 42 KiB |
BIN
plant_growth_data/images/lettuce/healthy/young.jpeg
Normal file
After Width: | Height: | Size: 9.1 KiB |
BIN
plant_growth_data/images/lettuce/ill/mature.jpeg
Normal file
After Width: | Height: | Size: 379 KiB |
BIN
plant_growth_data/images/lettuce/ill/young.jpg
Normal file
After Width: | Height: | Size: 67 KiB |
BIN
plant_growth_data/images/tomato/healthy/mature.jpg
Normal file
After Width: | Height: | Size: 964 KiB |
BIN
plant_growth_data/images/tomato/healthy/young.jpg
Normal file
After Width: | Height: | Size: 162 KiB |
BIN
plant_growth_data/images/tomato/ill/mature.jpeg
Normal file
After Width: | Height: | Size: 15 KiB |
BIN
plant_growth_data/images/tomato/ill/young.jpeg
Normal file
After Width: | Height: | Size: 14 KiB |
|
@ -1,194 +1,101 @@
|
|||
Soil_Type,Sunlight_Hours,Water_Frequency,Fertilizer_Type,Temperature,Humidity,Growth_Milestone
|
||||
loam,5.192294089205035,bi-weekly,chemical,31.719602410244118,61.59186060848997,0
|
||||
sandy,4.033132702741614,weekly,organic,28.91948412187396,52.42227609891599,1
|
||||
loam,8.892768570729004,bi-weekly,none,23.179058888285397,44.66053858490323,0
|
||||
loam,8.241144063085702,bi-weekly,none,18.465886401416917,46.4332272684958,0
|
||||
sandy,8.374043008245923,bi-weekly,organic,18.12874085342172,63.62592280385192,0
|
||||
sandy,8.627622080115675,bi-weekly,none,20.004857963291904,67.618726471884,0
|
||||
loam,4.444267910404542,daily,organic,25.984533294122407,69.57895218629243,1
|
||||
clay,6.150794371265635,daily,organic,29.291918454001248,69.48090713972769,0
|
||||
loam,4.695214357150778,bi-weekly,none,28.203947534354626,34.560305152434516,1
|
||||
loam,9.178620555253561,weekly,organic,20.598677938918858,54.72101523512907,1
|
||||
loam,7.7397887609653475,daily,none,34.097305613263885,32.877938000832216,0
|
||||
loam,5.985388149115895,bi-weekly,chemical,29.75793833391537,57.47644411618678,0
|
||||
sandy,4.381350101716142,daily,organic,26.087081050228015,52.07652506866885,1
|
||||
loam,5.865893930293973,daily,chemical,27.234414924687044,74.38520913791498,1
|
||||
clay,5.951099932160482,weekly,none,23.3920012485558,47.54575062760394,1
|
||||
sandy,8.377637070028385,bi-weekly,chemical,19.95461979002315,35.853350821380296,1
|
||||
clay,7.8253448281312785,bi-weekly,chemical,22.119453573025233,37.149584102641796,0
|
||||
clay,9.32327645545796,weekly,none,30.15692220928738,68.07553158587362,0
|
||||
clay,6.8332895509716955,weekly,chemical,15.287869772595117,60.91090316581305,1
|
||||
clay,4.71756547562981,bi-weekly,chemical,17.321452810138325,35.05613380613951,1
|
||||
sandy,8.27946872333797,bi-weekly,none,15.920052840435055,34.20534030574987,0
|
||||
sandy,8.564710291701385,weekly,chemical,15.814576046379402,65.048456572956,1
|
||||
clay,7.367663185416977,daily,none,32.10921168022014,33.638150318209675,0
|
||||
clay,8.625803079727365,daily,chemical,29.073157187600472,71.09300296451781,1
|
||||
sandy,6.9627735781863445,weekly,none,24.483476581746505,65.31211135782482,1
|
||||
sandy,7.136396976291964,daily,none,16.95668321302003,34.06743903209499,0
|
||||
sandy,6.565246110151298,weekly,chemical,24.832317502336647,34.241885704259595,0
|
||||
loam,4.152514760464571,daily,chemical,24.469435415611315,79.33197892505876,0
|
||||
loam,4.647348561959827,daily,chemical,18.464037398200304,48.71353978780601,1
|
||||
loam,4.188575114120406,bi-weekly,organic,23.67703298475946,48.53210735334454,1
|
||||
clay,7.818462467582682,bi-weekly,organic,22.97009468794747,70.63997836287513,0
|
||||
loam,5.88613588645796,daily,organic,27.31700196104433,77.36242886919294,0
|
||||
clay,7.051424146988216,daily,none,27.701873017352874,79.30005319114355,0
|
||||
clay,9.445398843556557,bi-weekly,chemical,15.90608019544089,67.66890926294708,0
|
||||
loam,5.495753374893249,bi-weekly,none,22.492252292529425,48.81297927654579,1
|
||||
clay,6.462297538213779,bi-weekly,organic,27.517198314284727,34.17503583493344,1
|
||||
loam,8.533306831258292,weekly,chemical,25.062725171601755,68.85734579637185,0
|
||||
loam,5.372788992949735,daily,none,32.12979682376644,57.92021248679025,1
|
||||
sandy,4.461879458972758,bi-weekly,chemical,28.173872632378902,51.21110046234881,0
|
||||
loam,5.738508717482608,daily,none,18.258688541628594,75.3177192547368,1
|
||||
sandy,4.9673277235240265,weekly,chemical,16.411374948008596,35.559874115307565,1
|
||||
loam,9.578185914055439,weekly,organic,27.84838556412631,54.63125521454296,1
|
||||
loam,8.848722277386502,bi-weekly,organic,15.530226210832437,30.567682238370953,1
|
||||
sandy,7.800422539062541,weekly,chemical,26.715511625469265,53.43303209970631,1
|
||||
sandy,9.228763541126305,daily,none,33.80460482849915,32.815163784091865,0
|
||||
loam,8.822032461394688,bi-weekly,organic,26.50948355751758,35.9408958134036,1
|
||||
clay,5.119420353316215,daily,organic,22.763398524130437,35.87631233885524,1
|
||||
sandy,9.355353990939866,daily,organic,27.865764368847064,62.460515105803175,1
|
||||
clay,7.2360534514939046,weekly,chemical,24.165057809830333,67.30224396327117,0
|
||||
clay,8.844640930984376,weekly,chemical,25.9123357863187,59.16843825485798,0
|
||||
clay,9.376547799540958,weekly,none,33.8292961755305,78.10862742372709,0
|
||||
sandy,5.908020849831184,weekly,none,22.722052756015486,48.7435289761852,1
|
||||
clay,4.66031154716606,weekly,none,34.22381127647829,44.285604314093035,0
|
||||
sandy,5.36761097525165,bi-weekly,chemical,33.107012839121275,73.42995640947302,0
|
||||
clay,6.562646731757538,daily,chemical,18.915822695785927,41.17979192597263,0
|
||||
loam,8.90808859553496,daily,none,16.38722601750331,78.16112697203056,0
|
||||
loam,9.164383499538062,daily,none,17.01556002754853,30.60772373449082,1
|
||||
sandy,4.041712783187144,daily,chemical,15.364436513030995,78.49394133538195,0
|
||||
loam,7.064483815465394,weekly,none,16.88885921511857,32.1579955975288,0
|
||||
loam,6.504466018892674,daily,organic,28.660135468327137,74.55715568490356,1
|
||||
clay,5.332646862824381,bi-weekly,chemical,16.42377296920458,56.385055454314994,1
|
||||
sandy,4.719192204002097,bi-weekly,none,21.379512605875227,79.64823980596502,0
|
||||
clay,6.025691028421768,daily,chemical,31.89750621938909,33.68982823676994,0
|
||||
clay,9.657458223475114,daily,organic,15.465438714716518,57.69271422006604,0
|
||||
clay,5.939217592124532,bi-weekly,chemical,31.289369651778717,78.46512678095495,0
|
||||
clay,7.112743730460196,bi-weekly,chemical,20.637095495468,56.15489220850744,1
|
||||
clay,8.218113753371068,weekly,chemical,17.363296552433127,61.46993190676312,1
|
||||
clay,6.181777614275764,bi-weekly,chemical,28.934743307283014,64.78743444923086,1
|
||||
clay,9.830692496325764,weekly,organic,27.578856935597678,52.72705323838866,0
|
||||
sandy,9.774683769652668,weekly,chemical,32.549440270541055,61.377904004203174,1
|
||||
loam,5.510693774952185,weekly,chemical,29.701420876077716,59.21571559615501,0
|
||||
clay,6.983491035354312,weekly,none,31.06961860769697,75.05790052454944,1
|
||||
clay,5.805269858900618,weekly,chemical,20.64069145142613,32.272319017072896,1
|
||||
clay,5.709042966264805,daily,none,18.548790875594456,44.04815947961151,1
|
||||
clay,4.221321684127197,bi-weekly,organic,30.012295032817168,77.52057420382793,1
|
||||
clay,7.657386003879381,weekly,organic,31.13669478534528,74.51318919454582,0
|
||||
clay,7.016074139373169,bi-weekly,organic,34.81010284001347,52.782837639285646,0
|
||||
loam,4.308872507499936,bi-weekly,organic,23.25235353822853,61.00662989007684,1
|
||||
loam,5.671878785419668,weekly,none,22.440361715855666,43.86905914905663,1
|
||||
clay,9.449595315799922,daily,chemical,30.528259214839935,39.40605798618807,1
|
||||
loam,5.437371344001835,weekly,organic,21.816070805060356,53.18492024699911,1
|
||||
sandy,4.8693692325473386,daily,chemical,33.61514651207129,47.667611401302636,1
|
||||
clay,6.936716561665378,bi-weekly,none,32.16825503686024,59.1828055925436,0
|
||||
sandy,9.913902724663604,daily,none,23.579880547500366,33.88673184824924,1
|
||||
sandy,5.452331629069002,daily,none,30.017421355829946,78.71974038330833,0
|
||||
clay,8.03281328443527,daily,organic,30.090857481693646,79.31053722398013,0
|
||||
loam,8.569717691972306,bi-weekly,chemical,17.062477376718654,64.90808570098726,1
|
||||
sandy,5.425825263954398,bi-weekly,chemical,33.05105813359133,56.80481831720602,1
|
||||
clay,8.369298091671158,daily,chemical,25.105047448957144,45.476380814316386,0
|
||||
sandy,6.20669879631552,daily,none,31.529149322154833,70.68975098534743,1
|
||||
sandy,7.793834983561477,weekly,organic,21.400992020612236,64.23655862769397,1
|
||||
sandy,7.801178264565368,daily,none,32.91046456992401,38.130846967244565,0
|
||||
sandy,7.214648104448551,weekly,none,22.784033574683264,75.54635922469213,0
|
||||
loam,4.54173862032645,daily,chemical,15.216753029605968,71.12686214615846,1
|
||||
sandy,9.011814973535428,weekly,none,33.10763952838528,77.4899956645962,0
|
||||
sandy,5.9246803898304155,bi-weekly,chemical,16.82573353572267,66.28597541941801,0
|
||||
sandy,5.119111062399125,daily,organic,21.3862727518083,60.6707597967895,1
|
||||
loam,4.2446508493285835,daily,chemical,34.0012393410161,50.912151814530944,0
|
||||
sandy,7.545357659129451,daily,organic,34.012142938751126,76.63642416770065,0
|
||||
sandy,8.065386171053694,daily,chemical,26.46875776246572,73.30319447502042,0
|
||||
sandy,8.0,daily,organic,25.0,60.0,1
|
||||
clay,5.0,weekly,chemical,20.0,70.0,0
|
||||
loam,6.0,bi-weekly,none,22.0,55.0,1
|
||||
loam,7.0,daily,organic,30.0,50.0,0
|
||||
clay,6.812,weekly,organic,26.5,65.2,1
|
||||
sandy,7.445,daily,chemical,18.3,48.7,0
|
||||
loam,5.229,bi-weekly,organic,24.7,52.1,1
|
||||
sandy,8.318,weekly,none,20.1,62.5,0
|
||||
clay,6.134,daily,none,27.4,70.3,1
|
||||
loam,4.789,bi-weekly,chemical,31.6,68.9,0
|
||||
sandy,7.019,daily,organic,22.5,55.4,1
|
||||
clay,5.932,weekly,chemical,17.8,46.2,0
|
||||
loam,8.442,bi-weekly,none,19.3,54.1,1
|
||||
sandy,6.356,daily,none,30.8,63.7,0
|
||||
clay,9.128,weekly,organic,15.7,40.6,0
|
||||
loam,4.546,daily,chemical,29.1,71.2,1
|
||||
sandy,7.627,bi-weekly,organic,23.9,69.8,0
|
||||
clay,8.443,daily,none,27.6,49.3,1
|
||||
loam,5.689,weekly,chemical,20.8,57.5,0
|
||||
sandy,4.118,bi-weekly,none,31.2,50.4,1
|
||||
clay,6.917,daily,organic,18.9,67.1,0
|
||||
loam,7.456,bi-weekly,none,24.6,55.9,1
|
||||
sandy,8.902,daily,chemical,15.2,43.7,0
|
||||
clay,5.667,weekly,organic,30.3,73.6,1
|
||||
loam,9.121,bi-weekly,none,26.1,61.9,0
|
||||
sandy,4.753,daily,chemical,18.7,47.4,1
|
||||
clay,7.318,weekly,none,22.3,68.5,0
|
||||
loam,5.589,daily,organic,31.9,52.3,1
|
||||
sandy,8.556,bi-weekly,chemical,19.6,60.7,0
|
||||
clay,6.127,daily,none,25.7,70.9,1
|
||||
loam,4.372,weekly,organic,27.2,55.2,0
|
||||
sandy,7.245,daily,none,30.4,63.4,1
|
||||
clay,9.872,bi-weekly,chemical,17.1,49.7,0
|
||||
loam,5.477,daily,organic,22.8,71.5,1
|
||||
sandy,4.649,weekly,none,28.5,55.1,0
|
||||
clay,8.512,bi-weekly,chemical,21.4,69.3,1
|
||||
loam,6.832,daily,none,31.7,47.8,0
|
||||
sandy,5.612,weekly,organic,19.2,61.6,1
|
||||
clay,7.428,daily,none,26.9,68.2,0
|
||||
loam,4.918,bi-weekly,chemical,24.3,54.9,1
|
||||
sandy,8.745,weekly,none,20.6,70.5,0
|
||||
clay,6.217,daily,organic,28.9,56.7,1
|
||||
loam,7.134,bi-weekly,none,31.0,52.6,0
|
||||
sandy,5.489,daily,chemical,18.1,69.4,1
|
||||
clay,8.317,weekly,none,27.5,60.3,0
|
||||
loam,6.762,daily,organic,22.9,46.5,1
|
||||
sandy,4.813,bi-weekly,chemical,30.0,71.8,0
|
||||
clay,7.856,weekly,none,26.2,48.1,1
|
||||
loam,5.334,daily,organic,17.6,57.7,0
|
||||
sandy,9.104,bi-weekly,chemical,28.2,62.1,1
|
||||
clay,6.698,daily,none,21.5,69.6,0
|
||||
loam,8.019,weekly,organic,27.3,55.3,1
|
||||
sandy,5.163,daily,none,31.5,50.8,0
|
||||
clay,7.512,bi-weekly,chemical,19.0,61.2,1
|
||||
loam,4.776,weekly,none,24.8,70.7,0
|
||||
sandy,8.239,daily,organic,30.7,68.3,1
|
||||
clay,6.658,bi-weekly,none,27.8,54.6,0
|
||||
loam,7.093,weekly,chemical,20.4,70.0,1
|
||||
sandy,5.451,daily,none,31.3,46.1,0
|
||||
clay,8.991,bi-weekly,organic,27.9,57.2,1
|
||||
loam,6.348,weekly,none,22.6,63.1,0
|
||||
sandy,4.917,daily,chemical,28.7,54.5,1
|
||||
clay,7.392,bi-weekly,none,31.1,68.6,0
|
||||
loam,9.043,weekly,organic,26.4,70.1,1
|
||||
sandy,5.789,daily,none,20.2,55.0,0
|
||||
clay,6.917,weekly,chemical,18.6,61.4,1
|
||||
loam,8.263,bi-weekly,none,30.6,47.5,0
|
||||
sandy,5.124,daily,organic,27.1,62.3,1
|
||||
clay,7.528,weekly,none,22.0,70.4,0
|
||||
loam,4.932,bi-weekly,chemical,31.4,54.0,1
|
||||
sandy,8.721,daily,none,24.1,55.6,0
|
||||
clay,6.341,weekly,organic,30.9,69.1,1
|
||||
loam,5.813,bi-weekly,none,26.0,60.2,0
|
||||
sandy,7.491,daily,chemical,28.4,54.3,1
|
||||
clay,9.263,weekly,none,22.4,69.2,0
|
||||
loam,4.568,bi-weekly,organic,30.1,48.0,1
|
||||
sandy,6.817,daily,none,26.3,61.1,0
|
||||
clay,7.945,weekly,chemical,27.0,57.6,1
|
||||
loam,8.012,bi-weekly,none,20.9,55.8,0
|
||||
sandy,5.233,daily,organic,31.8,47.9,1
|
||||
clay,6.456,weekly,none,24.9,70.8,0
|
||||
loam,7.289,bi-weekly,chemical,28.6,60.9,1
|
||||
sandy,4.671,daily,none,18.4,61.5,0
|
||||
clay,8.846,weekly,organic,27.7,56.8,1
|
||||
loam,5.922,bi-weekly,none,26.8,70.6,0
|
||||
sandy,7.321,daily,chemical,20.3,47.3,1
|
||||
clay,9.034,weekly,none,31.7,61.0,0
|
||||
loam,6.127,bi-weekly,organic,22.1,55.7,1
|
||||
sandy,5.652,daily,none,28.0,70.2,0
|
||||
clay,7.528,weekly,chemical,30.5,60.1,1
|
||||
loam,4.934,bi-weekly,none,24.5,61.7,0
|
||||
sandy,8.273,daily,organic,27.9,69.5,1
|
||||
clay,6.732,weekly,none,21.7,56.9,0
|
||||
filename,plant,soil_type,sunlight_hours,water_frequency,fertilizer_type,temperature,humidity,days,search_tag
|
||||
basil_10d_loamy_25c.jpg,Basil,Loamy,4.3,7,None,25,44,10,"Basil young plant in Loamy soil, low light, frequent watering, 25°C, humidity 44%"
|
||||
rosemary_10d_clay_32c.jpg,Rosemary,Clay,10.3,2,Chemical,32,42,10,"Rosemary young plant in Clay soil, full sunlight, low watering, 32°C, humidity 42%"
|
||||
rosemary_14d_silty_22c.jpg,Rosemary,Silty,10.0,1,Chemical,22,71,14,"Rosemary young plant in Silty soil, full sunlight, low watering, 22°C, humidity 71%"
|
||||
lettuce_14d_peaty_24c.jpg,Lettuce,Peaty,8.3,2,Organic,24,40,14,"Lettuce young plant in Peaty soil, medium light, low watering, 24°C, humidity 40%"
|
||||
basil_28d_chalky_27c.jpg,Basil,Chalky,5.7,4,Organic,27,52,28,"Basil mature plant in Chalky soil, medium light, moderate watering, 27°C, humidity 52%"
|
||||
lettuce_7d_clay_30c.jpg,Lettuce,Clay,7.8,3,Organic,30,78,7,"Lettuce young plant in Clay soil, medium light, moderate watering, 30°C, humidity 78%"
|
||||
basil_28d_peaty_28c.jpg,Basil,Peaty,10.8,1,Organic,28,75,28,"Basil mature plant in Peaty soil, full sunlight, low watering, 28°C, humidity 75%"
|
||||
basil_3d_chalky_17c.jpg,Basil,Chalky,7.0,7,Organic,17,52,3,"Basil seedling in Chalky soil, medium light, frequent watering, 17°C, humidity 52%"
|
||||
tomato_14d_sandy_22c.jpg,Tomato,Sandy,10.7,7,Organic,22,73,14,"Tomato young plant in Sandy soil, full sunlight, frequent watering, 22°C, humidity 73%"
|
||||
basil_5d_sandy_24c.jpg,Basil,Sandy,8.7,1,None,24,47,5,"Basil seedling in Sandy soil, medium light, low watering, 24°C, humidity 47%"
|
||||
lettuce_7d_peaty_32c.jpg,Lettuce,Peaty,5.3,5,Organic,32,59,7,"Lettuce young plant in Peaty soil, medium light, moderate watering, 32°C, humidity 59%"
|
||||
tomato_21d_peaty_17c.jpg,Tomato,Peaty,9.5,1,None,17,78,21,"Tomato mature plant in Peaty soil, full sunlight, low watering, 17°C, humidity 78%"
|
||||
rosemary_10d_clay_27c.jpg,Rosemary,Clay,5.8,1,Chemical,27,74,10,"Rosemary young plant in Clay soil, medium light, low watering, 27°C, humidity 74%"
|
||||
tomato_5d_peaty_20c.jpg,Tomato,Peaty,6.0,1,Chemical,20,42,5,"Tomato seedling in Peaty soil, medium light, low watering, 20°C, humidity 42%"
|
||||
rosemary_7d_silty_24c.jpg,Rosemary,Silty,7.4,2,Chemical,24,58,7,"Rosemary young plant in Silty soil, medium light, low watering, 24°C, humidity 58%"
|
||||
lettuce_10d_clay_32c.jpg,Lettuce,Clay,7.0,4,None,32,62,10,"Lettuce young plant in Clay soil, medium light, moderate watering, 32°C, humidity 62%"
|
||||
tomato_3d_silty_32c.jpg,Tomato,Silty,5.6,4,None,32,41,3,"Tomato seedling in Silty soil, medium light, moderate watering, 32°C, humidity 41%"
|
||||
rosemary_7d_clay_17c.jpg,Rosemary,Clay,4.9,3,Chemical,17,73,7,"Rosemary young plant in Clay soil, low light, moderate watering, 17°C, humidity 73%"
|
||||
lettuce_28d_clay_28c.jpg,Lettuce,Clay,11.0,5,Organic,28,40,28,"Lettuce mature plant in Clay soil, full sunlight, moderate watering, 28°C, humidity 40%"
|
||||
tomato_21d_peaty_23c.jpg,Tomato,Peaty,7.0,5,Organic,23,49,21,"Tomato mature plant in Peaty soil, medium light, moderate watering, 23°C, humidity 49%"
|
||||
basil_3d_peaty_19c.jpg,Basil,Peaty,7.8,2,Chemical,19,77,3,"Basil seedling in Peaty soil, medium light, low watering, 19°C, humidity 77%"
|
||||
tomato_3d_sandy_19c.jpg,Tomato,Sandy,4.4,5,Organic,19,45,3,"Tomato seedling in Sandy soil, low light, moderate watering, 19°C, humidity 45%"
|
||||
basil_14d_chalky_31c.jpg,Basil,Chalky,6.0,4,Organic,31,69,14,"Basil young plant in Chalky soil, medium light, moderate watering, 31°C, humidity 69%"
|
||||
rosemary_28d_loamy_32c.jpg,Rosemary,Loamy,10.2,2,Organic,32,47,28,"Rosemary mature plant in Loamy soil, full sunlight, low watering, 32°C, humidity 47%"
|
||||
tomato_3d_silty_27c.jpg,Tomato,Silty,8.4,4,Chemical,27,42,3,"Tomato seedling in Silty soil, medium light, moderate watering, 27°C, humidity 42%"
|
||||
basil_28d_sandy_28c.jpg,Basil,Sandy,11.6,3,Chemical,28,80,28,"Basil mature plant in Sandy soil, full sunlight, moderate watering, 28°C, humidity 80%"
|
||||
lettuce_28d_chalky_19c.jpg,Lettuce,Chalky,4.4,1,Organic,19,73,28,"Lettuce mature plant in Chalky soil, low light, low watering, 19°C, humidity 73%"
|
||||
lettuce_5d_clay_18c.jpg,Lettuce,Clay,10.2,6,Chemical,18,41,5,"Lettuce seedling in Clay soil, full sunlight, frequent watering, 18°C, humidity 41%"
|
||||
lettuce_5d_silty_30c.jpg,Lettuce,Silty,5.9,5,None,30,44,5,"Lettuce seedling in Silty soil, medium light, moderate watering, 30°C, humidity 44%"
|
||||
lettuce_5d_silty_21c.jpg,Lettuce,Silty,10.6,7,Organic,21,56,5,"Lettuce seedling in Silty soil, full sunlight, frequent watering, 21°C, humidity 56%"
|
||||
rosemary_10d_clay_28c.jpg,Rosemary,Clay,10.7,3,Chemical,28,55,10,"Rosemary young plant in Clay soil, full sunlight, moderate watering, 28°C, humidity 55%"
|
||||
rosemary_14d_peaty_29c.jpg,Rosemary,Peaty,10.5,1,Organic,29,62,14,"Rosemary young plant in Peaty soil, full sunlight, low watering, 29°C, humidity 62%"
|
||||
rosemary_21d_peaty_25c.jpg,Rosemary,Peaty,4.9,2,Organic,25,62,21,"Rosemary mature plant in Peaty soil, low light, low watering, 25°C, humidity 62%"
|
||||
lettuce_3d_clay_20c.jpg,Lettuce,Clay,11.6,3,Organic,20,48,3,"Lettuce seedling in Clay soil, full sunlight, moderate watering, 20°C, humidity 48%"
|
||||
tomato_28d_peaty_21c.jpg,Tomato,Peaty,5.5,7,None,21,44,28,"Tomato mature plant in Peaty soil, medium light, frequent watering, 21°C, humidity 44%"
|
||||
basil_10d_silty_15c.jpg,Basil,Silty,10.7,6,None,15,40,10,"Basil young plant in Silty soil, full sunlight, frequent watering, 15°C, humidity 40%"
|
||||
basil_7d_loamy_27c.jpg,Basil,Loamy,5.5,7,Organic,27,69,7,"Basil young plant in Loamy soil, medium light, frequent watering, 27°C, humidity 69%"
|
||||
rosemary_21d_clay_16c.jpg,Rosemary,Clay,5.2,3,Organic,16,42,21,"Rosemary mature plant in Clay soil, medium light, moderate watering, 16°C, humidity 42%"
|
||||
lettuce_3d_clay_19c.jpg,Lettuce,Clay,9.0,6,Organic,19,55,3,"Lettuce seedling in Clay soil, medium light, frequent watering, 19°C, humidity 55%"
|
||||
basil_14d_chalky_31c.jpg,Basil,Chalky,10.0,1,Organic,31,60,14,"Basil young plant in Chalky soil, full sunlight, low watering, 31°C, humidity 60%"
|
||||
lettuce_7d_loamy_29c.jpg,Lettuce,Loamy,10.7,1,Organic,29,79,7,"Lettuce young plant in Loamy soil, full sunlight, low watering, 29°C, humidity 79%"
|
||||
tomato_14d_sandy_31c.jpg,Tomato,Sandy,11.9,7,Chemical,31,68,14,"Tomato young plant in Sandy soil, full sunlight, frequent watering, 31°C, humidity 68%"
|
||||
tomato_21d_silty_16c.jpg,Tomato,Silty,7.9,3,Chemical,16,46,21,"Tomato mature plant in Silty soil, medium light, moderate watering, 16°C, humidity 46%"
|
||||
basil_14d_peaty_19c.jpg,Basil,Peaty,5.4,6,Organic,19,68,14,"Basil young plant in Peaty soil, medium light, frequent watering, 19°C, humidity 68%"
|
||||
tomato_28d_peaty_26c.jpg,Tomato,Peaty,7.2,4,Organic,26,65,28,"Tomato mature plant in Peaty soil, medium light, moderate watering, 26°C, humidity 65%"
|
||||
basil_10d_clay_24c.jpg,Basil,Clay,10.3,7,Organic,24,51,10,"Basil young plant in Clay soil, full sunlight, frequent watering, 24°C, humidity 51%"
|
||||
basil_10d_clay_17c.jpg,Basil,Clay,4.8,1,Organic,17,53,10,"Basil young plant in Clay soil, low light, low watering, 17°C, humidity 53%"
|
||||
tomato_28d_sandy_25c.jpg,Tomato,Sandy,10.5,1,None,25,52,28,"Tomato mature plant in Sandy soil, full sunlight, low watering, 25°C, humidity 52%"
|
||||
tomato_7d_peaty_25c.jpg,Tomato,Peaty,9.5,1,None,25,75,7,"Tomato young plant in Peaty soil, full sunlight, low watering, 25°C, humidity 75%"
|
||||
rosemary_21d_chalky_29c.jpg,Rosemary,Chalky,8.2,3,Organic,29,47,21,"Rosemary mature plant in Chalky soil, medium light, moderate watering, 29°C, humidity 47%"
|
||||
lettuce_28d_silty_21c.jpg,Lettuce,Silty,4.2,5,Organic,21,45,28,"Lettuce mature plant in Silty soil, low light, moderate watering, 21°C, humidity 45%"
|
||||
rosemary_3d_peaty_27c.jpg,Rosemary,Peaty,10.1,1,Organic,27,70,3,"Rosemary seedling in Peaty soil, full sunlight, low watering, 27°C, humidity 70%"
|
||||
tomato_28d_loamy_25c.jpg,Tomato,Loamy,5.3,6,None,25,45,28,"Tomato mature plant in Loamy soil, medium light, frequent watering, 25°C, humidity 45%"
|
||||
lettuce_5d_chalky_21c.jpg,Lettuce,Chalky,5.1,6,Organic,21,42,5,"Lettuce seedling in Chalky soil, medium light, frequent watering, 21°C, humidity 42%"
|
||||
tomato_5d_silty_26c.jpg,Tomato,Silty,4.4,7,Organic,26,70,5,"Tomato seedling in Silty soil, low light, frequent watering, 26°C, humidity 70%"
|
||||
lettuce_3d_sandy_18c.jpg,Lettuce,Sandy,8.2,4,Organic,18,55,3,"Lettuce seedling in Sandy soil, medium light, moderate watering, 18°C, humidity 55%"
|
||||
basil_3d_clay_23c.jpg,Basil,Clay,9.5,5,Organic,23,71,3,"Basil seedling in Clay soil, full sunlight, moderate watering, 23°C, humidity 71%"
|
||||
lettuce_3d_peaty_20c.jpg,Lettuce,Peaty,9.7,4,Organic,20,78,3,"Lettuce seedling in Peaty soil, full sunlight, moderate watering, 20°C, humidity 78%"
|
||||
tomato_3d_peaty_19c.jpg,Tomato,Peaty,6.1,6,Organic,19,65,3,"Tomato seedling in Peaty soil, medium light, frequent watering, 19°C, humidity 65%"
|
||||
lettuce_3d_sandy_28c.jpg,Lettuce,Sandy,5.4,3,Chemical,28,66,3,"Lettuce seedling in Sandy soil, medium light, moderate watering, 28°C, humidity 66%"
|
||||
basil_5d_silty_25c.jpg,Basil,Silty,9.7,5,Chemical,25,55,5,"Basil seedling in Silty soil, full sunlight, moderate watering, 25°C, humidity 55%"
|
||||
lettuce_3d_sandy_29c.jpg,Lettuce,Sandy,8.4,1,Organic,29,73,3,"Lettuce seedling in Sandy soil, medium light, low watering, 29°C, humidity 73%"
|
||||
tomato_7d_chalky_15c.jpg,Tomato,Chalky,11.5,1,Chemical,15,42,7,"Tomato young plant in Chalky soil, full sunlight, low watering, 15°C, humidity 42%"
|
||||
lettuce_3d_silty_29c.jpg,Lettuce,Silty,9.8,2,None,29,54,3,"Lettuce seedling in Silty soil, full sunlight, low watering, 29°C, humidity 54%"
|
||||
lettuce_5d_peaty_29c.jpg,Lettuce,Peaty,5.1,4,Organic,29,54,5,"Lettuce seedling in Peaty soil, medium light, moderate watering, 29°C, humidity 54%"
|
||||
lettuce_14d_silty_26c.jpg,Lettuce,Silty,5.1,3,None,26,78,14,"Lettuce young plant in Silty soil, medium light, moderate watering, 26°C, humidity 78%"
|
||||
tomato_14d_sandy_23c.jpg,Tomato,Sandy,10.3,1,Organic,23,63,14,"Tomato young plant in Sandy soil, full sunlight, low watering, 23°C, humidity 63%"
|
||||
rosemary_7d_clay_16c.jpg,Rosemary,Clay,4.5,1,None,16,75,7,"Rosemary young plant in Clay soil, low light, low watering, 16°C, humidity 75%"
|
||||
tomato_5d_peaty_26c.jpg,Tomato,Peaty,4.6,7,Organic,26,67,5,"Tomato seedling in Peaty soil, low light, frequent watering, 26°C, humidity 67%"
|
||||
tomato_28d_silty_19c.jpg,Tomato,Silty,8.6,3,Chemical,19,66,28,"Tomato mature plant in Silty soil, medium light, moderate watering, 19°C, humidity 66%"
|
||||
lettuce_21d_loamy_30c.jpg,Lettuce,Loamy,10.4,3,None,30,46,21,"Lettuce mature plant in Loamy soil, full sunlight, moderate watering, 30°C, humidity 46%"
|
||||
tomato_5d_clay_30c.jpg,Tomato,Clay,11.7,3,None,30,77,5,"Tomato seedling in Clay soil, full sunlight, moderate watering, 30°C, humidity 77%"
|
||||
lettuce_10d_sandy_23c.jpg,Lettuce,Sandy,8.2,5,Organic,23,77,10,"Lettuce young plant in Sandy soil, medium light, moderate watering, 23°C, humidity 77%"
|
||||
rosemary_21d_peaty_27c.jpg,Rosemary,Peaty,5.4,3,Organic,27,51,21,"Rosemary mature plant in Peaty soil, medium light, moderate watering, 27°C, humidity 51%"
|
||||
tomato_21d_chalky_31c.jpg,Tomato,Chalky,5.0,3,Organic,31,59,21,"Tomato mature plant in Chalky soil, low light, moderate watering, 31°C, humidity 59%"
|
||||
tomato_5d_silty_25c.jpg,Tomato,Silty,7.9,5,Organic,25,57,5,"Tomato seedling in Silty soil, medium light, moderate watering, 25°C, humidity 57%"
|
||||
rosemary_28d_loamy_31c.jpg,Rosemary,Loamy,12.0,1,Chemical,31,59,28,"Rosemary mature plant in Loamy soil, full sunlight, low watering, 31°C, humidity 59%"
|
||||
lettuce_3d_silty_22c.jpg,Lettuce,Silty,7.5,4,Chemical,22,76,3,"Lettuce seedling in Silty soil, medium light, moderate watering, 22°C, humidity 76%"
|
||||
tomato_10d_silty_27c.jpg,Tomato,Silty,9.5,2,None,27,67,10,"Tomato young plant in Silty soil, full sunlight, low watering, 27°C, humidity 67%"
|
||||
tomato_3d_clay_27c.jpg,Tomato,Clay,10.8,2,Chemical,27,54,3,"Tomato seedling in Clay soil, full sunlight, low watering, 27°C, humidity 54%"
|
||||
tomato_3d_clay_15c.jpg,Tomato,Clay,11.9,1,Chemical,15,66,3,"Tomato seedling in Clay soil, full sunlight, low watering, 15°C, humidity 66%"
|
||||
rosemary_10d_silty_17c.jpg,Rosemary,Silty,7.7,3,Chemical,17,72,10,"Rosemary young plant in Silty soil, medium light, moderate watering, 17°C, humidity 72%"
|
||||
rosemary_7d_silty_20c.jpg,Rosemary,Silty,4.2,1,Chemical,20,46,7,"Rosemary young plant in Silty soil, low light, low watering, 20°C, humidity 46%"
|
||||
basil_10d_peaty_24c.jpg,Basil,Peaty,7.6,2,Chemical,24,68,10,"Basil young plant in Peaty soil, medium light, low watering, 24°C, humidity 68%"
|
||||
lettuce_10d_clay_25c.jpg,Lettuce,Clay,8.2,3,None,25,70,10,"Lettuce young plant in Clay soil, medium light, moderate watering, 25°C, humidity 70%"
|
||||
lettuce_5d_chalky_30c.jpg,Lettuce,Chalky,4.8,1,Organic,30,53,5,"Lettuce seedling in Chalky soil, low light, low watering, 30°C, humidity 53%"
|
||||
rosemary_14d_sandy_15c.jpg,Rosemary,Sandy,11.7,1,Organic,15,51,14,"Rosemary young plant in Sandy soil, full sunlight, low watering, 15°C, humidity 51%"
|
||||
lettuce_5d_chalky_23c.jpg,Lettuce,Chalky,4.4,6,Chemical,23,44,5,"Lettuce seedling in Chalky soil, low light, frequent watering, 23°C, humidity 44%"
|
||||
lettuce_7d_peaty_31c.jpg,Lettuce,Peaty,10.4,7,Organic,31,41,7,"Lettuce young plant in Peaty soil, full sunlight, frequent watering, 31°C, humidity 41%"
|
||||
tomato_28d_clay_30c.jpg,Tomato,Clay,6.0,6,Organic,30,62,28,"Tomato mature plant in Clay soil, medium light, frequent watering, 30°C, humidity 62%"
|
||||
tomato_10d_sandy_20c.jpg,Tomato,Sandy,9.6,5,None,20,72,10,"Tomato young plant in Sandy soil, full sunlight, moderate watering, 20°C, humidity 72%"
|
||||
rosemary_14d_chalky_30c.jpg,Rosemary,Chalky,8.0,1,Chemical,30,53,14,"Rosemary young plant in Chalky soil, medium light, low watering, 30°C, humidity 53%"
|
||||
tomato_3d_loamy_29c.jpg,Tomato,Loamy,8.9,7,Chemical,29,46,3,"Tomato seedling in Loamy soil, medium light, frequent watering, 29°C, humidity 46%"
|
||||
lettuce_21d_sandy_16c.jpg,Lettuce,Sandy,10.1,1,Organic,16,45,21,"Lettuce mature plant in Sandy soil, full sunlight, low watering, 16°C, humidity 45%"
|
||||
rosemary_5d_sandy_32c.jpg,Rosemary,Sandy,6.7,2,Organic,32,47,5,"Rosemary seedling in Sandy soil, medium light, low watering, 32°C, humidity 47%"
|
||||
basil_28d_clay_16c.jpg,Basil,Clay,4.0,7,Chemical,16,63,28,"Basil mature plant in Clay soil, low light, frequent watering, 16°C, humidity 63%"
|
||||
lettuce_14d_chalky_21c.jpg,Lettuce,Chalky,8.8,4,None,21,76,14,"Lettuce young plant in Chalky soil, medium light, moderate watering, 21°C, humidity 76%"
|
||||
tomato_3d_chalky_22c.jpg,Tomato,Chalky,4.8,4,Organic,22,42,3,"Tomato seedling in Chalky soil, low light, moderate watering, 22°C, humidity 42%"
|
||||
rosemary_14d_peaty_29c.jpg,Rosemary,Peaty,5.4,1,Organic,29,80,14,"Rosemary young plant in Peaty soil, medium light, low watering, 29°C, humidity 80%"
|
||||
basil_5d_peaty_29c.jpg,Basil,Peaty,9.6,7,Organic,29,42,5,"Basil seedling in Peaty soil, full sunlight, frequent watering, 29°C, humidity 42%"
|
||||
|
|
|
134
requirements.txt
|
@ -1,134 +0,0 @@
|
|||
accelerate==1.9.0
|
||||
altair==4.2.2
|
||||
attrs==25.3.0
|
||||
blinker==1.9.0
|
||||
cachetools==6.1.0
|
||||
certifi==2025.7.14
|
||||
charset-normalizer==3.4.2
|
||||
click==8.1.8
|
||||
colorama==0.4.6
|
||||
diffusers==0.34.0
|
||||
diskcache==5.6.3
|
||||
entrypoints==0.4
|
||||
filelock==3.18.0
|
||||
fsspec==2025.7.0
|
||||
gitdb==4.0.12
|
||||
GitPython==3.1.45
|
||||
huggingface-hub==0.34.3
|
||||
idna==3.10
|
||||
importlib_metadata==8.7.0
|
||||
Jinja2==3.1.6
|
||||
joblib==1.5.1
|
||||
jsonschema==4.25.0
|
||||
jsonschema-specifications==2025.4.1
|
||||
llama_cpp_python==0.3.14
|
||||
markdown-it-py==3.0.0
|
||||
MarkupSafe==3.0.2
|
||||
mdurl==0.1.2
|
||||
mpmath==1.3.0
|
||||
narwhals==2.0.1
|
||||
networkx==3.2.1
|
||||
numpy==1.23.3
|
||||
packaging==25.0
|
||||
pandas==2.3.1
|
||||
pillow==11.3.0
|
||||
protobuf==3.20.3
|
||||
psutil==7.0.0
|
||||
pyarrow==21.0.0
|
||||
pydeck==0.9.1
|
||||
Pygments==2.19.2
|
||||
Pympler==1.1
|
||||
python-dateutil==2.9.0.post0
|
||||
pytz==2025.2
|
||||
pywin32==311
|
||||
PyYAML==6.0.2
|
||||
referencing==0.36.2
|
||||
regex==2025.7.34
|
||||
requests==2.32.4
|
||||
rich==14.1.0
|
||||
rpds-py==0.26.0
|
||||
safetensors==0.5.3
|
||||
scikit-learn==1.2.2
|
||||
scipy==1.13.1
|
||||
semver==3.0.4
|
||||
six==1.17.0
|
||||
smmap==5.0.2
|
||||
streamlit==1.12.0
|
||||
sympy==1.14.0
|
||||
threadpoolctl==3.6.0
|
||||
tokenizers==0.21.4
|
||||
toml==0.10.2
|
||||
toolz==1.0.0
|
||||
torch==2.7.1
|
||||
torchaudio==2.7.1+cpu
|
||||
torchvision==0.22.1
|
||||
tornado==6.5.1
|
||||
tqdm==4.67.1
|
||||
transformers==4.54.1
|
||||
typing_extensions==4.14.1
|
||||
tzdata==2025.2
|
||||
tzlocal==5.3.1
|
||||
urllib3==2.5.0
|
||||
validators==0.35.0
|
||||
watchdog==6.0.0
|
||||
zipp==3.23.0
|
||||
altair==5.5.0
|
||||
attrs==25.3.0
|
||||
blinker==1.9.0
|
||||
cachetools==6.1.0
|
||||
certifi==2025.7.14
|
||||
charset-normalizer==3.4.2
|
||||
click==8.2.1
|
||||
colorama==0.4.6
|
||||
diffusers==0.34.0
|
||||
diskcache==5.6.3
|
||||
filelock==3.18.0
|
||||
fsspec==2025.7.0
|
||||
gitdb==4.0.12
|
||||
GitPython==3.1.45
|
||||
huggingface-hub==0.34.3
|
||||
idna==3.10
|
||||
importlib_metadata==8.7.0
|
||||
Jinja2==3.1.6
|
||||
joblib==1.5.1
|
||||
jsonschema==4.25.0
|
||||
jsonschema-specifications==2025.4.1
|
||||
llama_cpp_python==0.3.14
|
||||
MarkupSafe==3.0.2
|
||||
mpmath==1.3.0
|
||||
narwhals==2.0.1
|
||||
networkx==3.5
|
||||
numpy==2.3.2
|
||||
packaging==25.0
|
||||
pandas==2.3.1
|
||||
pillow==11.3.0
|
||||
protobuf==6.31.1
|
||||
pyarrow==21.0.0
|
||||
pydeck==0.9.1
|
||||
python-dateutil==2.9.0.post0
|
||||
pytz==2025.2
|
||||
PyYAML==6.0.2
|
||||
referencing==0.36.2
|
||||
regex==2025.7.34
|
||||
requests==2.32.4
|
||||
rpds-py==0.26.0
|
||||
safetensors==0.5.3
|
||||
setuptools==80.9.0
|
||||
six==1.17.0
|
||||
smmap==5.0.2
|
||||
streamlit==1.47.1
|
||||
sympy==1.14.0
|
||||
tenacity==9.1.2
|
||||
tokenizers==0.21.4
|
||||
toml==0.10.2
|
||||
torch==2.7.1
|
||||
torchaudio==2.7.1
|
||||
torchvision==0.22.1
|
||||
tornado==6.5.1
|
||||
tqdm==4.67.1
|
||||
transformers==4.54.1
|
||||
typing_extensions==4.14.1
|
||||
tzdata==2025.2
|
||||
urllib3==2.5.0
|
||||
watchdog==6.0.0
|
||||
zipp==3.23.0
|
35
temp.py
|
@ -1,35 +0,0 @@
|
|||
import torch
|
||||
from diffusers import StableDiffusionImg2ImgPipeline
|
||||
from PIL import Image
|
||||
import requests
|
||||
from io import BytesIO
|
||||
|
||||
# Load the pipeline
|
||||
pipe = StableDiffusionImg2ImgPipeline.from_pretrained(
|
||||
"runwayml/stable-diffusion-v1-5",
|
||||
torch_dtype=torch.float16,
|
||||
).to("cuda" if torch.cuda.is_available() else "cpu")
|
||||
|
||||
# Function to load image from local path or URL
|
||||
def load_image(path_or_url):
|
||||
if path_or_url.startswith("http"):
|
||||
response = requests.get(path_or_url)
|
||||
return Image.open(BytesIO(response.content)).convert("RGB")
|
||||
else:
|
||||
return Image.open(path_or_url).convert("RGB")
|
||||
|
||||
# Load original plant image
|
||||
input_image = st.file_uploader("Upload an image of your plant", type=["jpg", "jpeg", "png"])
|
||||
|
||||
# Resize to 512x512 for best results
|
||||
input_image = input_image.resize((512, 512))
|
||||
|
||||
# Define environmental condition prompt
|
||||
prompt = "A withered plant with brown leaves, dry soil, and signs of dehydration, after 10 days of heat and no water"
|
||||
|
||||
# Generate the modified image
|
||||
output = pipe(prompt=prompt, image=input_image, strength=0.75, guidance_scale=7.5)
|
||||
output_image = output.images[0]
|
||||
|
||||
# Save the result
|
||||
output_image.save("plant_future_prediction.png")
|