投稿時間:2022-06-02 23:29:15 RSSフィード2022-06-02 23:00 分まとめ(35件)

カテゴリー等 サイト名等 記事タイトル・トレンドワード等 リンクURL 頻出ワード・要約等/検索ボリューム 登録日
AWS AWS Open Source Blog Increase app responsiveness with MongoDB Realm mobile database and AWS Wavelength https://aws.amazon.com/blogs/opensource/increase-app-responsiveness-with-mongodb-realm-mobile-database-and-aws-wavelength/ Increase app responsiveness with MongoDB Realm mobile database and AWS WavelengthThis post was contributed by Robert Oberhofer Senior Director of Technology Partnerships at MongoDB This blog post introduces MongoDB Realm and examines its core characteristics and key benefits While Realm is widely used for building mobile applications its capabilities are also relevant for other problem spaces including IoT and Edge Introduction to Realm Realm database … 2022-06-02 13:36:28
AWS AWS Government, Education, and Nonprofits Blog Managing the world’s natural resources with earth observation https://aws.amazon.com/blogs/publicsector/managing-worlds-natural-resources-earth-observation/ Managing the world s natural resources with earth observationWith increasing pressure from climate change loss of biodiversity and demand for natural resources from already stressed ecosystems it has become essential to understand and address environmental changes by making sustainable land use decisions with the latest and most accurate data As part of the Amazon Sustainability Data Initiative ASDI AWS invited Joe Sexton chief scientist and co founder of terraPulse to share how AWS technologies and open data are supporting terraPulse s efforts to provide accurate and up to date information on the world s changing ecosystems 2022-06-02 13:46:51
python Pythonタグが付けられた新着投稿 - Qiita pyenvでビルドが失敗して、pythonをインストールできない https://qiita.com/kojikojiXX/items/097eca9e89354cb5d382 atcoder 2022-06-02 22:58:24
python Pythonタグが付けられた新着投稿 - Qiita 福島県 県民割プラスのクーポンが使える加盟店のPDFをCSVに変換 https://qiita.com/barobaro/items/2b81fdb51d769aecc555 thlibfromurllibparseimpor 2022-06-02 22:55:30
python Pythonタグが付けられた新着投稿 - Qiita ワンポチでブロックチェーンにデータを刻むボタンを作ってみた https://qiita.com/kurikou_XymCity/items/b0836c11629256fd397d symbol 2022-06-02 22:55:05
python Pythonタグが付けられた新着投稿 - Qiita Kneser-NeyスムージングによるN-gram言語モデルを実装してミニマリズム言語トキポナを学習させる話 https://qiita.com/nymwa/items/daedca839430750c3551 kneserney 2022-06-02 22:08:35
AWS AWSタグが付けられた新着投稿 - Qiita S3にフロントエンド環境を構築してみた https://qiita.com/tToyoshima/items/c2700dc892930a90b407 設定 2022-06-02 22:23:06
AWS AWSタグが付けられた新着投稿 - Qiita ECSでタスクが起動しない時にコンテナの中身を見たい! https://qiita.com/P9eQxRVkic02sRU/items/d2c4354f4d4c6b86d662 fargate 2022-06-02 22:04:22
GCP gcpタグが付けられた新着投稿 - Qiita Google Cloud アップデート (5/19-5/25/2022) https://qiita.com/kenzkenz/items/e60b8d5a546a4178ca46 bigquerymayodbc 2022-06-02 22:54:58
Git Gitタグが付けられた新着投稿 - Qiita 【Git】origin/masterってなに? https://qiita.com/monaka45/items/a9908c0c275e27b8699d master 2022-06-02 22:28:51
海外TECH MakeUseOf The 5 Best Photo Editing Software for Windows https://www.makeuseof.com/windows-best-photo-editing-software/ windows 2022-06-02 13:30:13
海外TECH MakeUseOf How to Avoid Getting in Trouble With Instagram https://www.makeuseof.com/avoid-trouble-instagram-community-guidelines/ avoid 2022-06-02 13:15:14
海外TECH DEV Community Restful CRUD with Golang for beginners https://dev.to/samzhangjy/restful-crud-with-golang-for-beginners-23ia Restful CRUD with Golang for beginnersHey guys it s Sam Zhang So in the previous post we finished a simple Hello World request using Golang and Gin Today it s time for us to build something more complex CRUD with Gin Table of ContentsGetting startedInstalling GORMDefining database modelsConnecting to databaseRESTful APIsCreateReadUpdateDeleteConclusion Getting started This tutorial is made for developers who have some experience in programming but relatively new to Go Gin You might want to learn some common programming concepts if you re a total beginner So to start up you ll need to have the hello world program finished from our last post Or of course you could clone it from GitHub to continue Then let s get started CRUD stands for Create Read Update and Delete Those are the four basic operations in the database and we will be implementing it into our Go app today When dealing with databases you could just write some plain old SQL commands and execute directly it using the database drivers But there s a problem with it SQL injection attack So using ORMs is normally a better option We will be using GORM throughout this series just because it s popular and easy to get started with Installing GORM As it described in the docs simply use go get gorm io gorm to install it However GORM needs database drivers in order to connect to databases and do operations I will be using Postgres for now and you can use whatever database you wanted Note Sqlite is not recommended since it doesn t support some complex operations natively But for now you can use it since we don t have the need of complex operations and you can migrate to others in the future So let s install the database driver too go get u gorm io driver postgres or other database provider and GORM is ready to use Defining database models Like other ORMs GORM defines a table using models To define a model you need to declare a struct containing the information about the table For example type lt name gt struct lt field gt lt field type gt is the most basic form of defining a struct in Go I assume that you have some basic knowledge about relational database storage so we won t discuss it very much here In order to create a GORM model we simply need to fill in the information required If we wanted to store a blog post in the database then the following fields might be helpful ID unsigned integer primary key auto increment required Title string required Content string required Created at time defaults to current time So let s create a model for blog posts based on the above fields models post gopackage modelsimport time type Post struct ID uint json id gorm primaryKey Title string json title Content string json content CreatedAt time Time json created at Okay so let me explain all these We defined a GORM model using a struct and declared several fields Here uint is unsigned int in other languages and time Time is the datetime format in Golang But the backticks after the field type might be a little weird for new Go users Those strings are called tags They are using backtick annotation to define key value pairs Struct tags are small pieces of metadata attached to fields of a struct that provide instructions to other Go code that works with the struct The json defines with key should the JSON encoder use when serializing the current field into JSON format And the gorm key will let GORM know some extra information about this field For example here we defined ID as a primary key for the model Connecting to database So now we successfully created the database schema let s connect it to a real database models setup gopackage modelsimport gorm io driver postgres gorm io gorm var DB gorm DBfunc ConnectDatabase dsn host localhost user postgres dbname go blog port sslmode disable timezone Asia Shanghai database err gorm Open postgres Open dsn amp gorm Config change the database provider if necessary if err nil panic Failed to connect to database database AutoMigrate amp Post register Post model DB database In function ConnectDatabase we first defined our data source name and established the database connection Here I used the Postgres driver and you might change it to fit your own need If there s any problems when connecting to our database err will point to the error In this case we will call panic to terminate the whole process panic is a builtin function that acts similar to raise in Python and throw in JavaScript Then we registered our Post model to the database and exported the database variable Note that DB is a global variable that is accessible in every file of package models making operations with database easier without importing everything and then let s call the connection function in our main go main gopackage mainimport samzhangjy go blog models github com gin gonic gin func main router gin Default models ConnectDatabase new router Run localhost And now we ve finally made a connection to the database Time to code the request controllers RESTful APIs Unlike the first post we are going to put all of our request logic into a separate folder called controllers and import them later in main go to define the routes Create Let s start by adding a create method controllers post gopackage controllersimport net http samzhangjy go blog models github com gin gonic gin type CreatePostInput struct Title string json title binding required Content string json content binding required func CreatePost c gin Context var input CreatePostInput if err c ShouldBindJSON amp input err nil c AbortWithStatusJSON http StatusBadRequest gin H error err Error return post models Post Title input Title Content input Content models DB Create amp post c JSON http StatusOK gin H data post You might be wondering why is there struct again Well structs is an important concept in Go and you will see it a lot throughout this series In this case our struct CreateBlogInput defines body schema for request CreateBlog The new tag binding is a Gin validation tag based on Validator If you wanted to know something about Gin bindings here s a great read Then let s focus on CreateBlog We first validated the request body variable input here using context ShouldBindJSON If the body is invalid err would contain some error messages If err contains something then we will simply return a HTTP status code and abort the request This if err statement err nil statement is a commonly used error handling technique in Go If the input is valid we will first create a Post model with data given from the input Then we will call database Create to put this record into the Post table Finally we will return HTTP with the newly created post schema if everything goes as expected And let s bind our controller to a route main gopackage mainimport samzhangjy go blog controllers samzhangjy go blog models github com gin gonic gin func main router gin Default models ConnectDatabase router POST posts controllers CreatePost here router Run localhost Notice that we re passing the controller function itself to router POST without parentheses Run your app with air and use tools like Postman to play around with this endpoint Read Then let s quickly add an endpoint to view every post created controllers post go func FindPosts c gin Context var posts models Post models DB Find amp posts c JSON http StatusOK gin H data posts Unlike the previous request this one has no request body We defined array posts to store the posts created with type models Post DB Find amp posts means to find every entry that exists in the database and store the fetched result to posts Remember to pass in the pointer instead of the actual variable And then quickly bind it to our router main gopackage mainimport samzhangjy go blog controllers samzhangjy go blog models github com gin gonic gin func main router gin Default models ConnectDatabase router POST posts controllers CreatePost router GET posts controllers FindPosts router Run localhost And now you could see the posts you created using CreateBlog Then let s create a route that fetches only one specified post by URL param controllers post go func FindPost c gin Context var post models Post if err models DB Where id c Param id First amp post Error err nil c AbortWithStatusJSON http StatusNotFound gin H error err Error return c JSON http StatusOK gin H data post The new methods here is DB Where and DB First DB Where lets you write SQL query commands replacing the dynamic data with and passing the actual data as the second argument DB First amp post like its name selects the first name of the given collection of data and stores the result inside post context Param lt param name gt is a Gin method to fetch the URL parameter by param name The param name is defined like main gopackage mainimport samzhangjy go blog controllers samzhangjy go blog models github com gin gonic gin func main router gin Default models ConnectDatabase router POST posts controllers CreatePost router GET posts controllers FindPosts router GET posts id controllers FindPost here router Run localhost The slug starting with a colon is defined as url parameters in Gin The string after the colon is the parameter s name which we ll use to fetch the param value A route posts id will match the following posts posts But won t match posts abcd posts Update Then it s time for updating posts controllers post go type UpdatePostInput struct Title string json title Content string json content func UpdatePost c gin Context var post models Post if err models DB Where id c Param id First amp post Error err nil c AbortWithStatusJSON http StatusNotFound gin H error record not found return var input UpdatePostInput if err c ShouldBindJSON amp input err nil c AbortWithStatusJSON http StatusBadRequest gin H error err Error return updatedPost models Post Title input Title Content input Content models DB Model amp post Updates amp updatedPost c JSON http StatusOK gin H data post So we defined a struct containing request body schema again but this time without any validation since everything is optional We copied the code to validate if the current post exists from the previous FindPost method And if the post exists and the request body is valid we will define a new model containing the contents of the newly generated post data In this case its name is updatedPost Then we will fetch the model for the original post using DB Model amp post and update is using model Updates amp updatedPost model Updates will update multiple fields and won t modify the fields that didn t defined in the updated schema updatedPost model Update will only update one field at a time And bind it to the router main gopackage mainimport samzhangjy go blog controllers samzhangjy go blog models github com gin gonic gin func main router gin Default models ConnectDatabase router POST posts controllers CreatePost router GET posts controllers FindPosts router GET posts id controllers FindPost router PATCH posts id controllers UpdatePost router Run localhost Delete And finally here comes the DELETE operation at last controllers post go func DeletePost c gin Context var post models Post if err models DB Where id c Param id First amp post Error err nil c AbortWithStatusJSON http StatusNotFound gin H error record not found return models DB Delete amp post c JSON http StatusOK gin H data success And we need to ensure that the currently given post ID is valid Then we will call DB Delete amp post to delete the post entry from our database Then finally bind it to our router main gopackage mainimport samzhangjy go blog controllers samzhangjy go blog models github com gin gonic gin func main router gin Default models ConnectDatabase router POST posts controllers CreatePost router GET posts controllers FindPosts router GET posts id controllers FindPost router PATCH posts id controllers UpdatePost router DELETE posts id controllers DeletePost router Run localhost Congrats You ve successfully built a collection of simple but working CRUD restful API routes Play it around and try to modify some parts or add some new operations Conclusion This is Part of my learning Go web development I actually learned a lot from writing this series and if there s any mistakes in the post plz point them out I uploaded all the source code used in this post to GitHub Feel free to clone it and play around with it I m Sam Zhang and I ll see you guys next time From Golang Struct Tags explained 2022-06-02 13:27:40
海外TECH DEV Community Medusa v1.3.1: PriceList API, Promotions API, Migrations, And More! https://dev.to/medusajs/medusa-v131-pricelist-api-promotions-api-migrations-and-more-57jb Medusa v PriceList API Promotions API Migrations And More This week a new version of Medusa has been released If you re not familiar with Medusa it s an open source headless commerce platform that recently passed K stars on GitHub in less than a year Earlier this month we released version with many new features then followed it up by version this week for some fixes and enhancements We also published a new release for the Medusa Admin that add a few new UI elements and functionalities This article highlights some of the changes and additions that this update holds If you re interested in learning more details about the release check out our longer release post PriceList APIThe addition of the PriceList API adds another layer of customization and extendibility to Medusa by allowing merchants to have even more control over the pricing of products They can apply specific prices based on advanced conditions and rules This change comes of course with a new interface in our Admin that allows creating and editing price lists with many handy configurations Promotions APIThe use case of Promotions API has expanded from standard promotions to advanced promotions conditions For example a merchant might want to apply discounts for their VIP customers This API will also open the doors for providing better integration with third party discount services and tools for even more powerful features MigrationsWith these new features we ve introduced Migration scripts that are necessary to run after Medusa s upgrade To learn more about this check out the upgrade guide for version Clean UpAs part of our update to the Medusa Admin we ve cleaned it up to remove all unused dependencies and components New API ReferencesWe re excited to announce two new features in our documentation the Services Reference and the Events Reference Services can be used in any of your custom endpoints services and subscribers The service reference gives developers a better understanding of what services are available to use and what are some of their methods The event s reference shows developers what events they can listen to in subscribers when they are triggered and what data payload can be expected along with the event How to Upgrade If you want to upgrade your Medusa server run the following command to update the necessary dependencies npm install medusajs medusa latest medusa interfaces latestAlso read the upgrade guide for version Coming Soon Advanced Next js StorefrontP S We re currently hosting a contest related to customizing the existing Next js storefront and the winner receives a Medusa t shirt Read more about it here We re working on a new Next js starter with a cleaner design and more advanced features This new starter will allow developers to enable or disable features just by changing the store configurations Some of the features that will be added and are available to be switched on or off include search using the MeiliSearch plugin customer accounts with the ability to make changes to their profiles and accounts such as change addresses and see order history customer self service returns and exchange multi regional support and more 2022-06-02 13:15:14
海外TECH DEV Community Coding and ADHD - Can't Keep Going https://dev.to/abbeyperini/coding-and-adhd-cant-keep-going-5aj2 Coding and ADHD Can x t Keep GoingThe idea that anyone should be able to sit down and focus for four hours on command is a dangerous myth Any brain requires glucose to keep your brain going and breaks to keep you engaged ADHD brains add an extra hurdle when you re trying to focus on a schedule You ll have to keep pivoting in your strategies What works today may not work tomorrow and might begin to work again a month from now Limit Provide DistractionsI m hyperactive so counterintuitively my ability to focus often relies on fairly loud background noise I ve chosen For coding it s usually music and often lofi beats For me this blocks out smaller sounds I might want to investigate and provides a back up focus for when I get bored I pick noises that can t sustain my focus for long so I ll naturally gravitate back towards doing the task It really helps when I m waiting for the development server to load for example For the less hyperactive sustaining focus often involves blocking out all distractions This can be anything from temperature to lighting to clutter to the clothes you re wearing I ve heard many people describe putting a note on their office door or desk asking others not to distract them during focus time Phones and computers often have a focus mode that can limit notifications for a set time During classes presentations and meetings where blasting music would be rude and I desperately want to move I take notes try to come up with questions to ask the presenter draw and use fidget toys Creating a thought dump can be very helpful We all know the feeling I have to act on this thing I remembered NOW or I won t remember it seconds from now If you have a place to write those thoughts down while you re working you ll know you can come back to it later Working with Your BrainYou can use every trick and tip in the book but ADHD brains love to change the rules for what will work constantly If you find patterns in your productivity use them For example my best time for getting work done is like pm to pm Sometimes I can get in the groove when I sit down at am but if I can t I focus on tasks that will set me up for success later I ll do organizational tasks I ve been putting off check and respond to emails and messages and sometimes time block the rest of the day This is another area in which developer jobs can suit ADHD brains They re often pretty lenient about schedule as long as the work is getting done Notice things that regularly provide just enough time for you to get distracted We re developers so these are opportunities to automate In a comment on the last blog destynova describes automating alerts when his builds and tests finish gwenshap recommends streamlining your CI CD pipeline and Josh Comeau recommends chaining npm start and npm install Often for people with ADHD acknowledging the desire to pivot between tasks is very helpful If you can t get started on one task on the list but kinda want to do another do that one As long as you re still moving towards the goal there s no harm in bribing yourself with minutes of the thing you want to do just to get going on the thing you don t want to do Working with the way your brain focuses will probably work better than trying to force it to focus like someone else s brain would Another counterintuitive tip rewarding yourself at the beginning works way better for ADHD brains than promising yourself a reward at the end Literally eat a square of chocolate or whatever you can bribe yourself with and then try the thing Finally celebrate that you did the thing I don t care if the thing isn t done or it isn t done perfectly congratulate yourself for trying and putting in effort Anything you can do to give your brain positive feedback will help combat the shame and negative messaging you ve received in the past Embrace the Lack of ScheduleADHD people do not form habits like neurotypicals There s some variation in how long it takes people to form habits but it s normally somewhere in the months range I ve been trying to cultivate a morning routine for years and at this point I can reliably wash my face and brush my teeth but putting on moisturizer is still hit or miss Everything about planning out our day and making sure things get done is manual I leave calendar notifications on and write down every event I have to attend on my to do list and still end up being late or missing meetings I ve had success asking my teammates to ping me if I m RSVPed yes to a meeting but nowhere to be found Every time I got a ping that person got a shout out in retrospective I even have to plan breaks or I will find a way to entertain myself productively or not with my computer for several hours Based on how my brain works my daily goals are be available during my scheduled work hours make progress on ticket personal to do items like watering the plants an amount of water to drink and planned meals and breaks Nothing else is strictly scheduled because I will ignore alarms and then declare the task failed because I didn t do it on time The biggest gift I gave myself was accepting that tasks often take me longer than they should As long as they re getting done that s something to celebrate RestIt s tempting to expect yourself to be able to accomplish the same amount every day ADHD brains naturally have an ebb and flow One day I ll be in a shame spiral about my inability to start a ticket and the next day I ll get days worth of tickets done However that really productive day will take its toll If I manage to chain really productive days together I ll often crash and have an equal or larger number of unproductive days If I start to feel exhausted frustrated or overwhelmed I have to remind myself to try eating food or taking a minute walk Often that is enough to get me back on track If not I ask myself if I m trying to multi task again or re evaluate my plan for the day and take some items off Ultimately this is another area in which people with ADHD struggle to separate themselves from the constant negative messaging they get about their productivity from society I m still trying to internalize that I do not need to be productive to earn rest ConclusionDid I miss a resource or tip you love Interested in fidget toy reviews Leave a comment Coming soon Can t StopCan t Remember 2022-06-02 13:14:17
海外TECH DEV Community Automate identity document processing with Document AI https://dev.to/googlecloud/automate-identity-document-processing-with-document-ai-3h2p Automate identity document processing with Document AIHow many times have you filled out forms requesting personal information It s probably too many times to count When online and signed in you can save a lot of time thanks to your browser s autofill feature In other cases you often have to provide the same data manually again and again The first Document AI identity processors are now generally available and can help you solve this problem In this post you ll see how to…Process identity documents with Document AICreate your own identity form autofiller Use casesHere are a few situations that you ve probably encountered Financial accounts Companies need to validate the identity of individuals When creating a customer account you need to present a government issued ID for manual validation Transportation networks To handle subscriptions operators often manage fleets of custom identity like cards These cards are used for in person validation and they require an ID photo Identity gates When crossing a border or even when flying domestically you need to pass an identity check The main gates have streamlined processes and are generally well equipped to scale with the traffic On the contrary smaller gates along borders can have manual processes sometimes on the way in and the way out which can lead to long lines and delays Hotels When traveling abroad and checking in you often need to show your passport for a scan Sometimes you also need to fill out a longer paper form and write down the same data Customer benefits For benefit certificates or loyalty cards you generally have to provide personal info which can include a portrait photo In these examples the requested info including the portrait photo is already on your identity document Moreover an official authority has already validated it Checking or retrieving the data directly from this source of truth would not only make processes faster and more effective but also remove a lot of friction for end users Identity processors Processor typesEach Document AI identity processor is a machine learning model trained to extract information from a standard ID document such as Driver licenseNational IDPassportNote an ID can have information on both sides so identity processors support up to two pages per document AvailabilityGenerally available as of June you can use two US identity processors in production ProcessorAPI typeUS Driver License ParserUS DRIVER LICENSE PROCESSORUS Passport ParserUS PASSPORT PROCESSORCurrently available in Preview The Identity Doc Fraud Detector to check whether an ID document has been tampered withThree French identity processorsProcessorAPI typeIdentity Doc Fraud DetectorID FRAUD DETECTION PROCESSORFrance Driver License ParserFR DRIVER LICENSE PROCESSORFrance National ID ParserFR NATIONAL ID PROCESSORFrance Passport ParserFR PASSPORT PROCESSORNotes More identity processors are in the pipe To request access to processors in Preview please fill out the Access Request Form Processor creationYou can create a processor Manually from Cloud Console web admin UI Programmatically with the APIProcessors are location based This helps guarantee where processing will occur for each processor Here are the current multi region locations LocationAPI locationUnited StatesusEuropean UnioneuOnce you ve created a processor you reference it with its ID PROCESSOR ID hereafter Note To manage processors programmatically see the codelab Managing Document AI processors with Python Document processingYou can process documents in two ways Synchronously with an online request to analyze a single document and directly use the resultsAsynchronously with a batch request to launch a batch processing operation on multiple or larger documents Online requestsExample of a REST online request The method is named process The input document here is a PNG image base encoded This request is processed in the European Union The response is returned synchronously POST v projects PROJECT ID locations eu processors PROCESSOR ID process rawDocument content iVBORwKGg… mimeType image png skipHumanReview true Batch requestsExample of a REST batch request The method is named batchProcess The batchProcess method launches the batch processing of multiple documents This request is processed in the United States The response is returned asynchronously output files will be stored under my storage bucket output POST v projects PROJECT ID locations us processors PROCESSOR ID batchProcess inputDocuments gcsDocuments documents gcsUri gs my storage bucket input id doc pdf mimeType application pdf gcsUri gs my storage bucket input id doc tiff mimeType image tiff gcsUri gs my storage bucket input id doc png mimeType image png gcsUri gs my storage bucket input id doc gif mimeType image gif documentOutputConfig gcsOutputConfig gcsUri gs my storage bucket output skipHumanReview true InterfacesDocument AI is available through the usual Google Cloud interfaces The RPC API low latency gRPC The REST API JSON requests and responses Client libraries gRPC wrappers currently available for Python Node js and Java Cloud Console web admin UI Note With the client libraries you can develop in your preferred programming language You ll see an example later in this post Identity fieldsA typical REST response looks like the following The text and pages fields include the OCR data detected by the underlying ML models This part is common to all Document AI processors The entities list contains the fields specifically detected by the identity processor text … pages … entities textAnchor … type Family Name mentionText PICHAI confidence pageAnchor … id textAnchor … type Given Names mentionText Sundar confidence pageAnchor … id … Here are the detectable identity fields Entity typeCommentPortraitBounding box portrait photo Family NameStringGiven NamesStringDocument IdStringExpiration DateDate normalization Date Of BirthDate normalization Issue DateDate normalization AddressStringMRZ CodeString Machine Readable Zone Please note that Address and MRZ Code are optional fields For example a US passport contains an MRZ but no address Fraud detectionAvailable in preview the Identity Doc Fraud Detector helps detect tampering attempts Typically when an identity document does not pass the fraud detector your automated process can block the attempt or trigger a human validation Here is an example of signals returned Entity typeExamplefraud signals is identity document NOT AN ID fraud signals suspicious words PASS fraud signals image manipulation POSSIBLE IMAGE MANIPULATION Sample demoYou can process a document live with just a few lines of code Here is a Python example import google cloud documentai v as docaidef process document file typing BinaryIO mime type str project id str location str processor id str gt docai Document api endpoint api endpoint f location documentai googleapis com client docai DocumentProcessorServiceClient client options api endpoint raw document docai RawDocument content file read mime type mime type name client processor path project id location processor id request docai ProcessRequest raw document raw document name name skip human review True response client process document request return docai Document response document This function uses the Python client library The input is a file any format supported by the processor client is an API wrapper configured for processing to take place in the desired location process document calls the API process method which returns results in seconds The output is a structured Document You can collect the detected fields by parsing the document entities def id data from document document docai Document gt dict id data defaultdict dict for entity in document entities key entity type page index value entity mention text confidence normalized None None if entity page anchor page index entity page anchor page refs page if not value Send the detected portrait image instead image crop entity document entity value data url from image image if entity confidence confidence int entity confidence if entity normalized value normalized entity normalized value text id data key page index dict value value confidence confidence normalized normalized return id dataNote This function builds a mapping ready to be sent to a frontend A similar function can be used for other specialized processors Finalize your app Define your user experience and architectureImplement your backend and its APIImplement your frontend with a mix of HTML CSS JSAdd a couple of features file uploads document samples or webcam capturesThat s it you ve built an identity form autofillerHere is a sample web app in action Here is the processing of a French national ID dropping images from the client Note For documents with multiple pages you can use a PDF or TIFF container In this example the two uploaded PNG images are merged by the backend and processed as a TIFF file And this is the processing of a US driver license captured with a laptop p webcam Notes Did you notice that the webcam capture is skewed and the detected portrait image straight That s because Document AI automatically deskews the input at the page level Documents can even be upside down Some fields such as the dates are returned with their normalized values This can make storing and processing these values a lot easier and less error prone for developers The source code for this demo is available in our Document AI sample repository MoreTry Document AI in your browserDocument AI documentationDocument AI how to guidesSending a processing requestFull processor and detail listRelease notesCodelab Specialized processors with Document AICode Document AI samplesStay tuned the family of Document AI processors keeps growing and growing 2022-06-02 13:07:59
Apple AppleInsider - Frontpage News Daily deals June 2: discounted iPhone 12, 11% off Xbox Series X with 'Elden Ring,' Apple TV 4K for $150, more https://appleinsider.com/articles/22/06/02/daily-deals-june-2-discounted-iphone-12-11-off-xbox-series-x-with-elden-ring-apple-tv-4k-for-150-more?utm_medium=rss Daily deals June discounted iPhone off Xbox Series X with x Elden Ring x Apple TV K for moreThursday s best deals include an iPad scratch and dent sale off Bose QuietComfort Radeon RX graphics card for and much more Best deals June AppleInsider checks online stores daily to uncover discounts and offers on hardware and other products including Apple devices smart TVs accessories and other items The best offers are compiled into our regular list for our readers to use and save money Read more 2022-06-02 13:24:40
Apple AppleInsider - Frontpage News When retail is folded in, Apple pays employees less than Google or Microsoft https://appleinsider.com/articles/22/06/02/when-retail-is-folded-in-apple-pays-employees-less-than-google-or-microsoft?utm_medium=rss When retail is folded in Apple pays employees less than Google or MicrosoftA new examination of salaries across the Standard and Poor S amp P measure of large US firms says Apple pays less than its rivals ーbut only when its enormous worldwide retail staff are included It s possible to compare the salaries that two people doing the same job get as evidenced by how Apple has been revealed to pay women less than men It s not though possible to make definitive overall comparisons between companies because their constituent parts are so different Consequently while the Wall Street Journal has attempted a comparison between large US firms it notes that it cannot usefully calculate an average The mean or average pay earned at Apple or Google for instance is meaningless since there will be extremely high earners like Tim Cook on the board and per hour retail workers in the same list Read more 2022-06-02 13:21:35
海外TECH Engadget The best wireless headphones you can buy right now https://www.engadget.com/best-headphones-150030794.html?src=rss The best wireless headphones you can buy right nowWhen it comes to wireless headphones the over ear noise cancelling models typically offer the most comprehensive set of features we want The best options combine stellar audio with powerful active noise cancellation ANC and other handy tools to create as complete a package as possible Of course some companies do this better than others For this guide we ll focus primarily on the over ear style and offer a range of prices so you can decide how much you re comfortable spending Best overall Sony WH XMBilly Steele EngadgetSony s X line has been our top pick for a long time now Until another company can manage to pack in as many features as Sony and do so with a stellar mix of sound and effective ANC the crown is safe With the WH XM Sony redesigned its flagship headphones making them way more comfortable to wear for long periods of time The company also made noticeable improvements to the active noise cancellation adding a separate V chip in addition to the QN that was inside the M There are now eight total ANC mics as well the previous model only had four This all combines to better block high frequencies including human voices The XM still has all of the features that typically make Sony s top of the line headphones showstoppers That includes hour battery life and crisp clear sound with balanced tuning and punchy bass A combo of touch controls and physical buttons give you on board access to music calls and noise modes without reaching for your phone Speak to Chat automatically pauses audio when you begin talking and like previous Sony headphones the M can change noise modes based on your activity or location Plus this model offers better call quality than most of the competition The only real downside is that they re more than the WH XM Buy Sony WH XM at Amazon Runner up Bose QuietComfort Billy Steele EngadgetThe Bose was one of our top picks last time around but the company recently revived a workhorse with the QuietComfort The design is mostly unchanged from the previous QC models which could be a deal breaker for some Once you get past that though the QC combines Bose s excellent active noise cancellation with clear and balanced audio You can expect up to hours of battery life on a charge and a comfortable fit that doesn t get tiresome during long listening sessions We ve already seen them on sale for less than full price which makes the QuietComfort even more compelling Buy QuietComfort at Amazon Best budget Sony WH CHNBilly Steele Engadget If you want capable noise cancellation that won t break the bank Sony s WH CHN is a solid bet These headphones are much less than a flagship model at ーand they re often on sale for even less ーbut you will sacrifice a few things The biggest place these fall short is overall sound quality There s decent range and good clarity but they lack deep punchy bass that would help create a fuller sound For casual listeners who want a decent set of headphones that still have ANC these will likely offer enough in the sonic department In terms of noise cancellation the WH CHN exhibits enough sound blocking power to minimize distractions Thanks to Sony s dual noise sensor technology these headphones pick up a lot of that unwanted noise and automatically select the best noise cancellation for your environment There s also an ambient sound option should you need to keep tabs on what s going on around you With hours of battery life a quick charge feature and handy onboard controls the WH CHN offer a glimpse of flagship headphone luxury for less than Buy Sony WH CHN at Amazon Other alternativesAirPods Max Billy Steele Engadget After months of rumors we finally discovered that Apple successfully built a set of premium over ear headphones The AirPods Max combine the best features of AirPods earbuds with noise cancelling including spatial audio and easy access to Siri Right now spatial audio is limited and there s no high res music streaming However even with work to be done the overall audio quality stellar ambient sound mode and the all Apple aesthetics are enough to recommend the AirPods Max That is if you re willing to splurge Buy AirPods Max at Amazon Technics EAH ATechnics PanasonicBack at CES Panasonic announced the EAH A a new set of ANC headphones under the iconic Technics brand While most of the features are what you see on any number of headphones one figure stood out The company says you can expect up to hours of battery life on the A and that s with active noise cancellation enabled These are currently in my stable of review units for detailed analysis but I have already tested them on a long flight The ANC is impressive and they re comfortable enoughto avoid becoming a burden after several hours Sound quality is also quite good there s LDAC support too and there are enough features here to justify the premium price tag Buy EAH A at Amazon Audio Technica ATH MxBTBilly Steele Engadget The wireless version of Audio Technica s M headphones may not have ANC but that s okay The ATH MxBT quickly became one of my favorite sets when it debuted in thanks to the warm natural sound profile and a very comfy fit The company revamped the wireless model in adding multipoint connectivity quick access to Alexa and a low latency mode in the MxBT Everything else from the previous model is still here and that s excellent news If you spend most of your time listening to music in a spot where you don t need active noise cancellation to block out the world the MxBT is an excellent choice at nbsp Buy ATH MxBT at Amazon 2022-06-02 13:45:20
海外TECH Engadget Amazon to pull Kindle e-readers and bookstore from China https://www.engadget.com/amazon-kindle-china-shutdown-132935052.html?src=rss Amazon to pull Kindle e readers and bookstore from ChinaChinese readers are about to lose some choice in e books Reutersreports Amazon is pulling Kindle products from China over the course of the next two years The company will stop offering Kindle e readers to local retailers as of today and plans to shutter its digital bookstore in the country on June th The Kindle app will leave Chinese online stores on June th and customers will have until then to download any books they ve already purchased Amazon will still provide warranty service and other help for Kindle e readers and will accept returns for quot non quality issues quot for any device bought after January st Hardware apps and books will still be usable after the cutoff In its notice Amazon stressed that this didn t represent a withdrawal from China The company had a quot long term commitment quot that included online shopping and smart home devices Amazon also told Reuters that this wasn t due to censorship or other government pressure and that it occasionally quot make s adjustments quot following reviews Poor sales might play a role While Amazon is a frontrunner in the e reader and e book markets for numerous countries it has struggled in China as of late The country was once the Kindle s largest market with internal data obtained by Reuters showing that it represented over percent of e reader sales in The rise of Chinese competitors like Xiaomi andTikTok parent ByteDance eroded Amazon s share however and iiMedia Research analyst Zhang Yi told Nikkei that the Kindle brand is now quot relatively niche quot in the region The Chinese are more likely to read with their phones and domestic e book services like Tencent s China Literature dominate where the Kindle app isn t even in the top Amazon isn t the only American company scaling back its Chinese presence Airbnb LinkedIn and Yahoo Engadget s parent company have either limited services or withdrawn entirely Amazon s exit from e reading is one of the more prominent examples though and illustrates how difficult it can be for US firms to court Chinese audiences 2022-06-02 13:29:35
海外TECH Engadget What we bought: How BenQ’s Screenbar completed my home office setup https://www.engadget.com/benq-screenbar-irl-131550958.html?src=rss What we bought How BenQ s Screenbar completed my home office setupOne of the first things I set out to do when I joined Engadget in the summer of was to build a beautiful home office At my previous job I didn t get many opportunities to work remotely so it wasn t a priority That turned out to be a mistake because when I began working from home I found it quickly wore me down My kitchen simply wasn t cutting it as an office so I set out to change things Igor Bonifacic EngadgetPiece by piece the office I built in my bedroom came together into a space where I enjoyed sitting down to write But it wasn t until this year that it felt like it was complete The piece that was missing was the BenQ Screenbar a lighting fixture you install on your monitor I put off buying the Screenbar for a few years mostly because of its CAD USD price tag So why then didn t I buy a regular table lamp you ask Well the Screenbar drew my eye for a few reasons I live in a small condo in Toronto so a lamp that could sit on my monitor instead of my table was appealing because space is at a premium especially on my small desk Additionally the Screenbar shares a feature I love on the Philips Hue lights Out of the box you can adjust the color temperature of its LEDs ーno need to buy separate bulbs BenQ also claims the Screenbar produces less glare than a traditional table lamp due to how you position it on top of your monitor Igor Bonifacic EngadgetSetup is also easy A USB C to USB A cable connects the Screenbar to your computer providing it with all the power it needs You don t need to install any software on your PC to use the device Four capacitive buttons on the top allow you to turn the Screenbar on and off adjust the color temperature and brightness or turn on automatic brightness BenQ sells a more expensive version of the Screenbar that comes with a puck you can place on your desk for more convenient access to the controls but that s unnecessary for most people The one downside of the Screenbar is that it takes up space you could otherwise use to mount a webcam With a flat inch monitor like my Dell it s possible to fit both but neither could sit dead center Depending on your needs that could dissuade you entirely from considering the BenQ Screenbar For me it was an easy decision to make I don t need to do a lot of Zoom calls The position of my office desk also isn t ideal for video calling When I sit down to write my back faces a wall to wall window That s not an easy scene for a web camera to expose My solution has been to use my MacBook Air and sit by the side of the window when I need to jump on Zoom Igor Bonifacic EngadgetLooking back now I wish I had bought the Screenbar earlier To say it has transformed the atmosphere of my bedroom and office would be an understatement Winter in Toronto is a long dark affair In January and February the sun can set as early as PM My mood like many people s can vary greatly depending on the amount and quality of light that filters into my home The fact you can adjust the color temperature of the Screenbar s LEDs between K and K means it can produce warm bright sunlight esque whites making it ideal for all day use and even color sensitive work like photo editing In my experience it s the perfect solution for a small space 2022-06-02 13:15:50
海外TECH Engadget TCL is jumping on the pen phone trend with the Stylus 5G https://www.engadget.com/tcl-announces-its-first-stylus-phone-tcl-stylus-5-g-specs-price-availability-130046572.html?src=rss TCL is jumping on the pen phone trend with the Stylus GA couple of years ago Motorola introduced its first phone with a built in stylus which quickly became one of the company s best selling handsets And now TCL is jumping on the trend with its first attempt at making a budget Galaxy Note alternative with the TCL Stylus G Featuring a large inch FHD display the TCL Stylus G provides ample room for things like drawing taking notes or simply watching videos And similar to other TCL handsets the phone features a blue light filter and support for the company s NXTVISION tech which can upscale SDR content to HDR to improve things like contrast and color saturation in both movies and games Other specs include a mAh battery an octa core Mediatek Dimensity chip GB of RAM and GB of storage Thankfully unlike a lot of premium smartphones the Stylus G still comes with a microSD card slot for expandable storage and a mm jack for wired audio Cameras include a MP main sensor in back along with a MP ultrawide lens a MP depth sensor and even a MP macro cam Meanwhile in front there s a MP selfie shooter TCLAs for the stylus just like on a Galaxy Note or more recently the Galaxy S Ultra the TCL Stylus G has a built in storage slot for its pen along with a number of pre installed stylus apps There s a feature similar to Samsung s Screen Off memo that lets you start taking notes without needing to unlock your phone first There are also dedicated shortcuts for grabbing screenshots and creating custom GIFs And thanks to a partnership with MyScript the phone also comes with free subscriptions for the Nebo and MyScript Calculator apps which allow you to convert handwritten notes or formulas into text Unfortunately the Stylus G lacks some of the advanced functions you get on more expensive alternatives The phone s pen is a passive stylus so it can t be used as a remote camera shutter or presentation tool and despite having G in its name the phone only supports sub Ghz G That said TCL claims the Stylus G has percent less latency than similarly priced rivals like the Moto Stylus G So in the end perhaps the biggest concern about the phone is limited software support as TCL is only promising one major Android OS update and just two years of security patches However if you re looking for a super affordable phone with a built in pen it s nice to see a company other than Motorola test the market with the TCL Stylus G The phone is available today on T Mobile and Metro 2022-06-02 13:00:46
Cisco Cisco Blog Optics for hyperscale data centers (Part 1 of 4): Cisco Optics Podcast Episode 25 notes https://blogs.cisco.com/sp/optics-for-hyperscale-data-centers-part-1-of-4-cisco-optics-podcast-episode-25-notes Optics for hyperscale data centers Part of Cisco Optics Podcast Episode notesJoin us for Episode of the Cisco Optics Podcast where we begin a second conversation with Ron Horan who runs Product Management for the Cisco Client Optics Group 2022-06-02 13:03:56
ニュース BBC News - Home In pictures: The Royal Family at Jubilee celebrations https://www.bbc.co.uk/news/uk-61672048?at_medium=RSS&at_campaign=KARANGA colour 2022-06-02 13:35:43
ニュース BBC News - Home Travel industry plea for overseas workers rejected https://www.bbc.co.uk/news/business-61671835?at_medium=RSS&at_campaign=KARANGA special 2022-06-02 13:31:23
ニュース BBC News - Home Jack Leach: England spinner out of New Zealand Test with concussion https://www.bbc.co.uk/sport/cricket/61673902?at_medium=RSS&at_campaign=KARANGA concussionengland 2022-06-02 13:11:06
ニュース BBC News - Home Platinum Jubilee: Crowds cheer Queen at palace as Jubilee begins https://www.bbc.co.uk/news/uk-61674520?at_medium=RSS&at_campaign=KARANGA colour 2022-06-02 13:09:25
北海道 北海道新聞 当別「赤ちゃんポスト」、設置に法規制なく道が苦慮 安全性確保に疑問 https://www.hokkaido-np.co.jp/article/688905/ 石狩管内 2022-06-02 22:37:23
北海道 北海道新聞 芝刈り機の下敷き、75歳男性死亡 足寄 https://www.hokkaido-np.co.jp/article/688904/ 十勝管内 2022-06-02 22:21:00
北海道 北海道新聞 広6―3日(2日) 日本ハム逆転負け https://www.hokkaido-np.co.jp/article/688895/ 日本ハム 2022-06-02 22:15:35
北海道 北海道新聞 上川管内75人感染 新型コロナ https://www.hokkaido-np.co.jp/article/688684/ 上川管内 2022-06-02 22:09:36
北海道 北海道新聞 沖縄在住の塩川さん 東京→稚内縦断に挑戦 「歩けるのは平和だから。ちむどんどんしている」 1千キロ踏破 函館に到達 https://www.hokkaido-np.co.jp/article/688901/ 本土復帰 2022-06-02 22:06:00
北海道 北海道新聞 エリザベス女王在位70年を祝賀 パレードで華やかに開幕、英国 https://www.hokkaido-np.co.jp/article/688900/ 開幕 2022-06-02 22:05:00
北海道 北海道新聞 平野佳寿が最年長200セーブ 38歳2カ月、史上7人目 https://www.hokkaido-np.co.jp/article/688899/ 平野佳寿 2022-06-02 22:05:00
北海道 北海道新聞 NY円、129円後半 https://www.hokkaido-np.co.jp/article/688898/ 外国為替市場 2022-06-02 22:05:00

コメント

このブログの人気の投稿

投稿時間:2021-06-17 05:05:34 RSSフィード2021-06-17 05:00 分まとめ(1274件)

投稿時間:2021-06-20 02:06:12 RSSフィード2021-06-20 02:00 分まとめ(3871件)

投稿時間:2020-12-01 09:41:49 RSSフィード2020-12-01 09:00 分まとめ(69件)