Sam Fred commited on
Commit
82aee85
·
1 Parent(s): 4a8721b
app.py CHANGED
@@ -21,6 +21,6 @@ if __name__ == "__main__":
21
  analyze_engagement()
22
 
23
  # Analyze an example image
24
- image_url = "https://example.com/path/to/image.jpg"
25
  caption = "This is a beautiful sunset!"
26
  analyze_image_url(image_url, caption)
 
21
  analyze_engagement()
22
 
23
  # Analyze an example image
24
+ image_url = "https://instagram.flos5-3.fna.fbcdn.net/v/t51.29350-15/461962570_446497237879604_125381930282480249_n.jpg?stp=dst-jpg_e15_tt6&efg=eyJ2ZW5jb2RlX3RhZyI6ImltYWdlX3VybGdlbi43MjB4MTI4MC5zZHIuZjI5MzUwLmRlZmF1bHRfY292ZXJfZnJhbWUifQ&_nc_ht=instagram.flos5-3.fna.fbcdn.net&_nc_cat=108&_nc_ohc=I22rbM-bFp4Q7kNvgEwCOwX&_nc_gid=22ddc0b11dfd44968a15fc79be74c9b9&edm=AEhyXUkBAAAA&ccb=7-5&ig_cache_key=MzQ3MjEwOTAyNDM0NzA1NTM4NzE3MjMxODMzOTg0NDgzOTg%3D.3-ccb7-5&oh=00_AYCYZr-aNIHjjQ86_HzvYiLDaExV26TEpndfIl9-rjyFcg&oe=678FAD53&_nc_sid=8f1549"
25
  caption = "This is a beautiful sunset!"
26
  analyze_image_url(image_url, caption)
models/engagement_rate_model.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:aafaee190ed53d6859751ab011e123134648137afcf840f57ae58e8d1e97445a
3
+ size 73122
models/promotion_strategy_model.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1d9f980263c17b1c8f05732ede25d5235caf5138f8d00620d457762ae0da21ec
3
+ size 1247
models/prophet_model.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:359ea47c7383c48dcaee07b947b8c6ef4f77694a1f2d39dc194861eee9b3e84c
3
+ size 178763
models/viral_potential_model.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:497dd50e7db8b9b7419121babc96a01efd5fbdb35a365971a289f9bba7c8d784
3
+ size 48185
scripts/__pycache__/analyze_engagement.cpython-312.pyc ADDED
Binary file (1.19 kB). View file
 
scripts/__pycache__/analyze_image.cpython-312.pyc ADDED
Binary file (1.4 kB). View file
 
scripts/__pycache__/train_engagement_rate.cpython-312.pyc ADDED
Binary file (1.53 kB). View file
 
scripts/__pycache__/train_promotion_strategy.cpython-312.pyc ADDED
Binary file (1.92 kB). View file
 
scripts/__pycache__/train_time_series.cpython-312.pyc ADDED
Binary file (1.28 kB). View file
 
scripts/__pycache__/train_viral_potential.cpython-312.pyc ADDED
Binary file (1.9 kB). View file
 
scripts/train_engagement_rate.py CHANGED
@@ -26,14 +26,3 @@ def train_engagement_rate():
26
 
27
  # Save the model locally
28
  joblib.dump(engagement_model, "engagement_rate_model.pkl")
29
-
30
- # Upload the model to Hugging Face Hub
31
- login(token=os.environ.get("HF_TOKEN")) # Use your Hugging Face token
32
- api = HfApi()
33
- api.upload_file(
34
- path_or_fileobj="engagement_rate_model.pkl",
35
- path_in_repo="engagement_rate_model.pkl",
36
- repo_id="Fred808/Insta-8084", # Replace with your repo
37
- repo_type="model",
38
- )
39
- print("Engagement Rate Model uploaded to Hugging Face Hub!")
 
26
 
27
  # Save the model locally
28
  joblib.dump(engagement_model, "engagement_rate_model.pkl")
 
 
 
 
 
 
 
 
 
 
 
scripts/train_promotion_strategy.py CHANGED
@@ -29,14 +29,3 @@ def train_promotion_strategy():
29
 
30
  # Save the model locally
31
  joblib.dump(promotion_model, "promotion_strategy_model.pkl")
32
-
33
- # Upload the model to Hugging Face Hub
34
- login(token=os.environ.get("HF_TOKEN")) # Use your Hugging Face token
35
- api = HfApi()
36
- api.upload_file(
37
- path_or_fileobj="promotion_strategy_model.pkl",
38
- path_in_repo="promotion_strategy_model.pkl",
39
- repo_id="Fred808/Insta-8084", # Replace with your repo
40
- repo_type="model",
41
- )
42
- print("Promotion Strategy Model uploaded to Hugging Face Hub!")
 
29
 
30
  # Save the model locally
31
  joblib.dump(promotion_model, "promotion_strategy_model.pkl")
 
 
 
 
 
 
 
 
 
 
 
scripts/train_time_series.py CHANGED
@@ -22,14 +22,3 @@ def train_time_series():
22
 
23
  # Save the model locally
24
  joblib.dump(prophet_model, "prophet_model.pkl")
25
-
26
- # Upload the model to Hugging Face Hub
27
- login(token=os.environ.get("HF_TOKEN")) # Use your Hugging Face token
28
- api = HfApi()
29
- api.upload_file(
30
- path_or_fileobj="prophet_model.pkl",
31
- path_in_repo="prophet_model.pkl",
32
- repo_id="Fred808/Insta-8084", # Replace with your repo
33
- repo_type="model",
34
- )
35
- print("Prophet Model uploaded to Hugging Face Hub!")
 
22
 
23
  # Save the model locally
24
  joblib.dump(prophet_model, "prophet_model.pkl")
 
 
 
 
 
 
 
 
 
 
 
scripts/train_viral_potential.py CHANGED
@@ -29,14 +29,3 @@ def train_viral_potential():
29
 
30
  # Save the model locally
31
  joblib.dump(viral_model, "viral_potential_model.pkl")
32
-
33
- # Upload the model to Hugging Face Hub
34
- login(token=os.environ.get("HF_TOKEN")) # Use your Hugging Face token
35
- api = HfApi()
36
- api.upload_file(
37
- path_or_fileobj="viral_potential_model.pkl",
38
- path_in_repo="viral_potential_model.pkl",
39
- repo_id="Fred808/Viral-P234", # Replace with your repo
40
- repo_type="model",
41
- )
42
- print("Viral Potential Model uploaded to Hugging Face Hub!")
 
29
 
30
  # Save the model locally
31
  joblib.dump(viral_model, "viral_potential_model.pkl")
 
 
 
 
 
 
 
 
 
 
 
utils/__pycache__/image_processing.cpython-312.pyc ADDED
Binary file (2.38 kB). View file
 
utils/__pycache__/logging_utils.cpython-312.pyc ADDED
Binary file (494 Bytes). View file
 
utils/__pycache__/preprocessing.cpython-312.pyc ADDED
Binary file (2.36 kB). View file
 
utils/__pycache__/visualization.cpython-312.pyc ADDED
Binary file (1.63 kB). View file