python |
Pythonタグが付けられた新着投稿 - Qiita |
ポケモンスリープの睡眠データを簡単に読み取りたかった |
https://qiita.com/ak-sakatoku/items/9d91ed35e0a9a8aac408
|
sleep |
2023-08-16 22:19:29 |
python |
Pythonタグが付けられた新着投稿 - Qiita |
変数について |
https://qiita.com/ayamo/items/43bb104408bf7671b05d
|
計算 |
2023-08-16 22:19:09 |
js |
JavaScriptタグが付けられた新着投稿 - Qiita |
JavaScript タイマー機能 メモ |
https://qiita.com/takahigu642/items/c69e2033c943be117ee4
|
crearinterval |
2023-08-16 22:25:36 |
js |
JavaScriptタグが付けられた新着投稿 - Qiita |
react-native-sqlite-storageとexpo-sqliteの罠 |
https://qiita.com/ikakusa/items/27d41e01d9269ead102f
|
native |
2023-08-16 22:14:17 |
AWS |
AWSタグが付けられた新着投稿 - Qiita |
AWS SSOのIDプロバイダを消してしまったら、許可セットを再保存すれば復旧できる |
https://qiita.com/yoshi-taka/items/1f701f5f79ba2e73468c
|
iamidentit |
2023-08-16 22:03:38 |
Git |
Gitタグが付けられた新着投稿 - Qiita |
gitアカウントの切り替え方法 |
https://qiita.com/takiguchi-yu/items/d2aeca7d6ba43e2028b1
|
hostgithubcom |
2023-08-16 22:51:05 |
海外TECH |
MakeUseOf |
10 Basic Skills You Need to Manage Any PDF File |
https://www.makeuseof.com/skills-to-manage-pdf-file/
|
essential |
2023-08-16 13:31:24 |
海外TECH |
MakeUseOf |
How to Turn Off Voice Narration (Screen Reader) on Roku |
https://www.makeuseof.com/how-to-turn-off-voice-narration-on-roku/
|
chances |
2023-08-16 13:15:24 |
海外TECH |
DEV Community |
What is DigitalOcean? - Everything You Need to Know |
https://dev.to/devarshishimpi/what-is-digitalocean-everything-you-need-to-know-39ph
|
What is DigitalOcean Everything You Need to Know IntroductionIn today s digital age cloud computing has become an integral part of the tech industry And when it comes to cloud infrastructure providers DigitalOcean is a name that often pops up In this blog we will explore DigitalOcean and what it has to offer for developers and businesses alike Feel free to checkout the below video I made for this tutorial as well DigitalOcean The Virtual LandlordDigitalOcean can be best described as a virtual landlord for your software applications Just like you need a physical space to run your apps databases or other tech stuff DigitalOcean provides the virtual computers known as servers that you need up in the cloud The beauty of DigitalOcean lies in its simplicity They take care of the heavy lifting by owning and managing the servers while giving you the control to customize and set things up according to your requirements It s like renting your own tech playground Flexible and Cost EfficientDigitalOcean offers flexible payment options allowing you to only pay for what you use Similar to how you pay for electricity or water DigitalOcean offers different plans with varying resources These resources can be seen as the power and space your virtual playground gets The plans which include Basic Standard and Premium cater to different needs and budgets The best part is that you are not locked into any long term contracts You can choose to pay monthly or even hourly providing great flexibility If you re just looking to tinker or experiment you can opt for the hourly pricing model allowing you to pay as you go This is particularly useful for developers and small businesses who want to test out their applications before committing to larger resources DigitalOcean vs the CompetitionWhile DigitalOcean is a popular choice it is important to mention that there are other cloud infrastructure providers available such as Google Cloud Microsoft Azure and AWS Each provider has its own set of offerings and features However DigitalOcean stands out with its user friendly interface and easy to understand pricing structure Getting Started with DigitalOceanTo give DigitalOcean a try you can sign up using the special link provided By doing so you will receive free credit allowing you to explore and experiment with the platform without any financial commitment It s a great opportunity to dive into the world of cloud computing and experience the benefits of DigitalOcean firsthand ConclusionDigitalOcean provides developers and businesses with a user friendly and cost effective platform for running their applications and services in the cloud With its virtual playground approach flexible payment options and easy to understand interface it has become a go to choice for many in the tech industry So if you re looking for a reliable cloud infrastructure provider DigitalOcean might just be the virtual landlord you ve been searching for Sign up today using the link below and embark on your cloud computing journey with free credit Get ready to take your software applications to new heights with DigitalOcean Thanks for reading till the end Please consider supporting me on my socials YoutubeGithubTwitterLinkedinThis post includes affiliate links I may receive compensation if you purchase products or services from the different links provided in this article |
2023-08-16 13:42:59 |
海外TECH |
DEV Community |
PostgreSQL Full-Text Search: A Practical Introduction with Examples |
https://dev.to/thedataisaac/postgresql-full-text-search-a-practical-introduction-with-examples-bn9
|
PostgreSQL Full Text Search A Practical Introduction with ExamplesFull text search is a technique used to search within a large collection of documents or data by matching the words or phrases in the query It is superior to traditional search because it has the capability to sort the search results in order of similarity to the query Traditional search involves simple queries that match exact terms or phrases Operators like LIKE and ILIKE are used in this case However full text search builds upon this limitation and allows for the preprocessing of natural language documents before performing a search If you need to perform text searches on a large document that contains text data full text search is the way to go This article covers the basics use cases and how to optimize full text search Walk with me to tsvector and to tsvector in postgreSQLIn PostgreSQL two commonly used functions for full text search are to tsvector This function is used to convert a document s text into a vector of tokens words where each token is associated with its normalized form The to tsvector function performs several processes as part of its normalization such as Tokenization the text is divided into individual tokens or words The text is separated based on punctuation marks and spaces Lowercasing All tokens are converted to lowercase This ensures the text case insensitivity Stemming All tokens are reduced to their root forms called lexemes Suffixes and endings are removed For instance believe believer and believing would be stemmed to believ Stopword removal Stop words are common words like are the and that do not contribute significantly to the meaning of the document The function also assigns position information to each token indicating their location in the original text Normalization is a crucial step in full text indexing and searching For example Convert text to tsvector SELECT to tsvector english Innovative technologies are shaping the future This query would generate a vector of tokens like futur innov shape technolog english is passed as a parameter into the to tsvector function to indicate text search configuration to tsquery This function is used to convert a query string into a query expression that can be used for full text searching It takes into account the same language configuration as to tsvector For instance Convert text to tsquery SELECT to tsquery english cat amp rat This query would create a query expression to find documents containing both cat and rat Full Text Search Operators Match Operator A match operator is used to test whether a tsvector matches a tsquery It returns true if the document contains the tokens and operators specified by the query and false otherwise For example consider a table called books with a column named title which contains the titles of various books ID Title The Hitchhiker s Guide to the Galaxy One Hundred Years of Solitude Pride and Prejudice and Zombies The Girl with the Dragon Tattoo To Kill a Mockingbird The Perks of Being a Wallflower The Curious Incident of the Dog in the Night Time The Fault in Our Stars The Catcher in the Rye The Lost Girl of Paris Under the Stars Embrace The source code including the query for creating this table can be found on GitHubWe can use the match operator to find all the books that have the word “Girl in their titles Here s the query to achieve that Select books where the title matches the tsquery Girl SELECT FROM booksWHERE to tsvector english title to tsquery english Girl This query returns the following output ID Title The Girl with the Dragon Tattoo The Lost Girl of Paris The amp AND OperatorThis operator is used in a query when multiple words are being searched for The multiple words are usually separated by amp and the query only returns documents where ALL the words are presentFor example Select books where the title matches the tsquery girl and dragon SELECT FROM booksWHERE to tsvector english title to tsquery english girl amp dragon In this query the amp symbol represents the AND operator It would create a query expression to find documents containing both girl and dragon matching the record with ID from the books table ID Title The Girl with the Dragon Tattoo The OR OperatorThis operator is used in a query to find documents that contain at least one of the specified search terms Let s say we want to find books that have either Galaxy or Stars in their titles from the books table We can use the OR operator to achieve this Select books where the title matches the tsquery Galaxy or Stars SELECT FROM booksWHERE to tsvector english title to tsquery english Galaxy Stars The symbol represents the OR operator The query will match documents containing either Galaxy Stars or both The query above returns the following result ID Title The Hitchhiker s Guide to the Galaxy The Fault in Our Stars Under the Stars Embrace The NOT OperatorThis operator is used in queries to exclude documents that contain the word alongside which the operator is used Select books where the title does not match Perks SELECT FROM booksWHERE to tsvector english title to tsquery english Perks The symbol represents the NOT operator The query will match only documents that do not contain the word Perks The lt gt FOLLOWED BY OperatorThis functions like the AND operator but the order in which the words are written in the document matters The two words need to be right next to each other without any other words in between In this instance even though there is a row in the table with the title One Hundred Years of Solitude searching for Solitude followed by Hundred will not match any document because the Hundred is not immediately after the Solitude Select books where the title matches Hundred followed by Solitude SELECT FROM booksWHERE to tsvector english title to tsquery english Hundred lt gt Solitude There is an extension of the FOLLOWED BY operator that allows us to specify the gap between the two words allow for a specified number of words between the position of the two words we are trying to match in the document This is the lt N gt operator N represents an integer denoting the maximum gap length between the positions of the two words For example we want to find sentences where the words Hundred and Solitude appear within range of words from each other We can use the lt gt operator as follows Select books where the title matches Hundred lt gt Solitude SELECT FROM booksWHERE to tsvector english title to tsquery english Hundred lt gt Solitude In this query the lt gt operator specifies that there can be words between Hundred and Solitude in the title column The query will return this result ID Title One Hundred Years of Solitude Creating IndexesIndexes can be created on a table before text search is done These indexes help our database quickly locate the relevant documents being we re searching for By setting up indexes before performing text searches we re providing a shortcut for the database to find the information we need Instead of scanning through every record in the table the database can follow these indexes to directly reach the data we re looking for making the process much more efficient Create an index on the title columnCREATE INDEX title idx ON books title Full text search with precomputed vectorsHere a new column is created for the text search vectors followed by the creation of an index on that column This method is faster than solely creating the index on the table and vectorizing the document during query processing We can add the new column to an already loaded table then update the table to include the vector for each row Alter the books table to add a new column for tsvectorALTER TABLE books ADD COLUMN title tsvector tsvector Update the title tsvector column for all rowsUPDATE books SET title tsvector to tsvector english title Create an index on the title tsvector column using GINCREATE INDEX title tsvector idx ON books USING GIN title tsvector Alternatively we can create the column while making the table and utilize Stored Procedures to update the column whenever a new row is added to the table Create the books table with id title and title tsvector columnsCREATE TABLE books id serial PRIMARY KEY title text title tsvector tsvector Create a stored procedure to update title tsvectorCREATE OR REPLACE FUNCTION update title tsvector RETURNS TRIGGER AS BEGIN NEW title tsvector to tsvector english NEW title RETURN NEW END LANGUAGE plpgsql Create a trigger to automatically update title tsvectorCREATE TRIGGER update title tsvector triggerBEFORE INSERT ON booksFOR EACH ROWEXECUTE FUNCTION update title tsvector Ranking Search resultsFull text search has the capability to sort the results in order of relevance to the query It assigns a score to indicate the level of similarity between each match and the query This feature makes full text search incorporated in web search engines providing users with relevant search results from the vast amount of information available on the internet It also enable job seekers to search for job postings based on keywords and criteria Selecting book ID title and calculated rank and ordering the results by rank in descending order for relevanceSELECT id title ts rank to tsvector english title to tsquery english stars AS rankFROM booksWHERE title tsvector to tsquery english stars ORDER BY rank DESC This query retrieves book records where the word stars is present in the title The results are then ordered based on their relevance to the search query Since the query is searching for a single word in a small table both books might end up having a similar rank ConclusionFull text search enhances search capabilities within large collections of documents or data Another notable feature of full text search which was not mentioned earlier is its ability to assign weights allowing us to prioritize certain words over others when performing a search By understanding its functions and operators we can optimize searches and efficiently retrieve relevant information |
2023-08-16 13:40:48 |
海外TECH |
Engadget |
The best soundbars for 2023 |
https://www.engadget.com/best-soundbars-143041791.html?src=rss
|
The best soundbars for It s no secret that the built in speakers in most TVs are trash They don t project enough sound out to the front so you can hear well ーespecially subtle details Thankfully you don t have to splurge for a five speaker or more surround sound system to improve your sound experience In most living rooms a single soundbar and maybe a subwoofer can coax better sound from your TV To help guide your shopping spree we ve compiled a list of everything to look for when searching for the best soundbar for you along with a list of the top picks for a range of budgets What to look for in a soundbarFeaturesWhen it comes to features the more you pay the more you re going to get Most affordable options or less will improve your television s audio quality but that s about it Step into the to range and you ll find a smart soundbar with things like built in voice control wireless connectivity Google Chromecast AirPlay and even Android TV They re all helpful when you want to avoid looking for the remote control but the best sound quality is usually only in the top tier and the formats those premium soundbar systems support I m talking about things like Dolby Atmos DTS X and other high resolution audio standards These are what you ll want to look for if truly immersive sound is what you crave for your living room setup And not all Atmos soundbars are equal so you ll need to look at the finer details carefully before you break into the savings account PortsSonyThis is a big one A lot of the more affordable soundbars are limited when it comes to connectivity options They either offer an optical port or one HDMI jack and if you re lucky both Things get slightly better in the mid range section but that s not always the case The Sonos Beam for example is but only has a single HDMI port If you want to connect your set top box gaming console and more directly to your soundbar for the best possible audio you ll likely want to look for an option with at least two HDMI eARC inputs HDMI connections are essential for things like Dolby Atmos DTS X and other high res and immersive audio formats And with the HDMI spec soundbars can support HDR K and K passthrough to make these speaker systems an even better companion for a game console ChannelsAnother big thing you ll want to pay attention to when looking for the best soundbar is channels That s the or other decimal number that companies include in product descriptions The first figure corresponds to the number of channels A two would just be left and right while a more robust Atmos system especially one with rear satellite speakers could be five or seven left right center and upward The second number refers to the subwoofer so if your new soundbar comes with one or has them built in you ll see a one here The third numeral is up firing speakers important for the immersive effect of Dolby Atmos Not all Atmos enabled units have them but if they do the third number will tell you how many are in play WirelessSonyMost soundbars these days offer either Bluetooth WiFi or both When it comes to WiFi that connectivity affords you luxuries like voice control either built in or with a separate device Chromecast Spotify Connect and AirPlay Depending on your preferences you might be able to live without some of these For me AirPlay and Chromecast are essentials but the rest I can live without Those two give me the ability to beam music and podcasts from my go to apps without having to settle for ーor struggle with ーa Bluetooth connection SizeThis one might seem obvious but humor me for a minute Nothing is more soul crushing than getting a pricey soundbar in your living room only to discover you have to rearrange everything to find a spot for it This was my plight when the Sennheiser Ambeo Soundbar arrived at my door Yes that speaker is absurdly large and heavy and most soundbars aren t nearly as big I learned a valuable lesson Make sure the space where you want to put a soundbar will accommodate the thing you re about to spend hundreds if not thousands of dollars on Basically it all comes down to the TV you have or are planning to get and what the primary goal is for your living room audio Is it ease of use Do you want the best possible sound from a single speaker or speaker sub combo Do you just want to be able to actually hear your TV better Or do you want to turn your living room into an immersive home theater system with surround sound By paying attention to each of those areas you should have a good idea of what to look for in a soundbar soundbar subwoofer combo or a more robust setup With that said we ve put numerous products through their paces at Engadget and have a few favorites for best soundbar at various price points to get you started The Best SoundbarsBest premium soundbar Sony HT ASony has a long track record of excellent high end soundbars and its latest is another great sounding product The A is a robust Dolby Atmos soundbar capable of immersive audio thanks to Sony s Sound Mapping Sound Field Optimization vertical surround technology and S Force Pro front surround There s a lot of tech at work here and I haven t even mentioned Reality Audio or DSEE Extreme upscaling both handy when it comes to listening to music Speaking of audio you ll have the option of using Chromecast Spotify Connect or Apple AirPlay to send your tunes to the A Two HDMI eARC inputs mean you can hook up multiple streaming boxes or gaming consoles And thanks to HDMI support you can expect K and K passthrough to your television so the A is a great option for gamers This soundbar is expensive at and it doesn t come with a separate subwoofer though it does have one built in However Sony does give you multiple options for both a sub and rear satellite speakers The SA SW sub is while the SA SW is For rear speakers the SA RSS is while the truly wireless and much better looking SA RS set is If you re looking to save some money on the soundbar itself Sony offers the HT A for although we ve seen it on sale for recently It packs nearly all of the same bells and whistles as the A only in a channel configuration Runner up premium soundbar Sonos ArcThe top end of Sonos home theater lineup was well overdue for a refresh by the time the company introduced the Arc in This unit replaced the Playbar that debuted in offering directional sound via Dolby Atmos support as the main upgrade The Arc sports a more modern design stellar sound quality and all of Sonos smarts including the ability to automatically calibrate to your living room and when you add more Sonos speakers The price doesn t include a sub but the Playbar didn t come with one either And sadly Sonos doesn t include a second HDMI input for directly connecting devices other than your TV As is typically the case with the company s wares expansion gets expensive quickly as the wireless sub is and satellite One speakers are each However the combination of the Arc and a sub will get you pretty far sound wise even if they are separate purchases Plus the company s wireless subwoofer the Sub Mini works well with this premium soundbar and it clocks in at Read our Full Review of Sonos Arc SoundbarAnother premium soundbar Bowers amp Wilkins Panorama Bowers amp Wilkins introduced its first Dolby Atmos soundbar back in March filling a void in the company s existing home theater lineup The Panorama has a channel configuration but it packs total speakers including two subwoofers and watts of sonic power For that reason the company doesn t think you ll need a dedicated sub Indeed the Panorama does offer ample bass but it s not nearly on the level as a standalone unit This smart soundbar does have a low profile refined design alongside voice capabilities “hidden until lit touch controls and support for aptX Adaptive Apple AirPlay and Spotify Connect Most importantly it s currently available for less than the original MSRP at Best midrange soundbar Sonos BeamSolid sound quality Check Dolby Atmos Yep Compact and easy to set up Uh huh Compatible with other Sonos products for a more robust system You betcha The first gen Sonos Beam has been one of our favorites since it arrived in but there was one thing it didn t have Dolby Atmos That was the big addition to the model though it s a bit limited since the Beam doesn t have any upward firing speakers Sonos manages to make things seem more directional by tweaking audio timing and frequency instead of adding more drivers The new Beam still only has the one HDMI port which means you won t be connecting a gaming console or set top box directly to this It also means that if you have an older TV with an optical jack you ll need an adapter Read our Full Review of Sonos Beam SoundbarRunner up midrange soundbar Samsung HW QBSamsung s mid range QB will cost you but it comes with a bundled subwoofer This model also supports wireless Dolby Atmos connectivity with the latest Samsung smart TVs over WiFi and the channel configuration includes up firing speakers for proper immersive sound The QB supports Q Symphony which allows you to use both the soundbar and your TV speakers for a more robust surround sound setup on some and Samsung TVs SpaceFit Sound automatically calibrates the soundbar sub combo to a room Adaptive Sound optimizes audio for specific content types and Tap Sound allows you to send tunes from a Samsung phone to the QB with a simple tap HDMI eARC connectivity is here as well and so is voice control AirPlay Chromecast and a gaming specific sound mode Another midrange soundbar Sonos RaySonos latest bid for best soundbar may be its most affordable to date but at it s not exactly a budget pick Especially when you consider there are cheaper options that come with a subwoofer Still the compact design doesn t command a lot of space in front of your TV or on your TV stand making it a great option for smaller living spaces The Ray is easy to set up and provides great sound quality for both TV and music There are some trade offs when it comes to the immersive nature of the audio but it s a good option for upgrading your TV sound with minimal fuss Read our Full Review of Sonos Ray SoundbarBest budget soundbar Vizio Vt JIf you re looking for a way to improve your TV sound on a budget Vizio has some high quality options With the Vt J you get a channel setup in a compact soundbar and inch wireless sub combo for This would be a great choice if you don t want your add on TV speaker to take up a lot of space There s no WiFi connectivity but that s really the only sacrifice when it comes to the basics HDMI ARC eARC and optical connections link to your television while a mm aux jack and Bluetooth allow you to play music from your phone or another device DTS Virtual X compatibility offers some of the effect of surround sound without a bigger unit or additional speakers This article originally appeared on Engadget at |
2023-08-16 13:45:03 |
海外TECH |
Engadget |
With some tech savvy, you can disconnect your robot vacuum from the cloud |
https://www.engadget.com/robot-vacuum-security-privacy-irobot-cloud-133008625.html?src=rss
|
With some tech savvy you can disconnect your robot vacuum from the cloudRobot vacuums may seem like mindless suction machines with wheels But today “basically these devices are like smartphones Dennis Giese PhD student at Northeastern University who researches robot vacuum security said From internet capabilities to video recording to voice control robot vacuums have become an advanced Internet of Things technology but the security upkeep hasn t caught up “You don t have any insight what kind of data they re recording what kind of data is stored on the device what kind of data is sent to the cloud Giese told Engadget That might seem harmless for a device that sweeps your floors but the real life consequences have already taken effect Like in when the iRobot Roomba J captured private moments including photos of a woman on the toilet that the company sent to startup Scale AI to label and train AI algorithms Amazon which has experienced countless surveillance and data privacy scandals is currently attempting to acquire iRobot for over billion With all these features robot vacuums can act as a surveillance system in your own home meaning there s a world where someone can access live view functions and spy on you Companies can say this information is secure and only used when needed to improve your experience but there s not enough transparency for reviewers or consumers to figure out what s actually going on “People like me are catching the companies basically lying Giese said So Giese is on a mission to give people more control over the robot vacuums in their homes because every device he s tested has some sort of vulnerability He spoke at DEF CON on Sunday about how people can hack their devices to disconnect from the cloud Not only does this help protect your data from being used by the company but it also gives access to the device so that you can repair it on your own terms The “right to repair ethos means that even if the warranty ends or the company goes bankrupt and stops supporting it you can still use it Unfortunately hacking into your robot vacuum s firmware isn t for newbies It requires a level of technical expertise to figure out according to Giese but owners of robot vacuums can take steps to improve on device data security What you can do is make sure that you wipe all of the data before selling or getting rid of a robot vacuum Even if the device is broken “as a malicious person I can just repair the device and can just power it on and extract the data from it Giese said “If you can do factory resets Or for full data privacy control but none of the convenience stick to the standard push vacuum This article originally appeared on Engadget at |
2023-08-16 13:30:08 |
ニュース |
BBC News - Home |
Australia 1-3 England: Lionesses reach first Women's World Cup final |
https://www.bbc.co.uk/sport/football/66499185?at_medium=RSS&at_campaign=KARANGA
|
Australia England Lionesses reach first Women x s World Cup finalEngland spoil co hosts Australia s party by booking their place in the Women s World Cup final for the first time on a historic night in Sydney |
2023-08-16 13:39:36 |
ニュース |
BBC News - Home |
Rishi Sunak defends government cost-of-living support |
https://www.bbc.co.uk/news/uk-politics-66521633?at_medium=RSS&at_campaign=KARANGA
|
energy |
2023-08-16 13:31:46 |
ニュース |
BBC News - Home |
Ulez expansion: Mayor of London urges councils to 'put their politics aside' |
https://www.bbc.co.uk/news/uk-england-66521469?at_medium=RSS&at_campaign=KARANGA
|
council |
2023-08-16 13:09:06 |
ニュース |
BBC News - Home |
Ukraine war: Ship leaves Odesa despite Russia Black Sea attack fears |
https://www.bbc.co.uk/news/world-europe-66518504?at_medium=RSS&at_campaign=KARANGA
|
odesa |
2023-08-16 13:12:38 |
ニュース |
BBC News - Home |
Maui fire: First victims named as death toll reaches 106 |
https://www.bbc.co.uk/news/world-us-canada-66518502?at_medium=RSS&at_campaign=KARANGA
|
buddy |
2023-08-16 13:43:15 |
ニュース |
BBC News - Home |
Crooked House owners' links to previous major fire |
https://www.bbc.co.uk/news/uk-england-birmingham-66514759?at_medium=RSS&at_campaign=KARANGA
|
blaze |
2023-08-16 13:13:57 |
ニュース |
BBC News - Home |
Rate the players after England reach final |
https://www.bbc.co.uk/sport/football/66521248?at_medium=RSS&at_campaign=KARANGA
|
spain |
2023-08-16 13:13:52 |
コメント
コメントを投稿