Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
window.print
- Page 1
Retrieval Augmented Generation with Hugging Face Models in LangChain
Programming
Computer Science
6 Days Ago
by usmanmalik57
… = prompt | hf question = "How to bake a pizza?"
print
(chain.invoke({"Question": question})) ``` **Output:** ![image1.png](https… points where Republicans and Democrats agree?" result = generate_response(query)
print
(result.split("<end>")[1]) ``` **Output:** ![image2…
Re: Printing multiple integers EASY SOLUTION
Programming
Software Development
3 Days Ago
by Bunker
A straightforward solution to printing multiple integers is to use a loop. For example, in Python, you could use a "for" loop to iterate through a list of integers and
print
each one. This method is simple and effective.
Re: Using Natural Language to Query SQL Databases with Python LangChain Module
Programming
Computer Science
2 Days Ago
by aishamushtaq
very helpful
Re: how to create a simple elevator simulation?
Programming
Software Development
3 Days Ago
by trueframe
To make a basic elevator simulation, first, identify the floors and the elevator's capacity. Then, use loops and conditionals in programming to mimic its movement. Include buttons for users to call the elevator and select floors. Test thoroughly for accuracy.
Question Answering with YouTube Videos Using RAG in LangChain
Programming
Computer Science
1 Week Ago
by usmanmalik57
…(docs)}")
print
("=====================================")
print
("Contents of video 1")
print
("=====================================")
print
(docs[0]) …the user types `bye`. ```
print
("=======================================================================")
print
("A Chatbot that tells you…
Using Natural Language to Query SQL Databases with Python LangChain Module
Programming
Computer Science
2 Weeks Ago
by usmanmalik57
…` key of the response dictionary to see the returned response. ```
print
(response['output']) ``` **Output:** ``` The top 10 employees who made the…/4/f98c2491a5b15f1e5c88e4f7db8b74ae.png) The script below returns the final output: ```
print
(response['output']) ``` **Output:** ``` The top 10 customers with the most…
How NOT to do business online
Digital Media
Digital Marketing
4 Weeks Ago
by Reverend Jim
… and when I clicked on that it opened a chat
window
where I typed a question, and was immediately told to…
'30% of Activities Performed by Humans Could Be Automated with AI'
Community Center
1 Week Ago
by Johannes C.
… AGI by the year…? ## I think that one one-year
window
is too short to achieve AGI in general. I think…
Re: sequential file save read option button
Programming
Software Development
1 Week Ago
by SCBWV
… what you mean by "record." Do you mean
print
? Read values from a file? I would suggest instead of…
Re: How can I upload a tar.bz2 file to openstack swift object storage container
Programming
Software Development
4 Weeks Ago
by Hanginium65
Good day, Salem. My apologies for taking so long to reply to your suggestion. I refactored my code to read the contents of the tar.bz2 file and then pass them as a file-like object to the 'put_object' and also to change the content type for the file transfer to "application/octet-stream". The first was sent through to object storage …
Re: How can I upload a tar.bz2 file to openstack swift object storage container
Programming
Software Development
4 Weeks Ago
by Salem
I don't understand why you need to extract all the files from the compressed `tar.bz2` just to upload to a backup. Also, line 69 is now meaningless having just posted only a snippet of the code. Before the error, what was the last `logger.info` message?
Re: Shared Printer Problem
Hardware and Software
Microsoft Windows
2 Weeks Ago
by Bunker
Network hiccup, paper jam, or driver glitch - troubleshooting the shared printer quandary demands patience, tech-savvy finesse, and perhaps a dash of printer exorcism.
Re: How NOT to do business online
Digital Media
Digital Marketing
4 Weeks Ago
by rproffitt
Someone wanted me to pay with Venmo which I also have never used. Sorry, but I don't want to add more apps today.
Re: How NOT to do business online
Digital Media
Digital Marketing
3 Weeks Ago
by Dani
Not that it is an excuse, but I would like to offer up an explanation, if I may. You can [see here](https://www.daniweb.com/programming/web-development/threads/541688/airtm-api-how-to-build-a-form) that only 4 days ago, FarrisFahad had a button to pay by Paypal on his website, and wants to convert it into utilizing a payment API (e.g. something …
Re: How NOT to do business online
Digital Media
Digital Marketing
3 Weeks Ago
by Reverend Jim
I could understand that for a small company but it looks like this place (US based) also has a Canadian presence. And judging by [their range of products](https://www.thewoodveneerhub.ca/) they aren't a small company. In any case, after pricing out what we wanted ($800+) and failing to get an alternate payment option we decided to invest in a …
Re: How NOT to do business online
Digital Media
Digital Marketing
3 Weeks Ago
by Dani
> I could understand that for a small company but it looks like this place (US based) also has a Canadian presence. According to their about us page, it’s a family owned business run by a guy named Lawrence who has been in the industry since the 1970s but just started his own business in the 2000s. Which fits the profile I had laid out. (Eg …
Re: How NOT to do business online
Digital Media
Digital Marketing
3 Weeks Ago
by Reverend Jim
Fair enough.
Re: DomContentLoaded vs jQuery Ready fn
Programming
Web Development
1 Month Ago
by jkon
…function completed() { document.removeEventListener( "DOMContentLoaded", completed );
window
.removeEventListener( "load", completed ); jQuery.ready(); } … asynchronously to allow scripts the opportunity to delay ready
window
.setTimeout( jQuery.ready ); } else { // Use…
Claude 3 Opus Vs. Google Gemini Vs. GPT-4 for Zero-Shot Text Classification
Programming
Computer Science
1 Month Ago
by usmanmalik57
…if 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 Except as e:
print
("===================")
print
("Exception occured", e)…
7 NLP Tasks to Perform for Free in Python with Mistral 7b LLM
Programming
Computer Science
1 Month Ago
by usmanmalik57
…'neutral: {review}" response = generate_response(input_text, 10, 0.1)
print
(response) ``` **Output:** ``` neutral ``` The above output shows that the …entity type: {input}" response = generate_response(input_text, 100, 0.1)
print
(response) ``` **Output:** ``` Ronaldo -> Person Portugal -> Location …
Extract Tabular Data from PDF Images using Hugging Face Table Transformer
Programming
Computer Science
2 Months Ago
by usmanmalik57
…: max_num_columns = len(row_text) data[idx] = row_text
print
("Max number of columns:", max_num_columns) # pad…in range(max_num_columns - len(row_data))] data[row] = row_data
print
(row_data) return data data = apply_ocr(cell_coordinates, cropped_image) ``` …
Fine Tuning Google Gemma Model for Text Classification in Python
Programming
Computer Science
2 Months Ago
by usmanmalik57
…quot;).to(device) outputs = model.generate(**inputs, max_new_tokens=10)
print
(tokenizer.decode(outputs[0], skip_special_tokens=True)) ``` **Output:** ``` … "negative"]: targets.append(target_sentiment) predictions.append(predicted_sentiment)
print
(f"Record {i+1} - Actual:{target_sentiment}, Predicted: …
Retrieval Augmented Generation (RAG) with Google Gemma From HuggingFace
Programming
Computer Science
1 Month Ago
by usmanmalik57
… = DirectoryLoader(folder_path, glob='**/*.txt') docs = loader.load()
print
(f"Total documents loaded: {len(docs)}") ``` …generate_response(query)
print
("===================================")
print
("RESPONSE FROM RAG MODEL")
print
("===================================")
print
(final_response.split("…
Paris Olympics Chatbot- Get Ticket Information Using Chat-GPT and LangChain
Programming
Computer Science
1 Month Ago
by usmanmalik57
… "input": "Tell a joke about mathematics"} )
print
(result.content) ``` **Output:** ``` Why was the math book sad? … ``` def generate_response(query): response = retrieval_chain.invoke({"input": query})
print
(response["answer"]) ``` Let's now ask some questions…
How can I upload a tar.bz2 file to openstack swift object storage container
Programming
Software Development
1 Month Ago
by Hanginium65
… = 'netbox-backups' try: resp_headers = swift_conn.head_object(container, obj1)
print
("The object " + obj1 + " was successfully created… = 'netbox-backups' try: resp_headers = swift_conn.head_object(container, obj2)
print
("The object " + obj2 + " was successfully created…
Paris Olympics Ticket Information Chatbot with Memory Using LangChain
Programming
Computer Science
1 Month Ago
by usmanmalik57
…script and a sample output. ```
print
("=======================================================================")
print
("Welcome to Paris Olympics Ticket …Information Chatbot. Enter your query")
print
("=======================================================================") query = "" while…
Re: How can I upload a tar.bz2 file to openstack swift object storage container
Programming
Software Development
1 Month Ago
by Salem
… let it figure out the compression >>>
print
(tf1.getnames()) ['foo_1.txt', 'foo_2.txt'] >…let it figure out the compression >>>
print
(tf2.getnames()) ['foo_1.txt', 'foo_2.txt'] In particular…gt; rawbytes = rawfile.read() >>>
print
(len(rawbytes)) 181 In other words, treat every …
Why am getting different syntax errors when running a Python script
Programming
Software Development
2 Months Ago
by Tom_45
…name = match[1] item = (year, name, rank) names.append(item) #
print
(item) name = match[2] item = (year, name, rank) names.append…(item) #
print
(item)` On the re.findall statement, the error message invalid…
Re: VB6 - RayCasting: why my Vertical intersection is so big?
Programming
Software Development
2 Months Ago
by cambalinho
…(Player.PosY), Fix(HorizX), Fix(HorizY) WallDistance = HorizDist 'Debug.
Print
HorizDist & vbTab & " Draw Horizontal" …Radians - Radian30) RayCounts = RayCounts + 1 DoEvents Loop 'Debug.
Print
RayCounts End Sub the bugs: - when radians is between 6…
DomContentLoaded vs jQuery Ready fn
Programming
Web Development
1 Month Ago
by Dani
I think that I understand the difference between: document.addEventListener('DOMContentLoaded', callback_fn); and:
window
.addEventListener('load', (event) => { ... }); However, as a jQuery user, what is the difference between DOMContentLoaded and the jQuery ready fn?
1
2
3
17
Next
Last
Search
Search
Forum Categories
Hardware/Software
Programming
Digital Media
Community Center
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Meet People
Forums
Top Members
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