Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
print
- Page 1
How to Fine-tune the OpenAI GPT-4o Model - The Wait is Finally Over
Programming
Computer Science
3 Weeks Ago
by usmanmalik57
…i += 1
print
(i, sentiment_value) except Exception as e:
print
("===================")
print
("Exception occurred:&… accuracy = accuracy_score(all_sentiments, dataset["airline_sentiment"])
print
(f"Accuracy: {accuracy}") find_sentiment(client,ft_model_id…
Enhancing RAG Functionalities using Tools and Agents in LangChain
Programming
Computer Science
2 Weeks Ago
by usmanmalik57
…is the current President of America?" response = generate_response(query)
print
(response["output"]) ``` **Output:** ``` The current President …``` query = "And of France?" response = generate_response(query)
print
(response["output"]) ``` **Output:** ``` The current President of France…
Extracting Structured Outputs from LLMs in LangChain
Programming
Computer Science
1 Week Ago
by usmanmalik57
… article_information = extraction_chain.invoke({"input":first_article})
print
(article_information) ``` **Output:** ![image2.png](https://static…) article_information = extraction_chain.invoke({"input":formatted_articles})
print
(article_information.articles) ``` **Output:** ![image4.png](https://…
Re: Fine-Tuning OpenAI Whisper Model for Audio Classification in PyTorch
Programming
Computer Science
2 Weeks Ago
by Duane_4
This is an interesting and useful post. I believe there is a typo in the 7th code block relating to train/val/test split. The second line should read: val_df, test_df = train_test_split(temp_df, test_size=0.5, random_state=42) The whole point of temp_df in the first line was to separate out 30% for val/test; the second line splits that to …
Re: Fine-Tuning OpenAI Whisper Model for Audio Classification in PyTorch
Programming
Computer Science
1 Week Ago
by meyerrluanna
The post gives a really clear, step-by-step guide on how to fine-tune the OpenAI Whisper model for audio classification. Its great how it covers everything from preparing the dataset to using tools for feature extraction and model training .This is definitely worth checking out, The explanations are practical, and the code snippets make it easy to …
Re: Key Insights from Google's Search Algorithm Leak
Community Center
2 Weeks Ago
by emiilyyjohnson2
Thanks for sharing such valuable information with us. It was a goldmine if we dig down it deeply.
Comparing GPT-4o vs Claude 3.5 Sonnet for Zero Shot Text Classification
Programming
Computer Science
2 Months Ago
by usmanmalik57
…needed dataset.reset_index(drop=True, inplace=True) #
print
value counts
print
(dataset["airline_sentiment"].value_counts()) ``` **Output:**…i = i + 1
print
(i, sentiment_value) except Exception as e:
print
("===================")
print
("Exception occurred:", …
GPT-4o mini - A Cheaper and Faster Alternative to GPT-4o
Programming
Computer Science
2 Months Ago
by usmanmalik57
… dataset.reset_index(drop=True, inplace=True) #
print
value counts
print
(dataset["airline_sentiment"].value_counts()) ``` **Output…) i += 1
print
(i, sentiment_value) except Exception as e:
print
("===================")
print
("Exception occurred:"…
Comparison of Fine-tuning GPT-4o mini vs GPT-3.5 for Text Classification
Programming
Computer Science
1 Month Ago
by usmanmalik57
…training dataset. ``` training_data = preprocess_data(dataset, 0)
print
(training_data["airline_sentiment"].value_counts()) training_data.head() ``` …i += 1
print
(i, sentiment_value) except Exception as e:
print
("===================")
print
("Exception occurred:&…
GPT-4o Snapshot vs Meta Llama 3.1 70b for Zero-Shot Text Summarization
Programming
Computer Science
1 Month Ago
by usmanmalik57
…article_id'], 'content'].iloc[0] scores = llm_evaluate_summary(article, row['generated_summary'])
print
(f"Article ID: {row['article_id']}, Scores: {scores}")…'], 'content'].iloc[0] scores = llm_evaluate_summary(article, row['generated_summary'])
print
(f"Article ID: {row['article_id']}, Scores: {scores}")…
Extracting YouTube Channel Statistics in Python Using YouTube Data API
Programming
Computer Science
2 Months Ago
by usmanmalik57
…;]["title"]) request = youtube.search().list_next(request, response) ``` Finally,
print
the total number of extracted video titles and display the… extraction process is working correctly. ``` #
Print
the video titles
print
("Total extracted videos:", len(video_titles))
print
("First 10 videos"…
Re: How can I upload a tar.bz2 file to openstack swift object storage container
Programming
Software Development
2 Months Ago
by Hanginium65
…(container) res_headers, containers = swift_conn.get_account() if container in containers:
print
("The container " + container + " was created!&…= 'object-backups' try: resp_headers = swift_conn.head_object(container, obj1)
print
("The object " + obj1 + " was successfully created…
Image Analysis Using Claude 3.5 Sonnet Model
Programming
Computer Science
2 Months Ago
by usmanmalik57
…].text response_content = analyze_graph("Can you summarize the graph?")
print
(response_content) ``` **Output:** ![image3.png](https://static.daniweb.com/attachments…;Can you predict facial sentiment from the input image?")
print
(response_content) ``` **Output:** ![image3c.png](https://static.daniweb.com/…
GPT-4o mini vs. GPT-4o vs GPT-3.5 Turbo for Text Summarization
Programming
Computer Science
1 Month Ago
by usmanmalik57
…= dataset['human_summary'].apply(len) average_length = dataset['summary_length'].mean()
print
(f"Average length of summaries: {average_length:.2f} characters&…rougeL']].mean() average_scores_sorted = average_scores.sort_values(by='rouge1', ascending=False)
print
("Average ROUGE scores by model:") average_scores_sorted.head() ```…
How to uploade the .gzip file to Swift Object Store?
Programming
Software Development
2 Months Ago
by Hanginium65
…) res_headers, containers = swift_conn.get_account() if container in containers:
print
("The container " + container + " was …'object-backups' try: resp_headers = swift_conn.head_object(container, obj1)
print
("The object " + obj1 + " was successfully…
Extract Schema.org Data Script (Python)
Digital Media
Digital Marketing
Search Engine Strategies
1 Month Ago
by Chris Hüneke
… extract_types_and_fields(json_data) except json.JSONDecodeError as e:
print
(f"Error decoding JSON: {e}"…, field_count = extract_schema_data(url) if not schema_data:
print
("No Schema.org data found.") return…
Retrieval Augmented Generation with Claude 3.5 Sonnet
Programming
Computer Science
2 Months Ago
by usmanmalik57
…an ice cream shop on a beach.")
print
(result.content) ``` **Output:** ![image1.png](… a music store on a beach."} )
print
(result) ``` **Output:** ![image2.png](https://static… response = retrieval_chain.invoke({"input": query})
print
(response["answer"]) ``` To demonstrate the system …
Extract and Count Reviews/AggregateRating Script (Python)
Digital Media
Digital Marketing
Search Engine Strategies
1 Month Ago
by Chris Hüneke
… category_url = category.text category_name = category_url.split('/')[-2]
print
(f"Processing category: {category_name}") total_reviews = …encoding='utf-8') as file: file.writelines(results)
print
("Results saved to result.txt") if __name__…
Re: What is wrong in my this backup code? sql C#
Programming
Software Development
2 Months Ago
by Salem
1. Run the program in the debugger. 2. Put a breakpoint on `con.Open();` 3. Run the backup part of the program. 4.
Print
the contents of the `cmd` string, after it's made all the runtime substitutions. Is that string what you were expecting? The spaces around your double-back-slash seem out of place.
Re: AttributeError: module 'pandas' has no attribute 'read_csv'
Programming
Software Development
2 Months Ago
by toneewa
…) #pd.set_option('display.max_columns', None) df = pd.read_csv('people.csv')
print
(df) Index User Id ... Date of birth Job Title 0…
Re: How can I upload a tar.bz2 file to openstack swift object storage container
Programming
Software Development
2 Months Ago
by Salem
How did you open the file to save the download? Did you use 'wb' mode in the open? > file_gz_content = f.read() Verify that the length of this is the whole file. > swift_conn.put_object https://docs.openstack.org/python-swiftclient/latest/swiftclient.html#swiftclient.client.put_object One of the parameters is `response_dict`. …
Re: How to uploade the .gzip file to Swift Object Store?
Programming
Software Development
2 Months Ago
by rproffitt
Check the type of compression using the file command: file name_name.tgz
Re: How to uploade the .gzip file to Swift Object Store?
Programming
Software Development
2 Months Ago
by Hanginium65
This is the compression type of the original file in my local machine: file netbox_2024-07-09.psql.gz netbox_2024-07-09.psql.gz: gzip compressed data, last modified: Tue Jul 9 07:56:02 2024, from Unix, original size 1875639 Below is the compression type of the file downloaded from the OpenStack Object Storage file …
Re: How to uploade the .gzip file to Swift Object Store?
Programming
Software Development
2 Months Ago
by rproffitt
I can't tell where the file is altered but it appears the file is indeed being altered. To figure out where I would be using the file command on the server as well. But I can't tell if you can shell into said server.
Re: How to uploade the .gzip file to Swift Object Store?
Programming
Software Development
2 Months Ago
by Hanginium65
No, unfortunately. I can communicate with the server through the swift command since it's an OpenStack Object store. If I use the Swift command, the uploaded file is in the same format and size as the one on my local machine. I wanted to automate this process using a Python script.
Re: How to uploade the .gzip file to Swift Object Store?
Programming
Software Development
2 Months Ago
by rproffitt
I will try again to convey how I would troubleshoot this. Now that you revealed that "it works" with the Swift command but not Python you still need to find out where the file alteration happens. To wit, I would see if the file made it to the server intact first. Use your code to send the file up and the Swift commands to check the …
Re: Extract Schema.org Data Script (Python)
Digital Media
Digital Marketing
Search Engine Strategies
1 Month Ago
by Chris Hüneke
Sorry, i got that wrong. I can't post scripts in Digital Marketing section, right?
Re: Key Insights from Google's Search Algorithm Leak
Community Center
1 Month Ago
by Chris Hüneke
Nice read! you basically say it (link quality + user interactions) - but i'dd like to add a little somthing, if it's alright: A backlink, which actually drives traffic, is counted. A Backlink, which does not drive any traffic, not. This way Google tries to filter and disavow spammy links automatically - because most Spam sites dont have …
Re: Extract and Count Reviews/AggregateRating Script (Python)
Digital Media
Digital Marketing
Search Engine Strategies
1 Month Ago
by Chris Hüneke
Sorry, i got that wrong. I can't post scripts in Digital Marketing section, right?
Re: Extract and Count Reviews/AggregateRating Script (Python)
Digital Media
Digital Marketing
Search Engine Strategies
1 Month Ago
by Dani
No, just in Web Development, but you can use the seo tag.
1
2
3
17
Next
Last
Search
Search
Forum Categories
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Forums
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2024 DaniWeb® LLC