text
stringlengths 3
1.74M
| label
class label 2
classes | source
stringclasses 3
values |
---|---|---|
How to draw lemniscate with TikZ. <p>How to draw e.g. the given set (known as Brauer Cassini Ovals)</p>
<pre><code> { z : |z-a|·|z-b| <= c }
</code></pre>
<p>in the complex plane </p>
<p>The question is just about how to draw this (filled or unfilled) curve, not how to the coordinate system or something else.</p>
<p>Is there an easy way to do this with TikZ or do I have to use pstricks / gnuplot / or somethin similar?</p>
<p>I would prefer using TikZ only, because I already have a complex plot done in TikZ, to which I want to add some of those lemniscates.</p>
| 0non-cybersec
| Stackexchange |
User input file name in function - R. <p>I want to analyze 75 data files separately, but all in the same way. I wrote functions for every step of the analysis. The data sets look basically like this:</p>
<pre><code>df = data.frame(
Time = c(1, 2, 3, 4),
Concentration = c(2983, 9848, 2894, 8384))
</code></pre>
<p>I ask the user for the file name and I would like to enter the chosen file name in the functions. </p>
<pre><code>enterFileName <- function(){
filename <- readline(prompt="Enter file name: ")
return(filename)}
</code></pre>
<p>I have two questions about this:</p>
<ol>
<li><p>Is it possible to write the code so that the file name entered by the user will automatically be used in the function when I run it (using the variable "filename" that I created before)? So I will not have to repeat typing the file name every time. I tried this, but it doesn't work:</p>
<pre><code>averageFun <- function(){
summary(filename$Concentration)}
enterFileName()
averageFun()
Error in summary(filename$Concentration) : object 'filename' not found
</code></pre></li>
<li><p>Can I use the file name entered by the user for the main title in a ggplot graph? Something like this...</p>
<pre><code>plotFirst <- function(df){
ggplot(data = df, aes(x = Time, y = Number)) + geom_line() +
ggtitle("UFP concentrations raw data" + filename)
}
</code></pre></li>
</ol>
<p>This just returns a graph without main title.</p>
<p>Can somebody help me with this? Thanks in advance!</p>
| 0non-cybersec
| Stackexchange |
Kitty on the prowl. | 0non-cybersec
| Reddit |
ssh-copy-id to different remote hosts. <p>Hello i have a laptop with ubuntu and a mac i have <code>ssh-copy-id</code> to mac succesfully but when i tried from Mac to ubuntu i got a warning. I set a new key but then when tried from Mac <code>to ssh-copy-id</code> to <code>ubuntu</code> i got this warning </p>
<pre><code>The authenticity of host '192.168.x.xxx (192.168.x.xxx)' can't be established.
ECDSA key fingerprint is -----------------------------------------.
Are you sure you want to continue connecting (yes/no)?
</code></pre>
<p>So every time i am going to <code>ssh-copy-id</code> to any remote machine i am always going to get</p>
<pre><code>The authenticity of host '192.168.x.xxx (192.168.x.xxx)' can't be established.
ECDSA key fingerprint is -----------------------------------------.
Are you sure you want to continue connecting (yes/no)?
</code></pre>
<p>the first time ?? Or am i doing something wrong?</p>
<p>Thank you in advance ~!</p>
| 0non-cybersec
| Stackexchange |
Attending a wedding for the first time, a little girl whispered to her mother, "Why is the bride dressed in white?". "Because white is the color of happiness, and today is the happiest day of her life."
The child thought about this for a moment, then said, "So why is the groom wearing black?" | 0non-cybersec
| Reddit |
Why dual graph for mesh partitioning. <p>Software such as ParMetis or PTScotch partition a graph. When one wants to use it for mesh partitioning (for example for FEM), a dual graph whose vertices represent cells of the original mesh is usually constructed first. This dual graph is then partitioned. I was wondering why one cannot simply interpret the connectivity of the input mesh as a graph directly - mesh nodes are graph vertices and mesh edges are also graph edges. This would assume that the list of mesh edges is built by client application before the call to the partitioning routine.</p>
<p>If I understand correctly, the cut through a dual graph will contain whole faces of adjacent mesh cells belonging to different partitions, while cut through the mesh (seen as a graph) will be less pretty in the sense that only some nodes of an element face might become ghost nodes. In addition, the number of mesh edges (especially in 3D) will probably be much higher than the number of cells. Apart from that, I don't see what are the advantages of using the first or the second approach. Can anyone comment on this?</p>
<p>I am aware of the fact that (Par)Metis has a function to construct a dual graph. My question is 'why', not 'how'. I'm mainly interested in mesh partitioning for FEM. </p>
| 0non-cybersec
| Stackexchange |
What is the purpose of double `w` in `ps -ww`?. <p>From <a href="https://askubuntu.com/a/831521/1471">https://askubuntu.com/a/831521/1471</a></p>
<pre><code>ps -Flww -p THE_PID
</code></pre>
<p>I was wondering what the purpose for double <code>w</code> is? Is it the same as just one <code>w</code>?</p>
<p>Thanks.</p>
| 0non-cybersec
| Stackexchange |
Video game logic. | 0non-cybersec
| Reddit |
Internet Explorer 10 auto-correct randomly capitalises words. <p>I use Internet Explorer 10 on my Windows 7 laptop (because the fingerprint browser add-on only works in IE).</p>
<p>I have noticed that IE 10 has a built-in spellchecker, which is great. Now, I write about 90 % English and 10 % Swedish on web sites, so it is somewhat unfortunate that it isn't possible to change the spell-checker language 'on-the-fly'. But that's a minor issue.</p>
<p>The main problem is that, when I write English comments, the spell-checker (apparently randomly) capitalises some Words. For instance, the 'words' of the previous sentence was changed automatically to 'Words'. Another Word that is Always capitalised is Before. (Yes, the Three Words that are incorrectly capitalised in the previous sentence are due to the auto-correct 'feature', and apparently 'three' is also a problematic word.)</p>
<p>Is this really something that happens to every (bilingual) user? Is there any way to fix the issue (preferably without disabling the spell-checker altogether)?</p>
| 0non-cybersec
| Stackexchange |
Howto hide a Listings or Verbatim environment using a \newif enable command. <p>Due to make life easier I want to create a Exercise sheet for a lecture including the corresponding solutions. Therefore I defined a <code>\newif</code> to control whether the solution should be included or not. That worked fine until I need a <code>lstlisting</code> or a <code>verbatim</code> environment in it. The following code is the minimal example for the error, it works with <code>verbatim</code> too. </p>
<pre><code>\documentclass[a4paper,10pt]{article}
\usepackage[utf8]{inputenc}
\usepackage{listings}
\newif\ifsolution
\solutionfalse
\ifsolution
\newcommand{\solution}[1]{#1}
\else
\newcommand{\solution}[1]{}
\fi
\begin{document}
This is always shown.
\solution{The listing is only shown if ifsolution is true.
\begin{lstlisting}
Test
\end{lstlisting}
}
\end{document}
</code></pre>
<p>Setting <code>solution</code> to true produces the error. How can I defined a command or an environment with this function? </p>
| 0non-cybersec
| Stackexchange |
Import typescript files based on naming convention in React Native. <p>So I have three <code>ts</code> files named as below : </p>
<ul>
<li>MyModule.ios.ts</li>
<li>MyModule.android.ts</li>
<li>MyModule.ts ( this is empty )</li>
</ul>
<p>first two files have a method named : <code>setup()</code> which need to run based on platform Also metro bundler will do the resolution, it will try to import .ios when building for ios and .android when building for android..</p>
<p>and I have another file which import this method like this : </p>
<pre><code>import { setup } from 'MyModule';
</code></pre>
<p>the problem is, I am not sure if this will resolve the .android and .ios files. What is the proper way to do this kind of code splitting?</p>
<p>I find this workaround here but I was wondering if there is a better way : <a href="https://github.com/Microsoft/TypeScript/issues/8328#issuecomment-219583152" rel="nofollow noreferrer">https://github.com/Microsoft/TypeScript/issues/8328#issuecomment-219583152</a></p>
| 0non-cybersec
| Stackexchange |
Custom Variable in Fastlane Script. <p>Sorry for such a newbie question, but I'm very confused on how to write a Fastlane script outside of using the supplied methods.</p>
<p>What I'm looking to do is create a variable called <code>message</code>, that can be passed to the <code>after_all</code> function, so when I post to Slack, each lane can have it's own custom message:</p>
<pre><code>put message # is this how to set a variable?
lane :alpha do
# This is what I'd like to do
message = "[Google Play] Alpha Channel Deployed"
end
after_all |lane, options| do
slack(message: message)
end
</code></pre>
<p>Can anyone point me in the right direction? I'm so utterly lost on how to create and pass variables that don't come from the command line in a Fastfile script</p>
| 0non-cybersec
| Stackexchange |
Writing text on a curve in tikz. <p>I was trying to change the typeface of some text that I wrote in a tikzpicture. I have tried a few things, but none of them seem to work. What I current have is</p>
<pre><code>\begin{tikzpicture}[scale=0.4]
\path [decorate,
decoration={text along path, text={Sample Text}, text align={center}}]
(-30,8) .. controls (-15,22) and (15,22) .. (30,8) ;
\end{tikzpicture}
</code></pre>
<p>but I would like to change the typeface to <code>qag</code> from the <code>tgadventor</code> font package. Does anyone know how I might be able to do this? I have also had difficulties changing the font colour.</p>
| 0non-cybersec
| Stackexchange |
perl: how to remove particular word or pattern in between two patterns. <p>I want to remove some words within two patterns using perl</p>
<p>The following is my text</p>
<pre><code>..........
QWWK jhjh kljdfh jklh jskdhf jkh PQXY
lhj ah jh sdlkjh PQXY jha slkdjh
PQXY jh alkjh ljk
kjhaksj dkjhsd KWWQ
hahs dkj h PQXY
.........
</code></pre>
<p>Now i want to remove all <code>PQXY</code> words which only lies between the two patterns
<code>^QWWK</code> and <code>KWWQ$</code></p>
<p>I know how to replace the whole thing inbetween the two patterns by the following command</p>
<pre><code>perl -0777pe 's/^QWWK(?:(?!QWWK|KWWQ).)*KWWQ$/sometext/gms' filename
</code></pre>
<p>Also note that <code>^QWWK(?:(?!QWWK|KWWQ).)*KWWQ$</code> this pattern only matches those where there is no QWWK and KWWQ inbetween. </p>
| 0non-cybersec
| Stackexchange |
When I'm enjoying some great OC but it turns out to be a repost.. | 0non-cybersec
| Reddit |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange |
Isaiah Rashad - S.B.B.B. (Goblin) (ft. TUT). | 0non-cybersec
| Reddit |
Dynamically discover new IP address of device upon new network. <p>I carry my phone and laptop with me everywhere, and I have many software solutions that communicate through Wi-Fi. (For example, I can play/stop/pause the music on my laptop using my cell phone). </p>
<p>I'd like a way for my laptop to automatically discover the new IP address of my phone upon joining a new network, like a coffee shop for instance. I could just assign a static IP to my phone, but I'd prefer to keep DHCP.</p>
<p>I'm thinking maybe a script that executes an arp-scan? My phone's MAC address is static, obviously. Then sets an environment variable?<br>
I could run this script after I have seen that my phone is connected.<br>
Just where my head is going. Thanks for your advice.</p>
| 0non-cybersec
| Stackexchange |
Calculate colour temperature in K. <p>I have written a lib for working with colours and stuck trying to calculate <code>Tc(k)</code>. From what I have read working in the <a href="http://en.wikipedia.org/wiki/CIE_1931_color_space" rel="noreferrer">CIE 1931</a> <code>XYZ</code> colour space is the way to go and it can be obtained using <code>xyY</code>.</p>
<p>So far I have got everything correct to the point of figuring out the correct <code>x</code> and <code>y</code> from :</p>
<pre><code> X Y
x = ____________ y = ____________
( X + Y + Z) ( X + Y + Z)
</code></pre>
<p>The numbers much up to the chart, but cant find anything that details how you go from <code>x</code> and <code>y</code> to <code>Tc(K)</code></p>
<p><img src="https://i.stack.imgur.com/KwAFc.png" alt="enter image description here"></p>
<p>eg: For #FF0000 I get the following.</p>
<pre><code>x: 0.64007449945677
y: 0.32997051063169
</code></pre>
<p>I have read a number of papers on the topic and litterally all the wikipedia articles. All the questions I have come across on SO simply link to a wiki article on colours, not seen one that has the actual formula for calculating <code>Tc(k)</code></p>
| 0non-cybersec
| Stackexchange |
A Question for Female Redditors: How Often do you Think about Sex? I know I know..It Depends on your current situation and on a million and one variables. . That notwithstanding...how often on a typical day?. | 0non-cybersec
| Reddit |
Daily cannabis use among US university students highest since 1980, new study finds. | 0non-cybersec
| Reddit |
A problem about fundamental solution of Laplace equation. <p>I would like to derive a solution to the following equation in <span class="math-container">$R^{3}$</span>:</p>
<p><span class="math-container">$$-\Delta u(x) + e^{u(x)} - e^{-u(x)} = \delta(x)$$</span>where <span class="math-container">$\Delta$</span> is the Laplace Operator and <span class="math-container">$\delta(x)$</span> is the Dirac's delta function. </p>
<p>I know how to solve <span class="math-container">$-\Delta u(x) = \delta(x)$</span> in the sense of weak convergence but I'm stuck on the exponential term of the equation above.</p>
| 0non-cybersec
| Stackexchange |
Explicit solution to linear stochastic differential equation (in several dimensions). <p>I have found many references where they provide with a "explicit" solution of the following SDE:
$$dX_t = (a_1(t) X_t + a_2(t) )dt + (b_1(t) X_t + b_2(t))dB_t, \quad X_0=x, \quad (1)$$
where $B$ is a standard Brownian motion.</p>
<p>It is namely given by
$$X_t = \Phi_t \left(x + \int_0^t (a_2(s) - b_1(s)b_2(s)) \Phi_s^{-1} ds+ \int_0^t b_2(s)\Phi_s^{-1} dB_s \right)$$
where
\begin{align}
\Phi_t = \exp \left\{\int_0^t \left(a_1(s)-\frac{1}{2}b_1(s)^2 \right)ds + \int_0^t b_1(s)dB_s\right\}. \quad (2)
\end{align}</p>
<p>Nevertheless, in several dimensions it might not be possible to find a close explicit solution of the homogeneous SDE and hence expression (2) does not make sense.</p>
<p>Can we solve Equation (1) when $a_1,a_2,b_1$ and $b_2$ are square matrices? In exactly the same way by just defining $\Phi_t$ the solution to $d\Phi_t = a_1(t)\Phi_1 dt + b_1(t) \Phi_t dB_t$, $\Phi_0=Id$? I found this link <a href="http://math.uni-heidelberg.de/studinfo/reiss/sode-lecture.pdf" rel="nofollow">http://math.uni-heidelberg.de/studinfo/reiss/sode-lecture.pdf</a> (page 26) for the case $b_1(t)=0$.</p>
<p>Does anyone know any references on this?
Thanks!</p>
| 0non-cybersec
| Stackexchange |
connecting to a FTP by TLS fails from one client, but succeeds from the other. <p>Trying to connect from client2 using the following string works:</p>
<pre><code>client2@client2 curl -v --ssl -u 'user:password' ftp://www.example.com:21
* Rebuilt URL to: ftp://www.example.com:21/
* Trying 192.168.177.186...
* Connected to www.example.com (192.168.177.186) port 21 (#0)
< 220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
< 220-You are user number 1 of 50 allowed.
< 220-Local time is now 09:16. Server port: 21.
< 220-This is a private system - No anonymous login
< 220-IPv6 connections are also welcome on this server.
< 220 You will be disconnected after 15 minutes of inactivity.
> AUTH SSL
< 500 This security scheme is not implemented
> AUTH TLS
< 234 AUTH TLS OK.
* found 148 certificates in /etc/ssl/certs/ca-certificates.crt
* found 592 certificates in /etc/ssl/certs
* ALPN, offering http/1.1
* SSL connection using TLS1.2 / ECDHE_RSA_AES_256_GCM_SHA384
* server certificate verification OK
.
.
.
* Connect data stream passively
* ftp_perform ends with SECONDARY: 0
< 229 Extended Passive mode OK (|||35104|)
* Connecting to 192.168.177.186 (192.168.177.186) port 35104
* Connected to www.example.com (192.168.177.186) port 21 (#0)
> TYPE A
< 200 TYPE is now ASCII
* Remembering we are in dir ""
< 226-Options: -a -l
< 226 6 matches total
* Connection #0 to host www.example.com left intact
</code></pre>
<p><strong>Trying to connect from client1 doesn't:</strong></p>
<pre><code>client1@client1:~> curl -v --ssl -u 'user:pass' ftp://www.example.com:21
* About to connect() to www.example.com port 21 (#0)
* Trying 192.168.177.186...
* connected
* Connected to www.example.com (192.168.177.186) port 21 (#0)
< 220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
< 220-You are user number 1 of 50 allowed.
< 220-Local time is now 09:15. Server port: 21.
< 220-This is a private system - No anonymous login
< 220-IPv6 connections are also welcome on this server.
< 220 You will be disconnected after 15 minutes of inactivity.
> AUTH SSL
< 500 This security scheme is not implemented
> AUTH TLS
< 234 AUTH TLS OK.
* successfully set certificate verify locations:
* CAfile: none
CApath: /etc/ssl/certs/
* SSLv3, TLS handshake, Client hello (1):
* Unknown SSL protocol error in connection to www.example.com:21
* Closing connection #0
curl: (35) Unknown SSL protocol error in connection to www.example.com:21
</code></pre>
<p>What could be the cause?</p>
| 0non-cybersec
| Stackexchange |
I hate having this feeling and maybe this is due to the distance of dating between me and this girl. How do I get over the feeling of not being texted back of the text are just boring sometimes on both sides?. This girl that I have gone on two dates with really awesome person as well is maybe not the best texter and maybe I'm not. But I get anxious when they don't text back or are very bland text. I can't tell if it's just lack of interest or my mind just getting the best of me. Like she texted me out of the blue to see if my 4th was going well so like I think she is interested. In person for reference she seems to be very interested our last date got more physical contact like slight nudge against me when I make a sarcastic comment about her in a funny way. And we held hands and hugged. I just want to know how to get over it or help that anxiety. ( It only seems to happen in the beginning of a relationship) it could be that she is better in person as am I but how do I know if it not that. | 0non-cybersec
| Reddit |
Probability of drawing an element from a countably infinite sequence. <p>Consider a sequence containing $A$ and $B$ where, starting at $n=0$, there are $2^n A$'s followed by $2^{n+1} B \ $'s, so the sequence begins</p>
<p>$$A, B, B, A, A, B, B, B, B, A, A, A, A, B, B, B, B, B, B, B, B ...$$</p>
<p>If we continue this sequence indefinitely, what is the probability of drawing an A by randomly selecting and element of this sequence?</p>
<p>If we consider the sub-sequences, then whenever we hit a patch of A's, the probability of drawing an A from that sub-sequence approaches $1/2$, but then when we hit a string of B's, it will approach and reach $1/3$, before starting back toward $1/2$. To me, this shows that the sequence of probabilities of drawing an A from the sub-sequences does not converge in the ordinary calculus sense. However, does it converge in some weaker probability sense that gives this question a well-defined answer?</p>
| 0non-cybersec
| Stackexchange |
Is there a notion of a smallest category satisfying some requirements?. <p>Let <span class="math-container">$\text{Cat}$</span> be some category (e.g. category of algebras over <span class="math-container">$\mathbb{R}$</span>). In many typical constructions, if we want to find the smallest object <span class="math-container">$A \in \text{Obj}(\text{Cat})$</span> that satisfies some properties <span class="math-container">$R$</span>, we may explicitly construct
<span class="math-container">$$A = \bigcap_{B \in \mathcal{A}}B ,$$</span>
where <span class="math-container">$\mathcal{A} = \{B \in \text{Obj}(\text{Cat}) \: | \: B \text{ satisfies } R \}$</span>.</p>
<p>Is something analogous possible for categories themselves, i.e. is there a notion of "smallest" category <span class="math-container">$C$</span> that satisfies conditions <span class="math-container">$R$</span>?</p>
| 0non-cybersec
| Stackexchange |
My obsession with my brother's ex-wife.. The first time I met my brother's now ex-wife (when she was just his girlfriend) I had the hardest and longest lasting boner of my life. No woman had ever turned my on that much, and she, let's call her Michelle, did it just by existing. I shamed-spanked that night, partially feeling guilty, but mostly glad that someone like walked this earth. It made me hopeful.
They got married 2 years later. She still endlessly aroused me but I could control it much better. At one point I had a job offer where they lived (a couple hours north) but turned it down because I didn't trust myself around her. She never flirted or acted inappropriately but I spent every minute in her presence fighting the urge to stare. Or worse touch.
They got divorced last year. I tried to be there for my brother, took him camping. I should say here, I love my bro. We're two years apart, grew up best friends. I would do anything for him, but he's a flawed guy. Even from his side I could tell he had mistreated her, and she left him. The guilt got bigger as I found myself happy she was single. He quickly started dating the girl she had caught him sexting with.
I considered contacting her but knew it was wrong and didn't. I focused on my life, softball and work. I dated a girl for a bit, but ended it when I realized I was just passing time with her. I started regularly masturbating to Michelle's facebook pictures. I creeped on her page constantly, and would get ridiculously happy when she 'liked' my post. I battled myself with urges to contact her. I loved how she handled her divorce with grace and dignity. I loved how she never posing for pictures and seems to be laughing in every single one. I love her body, her hair, her voice, she smile, she hands, everything about her. She's wonderful and sexy and kind. She volunteers and collects salt & pepper shakers. She makes band posters and album art. She is the coolest person. I agree with her politics and she always seems to be reading what I'm reading.
And here's where I become even creepier.
She mentioned something about OKCupid once. I made a fake profile and found her. I started creeping her OKC page as much as her fb. It made me love her more. And one night, I messaged her. It was so great to say the things I always wanted to say to her. Of course, it was probably too much and she blocked me.
I made another profile and took it easier. She wrote back! We started talking! I lived to hear from her, to read her words for me. Within a week we were talking every night. We switched to email. I'm ashamed I used fake pictures, but I certainly couldn't use my own.
It lasted two months, the two best months of my life. We were sexual, we were loving, it was everything I ever wanted. But, I finally realized that I was being a jerk and told her I lied about what I looked like and told her good-bye. She's such an angel she tried to give 'me' another chance after that.
I'm trying to get a transfer to another country. I deleted my fb and every connection I had to her. I love her, but I mistreated her and could never actually be with her so I needed to stop it. I feel empty and alone now, but I had no other healthy choice. So, reddit confession, that's my wrong-doing. I'm an obsessed creeper.
**TL;DR** Made fake OKCupid profile to flirt with brother's ex, whom I'd always had strong feelings for. | 0non-cybersec
| Reddit |
Remark on equality of cohomology groups (Milne, Remark 1.14). <p>I'm having troubles with <a href="http://www.jmilne.org/math/CourseNotes/CFT.pdf" rel="nofollow noreferrer">Remark 1.14, page 69</a> of these notes. Explicitly, if $$ 0 \to M \to J^0 \to J^1 \to \cdots $$ is an exact sequence of $ G $-modules, such that $ H^s(G, J^r) = 0$ for all $ s > 0 $ and all $ r $, then $ H^r(G, M) = H^r(J^{\bullet G}) $. I'm not sure if I'm missing something obvious or if it's not that easy to show, since the author did not give any explanation. Thank you for your help. </p>
| 0non-cybersec
| Stackexchange |
metal cylindrical puck thingy my son found in the yard earlier. (aka what is missing off something of mine?!?!). | 0non-cybersec
| Reddit |
(Request)Advice on how to rent a moving truck to relocate across the country.. I'll get straight to the point. My SO and I are moving at the end of March from LA to CA, we just got our tax money in which was the final piece we needed to start making this move happen. We have a child, 2 cats and 1 dog, and we're trying to find the best option for renting a truck to go one way. We have a pretty modest amount to move so we wouldn't require anything more than something like a 15ft truck. The catch, is that I feel we need more cabin space than most moving trucks have to offer, but with our current budget which I would like to cap at around 1k-1.3k, I'm just not seeing very many options I'm comfortable with. We're going to spend about 3 days traveling 1.9k miles and I want to do it as safely and economically as possible. Any advice would be greatly appreciated. (also if there is a better subreddit for this type of post please point me in the right direction) | 0non-cybersec
| Reddit |
Accumulation points in $T_1$ space.. <p>Let $(X, \tau)$ be a $T_1$ space. If $S \subset X$, $S \neq \varnothing$ and $x \in S'$, then every open neighbourhood of $x$ contains infinitely many points of $S$.</p>
<p>Once I saw a pretty easy proof by contradiction, but I can't recall the details of it and I don't find it anywhere. The closest I got is this on <a href="https://proofwiki.org/wiki/Limit_Points_in_T1_Space" rel="nofollow">Proof Wiki</a>, but unless I'm missing something obvious, that's straightly wrong - the intersection of the neighbourhood with the set should be finite in their argument, not necessarily the neighbourhood itself.</p>
<p>Suppose by contradiction that there exists an open neighbourhood $U$ of $x$ such that $(U \setminus \{x\})\cap S$ is finite. This implies $U \cap S$ finite. Since $X$ is $T_1$, we get $U \cap S$ is closed. I'm stuck. Can someone give a hand completing this? Thanks.</p>
| 0non-cybersec
| Stackexchange |
A very happy girl. | 0non-cybersec
| Reddit |
Teen son and dangerous online behavior - I'm freaking out, how to handle?. My 17 year old son is a loner and socially awkward. He doesn't have any serious friends and struggles with anxiety and depression. He got involved with a niche Discord group earlier this year and seems to have found several online buddies to talk to on a daily basis (more like hourly!)
I can see his chats on our home computer although he uses his phone for chatting, since he occasionally uses the PC and it seemingly never logs out. I only monitor, and while the conversations turn a bit lewd at times it's been nothing shocking...I'm an open, sex positive person who realizes this is normal teen male speak, especially under the guise of anonymity. I don't feel bad about monitoring this. He is a minor, and my child, and I'm his parent, not his friend. I don't ask him about it or even bring it up, but I have to make sure he is being safe and also kept so.
But then, today, I found a private conversation where he talked about his sexual turn ons, sent "audio" material...and this person (a male) also offered to send him a sex toy to our home. My son, who has always been seemingly Internet savvy, wrote that he will give him our home address when he gets home because he can't remember it (he's at his dad's out of town at the moment.)
He will be home tomorrow. I have to say something. I'm dreading having to reveal that I saw the explicit things he wrote, although I don't judge him for it, but this is entering dangerous and possibly illegal territory. I'm contemplating blocking his Internet entirely...I'd take his phone but he's home alone sometimes while I'm at work and we don't have a landline. Anyone have any tips or experiences with this? I want to make this the least embarrassing I can but it MUST be dealt with. | 0non-cybersec
| Reddit |
Arab groups organize to delete profiles of atheist Arabs on Facebook - by spamming Facebook with bogus "reports". | 0non-cybersec
| Reddit |
Rearrangements of a conditionally convergent series. <p>In the case of conditional convergence of a series, why do rearrangements affect the value of the series?</p>
| 0non-cybersec
| Stackexchange |
How can I get a mass of lasagna?. <p>A lamina occupies the part of the disk $x^2+y^2\le25$ in the first quadrant.
and lamina's density at any point is proportional to its distance from the y-axis</p>
<p>I want to get a mass of the lamina but I don't know how to calculate it...
I think $\rho(x,y)=x$ but i don't know the bound of x and y.. </p>
| 0non-cybersec
| Stackexchange |
What MTU size should I use for VPN in the modem router settings. <p>In that TP-Link article its mentioned that <a href="http://www.tp-link.us/FAQ-190.html" rel="nofollow noreferrer">http://www.tp-link.us/FAQ-190.html</a> "Due to additional complications, VPNs require a different type of MTU test" I have adsl2+ model router. The MTU size for my network is 1432+28 = 1460.
I am using ADSL model and config mode is PPPOE</p>
<p>Now I connected to one of the VPN servers and then ran the command (ping www.google.com -f -l 1472) to check the MTU. The MTU size came out to be different while connected to the VPN 1472 + 28 = 1500 as opposed to 1432+28 = 1460 when I am not connected to the VPN.</p>
<p>So what MTU should I put in my modem router settings 1500 or 1460 or some other value, someone told me to use 1492.</p>
| 0non-cybersec
| Stackexchange |
Call by name vs call by macro expansion. <p>In non strict evaluation languages, what are the differences and advantages/disadvantages of using <em>call by name</em> vs <em>call by macro expansion</em>?</p>
<p>Could you provide an example that explains both evaluation strategies?</p>
<p>Thanks!</p>
| 0non-cybersec
| Stackexchange |
Press release: ASML Recently Discovered IT Systems Security Incident. | 0non-cybersec
| Reddit |
iOS 6 UITabBarController supported orientation with current UINavigation controller. <p>I have an iPhone app I am updating to iOS 6 that is having rotation issues. I have a <code>UITabBarController</code> with 16 <code>UINavigationCotrollers</code>. Most of the subviews can work in portrait or landscape but some of them are portrait only. With iOS 6 things are rotating when they shouldn't.</p>
<p>I tried subclassing the tabBarController to return the <code>supportedInterfaceOrienations</code> of the current navigationController's selected viewController:</p>
<pre><code>- (NSUInteger)supportedInterfaceOrientations{
UINavigationController *navController = (UINavigationController *)self.selectedViewController;
return [navController.visibleViewController supportedInterfaceOrientations];
}
</code></pre>
<p>This got me closer. The view controller won't rotate out of position when visible, but if I am in landscape and switch tabs the new tab will be in landscape even if it isn't supported.</p>
<p>Ideally the app will only be in the supported orienation of the current visible view controller. Any ideas?</p>
| 0non-cybersec
| Stackexchange |
Why don't nuclear power plants use direct air cycle turbines?. DACT were successfully spun up during the nuclear propulsion program but nuclear aircraft were not viable for obvious reasons.
However they seem to make a lot of sense, why heat steam and run a turbine when you can run the turbine directly off the heat of the core? Wouldn't this be more efficient?
| 0non-cybersec
| Reddit |
What is the difference between optimization on Banach space versus optimization on Hilbert space?. <p>In Chapter 4 of <a href="https://arxiv.org/pdf/1405.4980.pdf" rel="nofollow noreferrer">this book</a>, it says,</p>
<p><em>Suppose now that we are interested in the more general situation of optimization in some Banach
space <span class="math-container">$B$</span>. In other words the norm that we use to measure the various
quantity of interest does not derive from an inner product (think of
<span class="math-container">$B = l_1$</span> for example). In that case the gradient descent strategy does
not even make sense...</em></p>
<p>Can someone clarify what it means to "optimize" in some Banach space (as opposed to Hilbert space)? And what an example of it looks like?</p>
| 0non-cybersec
| Stackexchange |
Which iptables rule do you think is a 'must have'. <p>I have some basic iptable rules set up now for my vps. Just block everything except some default ports, 80,21,22,443. I do get brute forced a lot. I have heard that iptables is very powerful but I have not seen many use cases.</p>
<p>Can you give me an example of a(some) rule(s) you always use and give a small example why.</p>
<p>I can not find a general best practice post here on SF, if there is any I would like the link. If this is a duplicate I am sorry and it can be closed.</p>
| 0non-cybersec
| Stackexchange |
What I should do for these semi-feral cats?. Hello,
I am about to leave the country where I spent almost a year where I found true love with beautiful three cats, two of them highly connected with me, and the other one still afraid from me. I am in a deep struggle, I keep feed them almost a year and they were in a bad health situation, people of the university could feed them once in a week. I wake up everyday and feed them before myself three times, they love me and I love them so much, the university hated these cats and steal their food. cans/shelter and I fight for that and called the police to protect them.
Now I am. confused, these cats spent their time in the forest, hanging and I dont know if. I can take them to an apartment. Literally, I am afraid once I leave no one would bother to feed them, I am just crying, I know in my academic job, people make jokes that. I care about cats. But these two cats, in particular, helped me to cope with anxiety and depression, I am so grateful for both of them.
I would like to share their photo and video
The first one is a ginger cat I am attaching her picture and video and the other is a Calico cat (Both of them called Nuna -:)
​

​

​
​
 | 0non-cybersec
| Reddit |
What a good water boi. | 0non-cybersec
| Reddit |
two-axis pendulum (x post /r/gifs). | 0non-cybersec
| Reddit |
Quick poll - How many people here have found that their cholesterol numbers have worsened after going keto?. | 0non-cybersec
| Reddit |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange |
[Stein]: "Durant, agent/business manager Rich Kleiman and longtime friend/manager Charlie Bell met with Thunder officials for five hours, sources say". | 0non-cybersec
| Reddit |
In case you don’t know who Martin Palermo is, here are most of his weird goals, strange injuries and records.. Martin Palermo is retiring from football this next Saturday. He's one of Boca Juniors and Argentina’s most loved players ever. Here, he's cherished more than Messi. His career has been filled with weird goals, strange injuries, important goals and records. Here are most of them in videos:
- On April 24th, 1999 he made a goal through a penalty kicked with BOTH feet against Platense. At the moment he made the shot, he [slipped and the ball hit both his feet](http://www.youtube.com/watch?v=G5hWdRm2JjA) and went in. Later, FIFA considered the penalty valid.
- On July 4th, 1999 he made it into the Guinness Records [after missing THREE penalties in a match](http://www.youtube.com/watch?v=UNg1L5LNIkg) with Argentina’s national team against Colombia in the Copa America.
- On November 13th, 1999 on a game against Colon, he had a complete tear of the cruciate ligament of his right knee, [before he left the game, he managed to score his 100th goal](http://www.youtube.com/watch?v=qMuD_fOC1Vs) in the Argentine First Division. The injury took him out of the fields for six months. On his first game after the injury, [he played the last fifteen minutes and he scored against River Plate (the arch rival)](http://www.youtube.com/watch?v=gSSQJDrwsHs) on the Copa Libertadores’s quarterfinal match. One of the most important goals of his carrer.
- On the year 2000, [he scored his team’s both goals](http://www.youtube.com/watch?v=pgc-lelpbeM) in the Intercontinental Cup match against Real Madrid.
- Palermo then signed with Spain’s Villarreal and, after celebrating a goal, he stood on a small concrete wall, [which collapsed under the weight of the fans and broke both the tibia and fibula of his left leg.](http://www.youtube.com/watch?v=eABvx69RVX8)
- Back in Boca Juniors, in 2006, after the death of his son on birth, he asked his coach to play anyways. He scored two goals, crying in both celebrations and dedicating them to his son.
- On February of 2007 [he made a goal against Independiente, from 61 meters away.](http://www.youtube.com/watch?v=5hfBh5ciiSY)
- On march 18th, 2007, [Palermo made 4 goals in one match for the first time in his career.]( http://www.youtube.com/watch?v=KjEiOuIKt8k) That same week [he had made]( http://www.youtube.com/watch?v=c3bvb6C5Aws) 3 goals [against]( http://www.youtube.com/watch?v=aaqjOz86U4Q) Estudiantes, totalizing 7 goals in 7 days, a record in Argentine football.
- On January 2008, in a match against River Plate, [he made his team’s second goal while hanging from the crossbar](http://www.youtube.com/watch?v=orEQCyjYFRU), which is against FIFA’s rules but it was never noticed by the referee.
- On February 2008, he was selected as the best header in the world by FIFA.
- On the 4th of October 2009, he became the tenth footballer to score 200 goals in the Argentine First Division. [The goal with which he got to that number was a 40 meters HEADER, a record in Argentina and second in the world.](http://www.youtube.com/watch?v=LbyD9GUAi8k). Six days later, he played for the Argentine National Team in a qualifying match against Peru. [With the match tied at one, under heavy rain and wind, Palermo scored the winning goal in the last play of the match](http://www.youtube.com/watch?v=gEg618xdHZE), a huge help to his country’s qualification to the world cup. This was one of the goals I celebrated the most in my life.
- [In the last World Cup he broke another record, he scored against Greece](http://www.youtube.com/watch?v=BX5YSJq2Wro) and, with 36 years of age, he became the oldest player to make his debut and score for the Argentine National team in world cups.
- He has the records for most goals in one Argentine First Division tournament. (20 goals in 19 matches)
- He is Boca Juniors’s historic top scorer.
- He is the fifth top scorer in Argentina’s football history.
If, after watching this, at least one person half the world away starts to like Martin Palermo, I'll be happy I looked up all of these videos.
Sorry if the writing sucks! | 0non-cybersec
| Reddit |
Static game of incomplete information.. <blockquote>
<p>There is a buyer and a seller. The seller wants to sell a used scooter. The scooter
can either be of good or bad quality. The quality of the scooter is only observed by
the seller. To the seller, the scooter is worth $v_i$ and to the buyer it is worth $\frac65v_i$ with $i$ either good or bad and $v_g>v_b$. Note, neither the seller nor the buyer has an outside option. Assume that the seller has all the bargaining power.</p>
</blockquote>
<p>Now, I am trying to study this bayesian game. My problem is how to define the set of actions of the seller. Does it exist an obvious way to specify the set of possible actions of the seller?</p>
<p>I have tried a formulation in which the seller can either sell at a price $p=\frac65v_i$ or sell at a price $p>\frac65v_i$. But if the buyer can only accept or not accept the deal, I can draw a strategic form of the game with just two Nash Equilibria. The fact that puzzles me is that in these NE the trade does not take place.</p>
| 0non-cybersec
| Stackexchange |
Quick rave: Confronted my abusive ex today and I feel SO GOOD. EDIT: Trigger warning
A year and a half ago, I was 16, and I met a guy who was 36. I was excited to try new things, but was very naive and ended up being manipulated and pushed around. He forced himself on me regularly, not doing anything serious besides kissing and groping or pushing me against a wall, but finally he closed me in a room and fingered me without asking, breaking my hymen. I had never been in a "real" relationship before and just figured that this was the way things go. He dumped me over the phone two days after he broke my hymen, and said that I made his life difficult for being there and that I was to blame for what he'd done. I really thought I was the one at fault.
I was ashamed for what I'd done and I've had to hide this from my new partners. All of them are so nice and considerate, but I'm constantly in fear that they'll just drop me or change their minds about me, or hurt me like he did. I had a bad doctor's appointment a few months ago that brought back a lot of my old insecurities just when I thought I was getting better. I'm extremely under confident, and I try to be the most loving person I can be, but I kept blaming myself for what a guy did to me without my consent. Finally, I realized that a lot of my problems stemmed from what this guy did to me. I thought I had left the whole event behind, but I really hadn't, I just ran away from it. The only way to end it for me was to confront him, and get an apology from someone I used to be afraid of.
Yesterday, I tried to talk to him for the first time in 6 months. He was super congenial and chatted me up, asking me how I was doing, and I said, "great." I was completely disarmed by him. What's worse? His business, the same store where he led me to the back and fingered me, is doing really well and he has a fiancé. I lost all of my footing and bought a coffee to go.
I told a good friend of mine, who gave me some encouraging words and I went back again. At first I couldn't look him in the eyes. I started to tell him how badly he hurt me. He told me he would fix it, and I said that wasn't necessary, that I was better and stronger now. I just wanted him to realize that he wasn't innocent, that what he did was wrong, and that he should be ashamed of himself. He said, "I was only trying to help you, to make you happy. I want what's best for you." This made me feel terrible, of course. It wasn't what's best for me, and I felt deflated. I told him that what he did was sick and shameful. He said that he "tried to set limits," which was really just putting me down whenever he felt like it. I told him that he did a lot of things that he *knew* were wrong, that he always knew, and that he knew how vulnerable I was the whole time. He was an adult, and I was comparatively a child. When other people came into the store, I stopped talking and texted my friends, since I wanted this to be between only us.
However, I turned around and he *ran away*! *He* was afraid of talking to *me* and was "cleaning up" in the very back of the store with the delivery guy! Then, his fiancé/manager showed up! This was rich! She didn't understand why he wasn't serving "this poor girl at the counter who's been waiting here forever for a coffee." I leaned in and laid it on thick. He eeked out one pathetic apology, then I made him say he was ashamed of himself, and I told him about my hymen, how I'll never get that back and he physically hurt me. He started to tear up, and finally his fiancé was fed up and gave me the coffee herself, having no idea what was going on. The coffee was really hot, so I sat there for a while and he avoided looking at me. Every chance I got, I told him that he should regret what he did. Finally, he really did make a sincere apology. I walked up to him and whispered, "you're lucky I didn't go to the police. You're really, really lucky. You should be ashamed "honey are you cold?" He couldn't speak. I thanked her for the coffee as she went to the back. She wished me the best of luck in school. As I left, I mouthed the words "shame on you" one more time. I was a bully, but he deserved it.
I didn't think it was going to make all of my pain go away, but I already feel so much better and more confident. I'm already not bothered by things that would have upset me yesterday. If anyone else who was hurt by someone else this way has the chance, I can vouch that bringing that person down the way they brought you down is the sweetest revenge.
EDIT: Thank you so much everyone! It's so great time and again to see how supportive this community is. For others who were hurt this way: just know that if you were to come back strong, whole and angry to your abuser and hold them accountable, you'll find that someone you were afraid of is actually a big COWARD! I think every bad person should be dealt with this way. | 0non-cybersec
| Reddit |
Cat found three years after going missing.. | 0non-cybersec
| Reddit |
Edinburgh Student's Red/Black Themed Build.. | 0non-cybersec
| Reddit |
Wisconsin Abortion Ban Would Allow Father To Sue Doctor For Emotional Distress. | 0non-cybersec
| Reddit |
(NA) 30 Free Gold Points on My Nintendo. | 0non-cybersec
| Reddit |
How to show width and height of image files in Finder's column view?. <p>Is there any way to view the width and height of image type files in Finder's column view?</p>
<p><strong>I am runnning Snow Leopard.</strong></p>
<p>There isn't a checkbox for dimension in the Finder's view options:</p>
<p><img src="https://i.stack.imgur.com/SbSZ1.png" alt=""></p>
| 0non-cybersec
| Stackexchange |
Man plays Super Mario World with his nose and a recorder. | 0non-cybersec
| Reddit |
Black borders Ubuntu 14.04. <p>After installing wine, I see the black borders everywhere and can't see my terminal:</p>
<p><img src="https://i.stack.imgur.com/wi62r.png" alt="enter image description here"></p>
<p>I've reinstalled the wine, nvidia drivers and Bumblebee, but the problem still exist. Can anyone help me? The problem exist on every user of my ubuntu. Sorry for my English!</p>
| 0non-cybersec
| Stackexchange |
[Image] Never forget that daily struggle, the fire in which we must be forged. | 0non-cybersec
| Reddit |
Really Walmart?. | 0non-cybersec
| Reddit |
dirt bike games. | 0non-cybersec
| Reddit |
Android - Fill Path with color partially. <p>I am trying to draw a heart shaped Canvas using Path in Android. The code is as follows :</p>
<pre><code> @Override
protected void onDraw(Canvas canvas) {
super.onDraw(canvas);
// Fill the canvas with background color
canvas.drawColor(Color.WHITE);
// paint.setShader(null);
// Defining of the heart path starts
path.moveTo(left + WIDTH / 2, top + HEIGHT / 4); // Starting point
// Create a cubic Bezier cubic left path
path.cubicTo(left+WIDTH/5,top,
left+WIDTH/4,top+4*HEIGHT/5,
left+WIDTH/2, top+HEIGHT);
// This is right Bezier cubic path
path.cubicTo(left + 3 * WIDTH / 4, top + 4 * HEIGHT / 5,
left + 4 * WIDTH / 5, top,
left + WIDTH / 2, top + HEIGHT / 4);
paint.setShader(new LinearGradient(0, canvas.getHeight()/4, canvas.getWidth(), canvas.getHeight()/4, new int[]{Color.RED, Color.YELLOW, Color.GREEN}, new float[]{0, 0.6f, 1}, Shader.TileMode.CLAMP));
canvas.drawPath(path, paint);
heart_outline_paint.setColor(getResources().getColor(R.color.heart_outline_color)); // Change the boundary color
heart_outline_paint.setStrokeWidth(4);
heart_outline_paint.setStyle(Paint.Style.STROKE);
canvas.drawPath(path, heart_outline_paint);
}
</code></pre>
<p>I am able to draw heart without any issue and I am able to fill color inside the heart using the <code>Fill</code> option in Paint. But I should be able to fill the heart dynamically according to some data and it cannot be filled fully all the time. What I have achieved so far is as follows :</p>
<p><a href="https://i.stack.imgur.com/v3IS5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/v3IS5.png" alt="Heart Shape with Filled Color"></a></p>
<p>I have made an extensive search and came across a lot of things similar to this. Some of which includes : </p>
<ol>
<li><a href="https://stackoverflow.com/questions/25488151/android-fill-in-part-of-a-path">Android fill in part of a path?</a></li>
<li><a href="https://stackoverflow.com/questions/24858531/filling-a-circle-gradually-from-bottom-to-top-android/24866667?noredirect=1#comment38644747_24866667">filling a circle gradually from bottom to top android</a></li>
</ol>
<p>I also came across the concept of converting the canvas to bitmap and filling color inside the bitmap using <a href="http://www.codeproject.com/Articles/364413/Queue-Linear-Flood-Fill-A-Fast-Flood-Fill-Algorith" rel="nofollow noreferrer">Flood Fill Algorithm</a> which lets users to fill colors inside the bitmap. However, I do not want the bitmap to fill the color while touching inside the heart but to fill while a button click action. </p>
<p>I thought that <a href="https://stackoverflow.com/questions/24858531/filling-a-circle-gradually-from-bottom-to-top-android/24866667?noredirect=1#comment38644747_24866667">filling a circle gradually from bottom to top android</a>
would give help me but it makes use of a circle and I am not well-versed in Canvas which makes me very weak in adapting the circle code to such a shape. </p>
<p>If anybody has some ideas or any insights on how to achieve this, it will be really helpful. Cheers. Thanks in advance. </p>
<p><strong>P.S :</strong> I also tried some tricks using <code>setShader</code> in Paint but nothing would give me what I want. </p>
<p><strong>EDIT :</strong></p>
<p>I just stumbled upon a idea of drawing a rectangle over the heart with another color same as the background of the canvas so that it will look like its half filled !! I am still working on the idea and not sure how accurate this is gonna be for me. If someone has a better idea, you're most welcome.</p>
<p><a href="https://i.stack.imgur.com/VbnmF.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VbnmF.png" alt="enter image description here"></a></p>
| 0non-cybersec
| Stackexchange |
Spring Boot + Angular 4 with i18n. <p>I am currently developing an Angular 4 application with Spring Boot as backend. I use Maven to build the projects configured as explained in <a href="https://blog.jdriven.com/2016/12/angular2-spring-boot-getting-started/" rel="noreferrer">https://blog.jdriven.com/2016/12/angular2-spring-boot-getting-started/</a></p>
<p>I would now like to translate the application in other languages. I looked at <a href="http://www.baeldung.com/spring-boot-internationalization" rel="noreferrer">http://www.baeldung.com/spring-boot-internationalization</a> for the Spring Boot side, but now I'm wondering if it is possible to use my messages*.properties in Angular. Any experience with that?</p>
<p>Thanks,
<br>
Guillaume</p>
| 0non-cybersec
| Stackexchange |
Is the coefficient uniquely determined by the sign function?. <p>Suppose $a\in R^p$, $b\in R^p$, and $||a||=||b||=1$, is it true that if $sign(a'x)=sign(b'x)$ for any $x\in R^p$, then $a=b$, where $sign(t)=1$ if $t\geq 0$ and $sign(t)=-1$ if $t<0$?</p>
| 0non-cybersec
| Stackexchange |
[50/50] Tiny Cute Bunny(SFW) | Failed Suicide Attempt(NSFW). | 0non-cybersec
| Reddit |
Federal soldiers stand guard on a tank in a Detroit street during the Detroit Riots July 25, 1967 [1600x1108]. | 0non-cybersec
| Reddit |
Encrypted Booting. <p>I want to boot the Linux from the /boot partition, and also want to encrypt this /boot partition.</p>
<p>[ AFAIK, Grub is unable to find the kernel and initrd from an truecrypted partition or cryptsetup encrypted boot partition. ]</p>
<p>Is there any way to do so ?</p>
| 0non-cybersec
| Stackexchange |
What's causing bluescreens on my new PC?. <p>I recently brought a gaming PC and I am frequently encountering bluescreen problem:
The blue screen message is memory problem detection restart PC to prevent damage to the computer. The following information given below can give more idea.</p>
<pre><code>BCCode: 3b
BCP1: 00000000C0000005
BCP2: FFFFF80002D3BABF
BCP3: FFFFF88008395C60
BCP4: 0000000000000000
OS Version: 6_1_7600
Service Pack: 0_0
Product: 256_1
</code></pre>
<p>Can some please help me with this issue and tell me what can be done to solve this problem?</p>
<p>Full information on the specification of the PC:</p>
<ul>
<li>Computer: ACPI x64-based PC </li>
<li>Disk Drive: Toshiba DT01ACA050 ATA Device</li>
<li>Display Adaptor: AMD Radeon HD 6450 </li>
<li>DVD/CD-ROM drive: HL-DT-ST DVDRAM</li>
<li>GH24NSBO ATA DEVICE IDE ATA/ATAPI CONTROLLER:
<ul>
<li>ATA channel 4</li>
<li>ATA channel 5</li>
</ul></li>
<li>Intel 7 series/C216 Chipset Family </li>
<li>SATA AHCI controller- 1E02</li>
<li>Image Device: A4Tech USB 2.0 PC camera</li>
<li>Processor : Intel Core i7-3770 CPU 3.40 GHz</li>
</ul>
| 0non-cybersec
| Stackexchange |
find the probability that exist 1 person that all of his friends are in the other group.(split 6 persons in two groups?. <p>6 students in a class are randomly and independently split to 2 groups.</p>
<p>A group can be empty.</p>
<p>All students has a least 1 friend.</p>
<p>The total number of friendships is 10.</p>
<p>Find the probability that exist one student that all of his friends are in the other group.</p>
<p>The number of ways to split is:32.</p>
<p>$\frac{ \binom{6}{0}+ \binom{6}{1} + \binom{6}{2}+ \binom{6}{3}+ \binom{6}{4} + \binom{6}{5}+ \binom{6}{6}}{2} = \frac{64}{2} = 32$
,that is the sample space.</p>
<p>How can I solve it?</p>
<p>I tried to find the complementary event but I don't progress with it...</p>
| 0non-cybersec
| Stackexchange |
prove sum property by induction. <p>Knowing that $(a_i)_{i\ge1}$ prove that $\forall n \in \Bbb N$:
$$\sum^n_{i=1}ra_i=r\Big(\sum^n_{i=1}a_i \Big)$$</p>
<p>This kind of demonstrations is totally strange to me, I do not understand how to organize and how to develop it, so I appreciate someone could guide me, recommend books, websites, videos, or any kind of information about it.</p>
| 0non-cybersec
| Stackexchange |
In 20 years chocolate will be a rare delicacy, according to the Cocoa Research Association.. | 0non-cybersec
| Reddit |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange |
When sharks attack. | 0non-cybersec
| Reddit |
What is this place?. | 0non-cybersec
| Reddit |
How do I model (GitHub-like) permissions relationally?. <p><strong>tl;dr: how do i implement a permissions model like (e.g.) github's</strong> </p>
<p><strong>Updated to try to address some of @philipxy's comments:</strong></p>
<p>I am planning to implement a permissions model similar to github's:</p>
<ol>
<li>users</li>
<li>users can be in groups</li>
<li>users can be in organizations</li>
<li>groups can be in organizations</li>
<li>a user will be permitted any of C, R, U, and D operations on an asset, group, or organization <em>as</em>:
<ol>
<li>an individual user who has been permitted those (any of C, R, U, D) operations</li>
<li>a member of a group which has been granted those permissions</li>
<li>a member of an organization that has been granted those permissions
<ol>
<li>or as a member of a group where that group belongs to an org that has permissions</li>
</ol></li>
</ol></li>
<li>a user is granted Read because the asset/group/org is viewable (readable) to anonymous users ("public")</li>
<li>a user should also have a set of permissions to say whether they can do any of C, R, U, or D on the permissions (a user can create a permission[C,R,U,D] for another user, a group, or an org)
<ol>
<li>a user can set the permissions for any asset, group, or org they create, or any asset, group, or org for which they have been given permission to set permissions.</li>
</ol></li>
</ol>
<p>These permissions will control who can perform Create, Read, Update, and Delete (CRUD) actions on assets, groups, and organizations in the site.</p>
<p>Approximately how do I model this? </p>
<p>Obviously i have these models:</p>
<ol>
<li>Asset</li>
<li>User</li>
<li>Group</li>
<li>Organization</li>
</ol>
<p>What next?</p>
<ol>
<li>Permission? </li>
<li>PermissionType (to capture C/R/U/D)?</li>
</ol>
<p>I am using mysql from node (via sequelize), but I can figure out specific syntax an all that myself, I just haven't yet figured out how to do this conceptually.</p>
<p><strong>More to @philipxy's point:</strong></p>
<p>The very thing you are proposing I do more of is indeed the thing I think I'm asking for help with. That is, those info design methods (NIAM, FCO-IM, ORM2, IDEF1X) are what i'm looking for. I know a decent amount about relational db <em>implementation</em> (days of learning normalizing and normal forms and whatnot), but indeed the process of specifying business requirements and converting them into actionable specs is the challenge. </p>
<ul>
<li>ORM2 <s>is difficult to find because of name collisions with the nodejs module. </s>: I have downloaded the book linked from the <a href="https://en.wikipedia.org/wiki/Object-role_modeling#ORM_2_graphical_notation" rel="noreferrer">NIAM wikipedia page</a></li>
<li>NIAM seems to be less common in usage nowadays?</li>
<li>FCO-IM: I have downloaded the book from their website</li>
<li>IDEF1X: also looks interesting</li>
</ul>
<p>I guess I'm going to pick up a database text book.</p>
<p>More work toward predicates:</p>
<ol>
<li><code>U</code> identifies a <code>User</code></li>
<li><code>A</code> identifies an <code>Asset</code></li>
<li><code>G</code> identifies a <code>Group</code></li>
<li>a <code>User</code> <code>U</code> can be in 0 or more <code>Groups</code> <code>G</code></li>
<li><code>O</code> identifies an <code>Organization</code></li>
<li>a <code>User</code> <code>U</code> can be in 0 or more <code>Organizations</code> <code>O</code></li>
<li>a <code>Group</code> <code>G</code> can be in 0 or more <code>Organizations</code> <code>O</code></li>
<li>an asset <code>A</code> can be created by a <code>User</code> <code>U</code></li>
<li>CRUD on <code>Assets</code>:
<ol>
<li>an <code>Entity</code> <code>E</code> can be permitted (through <code>Permission</code> <code>P</code> ?) to perform actions <code>Ac</code> on <code>Assets</code></li>
<li>those <code>Actions</code> are:
<ol>
<li><code>Create</code></li>
<li><code>Read</code></li>
<li><code>Update</code></li>
<li><code>Delete</code></li>
</ol></li>
<li>the <code>Entity</code> may be of types:
<ol>
<li><code>User</code></li>
<li><code>Group</code></li>
<li><code>Organization</code></li>
<li><code>Anonymous User</code>/"the public"</li>
</ol></li>
<li>details (shown only for <code>Read</code>, but also relevant for <code>Create</code>, <code>Update</code>, and <code>Delete</code>):
<ol>
<li>a <code>User</code> <code>U0</code> can permit another <code>User</code> <code>U1</code> to <code>Read</code> an <code>Asset</code> <code>A</code></li>
<li>a <code>User</code> <code>U0</code> can permit <code>Users</code> <code>U</code> who are members of <code>Group</code> <code>G</code> to <code>Read</code> an <code>Asset</code> <code>A</code></li>
<li>a <code>User</code> <code>U0</code> can permit <code>Users</code> <code>U</code> who are members of <code>Organization</code> <code>O</code> to <code>Read</code> an <code>Asset</code> <code>A</code></li>
<li><code>Users</code> <code>U</code> in <code>Group</code> <code>G1</code>, where <code>G1</code> is a <code>Group</code> that is in an <code>Organization</code> <code>O</code> that has been permitted to <code>Read</code> <code>Asset</code> <code>A</code>, are therefore permitted <code>Read</code> <code>Asset</code> <code>A</code></li>
</ol></li>
</ol></li>
<li>a <code>Permission</code> <code>P</code> that references an <code>Asset</code> <code>A</code> may only be created by certain users:
<ol>
<li>By default, the <code>User</code> <code>U</code> who is the creator of an <code>Entity</code> can create <code>Permissions</code> for that <code>Entity</code>, </li>
<li>but they may only reference <code>Assets</code> to which they have <code>Permission</code> (in the base case: those <code>Assets</code> create by <code>U</code>)</li>
<li>a <code>User</code> who as been <code>Grant(?)</code>ed the privilege can also reference <code>Entity</code> <code>E</code> in a <code>Permission</code></li>
<li><code>Gr</code> identifies a <code>Grant</code>
<ol>
<li>a <code>Grant</code> gives an <code>Entity</code> the privilege to create, read, update, or delete <code>Permissions</code> that reference another <code>Entity</code></li>
<li>like <code>Permissions</code>, <code>Grants</code> have a transitive nature in that:
<ol>
<li>if <code>Organization</code> <code>O</code> has been <code>Granted</code> the privilege to (e.g.) modify <code>Permissions</code> for <code>Entity</code> <code>E</code>, then </li>
<li>not only may <code>Users</code> who are members of <code>O</code> modify <code>Permissions</code> referencing <code>E</code>,
<ol>
<li>but also <code>Users</code> who are members of any <code>Group</code> <code>G</code> where <code>G</code> is in <code>O</code> have the privilege to modify <code>Permissions</code> referencing <code>E</code></li>
</ol></li>
</ol></li>
</ol></li>
</ol></li>
</ol>
| 0non-cybersec
| Stackexchange |
Woke up, smoked a bowl, rushed to class at a [7] on my longboard. I'm stoned and my ecology lab is having a trip to a park to catch butterflies. I'm hyped as fuck boys | 0non-cybersec
| Reddit |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange |
Warning publishing Azure service bus queue trigger can't find named value in local.settings.json. <p>I have a Azure service bus queue trigger function and when I created it it asked me 3 fields, access rights, connection and queue name. </p>
<p>I put in listen for the access rights. For the connection I used the the 'primary connection' name given in the 'RootManageSharedAccessKey' in the service bus I created.
It looks something like this</p>
<blockquote>
<p>Endpoint=sb://yogaband2017.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=JG0gwJ90bkbGl1BU=</p>
</blockquote>
<p>and I created a queue in my service bus called yogaband and that is what I used for the queue name as the third parameter.</p>
<p>My function looks like this</p>
<pre><code>public static class PostEventEmails
{
[FunctionName("PostEventEmails")]
public static void Run([ServiceBusTrigger("yogaband2017", AccessRights.Listen, Connection = "Endpoint=sb://yogaband2017.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=gkbGl1BU=")]string myQueueItem, TraceWriter log)
{
log.Info($"C# ServiceBus queue trigger function processed message: {myQueueItem}");
}
}
</code></pre>
<p>When I publish the function I get this warning</p>
<blockquote>
<p>.nuget\packages\microsoft.net.sdk.functions\1.0.2\build\netstandard1.0\Microsoft.NET.Sdk.Functions.Build.targets(31,5): warning : Function [PostEventEmails]: cannot find value named 'Endpoint=sb://yogaband2017.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=0bkbGl1BU=' in local.settings.json that matches 'connection' property set on 'serviceBusTrigger' [C:\Users\Source\Workspaces\YogaBand2017\YogaBand2017\PostEventEmails\PostEventEmails.csproj]</p>
</blockquote>
<p>and in my site I can pass the queue a message and I see the message in the queue in my Azure portal, but the function isn't picking up the message and processing it. So I still see '1 message' in the active message count in the queue. I assume it would be 0 after the function picks it up and processes it and I would see the log trace in the window? But I don't so I think the connection isn't correct or I didn't configure something correctly but I don't know what!</p>
<p>Here is what I put into the local.settings.json file</p>
<pre><code>{
"IsEncrypted": false,
"Values": {
"AzureWebJobsStorage": "Endpoint=sb://yogaband2017.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=bGl1BU=",
"AzureWebJobsDashboard": ""}}
</code></pre>
<p>FYI - here is how I send the mesage to the queue in c#</p>
<pre><code> var queueClient = QueueClient.Create("yogaband2017");
BrokeredMessage message = new BrokeredMessage("some test message");
message.MessageId = newEvent.YogaSpaceEventId.ToString();
queueClient.Send(message);
</code></pre>
<p>and in my web.config file I added this</p>
<pre><code><add key="Microsoft.ServiceBus.ConnectionString" value="Endpoint=sb://yogaband2017.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=0gwJ90bkbGl1BU="/>
</code></pre>
| 0non-cybersec
| Stackexchange |
How to install the package \usetikzlibrary{positioning,fit,arrows.meta,backgrounds}?. <p>I used the line <code>\usetikzlibrary{positioning,fit,arrows.meta,backgrounds}</code> in my latex code to generate architecture diagram with arrows. But it shows error as </p>
<blockquote>
<p>Can't find file <code>\usetikzlibrary{positioning,fit,arrows.meta,backgrounds}...</code></p>
</blockquote>
<p>Due to this I can't generate my architecture diagram correctly. Please anyone help me to use the above package in my LaTeX code in Ubuntu 14.04.</p>
<p>My code is as below. </p>
<pre><code>\documentclass[border=3mm]{standalone}
\usepackage{tikz}
\usetikzlibrary{positioning,fit,arrows.meta,backgrounds}
\tikzset{
module/.style={%
draw, rounded corners,
minimum width=#1,
minimum height=7mm,
font=\sffamily
},
module/.default=2cm,
>=LaTeX
}
\begin{document}
\begin{tikzpicture}[
% This will show the frame around the figure
show background rectangle]
% Place first 6 items
\node[module] (I1) {Item-1};
\node[module, below=of I1] (I2) {Item-2};
\node[module, below=of I2] (I3) {Item-3};
\node[module=1cm, below=8mm of I3] (I5) {Item-5};
\node[module=1cm, left= 3mm of I5] (I4) {Item-4};
\node[module=1cm, right= 3mm of I5] (I6) {Item-6};
% Inner box around Items 3-6
\node[fit=(I3) (I4) (I6), draw, inner sep=2mm] (fit3) {};
% Outer box around all left items
\node[fit=(fit3) (I1), draw, inner sep=2mm] (fit1) {};
% Connections
\foreach \i in {4,5,6}
\draw[->] (I3)--(I\i);
\draw[->] (I2)--(I1);
\draw[->] (I2)--(fit3);
% Items 7-8-9. Item 7 as label of Item-8
\node[module, right=2cm of {I2-|fit1.east},
label={[yshift=5mm, font=\sffamily]Item-7}]
(I8) {Item-8};
\node[module, below=of I8] (I9) {Item-9};
%outer box around items 8-9
\node[fit={(I9) (I9|-fit1.south) (I9|-fit1.north)}, draw, inner xsep=5mm, inner ysep=-\pgflinewidth] (fit8) {};
%arrow between boxes
\draw[<->,dashed] (fit1)--(fit8);
%upper label
\path (fit1.north east)--node[above=3mm, font=\sffamily\bfseries] (arc) {Architecture} (fit8.north west);
\end{tikzpicture}
\end{document}
</code></pre>
| 0non-cybersec
| Stackexchange |
Aligning polynomials rightshifted by x. <p>I am trying to align some generating functions, to give a visual indication of how they represent recurrences. When I try to do this the natural-seeming way with <code>aligned</code>, it puts an obnoxiously large space after the constant term, and also leaves out some spacing around the plus signs.</p>
<p>I found a way to align it the way I want, but it has a bunch of <code>\,</code> and negative spaces that seem unnatural and are hard to align. Is there a better way to align this the way I want?</p>
<pre><code>\documentclass{article}
\usepackage{amsmath}
\begin{document}
Bad: $$
\begin{aligned}
A(x) &= a_0 +& a_1 x + a_2 x^2 +& a_3 x^3 + a_4 x^4 + \cdots \\
x\, A(x) &= & a_0 x + a_1 x^2 +& a_2 x^3 + a_3 x^4 + \cdots \\
x^3 A(x) &= & & a_0 x^3 + a_1 x^4 + \cdots
\end{aligned}
$$
Good: $$
\begin{aligned}
A(x) &= a_0 \,+&\negmedspace\negmedspace\!\! a_1 x + a_2 x^2 \,+&\, a_3 x^3 + a_4 x^4 + \cdots \\
x\, A(x) &= &\negmedspace\negmedspace\!\! a_0 x + a_1 x^2 \,+&\, a_2 x^3 + a_3 x^4 + \cdots \\
x^3 A(x) &= & &\, a_0 x^3 + a_1 x^4 + \cdots
\end{aligned}
$$
\end{document}
</code></pre>
<p>The above code gives this result in TeXworks (I am using the pdfLatex setting):</p>
<p><img src="https://i.stack.imgur.com/VbEwX.png" alt="the above code rendered in Latex"></p>
<p>I found <a href="https://tex.stackexchange.com/q/29612/62608">this similar question</a>, but I don't want any leading plus signs, as I am only omitting leading terms.</p>
| 0non-cybersec
| Stackexchange |
A question involving inequality. <p><span class="math-container">$x=cy+bz\ ,\ y=az+cx$</span> and <span class="math-container">$z=bx+ay$</span> has a non zero solution and atleast one of a,b,c is a proper fraction(a rational number whose absolute value is less than 1) , prove that <span class="math-container">$a^3+b^3+c^3<3$</span> and <span class="math-container">$abc>-1$</span>.</p>
<hr>
<p>For non zero solution implies , the determinant of following marix be zero because if AX=B (A<span class="math-container">$^{-1}$</span> should not exist for infinite solution).And there is no possibility of no solution because we already know (0,0,0) is a solution.</p>
<p><span class="math-container">$$
\begin{bmatrix}
-1 & c & b \\
c & -1 & a\\
b & a & -1 \\
\end{bmatrix}
$$</span></p>
<hr>
<p>Giving us <span class="math-container">$a^2+b^2+c^2+2abc=1$</span>. After this I am totally stuck. Somehow we have to use proper fraction condition .Thanks for the help</p>
| 0non-cybersec
| Stackexchange |
How do I set an environment variable in the shell to be result of python script?. <p>If I run</p>
<pre><code>export TEST=script.py
echo $TEST
</code></pre>
<p>It outputs script.py</p>
<p>script.py code:</p>
<pre><code>return 5
</code></pre>
<p>can TEST be set to 5? Obviously script will do something in future not just return a number</p>
| 0non-cybersec
| Stackexchange |
Is it best practices to have separate login for a domain for domain admins?. <p>I typically like to set up separate logins for myself, one with regular user permissions, and a separate one for administrative tasks. For example, if the domain was XXXX, I'd set up a XXXX\bpeikes and a XXXX\adminbp account. I've always done it because frankly I don't trust myself to be logged in as an adminstrator, but in every place that I've worked, the system administrators seem to just add their usual accounts to the Domain Admins group.</p>
<p>Are there any best practices? I've seen an article from MS which does appear to say that you should use Run As, and not login as an admin, but they don't give an example of an implementation and I've never seen anyone else do it.</p>
| 0non-cybersec
| Stackexchange |
what is the difference between ranlib, ar, and ld for making libraries. <p>To make libraries in c++/unix from *.o files, I have noticed two different ways in my project (legacy code):</p>
<pre><code>ar qc libgraphics.a *.o
ranlib libgraphics.a
</code></pre>
<p>and</p>
<pre><code>ld -r -o libgraphics.a *.o
</code></pre>
<p>What is the difference between the two approaches, and which is to be used for what purpose?</p>
| 0non-cybersec
| Stackexchange |
The Brit Who Tried To Kill Trump (2017). | 0non-cybersec
| Reddit |
docker compose oci runtime error, executable file not found in $PATH. <p>I'm following this post:</p>
<p><a href="http://eric-price.net/blog/centralized-logging-docker-aws-elasticsearch" rel="noreferrer">http://eric-price.net/blog/centralized-logging-docker-aws-elasticsearch</a></p>
<p>This is what my docker-compose.yml looks like :</p>
<pre><code>version: "2"
services:
fluentd:
image: fluent/fluentd:latest
ports:
- "24224:24224"
command: start.sh
networks:
- lognet
nginx:
image: nginx-pixel
ports:
- "80:80"
logging:
driver: fluentd
networks:
- lognet
networks:
lognet:
driver: bridge
</code></pre>
<p>my <code>start.sh</code> is in the same directory as the yml file. When I run <code>docker-compose up -d</code> this is what I get : </p>
<p><code>ERROR: for fluentd Cannot start service fluentd: oci runtime error: exec: "start.sh": executable file not found in $PATH
ERROR: Encountered errors while bringing up the project.</code></p>
<p>My docker-compose info: </p>
<pre><code>docker-compose version 1.8.0, build f3628c7
docker-py version: 1.9.0
CPython version: 2.7.9
OpenSSL version: OpenSSL 1.0.1e 11 Feb 2013
</code></pre>
| 0non-cybersec
| Stackexchange |
I just want everyone to know that freetaxusa.com files federal returns for free and only charges $12 for a state filing.. | 0non-cybersec
| Reddit |
Insert Multiple images inside EditText. <p>I am working on an app for deaf-mute people, so created a specific keyboard for the app. Now, I want to set images in an EditText, the images are symbols used by the deaf-mute people I want something like this :
<a href="https://i.stack.imgur.com/RyzDx.png" rel="nofollow noreferrer">deaf-muet keyboard + EditText</a></p>
<p>in that editText, I was able to set only the first sign which it refers to the first letter, but I want to set many images for each letter.
I used the .setCompoundDrawablesWithIntrinsicBounds() but it only gave me the first letter.
how can I do to set multiple images in an EditText or in ViewText?</p>
| 0non-cybersec
| Stackexchange |
When import docx in python3.3 I have error ImportError: No module named 'exceptions'. <p>when I import <code>docx</code> I have this error:</p>
<pre><code>>File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/docx-0.2.4-py3.3.egg/docx.py", line 30, in <module>
from exceptions import PendingDeprecationWarning
ImportError: No module named 'exceptions'
</code></pre>
<p>How to fix this error (<code>python3.3</code>, <code>docx 0.2.4</code>)?</p>
| 0non-cybersec
| Stackexchange |
Decoding of Hamming Codes. <p>I know some procedures for decoding of Hamming Code (syndrome table, ...). But There is an easy way for decoding of Hamming codes for example <a href="http://en.wikipedia.org/wiki/Hamming%287,4%29#Decoding" rel="nofollow">here</a> a very nice method for decoding of Hamming(7,4) code is suggested. I'm looking for similar decoding for other Hamming codes such as Hamming(15,11) , Hamming(31,26).</p>
<p>If you know similar decoding schemes, please let me know.</p>
| 0non-cybersec
| Stackexchange |
Finding certain messages in SQS. <p>I know SQS ain't build for that, but I'm curious is it possible to find messages in a queue that meet some criteria?</p>
<p>I can pull messages in a loop, search the message bodies for some pattern (without even deserializing them), and filter the messages I needed. But then it is possible to end up with an infinite loop - the first messages I read will be back to the queue by the time when I reach the end of the queue... </p>
<p>Extending visibility of the messages possible, but how do I know exactly how long it will take to scan the entire queue, and for how long should I extend the visibility? What if I have literally ten thousand messages in there?</p>
<p>Is there any workaround here?
I need to scan the queue for some messages, and delete those... </p>
| 0non-cybersec
| Stackexchange |
iptables rules on server break dynamic ssh port forwarding (SOCKS proxy) on local machine. <p>I use debian 9 on a rented VPS. On my laptop I use dynamic ssh port forwarding (using the SOCKS protocol) to tunnel the traffic of some applications. It all works fine but when I load the iptables rules on the server (the VPS) any application on my laptop that was using the local port forwarding stops working.</p>
<p>This is the command I use to forward local port 8080 of my laptop (debian 8) to my VPS:</p>
<pre><code>ssh -D 8080 -N [email protected]
</code></pre>
<p>The above command starts returning errors like the following:</p>
<pre><code>channel 7: open failed: connect failed: Connection timed out
channel 8: open failed: connect failed: Connection timed out
channel 9: open failed: connect failed: Connection timed out
channel 3: open failed: connect failed: Connection timed out
etc...
</code></pre>
<p>Here is the output of iptables -L on the VPS. Can anyone see why these rules would cause this problem? Any idea much appreciated.</p>
<pre><code>Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- google-public-dns-a.google.com anywhere
ACCEPT all -- resolver3.opendns.com anywhere
ACCEPT all -- resolver1.opendns.com anywhere
SYN_FLOOD_LOG_DROP tcp -- anywhere anywhere tcp flags:FIN,SYN,RST,ACK/SYN
UDP_FLOOD_LOG_DROP udp -- anywhere anywhere
ICMP_FLOOD_LOG_DROP icmp -- anywhere anywhere
tcp -- anywhere anywhere tcp dpt:ssh state NEW recent: SET name: DEFAULT side: source mask: 255.255.255.255
SSH_LOG_DROP tcp -- anywhere anywhere tcp dpt:ssh state NEW recent: UPDATE seconds: 60 hit_count: 4 name: DEFAULT side: source mask: 255.255.255.255
tcp -- anywhere anywhere tcp dpt:xmpp-client state NEW recent: SET name: DEFAULT side: source mask: 255.255.255.255
XMPP_LOG_DROP tcp -- anywhere anywhere tcp dpt:xmpp-client state NEW recent: UPDATE seconds: 60 hit_count: 8 name: DEFAULT side: source mask: 255.255.255.255
tcp -- anywhere anywhere tcp dpt:http state NEW recent: SET name: DEFAULT side: source mask: 255.255.255.255
HTTP_LOG_DROP tcp -- anywhere anywhere tcp dpt:http state NEW recent: UPDATE seconds: 60 hit_count: 8 name: DEFAULT side: source mask: 255.255.255.255
ACCEPT tcp -- anywhere anywhere tcp dpt:xmpp-client
ACCEPT tcp -- anywhere anywhere tcp dpt:http
ACCEPT tcp -- anywhere anywhere tcp dpt:ssh
ACCEPT tcp -- localhost anywhere tcp dpt:5582
Chain FORWARD (policy DROP)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain HTTP_LOG_DROP (1 references)
target prot opt source destination
LOG all -- anywhere anywhere LOG level warning prefix "IPTables DROP:HTTPATTACK "
DROP all -- anywhere anywhere
Chain ICMP_FLOOD_LOG_DROP (1 references)
target prot opt source destination
RETURN all -- anywhere anywhere limit: avg 1/sec burst 3
LOG all -- anywhere anywhere LOG level warning prefix "IPTables DROP:ICMPFLOOD "
DROP all -- anywhere anywhere
Chain SSH_LOG_DROP (1 references)
target prot opt source destination
LOG all -- anywhere anywhere LOG level warning prefix "IPTables DROP:SSHATTACK "
DROP all -- anywhere anywhere
Chain SYN_FLOOD_LOG_DROP (1 references)
target prot opt source destination
RETURN all -- anywhere anywhere limit: avg 1/sec burst 3
LOG all -- anywhere anywhere LOG level warning prefix "IPTables DROP:SYNFLOOD "
DROP all -- anywhere anywhere
Chain UDP_FLOOD_LOG_DROP (1 references)
target prot opt source destination
RETURN all -- anywhere anywhere state NEW recent: UPDATE seconds: 1 hit_count: 20 name: DEFAULT side: source mask: 255.255.255.255
LOG all -- anywhere anywhere LOG level warning prefix "IPTables DROP:UDPFLOOD "
DROP all -- anywhere anywhere
Chain XMPP_LOG_DROP (1 references)
target prot opt source destination
LOG all -- anywhere anywhere LOG level warning prefix "IPTables DROP:XMPPATTACK "
DROP all -- anywhere anywhere
</code></pre>
<p>Thank you.</p>
| 0non-cybersec
| Stackexchange |
Brotha Lynch Hung - Rest In Piss (classic). | 0non-cybersec
| Reddit |
How to Wait in Objective-C and Swift. <p>I want to change my <code>UILabel</code>'s text after 2 seconds.</p>
<p>I tried setting my <code>UILabel</code>'s text to <em>"A text"</em>, and use <code>sleep(2)</code> and finally changing the text to <em>"Another text"</em>.</p>
<p>But <code>sleep(2)</code> only freezes the app and <em>"Another text"</em> is set without displaying <em>"A text"</em> for 2 seconds.</p>
<p>How may I display <em>"A text"</em> for 2 seconds and then show <em>"Another text"</em>?</p>
| 0non-cybersec
| Stackexchange |
Is there a tool to make partition bootable?. <p>I tried Windows 8 Consumer Preview a couple months ago and it wiped out my partition table... or the boot information. </p>
<p>So now the machine cannot boot to anything at all. Is there Ubuntu tools or Linux tools that can fix all the partitions and make them boot again? (The partitions have Windows 7 and Vista on them. I run Ubuntu as a VM on Win 7). I tried another tool running on Vista and was able to see the Win 7 partition, except that tool wiped out the Vista boot info later on.</p>
<hr>
<p><strong>update:</strong> per @mlt's request, this is what <code>fdisk -l</code> says;</p>
<pre><code>ubuntu@ubuntu:~$ sudo fdisk -l /dev/sda
Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x1aca8ea5
Device Boot Start End Blocks Id System
/dev/sda1 284993226 350602558 32804666+ 7 HPFS/NTFS/exFAT
</code></pre>
| 0non-cybersec
| Stackexchange |
How can I upgrade gnome-terminal on Ubuntu 14.04 LTS?. <p>I would like to upgrade gnome-terminal to the latest version. Is that possible on Ubuntu 14.04 LTS?</p>
<p>I am using version 3.6.2 of gnome-terminal.</p>
<p>I have tried:</p>
<pre><code>sudo apt-get install --only-upgrade gnome-terminal
</code></pre>
<p>and it says gnome-terminal is already the newest version.</p>
| 0non-cybersec
| Stackexchange |
Pole master. | 0non-cybersec
| Reddit |
UPDATE: The fort has been completely decorated and some of us have met! A full update is in the comments.. | 0non-cybersec
| Reddit |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.