Do convolutional neural networks perform convolution or cross-correlation?

Question: Typically, people say that convolutional neural networks (CNN) perform the convolution operation, hence their name. However, some people have also said that a CNN actually performs the cross-correlation operation rather than the convolution. How is that? Does a CNN perform the convolution or cross-correlation operation? What is the difference between the convolution and cross-correlation operations?
Answer: Short answer
Theoretically, convolutional neural networks (CNNs) can either perform the cross-correlation or convolution: it does not really matter whether they perform the cross-correlation or convolution because the kernels are learnable, so they can adapt to the cross-correlation or convolution given the data, although, in the typical diagrams, CNNs are shown to perform the cross-correlation because (in libraries like TensorFlow) they are typically implemented with cross-correlations (and cross-correlations are conceptually simpler than convolutions). Moreover, in general, the kernels can or not be symmetric (although they typically won't be symmetric). In the case they are symmetric, the cross-correlation is equal to the convolution.
Long answer
To understand the answer to this question, I will provide two examples that show the similarities and differences between the convolution and cross-correlation operations. I will focus on the convolution and cross-correlation applied to 1-dimensional discrete and finite signals (which is the simplest case to which these operations can be applied) because, essentially, CNNs process finite and discrete signals (although typically higher-dimensional ones, but this answer applies to higher-dimensional signals too). Moreover, in this answer, I will assume that you are at least familiar with how the convolution (or cross-correlation) in a CNN is performed, so that I do not have to explain these operations in detail (otherwise this answer would be even longer).
What is the convolution and cross-correlation?
Both the convolution and the cross-correlation operations are defined as the dot product between a small matrix and different parts of another typically bigger matrix (in the case of CNNs, it is an image or a feature map). Here's the usual illustration (of the cross-correlation, but the idea of the convolution is the same!).

Example 1
To be more concrete, let's suppose that we have the output of a function (or signal) $f$ grouped in a matrix $$f = [2, 1, 3, 5, 4] \in \mathbb{R}^{1 \times 5},$$ and the output of a kernel function also grouped in another matrix $$h=[1, -1] \in \mathbb{R}^{1 \times 2}.$$  For simplicity, let's assume that we do not pad the input signal and we perform the convolution and cross-correlation with a stride of 1 (I assume that you are familiar with the concepts of padding and stride).
Convolution
Then the convolution of $f$ with $h$, denoted as $f \circledast h = g_1$, where $\circledast$ is the convolution operator, is computed as follows
\begin{align}
f \circledast h = g_1
&=\\
[(-1)*2 + 1*1, \\
(-1)*1 + 1*3, \\
(-1)*3 + 1*5, \\
(-1)*5+1*4]
&=\\
[-2 + 1, -1 + 3, -3 + 5, -5 + 4]
&=\\
[-1, 2, 2, -1] \in \mathbb{R}^{1 \times 4}
\end{align}
So, the convolution of $f$ with $h$ is computed as a series of element-wise multiplications between the horizontally flipped kernel $h$, i.e. $[-1, 1]$, and each $1 \times 2$ window of $f$, each of which is followed by a summation (i.e. a dot product). This follows from the definition of convolution (which I will not report here).
Cross-correlation
Similarly, the cross-correlation of $f$ with $h$, denoted as $f \otimes h = g_2$, where $\otimes$ is the cross-correlation operator, is also defined as a dot product between $h$ and different parts of $f$, but without flipping the elements of the kernel before applying the element-wise multiplications, that is
\begin{align}
f \otimes h = g_2
&=\\
[1*2 + (-1)*1, \\
1*1 + (-1)*3, \\
1*3 + (-1)*5, \\
1*5 + (-1)*4]
&=\\
[2 - 1, 1 - 3, 3 - 5, 5 - 4]
&=\\
[1, -2, -2, 1] \in \mathbb{R}^{1 \times 4}
\end{align}
Notes

The only difference between the convolution and cross-correlation operations is that, in the first case, the kernel is flipped (along all spatial dimensions) before being applied.

In both cases, the result is a $1 \times 4$ vector. If we had convolved $f$ with a $1 \times 1$ vector, the result would have been a $1 \times 5$ vector. Recall that we assumed no padding (i.e. we don't add dummy elements to the left or right borders of $f$) and stride 1 (i.e. we shift the kernel to the right one element at a time). Similarly, if we had convolved $f$ with a $1 \times 3$, the result would have been a $1 \times 3$ vector (as you will see from the next example).

The results of the convolution and cross-correlation, $g_1$ and $g_2$, are different. Specifically, one is the negated version of the other. So, the result of the convolution is generally different than the result of the cross-correlation, given the same signals and kernels (as you might have suspected).

Example 2: symmetric kernel
Now, let's convolve $f$ with a $1 \times 3$ kernel that is symmetric around the middle element, $h_2 = [-1, 2, -1]$. Let's first compute the convolution.
\begin{align}
f \circledast h_2 = g_3
&=\\
[(-1)*2 + 1*2 + (-1) * 3,\\ (-1)*1 + 2*3 + (-1) * 5,\\ (-1)*3 + 2*5 + (-1) * 4]
&=\\
[-2 + 2 + -3, -1 + 6 + -5, -3 + 10 + -4]
&=\\
[-3, 0, 3]
\in \mathbb{R}^{1 \times 3}
\end{align}
Now, let's compute the cross-correlation
\begin{align}
f \otimes h_2 = g_4
&=\\
[(-1)*2 + 1*2 + (-1) * 3, \\ (-1)*1 + 2*3 + (-1) * 5, \\ (-1)*3 + 2*5 + (-1) * 4]
&=\\
[-3, 0, 3]
\in \mathbb{R}^{1 \times 3}
\end{align}
Yes, that's right! In this case, the result of the convolution and the cross-correlation is the same. This is because the kernel is symmetric around the middle element. This result applies to any convolution or cross-correlation in any dimension. For example, the convolution of the 2d Gaussian kernel (a centric-symmetric kernel) and a 2d image is equal to the cross-correlation of the same signals.
CNNs have learnable kernels
In the case of CNNs, the kernels are the learnable parameters, so we do not know beforehand whether the kernels will be symmetric or not around their middle element. They won't probably be. In any case, CNNs can perform either the cross-correlation (i.e. no flip of the filter) or convolution: it does not really matter if they perform cross-correlation or convolution because the filter is learnable and can adapt to the data and tasks that you want to solve, although, in the visualizations and diagrams, CNNs are typically shown to perform the cross-correlation (but this does not have to be the case in practice).
Do libraries implement the convolution or correlation?
In practice, certain libraries provide functions to compute both convolution and cross-correlation. For example, NumPy provides both the functions convolve and correlate to compute both the convolution and cross-correlation, respectively. If you execute the following piece of code (Python 3.7), you will get results that are consistent with my explanations above.
import numpy as np

f = np.array([2., 1., 3., 5., 4.])

h = np.array([1., -1.])
h2 = np.array([-1., 2., 1.])

g1 = np.convolve(f, h, mode="valid")
g2 = np.correlate(f, h, mode="valid")

print("g1 =", g1) # g1 = [-1.  2.  2. -1.]
print("g2 =", g2) # g2 = [ 1. -2. -2.  1.]

However, NumPy is not really a library that provides out-of-the-box functionality to build CNNs.
On the other hand, TensorFlow's and PyTorch's functions to build the convolutional layers actually perform cross-correlations. As I said above, although it does not really matter whether CNNs perform the convolution or cross-correlation, this naming is misleading. Here's a proof that TensorFlow's tf.nn.conv1d actually implements the cross-correlation.
import tensorflow as tf # TensorFlow 2.2

f = tf.constant([2., 1., 3., 5., 4.], dtype=tf.float32)
h = tf.constant([1., -1.], dtype=tf.float32)

# Reshaping the inputs because conv1d accepts only certain shapes.
f = tf.reshape(f, [1, int(f.shape[0]), 1])
h = tf.reshape(h, [int(h.shape[0]), 1, 1])

g = tf.nn.conv1d(f, h, stride=1, padding="VALID")
print("g =", g) # [1, -2, -2, 1]

Further reading
After having written this answer, I found the article Convolution vs. Cross-Correlation (2019) by Rachel Draelos, which essentially says the same thing that I am saying here, but provides more details and examples.
Answer: Just as a short and quick answer to build of nbros:
The way CNNs are typically taught, they are taught using a correlation on the forward pass, rather than a convolution. In reality, Convolutional neural networks is a bit of a misleading name, but not entirely incorrect.
CNNs do in fact use convolutions every time they are trained and run. If a correlation is used on the forward pass, a convolution is used on the backward pass. The opposite is true if a convolution is used on the forward pass (which is equally valid as using a correlation). I couldn't seem to find this information anywhere, so had to learn it myself the hard way.
So to summarise, a typical CNN goes like this: Correlation forward, convolution backward.
Comment: I'd also like to say this a really good question and a pretty important one for anyone who wants to properly understand the inner workings of a CNN. It can be very confusing when you go to do an actual convolution and find it's not doing what you expect.
Comment: Maybe you should explain why if the forward pass performs a convolution (or cross-correlation) the backward pass performs a cross-correlation (and, respectively, convolution). It was also my intention (although I haven't yet done it) to provide links to libraries and explain how they implement CNNs (in particular, the convolutional layers). If you know how certain libraries implement the CNNs (e.g. TensorFlow, PyTorch, etc.), then feel free to add this info to your answer.
Comment: Also, I don't think that convolutional neural network is a misleading name. You could have called them "cross-correlation neural networks" (but that would be long and without any benefit) or, to be more precise, "convolutional or cross-correlation, down- or/and up-sampling, fully or not, with possible other layers, such as skip layers, neural networks", but that name would be quite ridiculous.
Comment: @nbro I still think it's slightly misleading in the sense that it's very easy to assume that a convolution is being performed when calculating an output, when in reality it's normally a correlation. Given that this is the core element that makes a CNN what it is, it can be a bit confusing. I know I personally found it confusing.
Comment: @nbro As for why for the relationship between correlation/convolution and how libraries implement CNNs, this I don't know. I figured out the correlation forward convolution backward by just mucking around and doing a few forward and backward passes by hand, and I haven't much looked into the implementation within libraries such as Tensorflow or Pytorch.


Unbale to use Q(lowercase) key after a failed key-binding effort

Question: I tried to use the Alt-q combination to set as a shortcut for opening 'terminator' using gconf -> metacity-> global keybindings. But it did not work. The problem now is that my 'q' key on the keyboard doesn't work (I am copy pasting 'q' here). Funny thing is that 'Q' still works fine. I am unable to track the fault. I have reset all the keybindings and reset the system many times, but all in vain. What can be done in this regard?
Comment: What did you set in gconf? Did you reset it?
Answer: After doing a lot of things that did not work, I finally purged Xbindkeys (which I had installed in between and may have created the conflict) and terminator. After a reboot, the 'q' key is working fine now.


How to bring up a bad GPA in a interview

Question: Suppose in an interview somebody asks you about your undergraduate Grade Point Average (GPA). If it is very low what should you say? Also suppose your graduate school GPA is very high. Could I somehow use this to answer the low undergrad GPA?
Comment: Masters? PhD? Immediately after undergraduate?
Comment: The key is to demonstrate that you have been becoming more mature. Doing well as a grad student shows that you are growing and becoming more responsible. If you didn't go to grad school but your grades in the last 1 1/2 years were dramatically better then you could focus on that. If your major GPA was much better than your overall then focus on that. If you were just skating by throughout your 4 years then I don't have any idea how you'd spin that in a positive light. It isn't uncommon for people to get poor grades their first year or two, but by year 3 some maturity should start to kick in.
Comment: Hi Inerguyeorij, and nicely done with your first question on the Workplace! I have added a link to the GPA definition and tagged this United States to make it more clear in regards to @JanDoggen's comments and hopefully get you more responses and votes. Please feel free to [edit](http://workplace.stackexchange.com/posts/31084/edit) your question if I have messed it up in any way.
Answer: You can always try:

I don't feel that my undergrad GPA accurately reflected my abilities, and here's how I fixed that in my graduate studies...

Everyone makes mistakes, the important thing is to acknowledge that it happened and explain how you fixed it going forward. You will eventually make mistakes at work, but gracefully recovering from those errors is a much more valuable skill than never making the mistake in the first place because it impresses clients and/or management.
In terms of businesses and customer service, this is called the Service Recovery Paradox.
The other nice thing about a bad undergraduate GPA is that it eventually doesn't matter on your resume, and chances are it won't come up in interviews after you are out of school for a few years.
Comment: A good graduate record should fix the problem. If they ask about your undergraduate experience, explain that you've grow and matured. I really don't pay much attention to degrees and GPAs. They aren't really that much of an indication of a person's ability. Your attitude and examples of your work are more important. Go to the interview wanting the job. Let them know you do, and why. A lot of places ask you to code during the interview process. If you can do that, you can work under pressure. Be ready for that. The very best of luck to you.
Comment: @System:For a new grad, why wouldn't GPA be "much of an indication of a person's ability"? Most people are FAR BETTER at talking a good game than actually performing up to their talk.
Answer: Usually, the grad school GPA counts for a lot more than the undergrad GPA, assuming that you can make the case that your grad education is relevant to the field you work in. I had a pretty good grad GPA in engineering, and I can't remember a single prospective employer who did Oooh's and Aaah's over it.
Don't volunteer anything  about your undergrad GPA, unless you like coming across as defensive, apologetic and possibly pathetic. The more explanations you give, the more you look like you're making excuses. If someone asks about your undergrad GPA, mention it with a pained grimace and immediately refocus the subject by saying that your grad GPA is a lot better.
Answer: You tell them your GPA. That's it. Never start defending yourself unprompted, because you're actually attacking yourself.
"My GPA was 2.5 [and my further silence indicates that this is a total non-issue that has no relation to my ability.]"
Or:
"My GPA was 2.5, and now I will nervously talk about how bad of a student I was and make revealing excuses."
Now of course if they prompt you to explain, you can answer in about two sentences, using your grad GPA to definitively prove that you improved and grew. If you spend more than two sentences, it really only raises the question of why that wasn't a sufficient explanation.
Comment: I disagree that you cannot answer that question in such a way to alleviate the asker's concerns. There are ways to answer questions which are factual to help with concerns the asker obviously has. Simply saying "My GPA was 2.5" is not one of them.
Comment: I think that regardless of what you say or do not say, the interviewer will have their own opinion about what it means anyway...
Answer: I think regardless of the actual GPA score, the important thing is to provide some explanation so the interviewer can put it in the right context.
For example, a bad GPA score may reflect that you are not good at exams if you can back it up with good practical knowledge and work experience.
Alternatively, a good GPA score may reveal some lack of practical knowledge but at least shows dedication to learning and commitment to achieving to your potential.
So the important thing is to bring out the positive aspects no matter what the score is, and address the concerns that the interviewer might have with any perceived shortcomings as reflected by the score.
Answer: You don't.
But if the interviewer brings it up, you have to tell him, and your silence after that should underline that the GPA doesn't matter.
But still, there are few companies obsessed with GPA. In this case you must have good student projects, or any other experience in your resume to vouch for you. I mention my great graduation project, for example.
Comment: This post adds nothing new to the already posted answers. Please remember to [not repeat others](http://meta.workplace.stackexchange.com/questions/255/faq-proposal-back-it-up-and-dont-repeat-others), particularly when you are resurrecting a question which is 2 years old.
Answer: You take a leaf out of the politicians interview playbook and answer with the Grad school GPA - answer the Q the puts you in the best light even though its not the "exact" Q asked.
Comment: As it's not a very important question, one might get away with that, especially with good grad GPA. If one gets caught, the interviewer will be admiring the politician interviewing skills. Only some less appreciative companies may pass on the candidate...
Answer: You can always say that there was so much to do and so many things that interested you at the time that you didn't always have time for academic stuff! It shows your interests. Bonus points if you can name something that can actually help you with this job or something you have in common with the interviewer. Or makes you an interesting person.
Comment: You often have to do a lot of things that don't interest you as part of a job (hopefully you do a lot of things that interest you as well). This excuse only raises concerns that you will slack off on projects you find boring.
Comment: "I went to school but once I was there, I was not into school". Not sure that this rationalization would fly unless the outside interests were compelling e.g. "I was consumed with fighting human trafficking" After all, a prospective employer such as myself would be asking "What's to prevent the candidate from doing to the job what they did to the school, given that the job could be even less exciting than school?"
Comment: Right. I didn't realize that. Thanks, it's actually really reasonable.


How to wrap a gift so it doesn't look like the gift?

Question: I need to wrap a gift but it has a really obvious shape and they would know what it is. Is there a way that I can wrap it so that they won't know what it is till they open it?
Answer: Use a cardboard box larger than the gift, and gift wrap the box.
If you don't have a large box, you could -- depending on the gift -- place smaller, disposable objects such as foam cups or crumpled newspaper around the gift to alter its shape under the wrapping paper.
Comment: Also if the gift is not fragile include some other objects in the box to provide a misleading weight/sound when picked up or shaken...
Answer: You can wrap them in the following methods:

Use cardboard or Newspaper. This can be done by crumpling the newspaper around the item or by plainly putting them in a cardboard box.

Putting them in cleaned cereal boxes is a good method and really small gifts can be concealed in origami. Its kind of tricky to fold them in though.

For something more fancy looking:
Buzzfeed.com:

Wrap them in Balls of Yarn. This is good as you can have any colour of yarn, but retrieving them can be tricky and wrapping them can be trickier.

Folding the gift into a sweater or other article of clothing. This is good for books and other items. Wrapping them in clothe also works. The buzzfeed.com article wraps them in scarves.

This is good for giving two gifts.

This article also shows putting gifts into a sweater sleeves. Not very concealing, but cute.

Use paper or plastic bags. Paper bags are more decorative. You shouldn't add the buttons and such because that totally gives it away.

A large black bag would work, but be sure to let the air stay in it.

Other Ideas

Putting them in Lego brick boxes is good for Lego fans and kids. But it may take a lot of bricks.
Taking multicolored cups or any cup, especially mugs and putting the gift inside. You can make a whole table of gifts by putting other gifts into dishes.

Garbage cans and other storage boxes, may help.

Putting the gift in jars with custom or large labels helps. You can even use cans, but be careful of the sharp edges.

Basically taking any container that wouldn't be expected works. Containers like lunch boxes, non-clear containers, etc.
Answer: Often times I have used multiple boxes wrapped within each other (like the classic "Russian Nesting Dolls") to mask the appearance of a smaller, more recognizable gift. Not only does this add to the illusion of what the gift is, or might be (and to the work for you, however), it adds a bit of fun to the process of opening the gift.
If the gift is either too large for the nesting theory, I have taken parts of boxes an taped or "added" to the length before. This makes the box either longer, wider or taller... sometimes even odd shaped if you care to be "silly" with the process.
I have also been known to add sections of the inner cardboard tubes to the gift in odd places from either toilet paper, paper towel, or even wrapping paper rolls. This interesting shape helps to mask the appearance easily. And, you can place a few rocks, pieces of candy, change, small jingle bells or the like within the tubes so they "rattle" a bit within the void and this too adds to the subterfuge of what the gift may be.
As a last resort, I have wrapped a picture of the larger gift within a small package before to entirely throw the individual off. Not only is this a great trick, it saves on a TON of paper and tape if the gift is quite large. Imagine the surprise a person would have if they opened up a photo of their new bike, new ice skates, a laptop/tablet, Playstation or Xbox...especially if the box was the size of an earring box!
Answer: Turn it into an Easter Egg hunt. Place a card under the Xmas tree. Inside the card give a clue as to where the present can be found. In the next place hide a box wrapped in Xmas paper - in there place another clue to where the real present can be found.
Comment: how ironic to use Easter Egg Hunt on Christmas.


PRP, PRF and modular arithmetic

Question: Are there any arithmetic or mathematical functions that can be used as PRPs or PRFs ?  Since, Conventional block ciphers like AES are that are proven to be good PRPs are not based on mathematics but on other principles like confusion and diffusion etc.
Comment: Please edit your question to give a precise definition of what you mean by an "arithmetic function". Is AES an "arithmetic function"?  How about cubing modulo a RSA modulus?  Also, please elaborate on what you mean by "simulate".  Finally, I suggest you add some context and motivation: why are you asking? what is the real goal? what research have you done to try to solve this on your own?
Comment: Are you asking for an arithmetic function $(k,x)\mapsto F(k,x)$ such that, for some random unknown $k$, $x\mapsto F(k,x)$ would be computationally indistinguishable from a random permutation or function? That seems to be a good question with some useful characterization of _arithmetic_, which is missing. Ultimately, AES or SHA-1 can be written as a long composition of arithmetic functions, if you consider $(a,b)\mapsto a\bmod b$ to be arithmetic. Any interesting definitions of _arithmetic_ that I can think of uses a threshold; like, at most some number of operators.
Comment: AES does not simulate a PRP, and a PRF ? I'm looking for functions based on hard mathematical problems, like factoring, or DH... Maybe the term "simulates" is not OK... ?
Comment: Do you want DDH/RSA-based PRFs? If so, we have them and I will answer.
Comment: @xagawa Yes, I want that :-)
Answer:
Do you want DDH/RSA-based PRFs? If so, we have them and I will answer. –  xagawa
@xagawa Yes, I want that :-) –  Dingo13

I list the PRFs based on the number-theoretical assumptions.
They are ``arithmetic or mathematical function.''
You can use the Feistel network to obtain (S)PRPs from PRFs in theory.
From the DDH assumption
The Naor-Reingold Pseudorandom Function is a PRF based on the DDH assumption.
Let $\mathbb{G}$ be a finite group of order prime $q$ with a generator $g$,
on which the DDH problem is hard.
Let $\{0,1\}^\ell$ be a domain.
The function is defined as
$$\mathrm{PRF_{NR}}(k, x) = g^{a_0 \prod_{i=1}^{\ell} a_i^{x_i}},$$
where $k = (a_0,a_1\dots,a_{\ell}) \in \mathbb{Z}_q^{\ell}$.
For the proof, see the original article in J. ACM.
Lewko and Waters generalized the NR PRFs in CCS 2009 (and ePrint 2009/486).
Their PRFs are based on the decisional linear assumption (and its weaker variants).
Most efficient one
Under stronger assumptions such as the DHI assumption,
 we have a cute PRF, say,
the Dodis-Yampolskiy PRF proposed as
Verifiable Random Function (VRF).
Let $\{0,1\}^{\ell}$ be the domain of PRF.
Suppose that $2^{\ell}$ is a polynoimal of the security parameter.
The DY PRF is defined on a symmetric bilinear group as follows:
$$\mathrm{PRF}_{DY}(k,x) = e(g,g)^{1/(x+k)},$$
where $k \in \mathbb{Z}_q$.
From the factoring assumption
This is a classical result obtained by a combining the Blum-Blum-Shub PRG and the Goldreich-Goldwasser-Micali PRF from any PRG.
Naor, Reingold, and Rosen improved efficiency of factoring-based PRFs.
See the original article available at ECCC TR 2001-064,
From the hardness of lattice problems
Nowadays, the lattice problems are often employed to construct cryptogrphic primitives.
You can find the PRFs from lattices in
Banerjee, Peikert, and Rosen (EUROCRYPT 2012),
Alwen, Krenn, Pietrzak, and Wichs (CRYPTO 2013),
and Banerjee and Peikert (ePrint 2014/074).
Comment: Correctly speaking, the size of domain $2^{\ell}$ should be small, because the construction is based on $2^{\ell}$-DBDHI assumption.
Comment: A note: the results in the Alwen et al paper are actually not strong enough to yield PRFs (contrary to what the paper says), because they are limited to an a priori bounded polynomial number of samples.
Comment: I do not understand " $2^{\ell}$ _is a polynoimal of the security parameter_", and that has nothing to do with the minor typo. The answer is still great.
Answer: No. Conceptually , not so strongly close but similar ones that would come closer is $k$-wise Independent Distributions/Functions .
Comment: I believe , what could be found out from google , can be left for seekers exercise and save some time of one who answers it.
Comment: I've downvoted this answer because I don't think it has sufficient explanation or depth
Comment: I've upvoted it because I think it is correct and points the original poster to the key technical term, from which they can find more.  You can look up what $k$-wise independent hash functions are pretty easily; I expect they're probably in Wikipedia and in good textbooks on derandomization/randomized algorithms.
Comment: Possibly. Even just the addition of a relevant link would I think satisfy my worries

PRP, PRF and modular arithmetic


MySQL root user can't access database

Question: We have a MySQL database ('myhours') on a production database server that is accessible to one user ('edsf') only, but not to the root user. The command 'SHOW DATABASES' as the root user does not list the 'myhours' database. The same command as the 'edsf' user lists the database:
mysql> SHOW DATABASES;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| myhours            |
+--------------------+
2 rows in set (0.01 sec)

Only the 'edsf' user can access the 'myhours' database with 'USE myhours'. Neither user seems to have permission to grant further permissions for this database.
My questions are:
Q1. How is it that the root user does not have permission to use the database? How could this have come about? The output of
SHOW GRANTS FOR 'root'@'localhost';

looks fine to me:
GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' IDENTIFIED BY PASSWORD '*xxx' WITH GRANT OPTION

Q2. How can I recover this situation to make this database visible to the MySQL root user and grant further permissions on it?
Thanks in advance for any help!
-- Ed
Answer: you need to flush the permissions

flush privileges;

the connect as root and list databases

MySQL root user can't access database


How did we get all these untagged questions?

Question: There are right now 15 questions with the only tag of untagged, linked here.
Some of these actually had tags at one time.
What happened here?
Please note I'm cleaning some of these up, though I don't have the time to take care of them all today.
Comment: there are currently 90 untagged questions
Comment: Now there are 94.
Answer: To be clear, the policy:

Any tag with only one question in it for an entire six month period, will be automatically culled at the end of that six month period. If this culling results in zero tags, the question will be retagged untagged.

Does every single question really need a unique boardgame tag, no matter how obscure it may be? Isn't plain old search sufficient?
If you feel strongly that a tag is justified, I'd make absolutely sure there are two questions containing that tag in a six-month period -- even by asking another question myself if need be.
15 untagged questions is honestly a tiny amount. And I think the retags Lance performed made the questions much better -- so thank you for that, Lance.
https://boardgames.stackexchange.com/users/96/lance-roberts?tab=activity
e.g.

[untagged] --> [valuation] [classic-games]
  [untagged] --> [online] [blogs]
  [untagged] --> [recommendations] [board-game-adaptations]

etc, etc.
In that sense, forcing the untagged is actually helping overall quality because it highlights questions that need more than one highly specialized tag.
(You might also look at meta.gaming where they have had similar discussions, and I urged them not to blindly create a tag for every single videogame that has ever been written in the history of recorded time.)
Answer: It's obviously true that questions about obscure games are likely to be the only ones populating the associated tag for some time, and are at risk of being orphaned by the clean-up script.
One thing we can do to minimize the impact is ensure that if other tags are valid that they are also added, especially in cases where the non-game-name-tag is really the most relevant. For example, this Hi-Ho-Cherry-O question had a lot of activity lately and is rightly tagged with the game name, but fundamentally it's really a question about probability and needed to be tagged as such to get the attention of the right experts (as it obviously did).
There are a lot of questions that can be tagged this way, and if we're good about it then the impact of losing a game-specific tag will be significantly blunted (after all the point of a tag is to group similar questions and if there's nothing to group the tag adds no value).
Answer: I think what happened was that the remove tags with only one question script, removed them and when that left the question with no tags, it added the untagged.  We should get that script disabled for this site, since there are MANY games out there that will take a while to build up a population.
I wrote the team on this issue, since there were no moderators responding.
Jeff said that it's a network setting, and the only recourse was to create a second question that used the tag, so that the tag wouldn't disappear.


How does a tilt-shift lens work, and why does it solve certain problems?

Question: So, I understand that a tilt-shift lens solves certain problems with shooting buildings and getting straight lines and such, but what I've not understood is why.  I'm looking for the technical reasons (maybe diagrams?) as to why tilting and/or shifting has this effect or other desirable (or undesirable) effects.
Answer: You don't use the tilt element of tilt-shift lenses to fix perspective, only the shift element.
Tilting tilts (or swings - that's the term for a horizontal tilt) the plane of focus. It's mostly used for increasing apparent depth of field. Imagine you're taking a picture of a football field. You want the entire field to be in focus but you're using a large format camera and you can't stop down too far. Thanks to movements (tilt/shift) you can tilt down your plane of focus, so instead of vertical, it's tilted forward covering the field. You lose focus on the sky, but that doesn't really need to be in focus anyway, right? What's funny is that although you tilt part of the lens, the scene you're framing never actually changes.
All this is covered in this fine wikipedia article on the Scheimpflug principle.
Shifting is pretty simple. Inside your camera, your lens works a bit like a projection lens works on a movie screen. This is why longer focal lengths give you more "zoom" - the same thing happens when you move your projector away from the screen. Your lens projects and image onto your sensor or film - just like you have it projected on a screen in a movie theater. With 99% of lenses, the position of the lens is fixed and the image shown on your sensor is just big enough to cover it... or sometimes, not, that's when vignetting happens. With shift lenses, your circle is much bigger, so when you shift, you really just move the lens around in front of your sensor, as if you were moving a projector.
Shooting large format really helps you understand that a camera isn't a fixed object, it's really two planes that can interact with each other in a huge number of ways.
Comment: Note, though, that shifts almost always require either some tilt or swing (a very minimal amount) for critical focus across the field. The process gets to be a bit of a pain in the butt, actually, since the tilt changes the perspective, which necessitates changing the POV somewhat, which changes the .... Having rear tilt/swing as well as front makes it a lot easier (which is probably why nobody uses a field camera for architecture if they have a choice).
Comment: Oh, "pain in the butt" and "movements" go hand in hand.
Answer: This is my intuitive understanding of the shift lens, based on the Wikipedia article, and especially the first diagram from that article:
Let's say we want to shoot a tall building, where we stand at the base level. Our field of view doesn't allow the whole building to be captured in the frame. In fact, when the camera is level, half of the frame is "wasted" on image of the ground.
It is obvious why, if we tilt the camera so we do capture the whole building, we get the converging vertical lines due to the perspective effect.
If we had a bigger film (sensor), then the FoV was bigger and we could capture the whole building. So, shifting the lens up relative to the image center effectively "extends" the frame in the opposite direction, so now we have a bigger "half frame" and we capture the whole building while at the same time we reduce the other "half frame" and eliminate the ground!
As for the tilt part - consider that in optical geometry is more or less symmetrical around the lens center. Now the plane of sharp focus is parallel to the lens. So, when you shoot, say, the ground, which is not parallel to the lens, you see the effect of DoF. Now, if you tilt the lens, then the plane of sharp focus is tilted as well. This way, you get on the film a much deeper DoF from the non-parallel plane that you are shooting.
Answer: If your film plane is parallel to the subject then no lines on the subject are distorted.  Conversely if you angle the film plane so its no longer parallel to the subject, lines converge towards the further away edge of the film plane and diverge from the closer edge of the film plane.
Using a tilt shift lens you can keep your film plane parallel to the subject and just move the lens about to change what is in the field of view.
Wikipedia: http://en.wikipedia.org/wiki/Perspective_control_lens
Answer: Let me first explain the tilt portion. An image is projected straight from the lens to the camera. If the lens is tilted relative to the sensor, then different parts of the image will be in focus at different lengths. The location in focus depends on 3 things. The first is the distance of the lens to the sensor. The second is the distance from the lens plane to the object of interest. The third is the focal length. What's happening in the tilt portion is that there is different lengths from the sensor to the lens plane. Thus since the focal length remains constant, the location of the in focus part must change.
The shift part is a bit more difficult, but let me give it a shot. What happens is you are moving the lens up and down. This causes a different area to be in focus, but the lines still remain as you have it originally.
Comment: Shifting can also occur to right or left, e.g. indoor shots with mirror on the wall.
Answer: The other answers are great but I wanted to add one more thing.
You can do the same correction in Photoshop or with various other tools (some panoramic tools can be used this way, such as Autopano Pro).
So why bother with tilt-shift lenses anymore?  Because when you correct this in software, the results may leave some areas far less sharp than others - because when you correct distortion you are literally "stretching" some pixels greatly, and those areas will be much less sharp (while in other areas you are compressing pixels and throwing out detail).
If you look around you can find third-parry tilt/shift lenses for most mounts, if you really want to explore using one.  Or you might be able to rent one for your camera.
Comment: If by "a similar effect", you mean "not at all the same thing"..then sure.
Comment: Fix in post may be fine for simulating the shift effect, but not the tilt effect. With a tilt lens you change the actual PoF (plane of focus), which means that different things are now in focus compared to a non-tilted lens. This is pretty much impossible to imitate in post.
Comment: True enough, although even there sharpening with a gradient mask can kind of give you a similar effect...
Comment: It can be similar because with selective gradient sharpening you can make the plane of focus appear to extend in ways that are not a flat plane in front of the camera.  It's not quite the same but would give a similar impression.  People good with Photoshop have been playing tricks like this for years.  It's no replacement for the real thing but you seriously underestimate what can be done in post by someone determined.


Are there performance and stability differences between vanilla and Bukkit servers?

Question: I am deciding whether to switch my vanilla server over to a Bukkit server. I did upgrade to the development build of Java 7 which did give me a slight performance boost. Just wondering if anyone has seen noticeable performance or stability difference between the two.
Answer: The core CraftBukkit server (Bukkit's implementation) itself is equivalent from my experience.
But since anyone that can copy/paste Java can create a plugin, it really depends on which plugins you use.  It pays to do your research here and understand the impact of each plugin you decide to install.
You can sort of rely on the most popular plugins (plugins with threads that have a lot of comments compared to others) to be fairly reliable.  If you start delving into lesser used plugins, spend the time to read the entire thread and understand exacly what the developer is trying to accomplish.  If you have any coding experience at all, look through the source code to get an idea of what it exactly does.
What I would say in summary is that a significant portion of most servers (small, medium, and large) run CraftBukkit successfully.  There are problems for sure, but there are problems with Vanilla also.  Nothing's perfect.
Answer: I run two different servers:

a Vanilla server

Running on a computer with the latest i7 I could get with 16 GB RAM

a Craftbukkit/Spigot hub

Running on an i5 processor with 12GB RAM
I have a few worlds on the same computer/connection via a hub
It has one server with 5 multi-worlds and three other worlds via the Spigot Hub

The craftbukkit ones run much better, with less lag and fewer problems, and can handle more players, despite having worse hardware.
Answer: The Bukkit server works really well, the Performance of the bukkit server is very good. But it really depends on the mods you might install via the bukkit server.
We have not seen any noticeable performance issues, and it is very stable! The mods might be unstable.
We run on Ubuntu with minecraft on Ramdisk!


Is it possible to disable Google Voice Search headset control in 4.1 Jelly Bean?

Question: I flashed my Samsung Galaxy S i9000 with the RemICS-JB 3.0 ROM, and now long-press on my headset is hard-coded to start Google Voice Search, which doesn't interest me. I'd much rather have long-press be available to other apps (I used it as "rewind" in my podcast player). Is it possible to disable this hard-coded headset control, or disable Voice Search entirely? There isn't a separate app for it, and I can't seem to disable the Google Search app.
Answer: You can use one of the "headset button controls" available on the playstore, e.g. JAYS Headset Control or Philips Headset. Both allow you to define an app started automatically when your headset attaches, and as well to assign actions on short/long/combined headset button presses.
To make that better understandable, let's take the morse code: . is short, - is long press. So the default configuration e.g. does on...

. play/pause or answer incoming call
- increase volume
.- decrease volume
.. skip to next title or reject incoming call

and more, up to triple combinations. With most of these apps, actions can be freely configured.


Login to salesforce with oauth 2.0 directly from external app using ajax

Question: I want to be able to login directly from my .net application's login (without having to use the user's security token). And I was wondering if it was possible to send my username and password to the salesforce OAuth endpoints via Ajax and then retreive the access token and other values without getting redirected to the salesforce page. And if it were possible how would I implement it? Since I'm a complete beginner when it comes to this so any help would be appreciated.
And I'm not sure about this but wouldn't sending the username and password be a security risk? Or is there a way to protect these informations.
And if someone wanted to clarify this a bit it would be great since I'm still looking around these solutions.
Comment: What is your use case? Are you trying to implement a SSO or you are trying to invoke APIs in Salesforce?
Comment: @JayantDas Well you could say both, since my application is based on only salesforce data. So for a specific user I need to get all his data to exploit it for the app.
Answer: Have you looked at Understanding the Username-Password OAuth Authentication Flow?
Per the warning on the page:

This OAuth authentication flow passes the user's credentials back and forth. Use this authentication flow only when necessary. No refresh token is issued.

You cannot get a refresh token this way, though, so it can only be used to get a temporarily usable token and you need to submit user/pass each time you want that token (as far as I can tell from the docs).
Why is it that you want to avoid the Salesforce oAuth screen? FWIW the oAuth flow has become a standard for a reason.
You can also Google around for methods that enable opening the auth screen in a pop-up and sending the code back to the main window (all in the browser via JavaScript), so you don't have to navigate away.
Comment: I actually have, but as you said that flow is not advised so I'm looking for a way to implement what I said in a secure way and that flow isn't even an option for me since, like I said I don't want the user to have to input his security token, only his password and in the that flow you need both. It was requested I implement it this way and I think it's because in order to use the app you must be logged in so having the main page just be a button to get a pop up of the sf login isn't the best. Whether it s a redirect or pop up the issue is the same that's why I asked about ajax
Comment: I think the terminology is misleading you: consumer key and consumer secret aren't the end user's key/secret. When you set up a connected app you get those two things. The only thing required from the user is their password and username.

The way you'd implement this, then, means that they're sending their username and password to your server, your server makes a call to this endpoint with the payload described in step one of the link above. At that point it gets a token back that you use for subsequent API calls.
Comment: What isn't clear to me is how permissions grants are done here since you aren't redirecting to Salesforce and they can't see the permissions you're requesting. It's easy to test this, though. 1. Setup a connected app 2. Make a request using the instructions above. 3. see what response you get back
Answer: Storing passwords in an application is always risky from security perspective .The security token is a security feature which expires everytime password changes .You can learn about some of the security measures salesforce recommends here.
The other option that you could use is an oauth JWT based flow .
With this approach you will create a connected app for your application and register a certificate .You will get clientId and also the certificate private key.
Securely store the private key and the client Id in a secure DB and you can use only the username to generate a JWT based token based on the client Id and the certificate private key .
This way you don't have to ask for the password or even a security based token .
Answer: Using OAuth, you will need to redirect to Salesforce. Salesforce employs a number of login security features depending on the user's permissions and customization. For example, you can use the Lightning Login app, an SMS single-use code, an email single-use code, etc; if their browser is already authenticated, no code will be required and they may even log in automatically. The security token is only required if you use the SOAP login() call. Your app doesn't need to open a new window; you can just use a WebView (or similar) to perform the login action if you prefer to keep everything in the same window. However, the downside is that the user will likely need to use whatever 2FA is configured (e.g. one-time code).


Describing requirements in SRS - use cases?

Question: I do not have the access to the IEEE standard and information on the net are contradictory. Can I capture user requirements in SRS using use cases? Or I should keep use cases separate as they are more like scenarios than separate requirements?
Answer: UML Use Cases were written long after the IEEE standards on SRS (UML in 1994 and SRS ten years earlier in 1984). Therefore there aren't really a reliable source on answering the if-and-where use cases should be in an SRS.
The IEEE standard for an SRS document mostly tells you how the document should be formed. So if you really want the use-cases placed somewhere in the SRS it would be under the "Specific Requirements" part of the document. Use-cases are specific scenarios and should be treated as specific requirements.
However the first step you should ask your client or reciever what they want from the requirements document. Do they really want to have UML Use Cases or something else? There are a bunch of ways to elicit requirements and some clients most likely want it their way. For reference check out the book "Software Requirements - Styles and Techniques" by Soren Lauesen.
Answer: Brief Summary
The answer is yes, you can use UML Use Cases to describe requirements in your SRS, however, the original SRS needs to be customized for that purpose because the standard is out of date.
IEEE 830-1998
It is important to bear in mind that the latest published version of the SRS standard IEEE 830-1998 is from 1998. The standard does not apply well to modern software engineering. Instead of following it as-is, we can use it as a basis for defining our own SRS.
One of the reasons is that in 1998, requirements were typically written as required functions. The major paradigm was procedural programming. Often, requirements were stated in a natural language. Today, we are using object-oriented programming and different techniques/tools to support it.
The best practice is, and always was, to write unambiguous requirements. For that, UML is a perfectly viable notation. The only suggestion would be to consider also textual use cases before deciding on graphical diagrams. Use cases contain much more information in text which helps to clear out possible misunderstandings.
Accessing the Standard
Without the need to buy a copy of the standard, you can read its outline available for free at wikipedia. Some software engineers have been using IEEE 830-1998 as a basis for their own custom SRS. That is how issues with its age can be addressed.
Examples of Customized SRS With Use Cases
Paper on the topic (A good enough solution to follow)
Sample Ad-hoc customized SRS #1
Sample Ad-hoc customized SRS #2
SRS Template with use cases incorporated in it


How to Calibrate / Setup an Electric Guitar?

Question: Even with new strings, my guitar makes some sort of buzzing noise on higher strings. I was told it needs to be set up.  What are the steps or where can I find a good guide to do this?
Comment: possible duplicate of [How do I set up an electric guitar?](http://music.stackexchange.com/questions/1612/how-do-i-set-up-an-electric-guitar)
Comment: @Luiscencio We still have your "tremolo" problem that we could address. Could you please describe it in more detail?
Comment: @Paul It's mostly (entirely?) a dupe, but see http://blog.stackoverflow.com/2009/04/handling-duplicate-questions/.  I think it falls into case (3) and we should keep it.
Comment: I bought this [book](http://www.amazon.com/Guitar-Player-Repair-Guide-3rd/dp/0879309210) and found it to be a great resource.
Answer: I have never heard the term 'tremolo' applied to higher pitched strings, but I will do my best to point you in the right direction when it comes to setups.
First of all, when setting up a guitar, set the action of the strings first. How you do this depends on your model of guitar, but there should be a screw or something else that adjusts the height. Remember, if it is a screw, turning to the right increases height. Adjust to desired height. If your preference is low, make sure there is no fret buzzing on any frets on any strings.
Next, you have to check the intonation. Tune up the guitar to perfect pitch (according to the tuner) and then, on each string, hit the 12th fret harmonic, listen, then play the 12th fret note. If there is any difference in the two, then your intonation is out, which will affect the ability to tune the guitar correctly, and mean the guitar will not be in tune with itself.
The G and B strings are usually the worst culprits when it comes to intonation, particularly in my experience.
If the fretted note is higher (sharper) than the harmonic, then the length of the string  needs to be lengthened.
If the harmonic note is sharper, then the length of the string needs to be shortened.
Again, adjusting intonation depends on your make of guitar, but their should be a screw or adjuster on the bridge. Adjust, and then check the harmonic and 12th fret notes again. Keep adjusting until they are exactly the same as each other.
The first time you have to setup your guitar, my suggestion would be to take it to a guitar luthier who will set the instrument up for you. If you ask him, he will talk you through what he is doing, so that you can do it yourself. He will fix any problems on the action, nut, neck, truss rod, and bridge piece that will be affecting how the instrument sounds/plays/tunes.
Full setups CAN be expensive, but nearly always a very good quality job is done, and is worth it, particularly if you are having problems with your guitar (it always sounds out of tune, even when in tune with a tuner etc). The first time you play your guitar in a perfectly re-setup condition you will know what I mean.
Hope this helps.
Answer: For your first guitar setup, I highly recommend you take it somewhere, have them do the work and ask questions about what they do and why, before trying it yourself.
Setup at your local music store can be as inexpensive as 30 USD or so, depending on the area in which you live. Seeing an actual luthier, one who's good, can run you as much as 120 USD for a full setup, and the difference in quality of work will be quite noticeable.
The buzzing you're describing is most likely from your action being set too low. Generally an action height of 1mm is a good starting point for a smooth, low, playable action. If things buzz there, raise it slowly until the buzzing stops. If it persists, or if your action gets too high before the buzzing stops then you may need new saddles, a new bridge, new nut, or possibly some re-fretting work. If this guitar was purchased from a music store and just pulled out of a box, then it only has factory setup (if that), and there's any number of issues that could have developed in the time between purchase and when you noticed the buzzing.
But yeah, definitely bring it in.
Answer: There are two ways to go, that I'm aware of. Either have a pro set up your guitar for you, or learn to do it yourself. If you choose to learn to do it yourself, you might enroll in a luthier training program or choose to learn from a book. I've used a book by Dan Erlewine as a guide for learning to set up my own guitars. He explains the process clearly and helps the reader understand the reasons for each adjustment.
Doing your own setup can require some specialized tools, so that will need to be considered as part of the decision. These tools are found at just about any guitar parts supplier on the internet, and they will send you a catalog of their merchandise if you request it. I hope this helps.


What's the difference between flight level and pressure altitude?

Question: When should we say flight level and when should we say pressure altitude?
I know they both set QNE 1013.25, but there is a difference between them.
Anyone know?
Comment: Flight levels are pressure altitudes.
Answer: Flight Level specifically refers to Pressure Altitude in 100 foot increments within the Standard Pressure Region, which in North America starts at 18000 ft and above, and at various lower altitudes elsewhere.
If you are in the Altimeter Setting Region where you set local barometric pressure to get indicated altitude, you normally use indicated altitude and could state the pressure altitude if asked, but you wouldn't use the term Flight Level.
Answer: Below are three answers: When should we say which, and what is the "difference" between the two terms.

Let's start with Pressure Altitude. There are lots of more-complex answers in various publications about what pressure altitude is, and many of them are already discussed on this site.  A "short and sweet" answer is: Pressure Altitude is simply the "height above a standard reference point at an agreed-upon air pressure measurement".
We use sea level as the reference point, and 1013.25 hectopascals (hPa) as the agreed-upon "standard pressure setting".  This atmospheric pressure is the equivalent of  1013.25 millibars, 29.92 inches of mercury, and 14.696 PSI.
Pressure altitude is useful for many things, but one of the most important to aviation is that almost all aircraft performance charts are based on pressure altitude. To a pilot making calculations, such as how much runway length will be needed to land or take off, the pressure altitude is one component of that formula.
For example: we know that Denver International Airport is at an elevation of 5430 feet above sea level.  If there is a low pressure system in this area of about 970mb, then the Pressure Altitude for DIA will be at about 6500'.  When a high pressure system moves in a few days later, the Pressure Altitude could drop down to around 4500 feet. These different pressure altitudes at the same location could prevent some aircraft operations that might normally be doable.
Summed up: Pressure Altitude is how high above (or sometimes below) sea level the current air pressure "feels", and can have a significant impact on aircraft performance.

Q: When should we say Pressure Altitude?
A: Whenever we need to know what the relative height above sea level is for a given location, so that performance calculations can be made.

Now let's move on to Flight Levels.  Flight Levels (FL) are "officially designated" pressure altitudes at or above the official transition altitude (TA). These TA and FL designations are different by country, or even within different terminal areas of the same country. As you noted in your question, a Flight Level is determined by setting your altimeter to QNE and then reading the value on the altimeter.  But this reading is only a "Flight Level" when the aircraft is above the TA.
Within the US and Canada, the TA is at 18,000 feet of altitude. If the regional QNH is 1013.25 hPa, then Flight Level One-Eight-Zero (FL180) will be right at 18,000 feet of altitude. FL200 will be right at 20,000 feet of altitude. However, if there is a low pressure system then FL200 could be all the way down at 18,000 feet.
(note: In this low pressure example, aircraft will not be assigned a flight level of FL180 or even FL190, because it would be unsafe - the aircraft would actually be at about 17,000 feet and below the Transition Altitude and interfering with other, possibly non-controlled, aircraft. Therefore, on this low pressure day, it would be said that "the lowest available Flight Level is FL200".)

Q: When should we say Flight Level?
A: Whenever we are talking about aircraft that are flying above the Transition Altitude, and assigned to a specific pressure altitude.

And finally, your 3rd question:

Q: What is the difference between the two?
A: A flight level is always "an officially-designated pressure altitude". But, any given pressure altitude is not necessarily a flight level, and will be used for purposes other than just determining flight levels.
Answer: The pressure altitude can be determined by either of two methods: 1. Setting the barometric scale of the altimeter to 29.92 (1,013.2 mb) and reading the indicated altitude. 2. Applying a correction factor to the indicated altitude according to the reported altimeter setting.
Airliners generally set the barometer to 29.92 when climbing thru 18000 feet and then fly the flight level they are cleared to.
When descending, the barometer is set to the local pressure, updated as needed (every 50-100 miles or so) and fly the assigned altitude (such as "descend and maintain 15000, one five thousand").
Us smaller guys just set to the locally reported barometer setting. (I've only been up to 12500 feet in my plane - and have actually driven higher, 14110 feet, to the top of Pikes Peak in the Rockies.)


What are some good options for bumper pushing

Question: What is a good way to push with your bumper without ruining the body of the car you are pushing (paint scratches do not matter.
Comment: I'd suggest using towing eyes and a tow rope. Causes less damage
Answer: The best option I have seen is to put an old tire (without a rim) between the cars.  The tire is flexible and provides a large surface area to minimize the possibility of dents and scratches.
That said, many, many cars these days are just not pushable or capable of pushing.  Many "bumpers" are for looks only and won't stand up to any real force without breaking attaching clips or internal mounting brackets.  My general rule would be that unless it has a chrome, metal bumper or you know for a fact exactly how the bumper is constructed or attached to the car, DON'T PUSH IT.
Comment: I don't care about the cars bumper  that I'm pushing it with ( it is cracked anyways and needs replaced) but care about the other car that's being pushed since all it needs is a paint job
Comment: I think it depends greatly on the car that you want to push.  Some bumpers will take it, some will just smash.
Comment: Honda civic  hatchback 89 (being pushed)  buick century 2000 (pushing)
Comment: On an '89, I bet the bumper could handle it.  Test with very little pressure at first tho!
Comment: Well I'll see  when the time comes
Comment: In the US and some other parts of the world, bumpers are/were mandated to be strong enough to be undamaged in a 5mph impact https://en.wikipedia.org/wiki/Bumper_(automobile)
Comment: That's true, but what happened in that single 5mph test with a brand-new car is different than a plastic or possibly fiberglass bumper that's been sitting in the sun and other elements for years.  An extreme example is the ['70's Cadillac](http://images.thetruthaboutcars.com/2010/02/CC-36-086-800.jpg) where the flexible "5mph bumper" section just rots and falls off.
Answer: Assuming you don't do anything really stupid the worst case scenario is the bumper of the dead vehicle riding up over the bumper of the push vehicle.  I have have broken more than one grill doing this.  But the grill is not the big issue, you also have the radiator and other fragile parts just behind the grill.
If you are hanging around the same crowd I did back in the day, there is more than one potential push vehicle available, the best choice is one where the center of the bumpers match of perfectly. Second best is the push vehicle being a bit higher.  A bit lower is bad (per above).  You can sometimes lower the back of the dead vehicle by putting junk in the trunk.  Concrete blocks, engine block, transmission, etc. Optimally if the one bumper slides on top of another you want the good vehicle to get the high position.
Cornering and bumps (onto driveway from road) are the two biggest problem areas. I you are pushing around a corner or over a bump that is when you tend to break, head lights, tail lights and get the bumpers on top of each other. The push vehicle should provide enough energy prior to the obstacle to get around the corner, or over the bump then fall back.  Once past the obstacle the push vehicle re-contacts the dead vehicle.
In all cases when touching bumpers you want relative speed to be close to 1 mph.  If the dead car is stopped, move forward slowly until they touch. If the dead car is still rolling, ease into as slowly as possible.  When they touch give the push vehicle a bit more power, you want to keep the pressure on, if you don't push a bit harder on contact you will bounce back then ram the dead car when you accelerate.  I use both feet for this, one brake, one gas. It takes a little practice, but it is easier to learn than keeping a tow rope tight when flat towing.
Some people like to use a tire (without a rim) as between the bumpers of the two cars. You can tie it to either vehicle, it doesn't really mater.  In my experience this just tends to put black scuff marks all over. Back in the day of chrome bumpers it had value, but since around the 1980's bumper have had built in shock absorber and plastic/rubber covers. So not a lot of added value.
If you do have to push where the push vehicle has the lower bumper the tire can be a good choice to protect the grill and other fragile parts.
Comment: I'll try to see about a towing strap but if not I'll totally just do this with my dad pushing
Comment: Good  news we got the car home  we ended up using a chain


What is the difference building an integration on Connected App and App Exchange?

Question: I am trying to build an integration solution for my clients to pull their Contacts and Leads into our system. When I tried to look up the Salesforce API, all the documentation seem to require our clients to set up a connected app, and give us the oauth token to pull data. However, my clients also told me that all their existing integrations (e.g. marketo) are done through installing from the SF App Exchange, and they needed to provide a user token, username and password to marketo. This seems quite different from the connected app approach. I am confused about which option I should pick. Could someone clarify this for me?
Answer: The AppExchange is a directory listing of apps that can be installed or used with Salesforce. You can choose to be listed or not. Listing yourself on the AppExchange enhances your product's visibility, and can provide a greater level of assurance with subscribers by going through a verification process called a Security Review.
There are a few ways to authenticate with an external application in Salesforce, one of the most common ways being a Connected App. A Connected App typically uses OAuth or the Canvas API to establish a secure connection between Salesforce and the external system. Even better, using a Connected App means you do not have to worry about authentication, such as storing your subscribers' passwords anywhere.
To be clear, your subscribers do not create a Connected App; you do. By doing this, subscribers that are trying to log in your system can identify which system they're logging in to by way of a custom logo and a set of permissions being granted. Here's an image of logging in to DocuSign (explained further in this question):

As you can see, the user gets visual confirmation that they're logging in to DocuSign, and granting access to DocuSign to use their Salesforce data by clicking the "Allow" button.
The Connected App includes some specific data that identifies your app from other apps your subscribers may also have installed or be connected to, and allows administrators to grant access for certain users to the app, etc.
By using a Connected App, you do not need to manage subscribers' user names and passwords, simplifying your security requirements. Also, if your app becomes compromised, the Connected App provides a way to disconnect all rogue agents at once (by changing the Connected Apps attributes).
Comment: Thanks for the explanation. So for simple use cases like exporting my clients' Salesforce records into our (3rd party) system, connected app would work? I just need to set up a connected app on my org's salesforce account, they don't have to do it?
Comment: @Pig Correct. Your subscribers would connect to it, and then your app can use that connection. It'll probably make sense once you start using it and read more. Also see https://trailhead.salesforce.com/en/projects/workshop-electric-imp/steps/connected-app-setup.
Answer: Appexchange - natively built app on salesforce platform which can be installed in your salesforce org with just one click. It doesn't require any kind of authentication.
Integration - this means you are trying to interact with another system(or vice versa) which is not on salesforce platform. Therefore, you need to have an identifier to authenticate this external org to perform any sort of operation. Connected app would last this external application and provides you client secret and consumer key which helps salesforce determine a valid user connection over api's call.
How this helps.


How to find an initial equilibrium benchmark portfolio that includes currencies for Black-Litterman model

Question: We're working on a term project to adjust B-L model to yield robust results. From our readings, we resulted in that initial benchmark portfolio is constructed by using market capitalization weight. However, we want to include different currencies to our portfolio (U.S. dollar, Euro etc.) and we are clueless about how to determine market caps of currencies. Using total money supply for currencies didn't seem intuitive to us since, in that case, it would outweigh currencies unreasonably. Is there a correct way to determine this?
Comment: Currencies are not really an asset like stocks, bonds, real estate, t-bills. They don't earn a return over the long run (some go up, some go down) so they probably should not be included in an equilibrium market portfolio. (An exception may be if you want to hedge foreign equities, bonds, etc. In this case you would *go* *short* the relevant currency to insulate yourself from currency fluctuations that would affect your foreign stocks, bonds, etc.).
Answer: We first need to define the risk-free asset. One may assume that for a US investor, the riskfree asset is the USD, whereas, for a Japanese investor, it is JPY.
This is important because the perceived volatility of USD to a Japanese will cause him to require a higher return on a USD asset than on a JPY asset, thereby causing some home bias.
While the market weights for a US investor are a linear combination of USD cash and an efficient market portfolio including some JPY cash seen as a foreign asset. The converse is true for a JPY cash investor.
Cash is always subject to inflation, arguably, an eternal investor such as an endowment might use the world stock market cap as its riskfree asset, in which case any currency holding is seen as a risky asset.
The point is that the weights depend on the risk-free reference, so that market weights reflecting expected returns and covariance should not be based on narrow monetary mass such as M0.
On the topic of equilibrium weights and fx cash holdings, BL (Black Litterman) refer in their article to an ICAPM (international capital asset pricing model) and Universal Hedging methodology to derive the weights they use.
Ironically the BL (Black Litterman) model advocated against home bias at the worst point of history for US investors: it was published and marketed in the late 80s/early 90s just as the Japanese market had overtaken the US market. It would help embolden US investors and justify that they jump ship from the home-biased investment to buy Japanese stocks.
The investors who followed this strategy must have fared very badly: they would enter the Japanese market at the height of its overvaluation, at the beginning of a 30-year bear market and missed 2 decades of bull market in the US.
Answer: I think you have to use money supply in some regard, but I also agree with you that it is not a good proxy for total market value of that money.
Why not multiply money supply by exchange rate. You could also consider using purchasing power parity as a proxy for the value of money. The result of this operation is highly analogous to market capitalization (i.e., shares $\times$ price $\to$ M0 $\times$ FxRate).
For example, a country which has printed a lot of worthless money won't exert nearly as much effect on the initial equilibrium model. Likewise, a country with small, but valuable monetary reserves won't fall off the allocation scale.


Can I solo mine ethereum instead of pool?

Question: I am running a single rx 480 at 22mh/s, this rig is not geared towards mining and I'm doing it for fun. Would I be able to solo mine ethereum blocks for a higher payout? Or should I stick to pool mining from the difficulty being too high?
Comment: https://etherscan.io/ether-mining-calculator
Answer: There are several variables which you need to know before working out if this is a viable approach. You know your hash rate is 22mh/s, and an 8GB rx 480 has a maximum draw of around 170 watts.
You will want to find out what your cost of KW/h is, and put these values into a calculator such as this one.
On the basis that your KW/h is $0.15, you would be making around $14.60 per month, if the average time to mine a block is 15 seconds, and Eth stays at $645.


method for versioning configuration of civicrm?

Question: Is there a way to version the configuration so we can just roll it back if its a bit broken? Or is the only option full filesystem and db backups?
Answer: There is the CiviConfigure extension but I'm not sure how current it is.
There is also still bin/csv/export.php which you can use for option values and tags and such.
You can also use the api to retrieve and set various entities, e.g. using the cv tool.
For CiviCase, one of the original arguments for using external files was for versioning and managing dev/production. You can still use xml files for its config.
Answer: There doesnt seem to be, so I have gone with just regular full backups, and keeping a list of all the changes that I made as I go along, so I can keep track and undo them ;)
Comment: Did you also see https://civicrm.stackexchange.com/questions/30438/reproduce-civicrm-configuration-best-practice which was added after your question and then included my answers above but also added some more.
Comment: thanks @Demerit thats very helpful!


What are character special and block special files in a unix system?

Question: How are character special files and block special files different from regular files in a Unix-like system? Why are they called "character special" and "block special" respectively?
Comment: Possible duplicate of *[How do character device or character special files work?](https://unix.stackexchange.com/questions/37829/how-do-character-device-or-character-special-files-work)*
Answer: When a program reads or writes data from a file, the requests go to a kernel driver. If the file is a regular file, the data is handled by a filesystem driver and it is typically stored in zones on a disk or other storage media, and the data that is read from a file is what was previously written in that place. There are other file types for which different things happen.
When data is read or written to a device file, the request is handled by the driver for that device. Each device file has an associated number which identifies the driver to use. What the device does with the data is its own business.
Block devices (also called block special files) usually behave a lot like ordinary files: they are an array of bytes, and the value that is read at a given location is the value that was last written there. Data from block device can be cached in memory and read back from cache; writes can be buffered. Block devices are normally seekable (i.e. there is a notion of position inside the file which the application can change). The name "block device" comes from the fact that the corresponding hardware typically reads and writes a whole block at a time (e.g. a sector on a hard disk).
Character devices (also called character special files) behave like pipes, serial ports, etc. Writing or reading to them is an immediate action. What the driver does with the data is its own business. Writing a byte to a character device might cause it to be displayed on screen, output on a serial port, converted into a sound, ... Reading a byte from a device might cause the serial port to wait for input, might return a random byte (/dev/urandom), ... The name "character device" comes from the fact that each character is handled individually.
See Wikipedia and Understanding /dev and its subdirs and files for more information.
Comment: @Giles what is the role of the kernel driver for regular files ? I mean how does the kernel driver talk to the filesystem driver ?
Comment: @Geek Which kernel driver? I don't understand the question.
Comment: @Giles The kernel driver that you talked about in the first line of your answer.
Comment: @Geek In the case of a regular file, the filesystem driver is the kernel driver in question.
Comment: @Giles and no kernel driver is involved for devices ?
Comment: @Geek The driver associated with the device (see my second paragraph).
Comment: And, if you read from or write to a character device for a disk (not only do they exist on many UN\*Xes, they're *all* that exists on FreeBSD!), each character is "handled individually" by the DMA hardware transferring it from disk to memory on a read and from memory to disk on a write.  (I.e., for disks, the driver generally does nothing with the data other than wiring the pages containing the data temporarily into memory and starting an I/O operation to transfer data to or from the region of memory corresponding to the data.)
Answer: They point to a driver and can be created by mknod. Looking at its man page, it seems that block devices are buffered while character devices are unbuffered. Block devices have a "block size" that indicate the size of the blocks that are accessible. (for storage devices, the block size is typically between 512 B and 4 KiB) Storage devices and memory are typically accessed as block devices, while devices such as serial ports and terminals are typically accessed as character devices.
They are typically found in /dev (and can not function on partitions mounted with a nodev option (or its equivalent))
In ls -l show two comma-separated numbers for devices in the place where the size is normally found. Those are the major and minor numbers, that point to the driver. Their type are also indicated as "c" or "b" in the permission column of the ls -l output.
/dev can be populated in several ways. On recent Linux kernel versions udev is typically used, on Solaris it contains links to /devices, which is a virual devfs filesystem.
Comment: You might want to add that block devices, as the name suggests, are interfaces for devices that have a minimum block size they can read/write bigger than 1 byte - typical example is a hard drive with 512B/4KB sectors. As for the creation, in the olden days the special files in `/dev` were created by the init scripts (and the system wouldn't boot without some important ones - like `/dev/null` - being present).
Comment: I assume they might still be manually created for some embedded systems or highly limited chroot environments... What I haven't figured out, is to determine what the major number should be if you manually create it.. (The major number seem to refer to the driver (at least on SCO which is what I found documentation for) and the minor number is a parameter for it...) Not sure if the major number is hardcoded in the driver... (And I assume it might differ between different variants..)
Comment: About block devices: Would they always have a block size? Just noticed that on Solaris, the disk can be accessed either as a block device (linked in /dev/dsk) or as a character device (the ",raw" (/dev/rdsk) variant) Interestingly, they have the same major and minor numbers. (On the Linux system that I checked,  only the disks and ram devices are block devices)
Comment: see e.g. [Linux device drivers](http://www.makelinux.net/ldd3/chp-3-sect-2) for discussion on how to find/allocate the numbers in Linux kernel. As for the block size: I suppose there has to be a sector size in the software layer, otherwise it would just be a character device. Whether you can access disk as char device is just a convenient shortcut running on top of block device I would say (because that's how the hardware works in the end).
Comment: So short version: Minor / Major number assignments are OS dependent and on Linux, driver dependent as well. (Some hard-coded, some dynamic)
Answer: File Types in Unix/Linux: Ordinary or Regular Files, Directories, Device (Special) Files, Links, Named Pipes, and Sockets.
A device (special) file is an interface for a device driver that appears in a file system as if it were an ordinary file. They are Character devices, Block devices and Pseudo-devices (like /dev/null).
Character-driven will send one character at the time, thus you need a small load to carry, but have to make many requests. Block-driven means you get a large collection of characters (data) so you have a** bigger load but have to do less requests. Analogy: Basically the same as buying soda by the bottle, or by the crate.
Block-driven is useful when you know how much data you can expect, which is often the case with files on disk.
Character-driven is more practical when you don't know when your data will stop thus you keep it running until no more characters get through. For example, an Internet connection, as you don't know the size of the data stream that you will receive from the server.
For example:

Character device drivers are special files allowing the OS to communicate with input/output devices. Examples: Keyboard, Mouse, Monitor,  audio or graphics cards and Braille.
Block devices are for communicating with storage devices and capable of buffering output and storing data for later retrieval. Examples: Hard drive, memory.

Courtesy


how to recognise handwriting and convert into text?

Question: I'm trying to develop a project that recognises handwriting and converts into text. What are the algorithms and tools to be used?
Comment: I suggest you take a look at the work of Alex Graves - https://www.cs.toronto.edu/~graves/handwriting.html
Comment: This feels a bit much like a "do my homework for me"question to me.  Could you make this question a little more specific?
Comment: I need to know about handwriting recognition through image processing i.e recognising patterns of handwriting in the image. I need some suggestions. Whether it is feasible or not?
Answer: What you described sounds to me like Optical Character Recognition(OCR).
If you want to implement your own, I would say read through how an open source OCR like Tesseract was implemented.
Otherwise just google for OCR and you will find a list of OCR engines, both comercial and open-source. To list but a few:

Tesseract: https://github.com/tesseract-ocr/tesseract
Matlab Computer Vision Toolbox's OCR: http://www.mathworks.de/de/help/vision/ref/ocr.html

Most OCRs makes use of a combination of a segmantation and image classification(usually done with Convolutional Neural Networks).
See here for more information.
Comment: Thanks for the info :) . But I want to recognise using image processing. How can I do that?


What is the biblical basis for it being acceptable to bring doubts to God?

Question: What is the biblical basis for the idea that it's okay to bring any doubts to God in prayer?
Comment: Meta: [Are all doubt related questions duplicates?](http://meta.christianity.stackexchange.com/q/322)
Answer: Yes, this is acceptable. It is not only in prayers and not only in the Old Testament but in the New Testament too.
It is important to see that Jesus himself endorses a critical stance.
Thomas the Apostle speaks (John, 20, 25):

"I won't believe it unless I see the nail wounds in his hands, put my fingers into them, and place my hand into the wound in his side.

Jesus endorses this attitude and bothers to get back to Thomas to give him proof (John, 20, 27):

Then he said to Thomas, "Put your finger here, and look at my hands. Put your hand into the wound in my side. Don't be faithless any longer. Believe!

And finally (John, 20, 29):

Then Jesus told him, "You believe because you have seen me.

So the Bible makes it very clear that Jesus wants us to not just be gullible but to demand proof. Neither of the Apostles was prepared to believe without a proof and Jesus respected that and had this very story been incorporated into the Bible for us.
Comment: In general I agree that Jesus satisfies our doubts, but your argument is somewhat un-creditable particularly in light of your incomplete quotation of John 20:29. The second half of the verse which you left out in your answer goes on "_Blessed are those who have not seen and yet have believed._"
Comment: If you are going to try to take Jesus at his word quoting a full sentence shouldn't hurt your focus. From your last comment I could quote "Jesus is not" and build a case that you don't believe Jesus exists, but it's hard for anybody to check if I rip out a half a statement like that. If what you are saying is legitimate, more context will not hurt your case.
Comment: @Caleb: Thank you for your remark. You have to be very careful here: Jesus is saying this **after** he gave proof and he is saying this only **unto him**, i.e. Thomas, who believes already because he has the evidence right before his eyes; Jesus is **not saying this unto us** or to anybody else or in general!!! So this part is one of the clearest and most unambiguous parts in the Bible. Christians have to take Jesus' word literally here and not try to interpret it as it seems convenient. I even think it is one of the most pivotal parts of the Bible!
Comment: Caleb, this is true, sorry for not giving more context. I think that it doesn't matter what I think, but you must agree that it is kind of strange when even the Apostles, his long-standing followers and best friends, don't believe in Jesus being some kind of supernatural being, right? And Jesus bothers eagerly to show them all kind of proofs - why only to them and not to us?  "Blessed are those who have not seen and yet have believed." - a very convenient position indeed, isn't it! I think this part of the Bible cries for us being skeptical and not gullible, would you not agree?
Answer: God's grace is such that you can just be honest. Consider Mark 9:24, one of my favourite NT verses:

'Immediately the boy's father exclaimed, "I do believe; help me overcome my unbelief!"'

Doubt mixed with faith is natural. Jesus' response is not recorded – so apparently He was neither surprised nor condemning.
Answer: Most of the Psalms are examples of this!
The Psalms express deep doubts about God – "where are you?", "Why are you letting your faithful people be oppressed?", "Why am I in such pain?", etc. You can find the full range of human emotion in the Psalms, expressed directly and honestly to God. If David can do it, we can do it.
Comment: "If David can do it, we can do it." Almost brings up an entire new question, if it weren't subjective!
Answer: The very act of bringing a sincere doubt to God in prayer could be seen as an act of faith.
Think of the opposite, having a doubt, and not bringing it the Lord in prayer because you "doubt" that he cares, "doubt" that he can hear you, or "doubt" him in General.
Do you see the element of faith overcoming when you bring your doubts to God in prayer?
The other Answers have some good scriptures. I especially like mark 9:24, posted by [Wikis]

'Immediately the boy's father exclaimed, "I do believe; help me overcome my unbelief!"'

To finally answer your question

What is the biblical basis for the idea that it's okay to bring any doubts to God in prayer?

Here is some biblical basis,
1 Peter 5:7

7 casting all your care upon Him, for He cares for you.

I think doubts which are troubling you can certainly be considered "Cares". Peter admonishes us to give them to the Lord. How can we do this?
Paul says in Philippians 4:6

6 Be anxious for nothing, but in everything by prayer and supplication, with thanksgiving, let your requests be made known to God;

Putting these all together, i think we begin to see a biblical basis for bringing our doubts to the Lord in faith.
--- Edit--- On a personal note, i would recommend taking your doubts right to the scripture, as well. you might be surprised how many of our "doubts" are dealt with directly in the Word, a great coupling with prayer. Talk to God (Prayer), and hear from God (reading the word)


What's the difference between shooting in daylight and at sunset?

Question: What's the difference of light between taking photos near sunset or during midday sunshine if there is any? Why would you go for a photo at sunset instead of a daylight photo when the sun is higher in the sky and vice versa?
Comment: you might not want to be vague, but you are being vague. What do you mean? Can you give more context? What problem are you trying to solve? Are you wondering why light at sunset appears to have a different colour to light during the day?
Comment: @Cris you need to clarify what you mean by "at sunshine". I have never heard someone refer to sunrise as sunshine. Any time the sun is shining is sunshine. Every photograph is going to be affected by the amount and quality of light ( sunshine or otherwise ) at the moment you take the photo. The quality of the light from the sun changes drastically through out the day.
Comment: See also
[What's different about photographing at sunrise vs. sunset?](https://photo.stackexchange.com/questions/11396/whats-different-about-photographing-at-sunrise-vs-sunset)
Comment: Also see [What is "golden hour"?](https://photo.stackexchange.com/questions/16028/what-is-golden-hour)
Comment: @MichaelClark I could have done "unclear what you are asking" instead but either way the current phrasing represents a problem as it draws in two very different sets of answers.  If we start answering before it is clarified some of those answers will end up no longer being valid from the edit, which would be bad.  That's the reasoning behind a speedy close, I just used the dupe to avoid having to reopen and change if that is the question.
Comment: @Cris could you please clarify what you meant by sunshine?  Either sunrise, or during the middle of the day?  It will make a big difference in the answers.
Comment: I mean, if you take a picture in a certain place on sunset and another one on sunshine, how it is going to be different? Are photo taken on sunset more dark? Which colours should I expect on sunset/sunshine? I was searching for a definition.
Comment: I was asking about the difference between when the sun is shining and when it is up in the sky. (Sorry for my English).
Answer: Several things change to make photography easier and often more pleasing around sunset:

The light is not as intense, except with the sun in the frame of course.
There is less contrast in the scene because the sky is darker.
Shadows are less harsh, again due to darker light.
Shadows are longer due to the low sun.
Color temperature is warmer before sunset and it starts cooling back after.

The lower contrast and change in color temperature give photos taken around sunset a very distinct look which is one of most used by photographers. If you look at good publications and contests, it is easy to see that a significant portion of top and winning images are taken around sunset:

Photographers call the period before sunset the Golden Hour.
While the period after it is called the Blue Hour.

Sunrise has very similar properties with a Golden Hour after it and a Blue Hour before it.
All cameras have a limited Dynamic Range which is basically how much contrast they can capture in a single image without any overexposure or underexposure. When the sun is close to the horizon, but outside of the frame, the dynamic range of the scene is lower, so it is more likely that a camera is able to capture details everywhere.
With the sun high in the sky, it stays out of photos more easily, but the shadows it casts are extremely dark compared to lit areas, so scenes can easily exceed the maximum dynamic-range of a camera.
The reason one takes photos in a specific type of light is because a photographer wants a certain look to the image. With harsh shadows, you have to compose more carefully and possibly use fill (flashes, reflectors, etc) to get something satisfying, making sure shadows do not cause underexposure in the parts of the scene you consider important, and that direct light does not overexpose them either. This is an art though, so it is about getting the image that you are looking for, not just taking the photo at that time simply because you are there, otherwise it is more of a snapshot than photography. Many places look amazing around sunset but there also also scenes which look better in sunshine. For example, with narrow streets and very colorful places, I personally find they have more impact when captured in bright light, while I love cityscapes much more at the blue hour when lights are turned on and add yet another element and dimension to the scene.
Answer: Sunset light is nice and golden warm, and can make skin tones appear really pleasing.  The light is also less intense so people tend to squint less when being lit by it, so it's very easy for anyone with little understanding of light to get someone looking towards the sun, and with any equipment take a photo that looks like that stereotypical awesome warm sunset shot.
Same for landscapes.  Sunset (and sunrise) just makes things come alive and a shot that will just look "bla" in midday will look warm and inviting.
Part of the reason behind this is how sunset and sunrise light isn't just a direct source.  Because it's coming through more atmosphere, it's defracted and bounced around so that when light reaches a subject it's like it's coming from a much bigger source.
In the theory of light,  the further away a light source is,  and the smaller it is, the harsher it will light something, so think of midday sun with no cloud. That's a pin prick of light 93 million miles away.. HARSH.
When shooting portraits in mid day sun, a photographer has to learn some tricks to soften that tiny light source.. and really to not use it as the primary direct light source at all.
It's actually better to shoot in the shade, and fill in with flash, or to use a huge diffuser held over someone to turn that tiny sun speck into a huge close by light source.  Lots of youtube videos on stuff like this.
When it comes to shooting buildings and landscapes, there is no way to control the light so you get what you get.
K


Linux: Creating hard links on a portable music player

Question: Whenever I try to create a link on my 16GB Walkman to another file on the Walkman, I get the error "Operation not permitted". This happens whether I'm trying to create a hard or soft link, and whether I'm sending the command as myself or as root (with sudo). Does anyone know why I can't do this and if there is any way around it?
Answer: Music players are usually formatted as FAT16 or FAT32, neither of which supports soft or hard links. There is no filesystem-level way around this.
Comment: Well, darn. Thanks for the prompt and clear response.
Answer: You're going to need both filesystem and OS support for softlinks, hardlinks or symlinks. Most portable media players use really simple filesystems underneath, fat32 for players that are accessible as a mass storage devices (or MTP), or various vendor specific filesystems for ptp, and basic OSes. If it was one of the newer android based players, then it would use an ext varient and this might work.
While, in theory you could reformat a mass storage class device to a file system that supports these features, the simple OS on most PMPs wouldn't support it. That said, this sounds like an XY problem - you might be able to get a better solution by focusing on why you want/need to link that file.