nc New website design launch for Automated Irrigation Systems in Zionsville, Indiana By feedproxy.google.com Published On :: Wed, 10 Oct 2018 19:27:54 +0000 We’re delighted to launch the first ever website for this local irrigation company that has been around since 1989! Automated...continue reading Full Article Web Design
nc Family Health Centers of Southwest Florida Website Design Launch By feedproxy.google.com Published On :: Tue, 12 Mar 2019 01:25:23 +0000 We recently completed a website design and development project for Family Health Centers of Southwest Florida. This National Health Service...continue reading Full Article Featured Fort Myers Web Design Naples Web Design Web Design Website Launches
nc She’s Geeky: My First Unconference & Having Feels about Solidarity Between Women in Tech By feedproxy.google.com Published On :: Sun, 11 May 2014 21:07:29 +0000 This Friday I attended the first day of She’s Geeky here in Seattle. It was my first experience of the Unconference Format and I had no idea what to expect, but ended up having a GREAT TIME. Discussions that I joined in on throughout the day included subjects such as Impostor Syndrome, Diversity Groups, Side- […] Full Article Community Liz
nc Neumorphism in Mobile Design Concepts By design4users.com Published On :: Sat, 09 May 2020 04:14:46 PDT https://design4users.com/neuomorphism-mobile-design/ Full Article
nc OpenCV Directly in the Browser (WebAssembly and webworker) By aralroca.com Published On :: Sat, 09 May 2020 11:11:00 PDT https://aralroca.com/blog/opencv-in-the-web Full Article
nc Check Out These Famous Logos Practicing Social Distancing – McDonald’s, Mercedes, and More By webdesignledger.com Published On :: Tue, 31 Mar 2020 10:34:51 +0000 We all know about the new coronavirus that has been affecting hundreds of thousands of people worldwide. And while scientists, researchers, and doctors are all working tirelessly to find a cure for this terrible disease, one thing is for sure: staying home is saving lives. The greatest tool that we have right now to help […] Read More at Check Out These Famous Logos Practicing Social Distancing – McDonald’s, Mercedes, and More Full Article Editors Pick Featured Inspiration News Uncategorized
nc 5 Incredible Free Tools For Designers That You Need To Try By webdesignledger.com Published On :: Thu, 16 Apr 2020 09:03:25 +0000 There’s nothing better than finding a new design tool that will make your life a million times easier. After all, we all want to get our work done as quickly and efficiently as possible, and if there’s a tool for that, then I want it. And I did find some tools that I absolutely love […] Read More at 5 Incredible Free Tools For Designers That You Need To Try Full Article Color Editors Pick Featured Freebies Resources Tools Uncategorized
nc 7 Biggest Mistakes Freelance Designers Make That Will Ruin Their Career By webdesignledger.com Published On :: Wed, 22 Apr 2020 11:44:23 +0000 When you’re a freelancer and you start to work directly with your clients, there’s something crucial you need to know. Your design is not the one and only, most important aspect of the transaction. While presenting your client with an amazing design is the final goal, there are a lot of other things at stake […] Read More at 7 Biggest Mistakes Freelance Designers Make That Will Ruin Their Career Full Article Editors Pick Featured Freelance Graphic Design Guides How-To Inspiration Jobs Tips Uncategorized
nc The invisible injury: How concussions have changed our lives By feedproxy.google.com Published On :: Mon, 09 Mar 2020 14:01:37 EDT 'It can happen to you anywhere, at any moment, and just change your world' Full Article
nc Concussion had made my life a mess. So I gave my brain injury a name By feedproxy.google.com Published On :: Mon, 09 Mar 2020 14:15:12 EDT By turning 'Stella' into a punchline, laughter became my medicine and sharing my story became my therapy Full Article
nc Post-concussion treatment, suicide prevention ‘a team sport,’ says lead researcher By feedproxy.google.com Published On :: Tue, 10 Mar 2020 12:26:16 EDT Suicide attempts common in post-concussion patients, says Dr. Charles Tator of the Canadian Concussion Centre Full Article
nc Treating PTSD Involves Science, Counseling, Group Support By feedproxy.google.com Published On :: Mon, 06 Apr 2020 10:05:09 EDT In the years since he had returned from Vietnam, Elmer “Snubby” Burket was a self-described workaholic, raising a son, keeping up his house and always taking jobs where he could be by himself as he tried to put the war behind him. Full Article
nc Could you get PTSD from your pandemic experience? The long-term mental health effects of coronavirus By feedproxy.google.com Published On :: Mon, 20 Apr 2020 10:10:58 EDT Experiencing intense flashbacks, nightmares, irritability, anger, and fear? In the face of a traumatic event like the Covid-19 pandemic, it’s common to feel this way. Full Article
nc Could you get PTSD from your pandemic experience? The long-term mental health effects of coronavirus By feedproxy.google.com Published On :: Monday, April 20, 2020 - 10:10am Experiencing intense flashbacks, nightmares, irritability, anger, and fear? In the face of a traumatic event like the Covid-19 pandemic, it’s common to feel this way. Full Article
nc How to Improve User Experience Design: Tips to Increase Conversion Rates By feedproxy.google.com Published On :: Fri, 24 Apr 2020 13:53:03 +0000 No one can deny that UX (user experience) is the foundation of any website. This is the main reason why many website owners always look for ways to improve it. Some even spend a lot of money on design because of it. So, what is UX design exactly? And what is the difference between user […] Full Article Blog How-to & tutorials UX Web design
nc How to personalize the mobile experience for app users By feedproxy.google.com Published On :: Sun, 03 May 2020 08:42:02 +0000 Mobile user experience somehow ‘imposed itself’ with all the development and improvement of mobile communication devices. In fact, it is the quality of user experience that divides outstanding apps from their less outstanding counterparts. The same factor enables startups to learn from big brands and to improve their products. User experience for mobile applications – […] Full Article Blog How-to & tutorials UX Web design
nc How to Cancel a Fetch Request By feedproxy.google.com Published On :: Tue, 17 Mar 2020 18:25:29 +0000 JavaScript promises have always been a major win for the language — they’ve led to a revolution of asynchronous coding that has vastly improved performance on the web. One shortcoming of native promises is that there’s no true way to cancel a fetch…until now. A new AbortController has been added to the JavaScript specification that […] The post How to Cancel a Fetch Request appeared first on David Walsh Blog. Full Article AJAX JavaScript Promises
nc 25 Best Freelance Tools to Enhance Your Business for Free By webdesignerwall.com Published On :: Mon, 05 Dec 2016 13:00:44 +0000 Freelancing can be a tough gig, but there is no better time than a new year to begin building (or rebuilding) a fantastic new business where you can do what you love. Being successful has a lot to do with your drive and passion, but depends largely on your efficiency, workflow and presentation. In this […] The post 25 Best Freelance Tools to Enhance Your Business for Free appeared first on Web Designer Wall. Full Article General Stuff freelance
nc Best Email Marketing Tips to Increase Engagement & Subscribers By webdesignerwall.com Published On :: Thu, 09 Feb 2017 17:06:31 +0000 Email is your post powerful marketing channel when used well. Your visitor’s inbox is a perfect opportunity for you to capture attention, communicate important updates and invite readers back to your site for increased visibility. The stats on email marketing effectiveness say it all – top marketing specialists and service providers tell us that email […] The post Best Email Marketing Tips to Increase Engagement & Subscribers appeared first on Web Designer Wall. Full Article General Stuff markeing
nc Harbingers: Florence, Forest Fires, and the Future By feedproxy.google.com Published On :: Wed, 26 Sep 2018 22:31:26 +0000 By John Atcheson Common Dreams If past is prologue, the media will soon move on, leaving the greatest threat humanity has ever faced virtually uncovered Climate change catastrophe is upon us. We see it in the record-breaking floods from storms … Continue reading → Full Article Points of View & Opinions Climate Change extreme weather events media
nc Why Use A Digital Marketing Agency? By icanbecreative.com Published On :: Wed, 25 Mar 2020 18:38:23 PDT Outsourcing your marketing when you're running a small or medium sized business is often seen as an expensive option, one that can be done yourself. It might even be seen as something that's... Full Article Marketing
nc Top 5 Best Internet Live Support Extension To Increase Customers Interactions By icanbecreative.com Published On :: Fri, 27 Mar 2020 03:19:08 PDT Creative interactions call for creative measures - numerous extensions reduce, minimize or dilute the frustration of the customers and resolve issues quickly without the customer support team need.... Full Article Learning
nc How Can SEO Help Market Your Designing Agency? By icanbecreative.com Published On :: Sun, 12 Apr 2020 17:28:24 PDT It's unusual, as indeed Google says that in case you've got to enlist an SEO strategy, you ought to do so early instead of late, like when you're appropriate arranging to launch a new site. Because... Full Article SEO
nc Advanced Photography Tips And Hints By icanbecreative.com Published On :: Sat, 25 Apr 2020 23:54:17 PDT It is in every case critical to pay special mind to any computerized photography insights and tips. A few people can truly take awesome photos without truly trying, yet most of us need whatever... Full Article Learning
nc Disney Princesses Comic Book Style By icanbecreative.com Published On :: Sun, 26 Apr 2020 15:56:22 PDT What happens when you mash-up Disney princesses with Marvel Super Heros, artist cartooncookie did an excellent job creating this mix: Marvel x Disney Princesses: a celebration of the X-Men joining... Full Article Design Roud-up
nc Neural network generates convincing songs by famous singers By flowingdata.com Published On :: Thu, 30 Apr 2020 19:25:39 +0000 Jukebox from OpenAI is a generative model that makes music in the same…Tags: Jukebox, music, neural network, OpenAI Full Article Statistics Jukebox music neural network OpenAI
nc Concurrency & Multithreading in iOS By feedproxy.google.com Published On :: Tue, 25 Feb 2020 08:00:00 -0500 Concurrency is the notion of multiple things happening at the same time. This is generally achieved either via time-slicing, or truly in parallel if multiple CPU cores are available to the host operating system. We've all experienced a lack of concurrency, most likely in the form of an app freezing up when running a heavy task. UI freezes don't necessarily occur due to the absence of concurrency — they could just be symptoms of buggy software — but software that doesn't take advantage of all the computational power at its disposal is going to create these freezes whenever it needs to do something resource-intensive. If you've profiled an app hanging in this way, you'll probably see a report that looks like this: Anything related to file I/O, data processing, or networking usually warrants a background task (unless you have a very compelling excuse to halt the entire program). There aren't many reasons that these tasks should block your user from interacting with the rest of your application. Consider how much better the user experience of your app could be if instead, the profiler reported something like this: Analyzing an image, processing a document or a piece of audio, or writing a sizeable chunk of data to disk are examples of tasks that could benefit greatly from being delegated to background threads. Let's dig into how we can enforce such behavior into our iOS applications. A Brief History In the olden days, the maximum amount of work per CPU cycle that a computer could perform was determined by the clock speed. As processor designs became more compact, heat and physical constraints started becoming limiting factors for higher clock speeds. Consequentially, chip manufacturers started adding additional processor cores on each chip in order to increase total performance. By increasing the number of cores, a single chip could execute more CPU instructions per cycle without increasing its speed, size, or thermal output. There's just one problem... How can we take advantage of these extra cores? Multithreading. Multithreading is an implementation handled by the host operating system to allow the creation and usage of n amount of threads. Its main purpose is to provide simultaneous execution of two or more parts of a program to utilize all available CPU time. Multithreading is a powerful technique to have in a programmer's toolbelt, but it comes with its own set of responsibilities. A common misconception is that multithreading requires a multi-core processor, but this isn't the case — single-core CPUs are perfectly capable of working on many threads, but we'll take a look in a bit as to why threading is a problem in the first place. Before we dive in, let's look at the nuances of what concurrency and parallelism mean using a simple diagram: In the first situation presented above, we observe that tasks can run concurrently, but not in parallel. This is similar to having multiple conversations in a chatroom, and interleaving (context-switching) between them, but never truly conversing with two people at the same time. This is what we call concurrency. It is the illusion of multiple things happening at the same time when in reality, they're switching very quickly. Concurrency is about dealing with lots of things at the same time. Contrast this with the parallelism model, in which both tasks run simultaneously. Both execution models exhibit multithreading, which is the involvement of multiple threads working towards one common goal. Multithreading is a generalized technique for introducing a combination of concurrency and parallelism into your program. The Burden of Threads A modern multitasking operating system like iOS has hundreds of programs (or processes) running at any given moment. However, most of these programs are either system daemons or background processes that have very low memory footprint, so what is really needed is a way for individual applications to make use of the extra cores available. An application (process) can have many threads (sub-processes) operating on shared memory. Our goal is to be able to control these threads and use them to our advantage. Historically, introducing concurrency to an app has required the creation of one or more threads. Threads are low-level constructs that need to be managed manually. A quick skim through Apple's Threaded Programming Guide is all it takes to see how much complexity threaded code adds to a codebase. In addition to building an app, the developer has to: Responsibly create new threads, adjusting that number dynamically as system conditions change Manage them carefully, deallocating them from memory once they have finished executing Leverage synchronization mechanisms like mutexes, locks, and semaphores to orchestrate resource access between threads, adding even more overhead to application code Mitigate risks associated with coding an application that assumes most of the costs associated with creating and maintaining any threads it uses, and not the host OS This is unfortunate, as it adds enormous levels of complexity and risk without any guarantees of improved performance. Grand Central Dispatch iOS takes an asynchronous approach to solving the concurrency problem of managing threads. Asynchronous functions are common in most programming environments, and are often used to initiate tasks that might take a long time, like reading a file from the disk, or downloading a file from the web. When invoked, an asynchronous function executes some work behind the scenes to start a background task, but returns immediately, regardless of how long the original task might takes to actually complete. A core technology that iOS provides for starting tasks asynchronously is Grand Central Dispatch (or GCD for short). GCD abstracts away thread management code and moves it down to the system level, exposing a light API to define tasks and execute them on an appropriate dispatch queue. GCD takes care of all thread management and scheduling, providing a holistic approach to task management and execution, while also providing better efficiency than traditional threads. Let's take a look at the main components of GCD: What've we got here? Let's start from the left: DispatchQueue.main: The main thread, or the UI thread, is backed by a single serial queue. All tasks are executed in succession, so it is guaranteed that the order of execution is preserved. It is crucial that you ensure all UI updates are designated to this queue, and that you never run any blocking tasks on it. We want to ensure that the app's run loop (called CFRunLoop) is never blocked in order to maintain the highest framerate. Subsequently, the main queue has the highest priority, and any tasks pushed onto this queue will get executed immediately. DispatchQueue.global: A set of global concurrent queues, each of which manage their own pool of threads. Depending on the priority of your task, you can specify which specific queue to execute your task on, although you should resort to using default most of the time. Because tasks on these queues are executed concurrently, it doesn't guarantee preservation of the order in which tasks were queued. Notice how we're not dealing with individual threads anymore? We're dealing with queues which manage a pool of threads internally, and you will shortly see why queues are a much more sustainable approach to multhreading. Serial Queues: The Main Thread As an exercise, let's look at a snippet of code below, which gets fired when the user presses a button in the app. The expensive compute function can be anything. Let's pretend it is post-processing an image stored on the device. import UIKit class ViewController: UIViewController { @IBAction func handleTap(_ sender: Any) { compute() } private func compute() -> Void { // Pretending to post-process a large image. var counter = 0 for _ in 0..<9999999 { counter += 1 } } } At first glance, this may look harmless, but if you run this inside of a real app, the UI will freeze completely until the loop is terminated, which will take... a while. We can prove it by profiling this task in Instruments. You can fire up the Time Profiler module of Instruments by going to Xcode > Open Developer Tool > Instruments in Xcode's menu options. Let's look at the Threads module of the profiler and see where the CPU usage is highest. We can see that the Main Thread is clearly at 100% capacity for almost 5 seconds. That's a non-trivial amount of time to block the UI. Looking at the call tree below the chart, we can see that the Main Thread is at 99.9% capacity for 4.43 seconds! Given that a serial queue works in a FIFO manner, tasks will always complete in the order in which they were inserted. Clearly the compute() method is the culprit here. Can you imagine clicking a button just to have the UI freeze up on you for that long? Background Threads How can we make this better? DispatchQueue.global() to the rescue! This is where background threads come in. Referring to the GCD architecture diagram above, we can see that anything that is not the Main Thread is a background thread in iOS. They can run alongside the Main Thread, leaving it fully unoccupied and ready to handle other UI events like scrolling, responding to user events, animating etc. Let's make a small change to our button click handler above: class ViewController: UIViewController { @IBAction func handleTap(_ sender: Any) { DispatchQueue.global(qos: .userInitiated).async { [unowned self] in self.compute() } } private func compute() -> Void { // Pretending to post-process a large image. var counter = 0 for _ in 0..<9999999 { counter += 1 } } } Unless specified, a snippet of code will usually default to execute on the Main Queue, so in order to force it to execute on a different thread, we'll wrap our compute call inside of an asynchronous closure that gets submitted to the DispatchQueue.global queue. Keep in mind that we aren't really managing threads here. We're submitting tasks (in the form of closures or blocks) to the desired queue with the assumption that it is guaranteed to execute at some point in time. The queue decides which thread to allocate the task to, and it does all the hard work of assessing system requirements and managing the actual threads. This is the magic of Grand Central Dispatch. As the old adage goes, you can't improve what you can't measure. So we measured our truly terrible button click handler, and now that we've improved it, we'll measure it once again to get some concrete data with regards to performance. Looking at the profiler again, it's quite clear to us that this is a huge improvement. The task takes an identical amount of time, but this time, it's happening in the background without locking up the UI. Even though our app is doing the same amount of work, the perceived performance is much better because the user will be free to do other things while the app is processing. You may have noticed that we accessed a global queue of .userInitiated priority. This is an attribute we can use to give our tasks a sense of urgency. If we run the same task on a global queue of and pass it a qos attribute of background , iOS will think it's a utility task, and thus allocate fewer resources to execute it. So, while we don't have control over when our tasks get executed, we do have control over their priority. A Note on Main Thread vs. Main Queue You might be wondering why the Profiler shows "Main Thread" and why we're referring to it as the "Main Queue". If you refer back to the GCD architecture we described above, the Main Queue is solely responsible for managing the Main Thread. The Dispatch Queues section in the Concurrency Programming Guide says that "the main dispatch queue is a globally available serial queue that executes tasks on the application’s main thread. Because it runs on your application’s main thread, the main queue is often used as a key synchronization point for an application." The terms "execute on the Main Thread" and "execute on the Main Queue" can be used interchangeably. Concurrent Queues So far, our tasks have been executed exclusively in a serial manner. DispatchQueue.main is by default a serial queue, and DispatchQueue.global gives you four concurrent dispatch queues depending on the priority parameter you pass in. Let's say we want to take five images, and have our app process them all in parallel on background threads. How would we go about doing that? We can spin up a custom concurrent queue with an identifier of our choosing, and allocate those tasks there. All that's required is the .concurrent attribute during the construction of the queue. class ViewController: UIViewController { let queue = DispatchQueue(label: "com.app.concurrentQueue", attributes: .concurrent) let images: [UIImage] = [UIImage].init(repeating: UIImage(), count: 5) @IBAction func handleTap(_ sender: Any) { for img in images { queue.async { [unowned self] in self.compute(img) } } } private func compute(_ img: UIImage) -> Void { // Pretending to post-process a large image. var counter = 0 for _ in 0..<9999999 { counter += 1 } } } Running that through the profiler, we can see that the app is now spinning up 5 discrete threads to parallelize a for-loop. Parallelization of N Tasks So far, we've looked at pushing computationally expensive task(s) onto background threads without clogging up the UI thread. But what about executing parallel tasks with some restrictions? How can Spotify download multiple songs in parallel, while limiting the maximum number up to 3? We can go about this in a few ways, but this is a good time to explore another important construct in multithreaded programming: semaphores. Semaphores are signaling mechanisms. They are commonly used to control access to a shared resource. Imagine a scenario where a thread can lock access to a certain section of the code while it executes it, and unlocks after it's done to let other threads execute the said section of the code. You would see this type of behavior in database writes and reads, for example. What if you want only one thread writing to a database and preventing any reads during that time? This is a common concern in thread-safety called Readers-writer lock. Semaphores can be used to control concurrency in our app by allowing us to lock n number of threads. let kMaxConcurrent = 3 // Or 1 if you want strictly ordered downloads! let semaphore = DispatchSemaphore(value: kMaxConcurrent) let downloadQueue = DispatchQueue(label: "com.app.downloadQueue", attributes: .concurrent) class ViewController: UIViewController { @IBAction func handleTap(_ sender: Any) { for i in 0..<15 { downloadQueue.async { [unowned self] in // Lock shared resource access semaphore.wait() // Expensive task self.download(i + 1) // Update the UI on the main thread, always! DispatchQueue.main.async { tableView.reloadData() // Release the lock semaphore.signal() } } } } func download(_ songId: Int) -> Void { var counter = 0 // Simulate semi-random download times. for _ in 0..<Int.random(in: 999999...10000000) { counter += songId } } } Notice how we've effectively restricted our download system to limit itself to k number of downloads. The moment one download finishes (or thread is done executing), it decrements the semaphore, allowing the managing queue to spawn another thread and start downloading another song. You can apply a similar pattern to database transactions when dealing with concurrent reads and writes. Semaphores usually aren't necessary for code like the one in our example, but they become more powerful when you need to enforce synchronous behavior whille consuming an asynchronous API. The above could would work just as well with a custom NSOperationQueue with a maxConcurrentOperationCount, but it's a worthwhile tangent regardless. Finer Control with OperationQueue GCD is great when you want to dispatch one-off tasks or closures into a queue in a 'set-it-and-forget-it' fashion, and it provides a very lightweight way of doing so. But what if we want to create a repeatable, structured, long-running task that produces associated state or data? And what if we want to model this chain of operations such that they can be cancelled, suspended and tracked, while still working with a closure-friendly API? Imagine an operation like this: This would be quite cumbersome to achieve with GCD. We want a more modular way of defining a group of tasks while maintaining readability and also exposing a greater amount of control. In this case, we can use Operation objects and queue them onto an OperationQueue, which is a high-level wrapper around DispatchQueue. Let's look at some of the benefits of using these abstractions and what they offer in comparison to the lower-level GCI API: You may want to create dependencies between tasks, and while you could do this via GCD, you're better off defining them concretely as Operation objects, or units of work, and pushing them onto your own queue. This would allow for maximum reusability since you may use the same pattern elsewhere in an application. The Operation and OperationQueue classes have a number of properties that can be observed, using KVO (Key Value Observing). This is another important benefit if you want to monitor the state of an operation or operation queue. Operations can be paused, resumed, and cancelled. Once you dispatch a task using Grand Central Dispatch, you no longer have control or insight into the execution of that task. The Operation API is more flexible in that respect, giving the developer control over the operation's life cycle. OperationQueue allows you to specify the maximum number of queued operations that can run simultaneously, giving you a finer degree of control over the concurrency aspects. The usage of Operation and OperationQueue could fill an entire blog post, but let's look at a quick example of what modeling dependencies looks like. (GCD can also create dependencies, but you're better off dividing up large tasks into a series of composable sub-tasks.) In order to create a chain of operations that depend on one another, we could do something like this: class ViewController: UIViewController { var queue = OperationQueue() var rawImage = UIImage? = nil let imageUrl = URL(string: "https://example.com/portrait.jpg")! @IBOutlet weak var imageView: UIImageView! let downloadOperation = BlockOperation { let image = Downloader.downloadImageWithURL(url: imageUrl) OperationQueue.main.async { self.rawImage = image } } let filterOperation = BlockOperation { let filteredImage = ImgProcessor.addGaussianBlur(self.rawImage) OperationQueue.main.async { self.imageView = filteredImage } } filterOperation.addDependency(downloadOperation) [downloadOperation, filterOperation].forEach { queue.addOperation($0) } } So why not opt for a higher level abstraction and avoid using GCD entirely? While GCD is ideal for inline asynchronous processing, Operation provides a more comprehensive, object-oriented model of computation for encapsulating all of the data around structured, repeatable tasks in an application. Developers should use the highest level of abstraction possible for any given problem, and for scheduling consistent, repeated work, that abstraction is Operation. Other times, it makes more sense to sprinkle in some GCD for one-off tasks or closures that we want to fire. We can mix both OperationQueue and GCD to get the best of both worlds. The Cost of Concurrency DispatchQueue and friends are meant to make it easier for the application developer to execute code concurrently. However, these technologies do not guarantee improvements to the efficiency or responsiveness in an application. It is up to you to use queues in a manner that is both effective and does not impose an undue burden on other resources. For example, it's totally viable to create 10,000 tasks and submit them to a queue, but doing so would allocate a nontrivial amount of memory and introduce a lot of overhead for the allocation and deallocation of operation blocks. This is the opposite of what you want! It's best to profile your app thoroughly to ensure that concurrency is enhancing your app's performance and not degrading it. We've talked about how concurrency comes at a cost in terms of complexity and allocation of system resources, but introducing concurrency also brings a host of other risks like: Deadlock: A situation where a thread locks a critical portion of the code and can halt the application's run loop entirely. In the context of GCD, you should be very careful when using the dispatchQueue.sync { } calls as you could easily get yourself in situations where two synchronous operations can get stuck waiting for each other. Priority Inversion: A condition where a lower priority task blocks a high priority task from executing, which effectively inverts their priorities. GCD allows for different levels of priority on its background queues, so this is quite easily a possibility. Producer-Consumer Problem: A race condition where one thread is creating a data resource while another thread is accessing it. This is a synchronization problem, and can be solved using locks, semaphores, serial queues, or a barrier dispatch if you're using concurrent queues in GCD. ...and many other sorts of locking and data-race conditions that are hard to debug! Thread safety is of the utmost concern when dealing with concurrency. Parting Thoughts + Further Reading If you've made it this far, I applaud you. Hopefully this article gives you a lay of the land when it comes to multithreading techniques on iOS, and how you can use some of them in your app. We didn't get to cover many of the lower-level constructs like locks, mutexes and how they help us achieve synchronization, nor did we get to dive into concrete examples of how concurrency can hurt your app. We'll save those for another day, but you can dig into some additional reading and videos if you're eager to dive deeper. Building Concurrent User Interfaces on iOS (WWDC 2012) Concurrency and Parallelism: Understanding I/O Apple's Official Concurrency Programming Guide Mutexes and Closure Capture in Swift Locks, Thread Safety, and Swift Advanced NSOperations (WWDC 2015) NSHipster: NSOperation Full Article Code
nc Committed to the wrong branch? -, @{upstream}, and @{-1} to the rescue By feedproxy.google.com Published On :: Thu, 27 Feb 2020 00:00:00 -0500 I get into this situation sometimes. Maybe you do too. I merge feature work into a branch used to collect features, and then continue development but on that branch instead of back on the feature branch git checkout feature # ... bunch of feature commits ... git push git checkout qa-environment git merge --no-ff --no-edit feature git push # deploy qa-environment to the QA remote environment # ... more feature commits ... # oh. I'm not committing in the feature branch like I should be and have to move those commits to the feature branch they belong in and take them out of the throwaway accumulator branch git checkout feature git cherry-pick origin/qa-environment..qa-environment git push git checkout qa-environment git reset --hard origin/qa-environment git merge --no-ff --no-edit feature git checkout feature # ready for more feature commits Maybe you prefer git branch -D qa-environment git checkout qa-environment over git checkout qa-environment git reset --hard origin/qa-environment Either way, that works. But it'd be nicer if we didn't have to type or even remember the branches' names and the remote's name. They are what is keeping this from being a context-independent string of commands you run any time this mistake happens. That's what we're going to solve here.Shorthands for longevityI like to use all possible natively supported shorthands. There are two broad motivations for that.Fingers have a limited number of movements in them. Save as many as possible left late in life.Current research suggests that multitasking has detrimental effects on memory. Development tends to be very heavy on multitasking. Maybe relieving some of the pressure on quick-access short term memory (like knowing all relevant branch names) add up to leave a healthier memory down the line.First up for our scenario: the - shorthand, which refers to the previously checked out branch. There are a few places we can't use it, but it helps a lot: Bash # USING - git checkout feature # hack hack hack git push git checkout qa-environment git merge --no-ff --no-edit - # ???? git push # hack hack hack # whoops git checkout - # now on feature ???? git cherry-pick origin/qa-environment..qa-environment git push git checkout - # now on qa-environment ???? git reset --hard origin/qa-environment git merge --no-ff --no-edit - # ???? git checkout - # ???? # on feature and ready for more feature commits Bash # ORIGINAL git checkout feature # hack hack hack git push git checkout qa-environment git merge --no-ff --no-edit feature git push # hack hack hack # whoops git checkout feature git cherry-pick origin/qa-environment..qa-environment git push git checkout qa-environment git reset --hard origin/qa-environment git merge --no-ff --no-edit feature git checkout feature # ready for more feature commits Switch We cannot use - when cherry-picking a range > git cherry-pick origin/-..- fatal: bad revision 'origin/-..-' > git cherry-pick origin/qa-environment..- fatal: bad revision 'origin/qa-environment..-' and even if we could we'd still have provide the remote's name (here, origin).That shorthand doesn't apply in the later reset --hard command, and we cannot use it in the branch -D && checkout approach either. branch -D does not support the - shorthand and once the branch is deleted checkout can't reach it with -: # assuming that branch-a has an upstream origin/branch-a > git checkout branch-a > git checkout branch-b > git checkout - > git branch -D - error: branch '-' not found. > git branch -D branch-a > git checkout - error: pathspec '-' did not match any file(s) known to git So we have to remember the remote's name (we know it's origin because we are devoting memory space to knowing that this isn't one of those times it's something else), the remote tracking branch's name, the local branch's name, and we're typing those all out. No good! Let's figure out some shorthands.@{-<n>} is hard to say but easy to fall in love withWe can do a little better by using @{-<n>} (you'll also sometimes see it referred to be the older @{-N}). It is a special construct for referring to the nth previously checked out ref. > git checkout branch-a > git checkout branch-b > git rev-parse --abbrev-rev @{-1} # the name of the previously checked out branch branch-a > git checkout branch-c > git rev-parse --abbrev-rev @{-2} # the name of branch checked out before the previously checked out one branch-a Back in our scenario, we're on qa-environment, we switch to feature, and then want to refer to qa-environment. That's @{-1}! So instead of git cherry-pick origin/qa-environment..qa-environment We can do git cherry-pick origin/qa-environment..@{-1} Here's where we are (🎉 marks wins from -, 💥 marks the win from @{-1}) Bash # USING - AND @{-1} git checkout feature # hack hack hack git push git checkout qa-environment git merge --no-ff --no-edit - # ???? git push # hack hack hack # whoops git checkout - # ???? git cherry-pick origin/qa-environment..@{-1} # ???? git push git checkout - # ???? git reset --hard origin/qa-environment git merge --no-ff --no-edit - # ???? git checkout - # ???? # ready for more feature commits Bash # ORIGINAL git checkout feature # hack hack hack git push git checkout qa-environment git merge --no-ff --no-edit feature git push # hack hack hack # whoops git checkout feature git cherry-pick origin/qa-environment..qa-environment git push git checkout qa-environment git reset --hard origin/qa-environment git merge --no-ff --no-edit feature git checkout feature # ready for more feature commits Switch One down, two to go: we're still relying on memory for the remote's name and the remote branch's name and we're still typing both out in full. Can we replace those with generic shorthands?@{-1} is the ref itself, not the ref's name, we can't do > git cherry-pick origin/@{-1}..@{-1} origin/@{-1} fatal: ambiguous argument 'origin/@{-1}': unknown revision or path not in the working tree. Use '--' to separate paths from revisions, like this: 'git <command> [<revision>...] -- [<file>...]' because there is no branch origin/@{-1}. For the same reason, @{-1} does not give us a generalized shorthand for the scenario's later git reset --hard origin/qa-environment command.But good news!Do @{u} @{push} @{upstream} or its shorthand @{u} is the remote branch a that would be pulled from if git pull were run. @{push} is the remote branch that would be pushed to if git push was run. > git checkout branch-a Switched to branch 'branch-a' Your branch is ahead of 'origin/branch-a' by 3 commits. (use "git push" to publish your local commits) > git reset --hard origin/branch-a HEAD is now at <the SHA origin/branch-a is at> we can > git checkout branch-a Switched to branch 'branch-a' Your branch is ahead of 'origin/branch-a' by 3 commits. (use "git push" to publish your local commits) > git reset --hard @{u} # <-- So Cool! HEAD is now at <the SHA origin/branch-a is at> Tacking either onto a branch name will give that branch's @{upstream} or @{push}. For example git checkout branch-a@{u} is the branch branch-a pulls from.In the common workflow where a branch pulls from and pushes to the same branch, @{upstream} and @{push} will be the same, leaving @{u} as preferable for its terseness. @{push} shines in triangular workflows where you pull from one remote and push to another (see the external links below).Going back to our scenario, it means short, portable commands with a minimum human memory footprint. (🎉 marks wins from -, 💥 marks the win from @{-1}, 😎 marks the wins from @{u}.) Bash # USING - AND @{-1} AND @{u} git checkout feature # hack hack hack git push git checkout qa-environment git merge --no-ff --no-edit - # ???? git push # hack hack hack # whoops git checkout - # ???? git cherry-pick @{-1}@{u}..@{-1} # ???????? git push git checkout - # ???? git reset --hard @{u} # ???? git merge --no-ff --no-edit - # ???? git checkout - # ???? # ready for more feature commits Bash # ORIGINAL git checkout feature # hack hack hack git push git checkout qa-environment git merge --no-ff --no-edit feature git push # hack hack hack # whoops git checkout feature git cherry-pick origin/qa-environment..qa-environment git push git checkout qa-environment git reset --hard origin/qa-environment git merge --no-ff --no-edit feature git checkout feature # ready for more feature commits Switch Make the things you repeat the easiest to doBecause these commands are generalized, we can run some series of them once, maybe git checkout - && git reset --hard @{u} && git checkout - or git checkout - && git cherry-pick @{-1}@{u}.. @{-1} && git checkout - && git reset --hard @{u} && git checkout - and then those will be in the shell history just waiting to be retrieved and run again the next time, whether with CtrlR incremental search or history substring searching bound to the up arrow or however your interactive shell is configured. Or make it an alias, or even better an abbreviation if your interactive shell supports them. Save the body wear and tear, give memory a break, and level up in Git.And keep goingThe GitHub blog has a good primer on triangular workflows and how they can polish your process of contributing to external projects.The FreeBSD Wiki has a more in-depth article on triangular workflow process (though it doesn't know about @{push} and @{upstream}).The construct @{-<n>} and the suffixes @{push} and @{upstream} are all part of the gitrevisions spec. Direct links to each:@{-<n>}@{push}@{upstream} Full Article Code Front-end Engineering Back-end Engineering
nc "In conceptual art the idea or concept is the most important aspect of the work. When an artist uses..." By feedproxy.google.com Published On :: Fri, 28 Oct 2011 12:13:00 -0700 “In conceptual art the idea or concept is the most important aspect of the work. When an artist uses a conceptual form of art, it means that all of the planning and decisions are made beforehand and the execution is a perfunctory affair. The idea becomes a machine that makes the art. This kind of art is not theoretical or illustrative of theories; it is intuitive, it is involved with all types of mental processes and it is purposeless. It is usually free from the dependence on the skill of the artist as a craftsman.” - Artist Sol Lewitt on conceptual art. Full Article
nc 5 Essentials To Create Your Own Website Presence By feedproxy.google.com Published On :: Wed, 15 May 2019 18:45:21 +0000 Only a website that has a well-established presence can stand out on the internet. Business owners and individuals hire web designers like yourself to create website presences for them. In order to prove yourself, you need to establish your own presence online first. Get to the point where you can showcase your own website during […] The post 5 Essentials To Create Your Own Website Presence appeared first on Bittbox. Full Article Culture
nc Vert.x ramblings: Asynchronous network, your time has come By feedproxy.google.com Published On :: Sat, 19 May 2012 02:00:24 +0000 With the debut of Vert.x, the asynchronous framework is reaching an inflection point, suggests Andrew Cholakian. With Vert.x, the software is packaged together in such a way as to be extremely practical, he states. For some JVM zealots, Vert.x may meet needs recently and apparently addressed by node.js. Vert.x is an asynchronous application server – Read the rest... Full Article Front Page Node
nc The Best Free Zoom Backgrounds to Make Your Video Conferencing More Fun By feedproxy.google.com Published On :: Mon, 06 Apr 2020 17:14:51 +0000 If you’re a remote worker, you may have plenty of experience with video conferencing as a way to communicate with clients, team members, or other colleagues. But with millions of additional... Click through to read the rest of the story on the Vandelay Design Blog. Full Article Featured Galleries
nc 9 Convincing Reasons Why Designers Should Pursue Personal Projects By feedproxy.google.com Published On :: Thu, 16 Apr 2020 14:06:24 +0000 Web designers have skills and expertise that open up a whole world of possibilities. Many designers and developers choose to pursue personal projects in their own time, which can be a nice change of... Click through to read the rest of the story on the Vandelay Design Blog. Full Article Business Design Featured
nc Humanity ‘Sleepwalking Towards the Edge of a Cliff’: 60% of Earth’s Wildlife Wiped Out Since 1970 By feedproxy.google.com Published On :: Tue, 30 Oct 2018 20:36:31 +0000 By Julia Conley Common Dreams “Nature is not a ‘nice to have’—it is our life-support system.” Scientists from around the world issued a stark warning to humanity Tuesday in a semi-annual report on the Earth’s declining biodiversity, which shows that … Continue reading → Full Article Biodiversity ET News biodiversity extinction mass extinction wildlife
nc ‘Coming Mass Extinction’ Caused by Human Destruction Could Wipe Out 1 Million Species, Warns UN Draft Report By feedproxy.google.com Published On :: Tue, 23 Apr 2019 18:47:43 +0000 By Jessica Corbett Common Dreams Far-reaching global assessment details how humanity is undermining the very foundations of the natural world On the heels of an Earth Day that featured calls for radical action to address the current “age … Continue reading → Full Article Endangered Species ET News mass extinction UN Report
nc Human Activity Increasing Rate of Record-Breaking Hot Years By feedproxy.google.com Published On :: Tue, 21 Nov 2017 21:18:38 +0000 American Geophysical Union (AGU) Press Release A new study finds human-caused global warming is significantly increasing the rate at which hot temperature records are being broken around the world. Global annual temperature records show there were 17 record hot years … Continue reading → Full Article Climate & Climate Change ET News Climate Change extreme heat Global Warming greenhouse emissions Temperature rise
nc Humanity ‘Sleepwalking Towards the Edge of a Cliff’: 60% of Earth’s Wildlife Wiped Out Since 1970 By feedproxy.google.com Published On :: Tue, 30 Oct 2018 20:36:31 +0000 By Julia Conley Common Dreams “Nature is not a ‘nice to have’—it is our life-support system.” Scientists from around the world issued a stark warning to humanity Tuesday in a semi-annual report on the Earth’s declining biodiversity, which shows that … Continue reading → Full Article Biodiversity ET News biodiversity extinction mass extinction wildlife
nc ‘Coming Mass Extinction’ Caused by Human Destruction Could Wipe Out 1 Million Species, Warns UN Draft Report By feedproxy.google.com Published On :: Tue, 23 Apr 2019 18:47:43 +0000 By Jessica Corbett Common Dreams Far-reaching global assessment details how humanity is undermining the very foundations of the natural world On the heels of an Earth Day that featured calls for radical action to address the current “age … Continue reading → Full Article Endangered Species ET News mass extinction UN Report
nc Repeat after me: Preference testing is not A/B Testing By feedproxy.google.com Published On :: Tues, 5 Mar 2019 08:13:21 GMT Researchers sometimes ask participants which of two alternative designs they prefer. The data from these studies comprise opinions that have little predictive value. In contrast, multivariate A/B testing involves target users doing real tasks. The data from these studies comprise behavioural observations that predict real-world behaviour. Full Article
nc The Principle of Least Surprise By feedproxy.google.com Published On :: Mon, 6 May 2019 08:44:21 GMT Consistency is at the heart of good product design. But consistency is often misinterpreted as making things look or behave the same way. This ignores context and can lead to a foolish consistency. Instead of consistency, designers should adhere to the Principle of Least Surprise. Full Article
nc 10 Design Principles to Reduce Cognitive Load By feedproxy.google.com Published On :: Thu, 25 Jul 2019 14:52:24 +0000 If you’re not familiar with cognitive load and how it impacts interface design, it’s worth reviewing our previous blog post. If you’re already convinced cognitive load is important, the next step is addressing it. Reducing cognitive load is accomplished by reducing or offloading mental effort (which are similar but different concepts.) Reducing mental effort is […] The post 10 Design Principles to Reduce Cognitive Load appeared first on Psychology of Web Design | 3.7 Blog. Full Article Psychology of Design User Experience
nc Hooked: How to engage your website audience in one second or less By feedproxy.google.com Published On :: Mon, 11 Nov 2019 14:10:24 +0000 You have less than one second to make the right impression. Almost immediately after landing on your website users will make an uninformed, mostly subconscious judgment about what type of organization they’re interacting with. This initial judgment will largely be influenced by layout, design, and visual tone. It will not only influence the rest of […] The post Hooked: How to engage your website audience in one second or less appeared first on Psychology of Web Design | 3.7 Blog. Full Article Psychology of Design Strategy and Planning User Experience Web Design
nc Branding and Visual Identity for Potency Design By feedproxy.google.com Published On :: Fri, 08 May 2020 13:42:55 +0000 Branding and Visual Identity for Potency Design abduzeedoMay 08, 2020 Guilherme Vissotto and Victor Berriel shared a branding and visual identity project for Potency Agency. The details about the project are quite scarce, they didn’t add any description. Based on the work itself I assume it’s for a design studio/agency. The presentation is beautiful. The color palette is also very well selected. The logo plays with white space to mix the lightning and the P. They do an excellent job, however I am not really a fan of the shadow. It adds a good depth, but in some of the examples, the shadow feels too strong. Perhaps, just the pure symbol without any effect would suffice. What are your thoughts? Branding and visual identity Full Article
nc Social Distancing By jepson.no Published On :: Tue, 07 Apr 2020 06:48:35 +0000 A lot of nice family time during these Corona times. Full Article Blog
nc Finding a Balance: College, Work, Family ... and Issues from TBI By feedproxy.google.com Published On :: Mon, 28 Oct 2013 00:00:00 EDT Returning to school as a veteran — especially with a brain injury — can be difficult. Adam suggests strategies like starting slowly or taking a smaller course load that balances better with work and life. Full Article
nc Using Communities to Further the True Meaning of Resiliency By feedproxy.google.com Published On :: Mon, 23 Dec 2013 00:00:00 EST Service members, veterans, and their caregivers are incredibly resilient, says Adam, but learning to connect with whatever community you are in will only strengthen that resiliency. Full Article
nc Three Principles to Remember for Successful Recovery By feedproxy.google.com Published On :: Tue, 18 Feb 2014 00:00:00 EST When it comes to TBI and PTSD, everyone's recovery is different. But Adam shares three key principles that can be crucial for everyone. Full Article
nc Escaping the maintenance mode trap By wpengineer.com Published On :: Mon, 06 Jan 2014 10:00:13 +0000 WordPress makes upgrading very easy . You simply click “Update now”, wait for a minute or two and your system […] Full Article WordPress Tutorials Maintenance Mode upgrade
nc Test or Meet at WordCamp San Francisco and Win a Plugin License! By wpengineer.com Published On :: Mon, 20 Oct 2014 06:12:30 +0000 Next week I will be at WordCamp San Francisco and a week later at the WooConf! Maybe one or antoher […] Full Article WPengineer Misc
nc Could you get PTSD from your pandemic experience? The long-term mental health effects of coronavirus By feedproxy.google.com Published On :: Monday, April 20, 2020 - 10:10am Experiencing intense flashbacks, nightmares, irritability, anger, and fear? In the face of a traumatic event like the Covid-19 pandemic, it’s common to feel this way. Full Article