投稿時間:2022-08-05 12:35:09 RSSフィード2022-08-05 12:00 分まとめ(35件)

カテゴリー等 サイト名等 記事タイトル・トレンドワード等 リンクURL 頻出ワード・要約等/検索ボリューム 登録日
ROBOT ロボスタ 東芝インフラが「ローカル5G共創センター」を開設 最新通信を使った技術の実証実験の場に 社外にも開放 https://robotstart.info/2022/08/05/toshiba-creative-circuit.html 東芝インフラが「ローカルG共創センター」を開設最新通信を使った技術の実証実験の場に社外にも開放シェアツイートはてブ東芝インフラシステムズ株式会社は、東芝府中事業所に「ローカルG」を利用するアプリケーションの実証試験ができるラボ『CreativeCircuitLG』を開設した。 2022-08-05 02:25:33
IT ITmedia 総合記事一覧 [ITmedia ビジネスオンライン] 仕事のストレスによる“健康リスク”が高い業種ランキング https://www.itmedia.co.jp/business/articles/2208/05/news090.html itmedia 2022-08-05 11:40:00
IT ITmedia 総合記事一覧 [ITmedia News] パナのエアコンに不具合 「AI快適」冷房中に運転停止 ソフト更新で解消 https://www.itmedia.co.jp/news/articles/2208/05/news096.html itmedia 2022-08-05 11:37:00
IT ITmedia 総合記事一覧 [ITmedia ビジネスオンライン] 「理想の地方暮らしができそう」と思う都道府県 3位は「山梨県」、2位と1位は? https://www.itmedia.co.jp/business/articles/2208/05/news083.html 意識調査 2022-08-05 11:10:00
IT ITmedia 総合記事一覧 [ITmedia Mobile] OnePlus 10T、米国で9月に発売へ 「Snapdragon 8+ Gen 1」搭載で649ドルから https://www.itmedia.co.jp/mobile/articles/2208/05/news094.html itmediamobileoneplust 2022-08-05 11:05:00
TECH Techable(テッカブル) 内・外カメラ両方を保護できるiPhoneケース「Revo Case」 https://techable.jp/archives/183579 iphone 2022-08-05 02:00:09
AWS AWS Japan Blog ハイブリッドノード管理のためのAWS Systems Manager ハイブリッドアクティベーションを自動化する https://aws.amazon.com/jp/blogs/news/automate-aws-systems-manager-activation-for-hybrid-managed-node-registration/ supportengineerwithawsp 2022-08-05 02:58:46
python Pythonタグが付けられた新着投稿 - Qiita [sphinx] WARNING Inline interpreted text or phrase reference start-string without end-string. https://qiita.com/flcn-x/items/c405b912c01d19ff750d idocfosourcedirmoduledirs 2022-08-05 11:59:19
python Pythonタグが付けられた新着投稿 - Qiita Raspberry-Py ロボットカー製作Go学習 https://qiita.com/tkurume/items/189efae9fd6561105a1d visitour 2022-08-05 11:23:24
python Pythonタグが付けられた新着投稿 - Qiita Pythonでスプレッドシートを操作したい! https://qiita.com/w-matayoshi/items/4df76bfd48170ae30d45 pythonjupyterlab 2022-08-05 11:07:20
Ruby Rubyタグが付けられた新着投稿 - Qiita 【Rails】好きなログファイルを作って出力 https://qiita.com/MATO/items/9a4c25e19eccdc087423 telogmsgaaaaaaaaaaaaalogi 2022-08-05 11:21:05
golang Goタグが付けられた新着投稿 - Qiita Raspberry-Py ロボットカー製作Go学習 https://qiita.com/tkurume/items/189efae9fd6561105a1d visitour 2022-08-05 11:23:24
Ruby Railsタグが付けられた新着投稿 - Qiita 【Rails】好きなログファイルを作って出力 https://qiita.com/MATO/items/9a4c25e19eccdc087423 telogmsgaaaaaaaaaaaaalogi 2022-08-05 11:21:05
海外TECH DEV Community Creating Flappy Bird with pygame. Part - 0 https://dev.to/pulimoodan/creating-flappy-bird-with-pygame-part-0-50fn Creating Flappy Bird with pygame Part IntroductionI am making the famous Flappy bird game using python and it s library called pygame It is so simple to make and much addictive to play It requires only lines of codes There is a web version of this game you can find at flappybird io About flappyFlappy Bird was a mobile game developed by Vietnamese video game artist and programmer Dong Nguyen Vietnamese Nguyễn HàĐông under his game development company Gears The game is a side scroller where the player controls a bird attempting to fly between columns of green pipes without hitting them Nguyen created the game over the period of several days using a bird protagonist that he had designed for a cancelled game in Pygamepygame is a Python wrapper for the SDL library which stands for Simple DirectMedia Layer SDL provides cross platform access to your system s underlying multimedia hardware components such as sound video mouse keyboard and joystick pygame started life as a replacement for the stalled PySDL project The cross platform nature of both SDL and pygame means you can write games and rich multimedia Python programs for every platform that supports them Install pygame using pip if you have already installed python pip install pygameImport it into your python program and intializeimport pygamepygame init ProjectCreate a project folder named flappy and create a python file named flappy py in it AssetsWe need some sprite assets to make this game The bird sprites with animated wings the green pipes ground background and the restart button You can find the assets heredownload the assets and keep it in a folder named img So the file structure would look like this flappy img bg png bird png bird png bird png ground png pipe png restart png flappy py Basic setupstart you code by importing required modules import pygamefrom pygame locals import import randompygame locals module contains various constants used by pygame We use random for generating random pipes through the sidescroller Initialize pygamepygame init Define screen height and width so we can create the window screen width screen height screen pygame display set mode screen width screen height pygame display set caption Flappy Bird And finally we need a game loop to run until the player exits run Truewhile run passMake sure to quit pygame at the end of the codepygame quit Now run the python program from your terminal python flappy pyThis will open a new blank window with the height and width we defined before But now we cannot close the window except we interrupt the terminal This is because we did not instruct the loop to break when the user closes the window and it will trigger the pygame quit at the end of the code We have to loop through the pygame events and check if it s a closing event Then make the run to false which will break the loop for event in pygame event get if event type pygame QUIT run FalseNow we will be able to close the window after running the program BackgroundLet s draw the background first So import the bg sprite from the img folder and scale it according to the screen bg pygame image load img bg png bg pygame transform scale bg And inside the loop draw the bg using blit function draw backgroundscreen blit bg also add the update function at the end of the looppygame display update Run the program now and you will see the background GroundImport the ground image as we imported the background ground img pygame image load img ground png ground img pygame transform scale ground img Also declare some variables to make the ground scroll game variablesground scroll scroll speed Inside the loop right after drawing the ground draw the ground with ground scroll as it s x value Also update the ground scroll with scroll speed draw groundscreen blit ground img ground scroll ground scroll scroll speedAnd we also need to reset the ground ground scroll to after it passes to get a continuous scroll if abs ground scroll gt ground scroll FPSNow the ground scrolls so fast and we have to control the fps Otherwise fps may vary from computers to computers So at the top declare fps and pygame clock fps controlclock pygame time Clock fps Inside the loop at the top call the tick function using fps variable clock tick fps Try the game and see the ground scrolls slowly Bird classNow let s create the bird class In the bird class we have a constructor where we receive the x y and an update method class Bird pygame sprite Sprite def init self x y pass def update self passSee we have derived the class from pygame sprite Sprite It s a simple base class for visible game objects Let s code the init method def init self x y pygame sprite Sprite init self self images self index self counter for num in range img pygame image load f img bird num png img pygame transform scale img self images append img self image self images self index self rect self image get rect self rect center x y self vel self clicked FalseHere we called the constructor of pygame sprite Sprite at first We have sprites of bird images to animate So we loop times and store each images to the images The index variable is used to get the nth images at each frame counter is to control the animation fps Also we center the image to the x y using the rect of the sprite vel is to set the velocity of the bird when the clicked true Now we have the update method to code def update self gravity if flying True self vel if self vel gt self vel if self rect bottom lt self rect y int self vel We coded the gravity functionality for the bird first Make sure we have declared the flying variable at the top of the code flying FalseWe will add the velocity by while the bird is flying and clamped the value to because the bird don t need to go below the ground The vel variable will be added to rect y which leads to bring the bird downward like it s falling down Then declare a game over variable at the top and append this code to the update method if game over False jump if pygame mouse get pressed and self clicked False self clicked True self vel if pygame mouse get pressed self clicked FalseCheck if it s not game over and the bird have to jump when the mouse pressed We don t need to get continuous clicks so we have to check the self clicked is false It it s time to jump we set clicked to true and vel to which leads the bird upwards We set the clicked to false when the mouse is released Now we have to animate the bird handle animation self counter flap cooldown if self counter gt flap cooldown self counter self index if self index gt len self images self index self image self images self index We set a variable flap cooldown to and will check if the counter goes after it Then change the index variable and update the sprite image according to the index Make sure that index is not greater than the length of the images If it is set it to At last we will rotate the bird according to the velocity rotate the bird self image pygame transform rotate self images self index self vel Make sure the above all codes are indented inside the game over False condition And when the game over true we have to point the bird down like it s falling down quickly So right after the above condition code this else self image pygame transform rotate self images self index Now our bird class is complete let s draw the bird inside the loop But before that we have to create a class group of bird right above the loop bird group pygame sprite Group And add a new Bird object to the group flappy Bird int screen height bird group add flappy We do this because it s easy to draw the sprite Group class of pygame because it has a default draw method itself Jump into the loop and call the draw and update method of the bird group draw birdbird group draw screen bird group update Make sure we put this code after drawing the bg and ground because we need the bird at the top of them Also add this code in the for event in pygame event get loop to make the flying true if event type pygame MOUSEBUTTONDOWN and flying False and game over False flying TrueThis will trigger the bird to fly when we click the mouse button for the first time But won t start the game when open it One more update to do we have to cover the ground scroll update we coded before inside a condition because we don t have to scroll the ground if the game is not started yet if game over False and flying True scroll ground ground scroll scroll speed if abs ground scroll gt ground scroll Now everything will start moving after we click the mouse button for the first time Try the game now ConclusionHope you loved this post and enjoyed making flappy together I will get back to you soon with another post where we add more functionalities to the game Comment your opinions and doubts 2022-08-05 02:59:31
海外TECH DEV Community NextJS vs ReactJS: Which Framework is Better for your Frontend? https://dev.to/sendhyrama/nextjs-vs-reactjs-which-framework-is-better-for-your-frontend-3e6e NextJS vs ReactJS Which Framework is Better for your Frontend What is a JavaScript Framework A JavaScript framework is a tool that helps developers to create and structure code A framework provides a predefined structure for code which makes it easier to develop complex applications There are many different JavaScript frameworks available but some of the most popular include ReactJS AngularJS and VueJS Each framework has its own strengths and weaknesses so it s important to choose the right one for your project The benefits of using a JavaScript frameworkUsing a JavaScript framework can have many benefits It can help you organize and automate your code making it more readable and maintainable in the process If you re looking to improve the quality of your code a JavaScript framework is definitely worth considering NextJS vs ReactJS FeaturesWhen comparing NextJS and React the first thing to look at is their features Both frameworks have a lot to offer but there are some key differences between them It s important to note them NextJS is based on React and is meant to amplity it s capabilities and provide tools to make the most out of react ReactJS Ease of use React is easy to learn and use making it a good choice for developers who are new to JavaScript frameworks Component based React allows you to create reusable components which can be used to build complex user interfaces and applications Virtual DOM React uses a virtual DOM which makes it fast and efficient when rendering large lists of data or complex user interfaces JSX JSX is a syntax extension of JavaScript that allows you to write HTMLlike code inside JavaScript files Data binding React uses oneway data binding which means that data flows in one direction from the parent component to the child component Extensibility React can be extended with thirdparty libraries and plugins to add additional functionality if needed Next js As I ve written before Next js is built on top of React here are some of the ways it changes and improves on it Serverside rendering Next js comes with builtin support for serverside rendering which can improve the performance of your application Static site generation With Next js you can generate static versions of your pages which can be deployed without a server Routing Next js has builtin routing capabilities making it easy to create singlepage applications SPAs TypeScript support TypeScript is a typed superset of JavaScript that enables type checking and other advanced features Next js comes with builtin support for TypeScript out of the box File system routing With Next js you can define your routes directly in your file system which can make things easier to manage if you have a large application NextJS vs ReactJS Which is Right for You There s no easy answer when it comes to choosing a JavaScript framework It really depends on your specific needs and preferences However if you re looking for a lighthearted and witty article on the subject then you can t go wrong with either Next js or React js 2022-08-05 02:51:00
海外TECH DEV Community Developer Life: If words could tell! https://dev.to/rounakcodes/developer-life-if-words-could-tell-33ml Developer Life If words could tell More than a decade back I looked up for the best text editor on the web and other than the contemporary heroes it was emacs or vim which stood out to be the classical choice for many developers It was hard to choose one since both had a strong community advocating one over the other I decided to go with vim just for the sake of choosing one and trying it out I had never heard of modal editing before And I couldn t believe that I had not thought of it How could I miss something so obviously important for editing text What was I thinking all these years repeating my keystrokes to navigate around text Until then I only knew the keyboard shortcuts for moving to the end of a line or word with a control key and a character or similar so called shortcuts About six months ago which is after two decades of computing I discovered the tiling window manager Xmonad When used in combination with Arch Linux and without a heavy desktop environment like Gnome it feels incredibly powerful and yet simple to manage my workflow needs The ability to move windows around on one workspace across workspaces and across multiple displays coupled with the customization to control the look and feel with keystrokes is astonishing And yet navigating around windows is just one of the things that Xmonad allows you to do I do not know Haskell and this is why I was not sure whether I would stick with Xmonad But over the last six months I have been able to modify the config for my needs without learning Haskell so no complaints Xmonad makes me rethink about my window management habits just like how vim made me do it for my text editing I feel rejuvenated to use my machine I would love to hear if you have had such moments with any tools games or anything tech If you liked this post you may want to read Optimizing the Desktop Environment 2022-08-05 02:41:00
海外TECH DEV Community Astro is awesome https://dev.to/kylefontenot/astro-is-awesome-38cl Astro is awesomeAstro is my daily driver for creating websites in my freelance web development business and I wanted to highlight the tool for anyone unfamiliar and also to get readers acquainted easily to the code I will have a second blog post on the usage here OverviewAstro is a really lovely well thought out framework for creating websites with little to no Javascript client side It uses Vite under the hood with all the yummy features like CSS Modules easy PostCSS static route generation and built in SCSS Astro is primarily a static site framework because it builds everything into static assets to be served The Astro team is leveraging a lot of SSR capabilities to not only optimize page load speeds but for using a full SSR implementation in beta as of writing this It enables an islands approach to each component each component created by default doesn t have any Javascript attached to it forcing the developer to opt in each component that needs some client side code When developers opt in for JS they have their own option for using a JS framework like React Vue Svelte SolidJS or just Vanilla with just a simple renderer installation with a CLI command like astro add react Quick BackgroundI took up Astro the instant I discovered and read what makes it unique because it fit into my development really well Gatsby initially fulfilled this role of static site generation for my small business clients but discovering Svelte and SolidJS broke the React paradigm for me By offering all modern capabilities of a major framework such as Gatsby with the exception of the beta SSR but with barely any runtime JS and a ton of flexibility SolidJS is essentially what drove me to Astro as it was one of the only ways of creating a MPA using SolidJS at the time Page Load Comparison To NextJSAstro mentions its benefits on its documentation site but it s better to see a direct example for the statistics I created the exact same basic website using NextJS and Astro Here is the example website with each corresponding Lighthouse score For the purposes of consistency I used the Image component per designated framework as an obstacle for page load a simple external SCSS stylesheet import and the SolidJS renderer installed for Astro With the SolidJS renderer in Astro anyone can literally do anything React is able to do there s always vanilla but just for React fans For consistency both websites are created From templates taken directly from each framework s official documentation website With Lighthouse audits executed on a Chrome private window to remove possiblities of extensions interacting With a cleared cache every test Using CSS Modules and Sass Out of the box it s a bit surprising that such a simple website with only semantic HTML elements and a dynamically presented image can show such a stark difference with frameworks and let s not mention how we have to clarify a document js file for lang en for NextJS With a previous project of mine I used NextJS because it simply scored better in Lighthouse being a more mature framework But just as Astro surmises on their documentation site it s all about content And clearly Google is heading in the same direction That s crazy The circled scores above are the most pivotal stats Astro scoring and average ascore of ms versus NextJS scoring values between and ms Even viewing the amount of resources used for such a basic site is pretty shocking Two big factors affecting these are React itself in the bundle but perhaps Vite as well Webpack looks remarkably sluggish compared to newer HMR bundlers And speaking of bundlers this Astro site would probably take around seconds to build costing the developers and clients even less for hosting Routing PatternsAstro like many modern frameworks nowadays have a static file route option for easily creating pages In the src pages folder each astro and md file is automatically created into a page For anyone familiar with NextJS s approach to this it is exactly the same particularly with dynamic routing using syntax like blogPost astro One perspective Astro takes is clarifying layouts for use of pages It s essentially just parent components that receive children components and typically span or inherit the html and head tags NextJS s equivalent is a very special and particular approach by using proprietary lt Head gt and document js tools to optimize its page load Astro proves if you keep it simple with great tools these types of workarounds aren t necessary In Astro keep your lt head gt tags as they should be and nest your components like you normally would StylingCSS modules are natively supported in Astro and are a great option for building but Astro also has a built in style method that assesses CSS from within a style tag inside the Astro component it belongs to This style below is only applied to this specific component There is a method of making this global if you need to though Here s the example lt button class special gt Button lt button gt lt style gt special outline px solid blue lt style gt EaseAstro s team has offered really handy CLI tools for perpetuating their integrations idea of Astro s Integrations are pretty much the same as any other frameworks plugin system with just a yarn astro command The integrations make it extremely easy to install Tailwind SolidJS native SSR tools and more I see this as very similar to Gatsby s plugin system especially when if the ecosystem expands in the future Misc Built In ToolsMarkdownOut of the box Astro natively supports Markdown with even MDX like capabilities for placing in custom components RSS supportA flexible Code component with tons of language supportPowerful directive configurations for finely splitting code Check out the official Astro docs for more I m planning on making an Astro primer article next for to make it easy for someone to jump in 2022-08-05 02:18:45
海外科学 NYT > Science Tourists Are Injured Near Icelandic Volcanic Eruption https://www.nytimes.com/2022/08/04/world/europe/fagradalsfjall-iceland-volcano-tourists.html Tourists Are Injured Near Icelandic Volcanic EruptionThe injuries were not serious but they underscored the risks facing tourists who hike to the Fagradalsfjall volcano in southwest Iceland officials said 2022-08-05 02:54:50
海外科学 NYT > Science As Monkeypox Spreads, U.S. Declares a Health Emergency https://www.nytimes.com/2022/08/04/health/monkeypox-emergency-us.html bureaucratic 2022-08-05 02:50:00
医療系 内科開業医のお勉強日記 long COVID:持続的身体症状 12.7%が関連 https://kaigyoi.blogspot.com/2022/08/long-covid-127.html nbspCOVID後日目のCOVID陽性の症状持続被験者をCOVID前とマッチ化対照を、呼吸困難、呼吸時胸痛、筋肉痛、味覚消失、嗅覚消失、tinglingextremities四肢知覚障害、咽頭部違和感、交互的温冷症状、腕・下肢自重感、一般的倦怠感を比較OVID陽性者人のうち人に対してCOVID陰性対照者人のうち人では、COVID診断後日または一致した時点でこれらの中核症状の少なくともつが少なくとも中程度の重症度に大幅に増加しており、患者のにおいて、これらの症状はCOVIDによるものである可能性が示された。 2022-08-05 02:41:00
海外ニュース Japan Times latest articles Japan and U.S. to cooperate on maintaining peace in Taiwan Strait https://www.japantimes.co.jp/news/2022/08/05/national/kishida-pelosi-meeting/ Japan and U S to cooperate on maintaining peace in Taiwan StraitU S House of Representatives Speaker Nancy Pelosi is in Japan on the last stage of an Asian trip that included a brief and unannounced stop 2022-08-05 11:21:27
海外ニュース Japan Times latest articles Brittney Griner receives nine-year prison sentence in Russia https://www.japantimes.co.jp/sports/2022/08/05/basketball/griner-sentence-russia/ Brittney Griner receives nine year prison sentence in RussiaGriner was found guilty of deliberately bringing cannabis infused vape cartridges into Russia a ruling U S President Joe Biden called unacceptable 2022-08-05 11:18:29
ニュース BBC News - Home Hosepipe ban set to begin in Hampshire and Isle of Wight https://www.bbc.co.uk/news/uk-england-hampshire-62423495?at_medium=RSS&at_campaign=KARANGA hampshire 2022-08-05 02:23:29
ニュース BBC News - Home Hungary's Viktor Orban fires up Texas conservatives https://www.bbc.co.uk/news/world-us-canada-62431415?at_medium=RSS&at_campaign=KARANGA christian 2022-08-05 02:47:15
GCP Google Cloud Platform Japan 公式ブログ Cloud Run のセッション アフィニティで応答性を向上 https://cloud.google.com/blog/ja/topics/developers-practitioners/improve-responsiveness-session-affinity-cloud-run/ CloudRunが受信トラフィックを処理するためにコンテナインスタンスを追加すると、クライアントはキャッシュされた結果を持たないインスタンスにそれ以降のリクエストを送信します。 2022-08-05 03:00:00
北海道 北海道新聞 国民、参院議席減「厳しい結果」 総括発表、玉木路線を継続へ https://www.hokkaido-np.co.jp/article/714475/ 国民民主党 2022-08-05 11:33:00
北海道 北海道新聞 <デジタル発>「もやし屋さん」消えていいのですか!? 「家計の味方」に押し寄せる危機 https://www.hokkaido-np.co.jp/article/714097/ 皆さん 2022-08-05 11:32:24
北海道 北海道新聞 滋賀・長浜で河川氾濫 4千人に避難指示 https://www.hokkaido-np.co.jp/article/714473/ 彦根地方気象台 2022-08-05 11:27:00
北海道 北海道新聞 韓国初の月探査機打ち上げ 米基地から、年末に軌道へ投入 https://www.hokkaido-np.co.jp/article/714470/ 韓国 2022-08-05 11:17:00
北海道 北海道新聞 旧統一教会系団体に祝電、会合であいさつも 小林経済安保相 https://www.hokkaido-np.co.jp/article/714466/ 統一教会 2022-08-05 11:17:00
北海道 北海道新聞 新千歳で200人一夜 羽田便、悪天候で到着遅れ https://www.hokkaido-np.co.jp/article/714463/ 新千歳空港 2022-08-05 11:11:00
北海道 北海道新聞 上半期の農産物輸出最高 6千億円超、外食需要回復 https://www.hokkaido-np.co.jp/article/714464/ 農林水産省 2022-08-05 11:11:00
北海道 北海道新聞 ドイツ、ガス不足で市民負担増 10月から臨時徴収 https://www.hokkaido-np.co.jp/article/714462/ 天然ガス 2022-08-05 11:06:00
IT 週刊アスキー あの「モッチッチ」に新作!「韓国旨辛」はカップ麺なのに手作りのような味わいが楽しめるアイデアがたくさん https://weekly.ascii.jp/elem/000/004/100/4100831/ 韓国 2022-08-05 11:30:00
GCP Cloud Blog JA Cloud Run のセッション アフィニティで応答性を向上 https://cloud.google.com/blog/ja/topics/developers-practitioners/improve-responsiveness-session-affinity-cloud-run/ CloudRunが受信トラフィックを処理するためにコンテナインスタンスを追加すると、クライアントはキャッシュされた結果を持たないインスタンスにそれ以降のリクエストを送信します。 2022-08-05 03:00: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件)