What happen to the digital image if I capture it without using any color filter arrays?

Question: I understand Bayer filter is a type of color filter array used in digital cameras
to create a color image. What happen to the digital image if I capture it without using any color filter arrays?
Comment: If you "understand" that the purpose of the Bayer filter array is "to create a color image", what should the consequence be if it is absent?  Or do you have something else in mind when you ask "what happen[s]"?
Comment: @JoshAlex What does the processing algorithm think? Does it assume the CFA is still there? Or has it been told a CFA is not there?
Comment: @xiota Will it show Black and White?
Answer: It all depends upon the set of instructions used to decode the information collected by the sensor. If you remove the CFA but don't tell the software used to process the raw data, you WON'T get a B&W image as expected, but you won't get a color image anything like you would expect, either.
Comment: @slingeraap That assumes one is using an automated exposure mode. Also, due to the overlapping sensitivity needed to imitate human vision, the color filters are fairly weak and allow around half of all light that strikes the CFA to pass through, so at most it's only one stop.
Comment: The image would probably also be overexposed, as the exposure controls of the camera would expose for a sensor with filters and without the filters much more light would reach the sensor.
Answer: In most cameras, a color filter array is necessary to reconstruct color from a single capture.  Without the filter, the result is a representation of the intensity of light captured by the sensor, but the raw data still needs to be processed to produce a usable image.  The typical result would be a monochrome image.
The sensor also has other filters, notably to block UV and IR.  The photographer may also choose to use color filters for creative effect.  Color can be reconstructed by combining multiple frames captured with color filters.
Comment: You didn't mention what happen to the image.
Comment: "The typical result would be a monochrome image."  But depends on how you process the raw.  It's not necessarily "black and white".
Answer: If there is no color filter array, then every pixel on the sensor has an equal (panchromatic) color response.
If the software processing the sensor data knows this, then the result is panchromatic black and white.
If the software processing the sensor data still thinks there is a color filter array (like if this was a radical mod to an existing color camera) then the result would be an almost-black-and-white image with color fringing in high-frequency high-contrast areas, as the demosaicing algorithm interprets the differences between neighboring pixels (which it thinks have different color responses) as color differences.
You don't actually have to remove the CFA from a sensor to see this: just look at what happens when a color digital camera without an optical low-pass filter shoots a high-detail black and white target:

(this is a 200% crop of a very small portion of the studio test image from DPReview's OM-System OM-1 review).
You'd probably also get a slight color cast (not true black-and-white) because the out-of-the-box white balance settings are tuned to the T-factors of the color array that isn't there, but that would be easily fixed with a filter in front of the lens, or pressing the Custom White Balance button while pointed at anything.
Answer: Yes, the image you get will be black and white. "Generation" of colours in the image are based on Bayer (or Foveon or X-Trans) filter. The process is named demosaic.
Comment: Not unless the decoding software is aware there is no CFA. That is, if the CFQ is removed but the raw file is still processed by an application that operates under the assumption the CFA is in place, the result will not be B&W, but the colors will be bizarre and nowhere near what one would expect.
Comment: @MichaelC, that is true if we get in consideration many if's in the question.
Answer: This is not an abstract question. You can actually buy cameras which don't have a color filter. See the Leica Monochrom for instance (manufacturer's site). Monochrome camera's are used all the time for scientific imaging, especially when working with fluorescence. By eliminating the color filter, you effectively improve the spatial resolution.


Trigger calls and application code

Question: When a trigger is set on a table does the application code wait for the original statement and the trigger to execute before resuming or just the original statement? Consider application code to be PHP or Ruby.Here by original statement I mean the sql query called by the application code.
Answer: Triggers in MySQL are synchronous. That means that the query submitter has to wait for the trigger to finish before it can resume its work.
Answer: When a trigger is set on a table, the code calling the trigger executes, and then the trigger executes. After the execution of the trigger, control is then returned back to the calling code to continue its execution from where it was interrupted.
The trigger has to execute first because other subsequent lines of the code may be relating to the table and may be trying to alter the table in a way that may be unacceptable to the set trigger.

Trigger calls and application code


Is it possible to use aptX on unsupported computers or phones?

Question: I've been reading up recently on different ways of wirelessly streaming media. At first I ignored bluetooth connections because of the quality, but then I started reading about aptX, which sounded pretty good (no pun intended). The only problem is that I have no idea if my devices support aptX - one of them being a Galaxy Player 4.0 (it is totally OK if you don't know what that is) with a custom ROM, where I'm figuring that it's probably not supported. Here's my question, though - the way I understand it, aptX is only a sort of codec that is used during the transmission via Bluetooth - so I'm figuring that it should, in theory at least, be possible to install this aptX codec on any computer or phone. Obviously the company/companies behind aptX are not advertising it this way - but is it still possible to do this somehow?
Comment: Depends if the Bluetooth & codec processig were implemented in user-accessible software, OS privileged software, firmware or hardware. And of course technically possible does not necessarily mean it's practical. IIRC CSR provides aptX support in Windows via a driver installation, but such a modification would be difficult if not impossible on your typical phone unless the OEM already supported it (mostly because it's proprietary and the owners don't seem to be interested in doing so).
Comment: Would depend entirely on the device and how much of the Bluetooth stack is modifiable. If you're asking about Windows, Linux or other computer OSes, please specify. If you're asking specifically about phones, please go to the appropriate site (e.g. [android.se], [apple.se], [windowsphone.se]).
Comment: So it's generally possible, it would just require a modifiable bluetooth stack (and obviously some programming skills, if it hasn't been done by anyone else)? If that's the case, that would answer my question for this purpose, and I could go onto one of the other sites to get more exact information.
Comment: Sorry about my edit, I didn't realize you had already replied.
Comment: OK, that answers my question. Could you please post it so I can mark it as the answer?
Answer: At its core, Apt-X is "just" a particular encoding for audio, taking advantage of clauses in the Bluetooth spec that allow vendor extensions.
In effect, from a hardware standpoint, all you technically need is a Bluetooth radio supporting the data rates and physical layer transmission modes that come with Bluetooth 3.0 (or later, since all the later specs are backwards compatible). It is difficult to impossible to retrofit Bluetooth 3.0 support onto a 2.1 or earlier radio due to hardware limitations, but once you have a Bluetooth 3.0 stack, adding apt-X is simply a software challenge.
So the Bluetooth stack for apt-X looks something like this:

Bluetooth 3.0 "base platform" (this includes physical radio specifications, link-layer protocols, minimum data transfer rates, connectivity and authentication, and eventually the A2DP stereo audio profile).
The apt-X codec, or an implementation thereof, which sits on top of A2DP and is advertised as being available. The client device and the host negotiate on what codec to use, then decide to use apt-X as the preferred codec if it's available on both sides.

Bob is 100% correct that doing this on an Android device, even with root, would be nigh-on impossible, because of how deeply the Bluetooth stack is buried in the system.
Furthermore, obtaining a copy of the apt-X codec is extremely difficult if you don't already have one. Possible issues include:

How do you get a copy of binaries of the apt-X codec for your platform?
Assuming you get the binaries, what's the chance they're compatible with your Bluetooth stack and toolchain? If any library versions, etc. are incompatible, it won't work.
Licensing. CSR licenses apt-X on a per-device basis. If they were aware of you doing this, they might have cause to go after you on legal grounds for copyright violation.
If you were to try and implement your own version of the apt-X codec, how are you going to find out how to do this, without an open standard? apt-X is proprietary, so you'd have to reverse engineer their code (which may be illegal).
Assuming you were able to find a working implementation of apt-X, how would you then integrate that into the Bluetooth stack of your device, which can vary widely in implementation? You'd have to compile it, fix any interface or header errors, linkage errors, etc.
Finally, even if you get all the software 100% working and everything is great, you could still be strung up on patent license violations in the extremely likely instance of CSR having exclusive software patents on some algorithms or ideas used in the apt-X codec. Think you can't patent an idea? Think again. Software OEMs do it all the time.

These days, the only reliable way to get apt-X is to buy devices (host devices and client devices) that actively advertise built-in apt-X support. They will probably have a CSR logo on the device or in the marketing literature advertising this support. Absent that, it's very unlikely that apt-X support has been added, and you're probably using something like SBC (or possibly AAC if you're lucky).


When installing software with Wine it does not put an Icon on the applications menu. Xubuntu 10.04

Question: When I install software with wine it appears to install correctly but does not add that program to the applications menu. I don't know the command to run the program from the command line so I can never run that program except through the wine installation command. How do I add that program to the menu? I am running wine from the terminal, but I believe the result is the same when starting it from the menu.
Thanks,
Daniel
Answer: This question have an easy way to solve.
Do this things

Create your own .desktop file
Add that .desktop file to there where you want

Create your own `.desktop` file
Just create a new file and set its name somthing.desktop. It is important that extension is .desktop. In that write this:
[Desktop Entry]
Name=(Apps name)
Exec=(command to execute(for example wine ~/.wine/drive_c/Program\ Files/(And Path)))
Icon=(select an icon and write its path here)
Type=Application

Add that `.desktop` file to there where you want
You can try just draging method or use Main menu to add New Item
Answer: You may also try to install PlayOnLinux and install your app from there. It's much easier and you can install as many wine versions.


APIC error on CPU1: 60(60) in dmesg what does it mean?

Question: APIC error on CPU1: 60(60) in my dmesg log. What does it mean? Should I be worried! Is this some hardware issue?
Comment: Please be more detailed: OS and kernel version, and type of hardware.

Also, are you on bare metal or in a virtual machine?
Comment: bare matal centos 5.6, 2.6.18-238.5.1.el5 x86_64 type of hardware its simple workstation(desktop) working as server, CPU Pentium(R) Dual  CPU  E2220  @ 2.40GHz
Answer: This error indicates a failure in the Advanced Programmable Interrupt Controller. The failure means that the kernel was not able to communicate with the CPU APIC (wrong message).
There isn't a unique solution to this; the cause may be:

a buggy driver (network card driver is a good candidate, as for unused modules that kernel loads anyway);
an old or defective BIOS;
some kind of wrong setting in the BIOS;
a broken motherboard or (uncommon) CPU.

If you experience a lot of crashes, freezings, strange behaviour of software, you can try:

boot with the "noapic" kernel parameter;
upgrade BIOS;
upgrade CentOS to 5.7 or 6.0;

Otherwise, if everything works, dont'worry....


What is difference between electric field and electrical charge?

Question: what is difference between electric field and electrical charge? I read about electrical charges and the electric field so I do not know what the difference is between them because they both are doing the same thing they act with repulsive or attractive force on other charges.
Comment: What is the difference between mass and gravitational field?
Answer: Think of a field as "the effect something has which spreads out". Like rings in water spreading from the splashing stone or like sound spreading from the clapping hands.

A magnetic field is the effect of a magnet. The field spreads out from/to the poles and grabs everything on its way that will interact magnetically.
Gravity is the effect of things with mass. The gravitational field spreads out from the mass and grabs every other mass on its way.
And an electric field is an effect of a charge. The field spreads out from/to charges and grabs every other charge on its way.

Everytime I said "grab", what I mean is that this field converts into a force of some sort. A force that causes motion in those other interacting objects.
A field is a way to explain how forces can be applied without physical touch. A charge is pulling in something else with an electric force without touching it - the "stuff" that connects the charge with its force through empty space is the electric field.
Answer: Electric charge is something that a particle/ object has due to excess/deficent charge present on it.
Electric field is the magnitude of Electrostatic force experienced by an electricaly charged particle in space.
Answer:
What is difference between electric field and electrical charge?

The field is what you detect. After detection you are able to name the source.
Only after doing experiments in the past, now we are able to call electrons and protons electric charges. Not to forget that doing other experiments, now we are able to call these subatomic particles magnetic dipoles too. Calling something a charge or magnet this is the easiest way to say that it has a field and we are interested in the interactions of charges.


Javascript difference between uber and prototype

Question: I'm relatively new in javaScript and I was doing some inheritance. I thought I know what prototype is but then i met with uber method. Now I don't know the difference between those two.
I know that uber is like super in java and that's all. But then prototype is something that bothers me.
If you can give me some simple example of using those two I would appreciate it very.
Comment: As far as I am aware, there is no `uber` method in JavaScript unless you're using a library which adds this method to objects. Are you using a library by any chance?
Comment: I've added an answer about the `uber` method Douglas Crockford uses in his inheritance tutorials assuming that you meant this. It seems to be the most popular example. Where exactly did you discover `uber`?
Comment: Well I'm using one. It might be defined in it. But still I don't know the difference assuimng I know what uber is. It's just a pointer to a parent's object
Comment: I'm not sure Crockford is the best way to learn prototype as I've never seen him implement "classical inheritance" correctly. The following answer covers constructor functions and prototype: http://stackoverflow.com/a/16063711/1641941 hope it helps
Answer: uber is just a sugar method Douglas Crockford created in his examples of inheritance in JavaScript which should help the devoloper when working with the very, very flexible nature of JavaScripts prototypal inheritance.
This method doesn't exist in native JavaScript.
He explains the sugar methods he uses in detail here.

In his examples he defines the uber method as a helper method to access the parent implementation of a method.
Let's assume that you have a "class" (I use this term to ease the example; strictly spoken there are no classes in JavaScript) Human which has a walk method. If you now "extend" this class in an Infant class, you could overwrite walk in such a way that the infant only crawls since it can't walk.
It's obviously not a great example but I hope you get the point.
In such a case you could use Douglas Crockfords uber method to access the Human implementation of walk in the Infant "class".

To compare JavaScripts native prototype object and Douglas Crockfords uber method would make no sense, since both serve completly different purposes.
If you want more information on JavaScripts prototype you can take a look at this question.


allowing a user of sharepoint on a subsite but not to the main site

Question: I have a SharePoint site dedicated to a department. This department site has a branch that needs a couple other users that are not in the department to access information in a sub site. How can I set up permissions in a way that the couple users can access the sub site, but not the main site?
Answer: First you need to Stop Inheriting Permissions on SubSite and then create Groups with unique permissions Put your external users in SubSite Viewer.
here is an outline to show you what I meant.
Answer: By default, all SharePoint sites inherit its permissions from its parent site.So in your scenario, you just need to

Stop inheritance, by going to Site Setting > Site permission > From the above ribbon, > Click on Stop inheriting permission.

Now you can manage the permission for this site uniquely.
So Create a group with the proper permission then add the users that you need to access the subsite.
Grant, this group to access subsite.
Answer: If you want a completely different set of permissions for http://XXXXXXX/depts/safety than you do for http://moss (and for that matter, http://XXXXXXX/depts/finance), set them up as site collections, with /depts as a wildcard inclusion managed path. That will allow you to keep navigation intact, but have completely different permissions (and site collection administrators) for each department site.
The alternative would be breaking inheritence and creating groups with permissions on the subsite that are not present on the root.
Answer: I like Melad's answer, though I add the following:

The new users will need to be given a url for the subsite, as they won't be able to browse to it from the parent site. (because of this difficulty, perhaps consider a different site structure)
The groups on the parent site can also be given permission on the subsite. So, the parent site would have topsite owners, members, and visitors. The sub site would have topsite owners, members, and visitors, and also sub site owners, members, and visitors. Then, add the new users to the appropriate sub site group. This arrangement would give "normal" users the same permissions on the subsite as the parent site, while giving those new users only permission to the subsite.


What is the "Count" column in the order book on Bitfinex?

Question:
I can't understand what count means here. I would have assumed that it was the number of orders at that price, but the total column does not seem to reflect this. Can't find any info in the documentation or glossary. Thanks
Comment: Count refers to the total numbers of orders. 1 means only one order at that price level, 15 would mean there are 15 orders at that price level.
Answer: It's because the Total column is not the cumulate sum of the column Count but of the column Amount. In your example, at the line for price 1612, Total=6.0 and indeed if you do the sum of all amount of the price above 1612 it gives you : 0.3+1.2+1.7+2.8 = 6
Answer: Count:
This is the total number of orders at that level. A count of 1 means that 1 order is at that price point. A count of 6 would mean that there are 6 orders at that price point.
From https://support.bitfinex.com/hc/en-us/articles/115003284889-Order-Book-Terms


Use 5V signal to power 12V relay

Question: I have a Corvette that keeps having the blower control module go bad, probably because the car is over 30 years old.  This module is no longer available and hard to find. This module also controls the AC compressor.  My problem is that I want to bypass this module and come up with my own relay. The AC module uses a 5V signal from the control panel inside the car. Is a reliable relay that I could use that is triggered by 5VDC but allows a 12VDC output to the AC compressor?
Pardon my ignorance on this I'm much better at the mechanical side. If I need a buffer relay is that something similar to a diode that won't let it damage the controller? I'm looking at this, could someone tell me if this is  good option ? CG Solid State Relay SSR-25DD DC to DC Input 3-32VDC To Output 5-240VDC 25A Single Phase Plastic Cover
Comment: @justin: It is **very** common for the coil voltage to be different from the contact voltage on a relay.  Relays with a 5V coil can be driven by a 5V signal.  There are loads of relays with 5V coils and 12V contacts.  The real questions are:  Do you know how much current the 5V output can deliver? Do you know how much current the AC needs?  The current ratings are very important.
Comment: Hundreds of them. Have you tried searching on DigiKey? I find 1224 to choose from: https://www.digikey.com/en/products/filter/power-relays-over-2-amps/188?s=N4IgjCBcoOwExVAYygMwIYBsDOBTANCAPZQDaIccAHFXAJwiFwAMVMAbDIyACwCsMNu25wedPlT4ixE4QF1CABwAuUEAGVlAJwCWAOwDmIAL6mgA
Comment: For a compressor you want the biggest current rating greater than steady Amp rating to handle turn off arcs, pref with a large diode clamp to Vbat. e.g. 3x
Comment: I'm not sure on current or how to even find it, the circuit board has a ac signal that switches 5vdc on and off, I imagine I need something fairly heavy duty to control the ac compressor coil, the fuse that ultimately runs the ac compressor is a 25 amp
Comment: Pick a relay that has a buffer, driving a relay directly with a 5V signal can possibly blow the controller. With out more information this is the path I would try. There are many available for Arduinos, There are some nice solid state opto coupled ones that would work nicely and do not require a coil voltage supply.
Comment: Do you have the wiring diagram or better yet a service manual with the schematic or diagnosis section of this part? That would help greatly in helping you.
Answer: You should ignore the 5V signal from the control panel (which could indeed be something like a PWM, current loop or even bus signal) and instead measure the voltage out from the module, because that's what matters. Lets assume it is 12V.
The first thing I'd try here would be to use a rugged transient voltage suppressor (TVS) diode. Pick one with voltage margins above the expected nominal voltage. So if you have 12V nominal like a car battery, that might in reality go up towards 15V somewhere when charged. The purpose of the TVS is to kill any spikes above that voltage, so you would pick one rated around 18V to 20V somewhere - the exact voltage isn't critical. Automotive grade usually means >1600W "peak pulse power", so pick one rated for that as well.
The diode should be mounted so that the anode sits on the output from the module towards the compressor and the cathode against ground. This will protect both against reverse EMF from the coil as well as generic electrical noise from whatever other sources that might be causing it. Also these are no doubt dirt cheap ($1-2 or so) in comparison to replacing the module, but you might need to solder it in place.
Adding a TVS also won't affect the existing electronics design, it will just add extra protection (that should have been built-in in that AC module to begin with). So the worst thing that could happen is that it does nothing.
The reason why you probably can't use a relay is because relays only work with pure digital on/off voltages. All proportional signals that correspond to a certain level, like the position of a knob, are not on/off. They'll be modulated somehow. In case you aren't certain if the signal is on/off or proportional, you can't really measure it with a multimeter either - you'd have to use an oscilloscope.
But in case you know for sure that you have a 5VDC signal, then it could probably be used to drive a 5DVC coil relay indeed. Though in case of relays, you should still add a diode across the coil (anode against coil+, cathode against coil-) similar to the TVS proposed above - this is known as a flyback or freewheel diode, where flyback/freewheel refers to the purpose of the diode rather than the type.
Comment: Without a schematic or knowing what the relay is I would assume it is a logic type signal and connecting an inductive load would destroy it. If it has PWM that would be one of the earlier days. Many cars used series resistors to control the blower. I also know automotive compressors in that time frame could not tolerate a PWM, that would cause the clutch to slip and fry. If I am correct a solid state relay will work just be sure to size it for at least 100V and maybe double the current or more. Reason I believe that vehicle has a 80V load dump specification.
Answer:
The AC module uses a 5V signal from the control panel inside the car.

The 5V signal probably uses PWM (Pulse Width Modulation), which is a fancy way of saying that it turns the blower motor on and off rapidly to control its speed. If you operate a mechanical relay with this signal it will buzz at the PWM frequency and wear its contacts out quickly. The signal might also not provide enough current to operate a relay with a 5 V coil.
A DC solid state relay may work provided that the 5V signal has enough current to operate it. However most solid state relays are not designed for PWM either, so the fast on/off switching may burn it out - and good ones aren't cheap. If you decide to try this, make sure that the motor has a diode across it to recirculate the 'back-emf' generated, otherwise it could blow up the relay.
If you want to continue using the variable speed control then you really should replace the control module with another compatible one, or get the original repaired. Alternatively you could replace it with a multi-position switch and resistor module, as is used in simpler air conditioning systems. however this will also bypass any automatic blower speed control.

Use 5V signal to power 12V relay


Difference between Managed and UnManaged Solution in CRM 5.0 (2011)?

Question: I am wondering what is the Difference between Managed Solution and UnManaged Solution in CRM 5.0 (2011)?
Answer: Unmanaged solution: Essentially the same as 4.0. As soon as someone imports an unmanaged solution into an organization, it becomes an integrated part of the organization and can only be removed by manually removing all parts of the solution. The components of it can be freely edited, changed, and removed.
Managed solution: Managed solutions can be locked down by the creators to not allow or allow editing of forms, adding new forms, changing display names, etc. A managed solution can be easily removed by just deleting the solution, and all components (that aren't needed for another solution) will be removed.
Answer: Unmanned Solution**:That solution we are edit update Unmanaged solutions are groups of unmanaged customizations. Any unmanaged customized solution component can be associated with any number of unmanaged solutions.
You create a managed solution by exporting an unmanaged solution and selecting to package it as a managed solution.
Manged Solutions:A managed solution is a completed solution that is intended to be distributed and installed.we cant modify and customizations that solutions.
Answer: Also,
an UnManaged solution has no restrictions on what can be customized, and when you make changes to the system through an UnManaged solution the changes remain behind.
Managed solution all customizations are lost when it is deleted. So there is the potential for data loss in that event.


Debugging a version of Qt Creator and plugins all built from source

Question: My goal is to be working on / debugging qt creator plugins and, maybe, editing / debugging qt creator source code. Towards this end I've tried a couple of things:

Downloading source for the qt sdk and qt creator, compiling each, and then making a qt creator plugin project and hooking everything together by hand. This got complicated pretty quickly (I tried to keep my plugin project outside the qt-creator/src/plugin/ folder) and doesn't really get me to a nice spot in terms of debugging.
Using an installed version of the qt creator to open the qtcreator.pro that came along with the source, adding a qt creator plugin as a sub project, and building everything from the already installed version of qt creator.

I like the second approach a lot because I have control over everything but I can rely on qt creators tools that make projects, enhance debugging, etc. There's just one small problem...
When I run my shiny new build of qt creator (with my plugin project) from inside the installed version all I get is a popup called "qtcreator_process_stub" that says "This is an internal helper of Qt Creator. Do not run it manually. Press  to close this window..."
So I'm not really sure how to debug my build of qt creator from my instance of qt creator. Any ideas? Note: if I run the generated Qt Creator.app I get a functioning instance of qt creator with my plugin loaded properly.
Answer: I believe this was a versioning problem. I had an older version of the ide installed and was using it to build and debug a newer version of the ide.
I was able, in the older ide, to launch and debug the new ide as an external process through the debug menu... but that was mildly annoying.
Once I installed a new version of the ide I was able to debug like normal.


Temporary message block

Question: My question is this: is there a way to temporarily block messages from a single contact and receive the messages later? If a contact is placed on the blocked list, the messages are no longer received; but they will stay so and not appear at a later time. If the contact is placed on do not disturb, there is simply no notification and the texts are still received. If the phone is put into Airplane Mode and is not connected to wi-fi, no messages are received at all. Is there a middle way between these two where the contact messages are blocked for the current time being and received later?
Answer: Not really. You can schedule do not disturb but not schedule a change of a contact from favorite to not favorite, so that option blocks all non-favorites on a temporary basis.

Temporary message block


Need help with my Smart Bin Project

Question: Hi I'm doing an individual project based on a Smart Bin,
My main objective for this project is to prevent bins from overflowing,to detect if bins are nearly full by using an Infrared distance sensor and to alert a person (sending a text message) if bins are almost full while tracking its location.
The equipment that I'm using for this project is a raspberry pi (base), GSM Module: Huawei E220 (sending text message to your phone), GPS Module: RPI Customized GPS Add-On V2.0 Module For Raspberry Pi (Track the location of the bin) and an Infrared Distance Sensor (detecting if the bin is nearly full), The infrared distance sensor has an analog output so I'm using a Analog to digital converter - MCP3002
I have connect the GSM Module to the Pi, the GPS Module to the Pi, I was suppose connect the analog to digital converter and the Infrared Distance Sensor to the breadboard by following this link:http://raspberry.io/projects/view/reading-from-a-mcp3002-analog-to-digital-converter/#step1
Through this link I have to substitute the potentiometer in the example for the Infrared Distance Sensor but the problem is I can't connect the Infrared Distance Sensor to the Breadboard because of the end the three cables wire, my question is how do I connect the Infrared Distance Sensor to the breadboard?
This is what I've done for my project so far through these images
Comment: Welcome to the site Richard. Unfortunately your question ('How do I attach pins to wires?') is non-Pi specific and as such is [off topic here](https://raspberrypi.stackexchange.com/help/on-topic). You might get some mileage from the [Electrical Engineering board](https://electronics.stackexchange.com/search?q=header+pins+wire), which has several hundred questions on header pins and wires.
Answer: The proper solution is to buy male Dupont pins and crimp them to the wires of your sensor:

Alternatively, you can attach/solder your sensor to a suitable connector (or three separate jumper wires) which you can then plug into the breadboard.
Comment: does this link http://www.instructables.com/id/Fitting-Dupont-Connectors/ explains how to do it, for me I'm just a beginner is it possible to get someone to do it for me e.g. at a store
Comment: Are these are the ones that I should buy from the store https://littlebirdelectronics.com.au/products/0-1-2-54mm-crimp-connector-housing-1x1-pin-25-pack
Comment: @Richard Yep, that link looks OK (I wouldn't cut the insulation in a conical shape, nor I would solder the crimped wires, just cut straight and crimp). 3 pins could be fitted in a reasonable time without the crimping tool (using pliers), but for beginners it is highly recommended to get the right tool which is much easier to use. Another tool which helps a lot is insulation remover (wire stripper), but again, 3 wires could be stripped with a small knife after some practice.

Need help with my Smart Bin Project


What is the nature of perturbation theory in QFT?

Question: In the perturbation theory approach to QFT, the total Hamiltonian $H$ is separated into a free part $H_0$ which we can solve exactly and another $H_{\rm int}$ which we cannot such that $$H=H_0+H_{\rm int}.$$
Is this a time-dependent perturbation theory like the one we are used to in ordinary quantum mechanics? I may have a few follow-up questions depending on the answer to this.
Comment: In lorentz invariant quantum field theories the hamiltonian cannot depend on time explicitly . Explicit time depends breaks poincare invariance. Perturbative explanation in QFT is analogous to time independent perturbation theory.
Comment: @Anonjohn But in my exposure to quantum mechanics so far, interaction picture is usually used only when the perturbing hamiltonian is time-dependent.
Comment: The perturbative expansion for physical observables is picture independent. Although some books present it in the interaction picture, the observables(green's functions) are all independent of the picture used. If you like, you can develop your perturbative expansion in the Heisenberg picture, which is standard in the derivation of the path integral. In the path integral quantization, it is manifest that the split into interaction and free hamiltonians in artificial and that the quadratic part of the Lagrangian is the "free" bit since Gaussian integrals are doable.
Comment: @Anonjohn there is a PT with Hamiltonian with explicit dependence on time, isn't it? Schwinger-Keldysh PT.
Comment: @ArtemAlexandrov. I am not on an expert on Schwinger - Keldysh formalism. But the fact remains that hamiltonians cannot contain explicit time dependance -break poincare symmetry is immediately manifest in observables. However, at finite temperature: which is where this formalism finds use(it appears), the time "coordinate" is an arbitrary choice.
Answer: It is rough answer withour rigorous mathematical construction. In QFT You always deal with integrals like
$$\int_{-\infty}^{+\infty}dx\exp\left(-m^2x^2-\lambda x^4+Jx\right)$$
and we unfortunately cannot calculate this type of integrals explicitly. Hopefully, part of Nature can be described with assumption that $\lambda$ is very small and we can perform expansion by $\lambda$. You can check first two chapters (may be paragraphs) of A. Zee "QFT in a nutshell" to see an anologue between calculation of simple 1D integrals with exp and non-quadratic terms and path integral in QFT. There is lot of criticism of path integral description of QFT but I believe that it is the most simple way to think about QFT.
Answer: The perturbation theory approach to QFT assumes the dynamics of a quantum field as determined by a Hamiltonian $H$ via the Heisenberg equations of motion
$i \partial_t \phi(x) = [\phi(x), H(t)]$
The formal solution is
$\phi(\vec x, t) = S(t, t_0)^\dagger \phi(\vec x, t_0) S(t, t_0)$
where $S(t, t_0)$ is the time-evolution operator that satisfies
$i \partial_t S(t, t_0) = S(t, t_0) H(t)$
and
$H(t) = S(t, t_0)^\dagger H(t_0) S(t, t_0)$
The first step in time-dependent perturbation theory is to write the Hamiltonian as
$H(t) = H_0 + V(t)$
where the time evolution by $H_0$ can be solved exactly and $V(t)$ is small. $H_0$ could be the free Hamiltonian which is time independent and $V$ some interaction, for instance a $\phi^3$, written as $V(t) = \int d^3 x \frac{g}{3!} \phi(\vec x, t)^3$. The time and spatial dependence of the perturbation potential is hidden in the fields.
Note that the operators $\phi(\vec x, t), H, H_0, V$ are in the Heisenberg picture, while $\phi(\vec x, t_0)$ is the Schroedinger picture field.
As second step we have to change to the interaction picture where the fields evolve with $H_0$ as
$\phi_0(\vec x, t) = exp(i H_0 (t-t_0)) \phi(\vec x, t_0) exp(-i H_0 (t-t_0))$
$\phi(\vec x, t) = U(t, t_0)^\dagger \phi_0(\vec x ,t) U(t, t_0)$
The operator $U(t, t_0) = exp(i H_0 (t-t_0)) S(t, t_0)$ relates the full Heisenberg picture fields to the free fields at the same time $t$ and obeys the differential equation
$i \partial_t U(t, t_0) = V_I(t) U(t, t_0)$
where $V_I$ is the original $V$ now in the interaction picture
The solution is
$U(t, t_0) = T\{exp(-i \int_{t_0}^t dt' V_I(t'))\}$
where $T\{\}$ is the time ordering operator.
This perturbation series is known as the Dyson series and is similar to the time-dependent perturbation theory in quantum mechanics.
Comment: "$H_0$ could be the free Hamiltonian which is time-independent" In your example both $H_0$ and $V$ are time-independent. So I am not sure why you are writing $V$ as $V(t)$.
Comment: @mithusengupta123. Time-independent in the Schroedinger picture, but the perturbation theory is firstly stated in the Heisenberg picture, and secondly in the interaction picture, where the operators are time-dependent.
Answer: Recalling that in QFT the fields are functions of space-time coordinates $x^\mu =(t, \mathbf x) $ in general the interaction part of the Hamiltonian density will depend on space and time positions.
One usually works in the so called Interaction Picture (somewhere between the Schrödinger and Heisenberg pictures) and in this picture the perturbative expansion often resembles more the series that come out of time independent perturbation theory in quantum mechanics.
Comment: Follow up questions are best submitted as new questions
Comment: Since fields depend on $x^\mu=(t,\vec{x})$ does not make the interaction term explicitly time-dependent. For example, in quantum mechanics, the fact that $H=H(p,x)$ and $x=x(t)$ and $p=p(t)$ does not make the hamiltonian time-dependent.
Comment: In quantum mechanics there is a special global time parameter $t$. In quantum field theory this is not the case: time is just the zeroth component of the four vector $x^\mu$ and will differ in different frames. There is no universal time
Comment: "There is no universal time." That does not make the Hamiltonian explicitly time-dependent. I think Anonjohn's first comment is reasonable.
Comment: I didn't say that it was explicitly time dependent. In fact my point is somewhat the revsere. You want the Lagrangian to be Lorentz invariant so it almost definitely does not depend explicitly on coordinates (unless you form invariant combinations thereof). When going to the Hamiltonian formalism one fixes a ref frame in order to define conjugate momenta as derivatives with respect to the temporal variation of the field. It's unlikely this will lead to explicit time dependence.
Comment: I agree with the comment you refer to, and I say in my answer that the perturbative expansion usually resembles the time independent PT
Comment: Then I misunderstood the first paragraph of the answer. It seemed to me that you are saying that $H$ is time-dependent.
Comment: Sorry if I gave you that impression; I was trying to point out that in fact the time and spatial dependence is "hidden" inside the fields - quite the contrary!!


Can the output of a probit regression with a Z-score predictor be interpreted as a standardised effect size?

Question: I want to obtain a standardised effect size for a regression with a binary outcome. If I standardise the (continuous) predictor and run a probit regression, the resulting coefficient can be interpreted as in the difference in Z-score outcome per one unit increase in the change in the Z-score predictor. Therefore, is this the same as a standardised regression coefficient?
Answer: I don't think you can interpret the coefficient of a probit model like that. For instance,  I think that your independent variable going from 1 to 2 is different than going from 2 to 3. You may want to read up on interpreting probit parameters. There's a good explanation here: https://stats.idre.ucla.edu/stata/output/probit-regression/


Schiller Stock Data

Question: I was analysing the data provided by Schiller (http://www.econ.yale.edu/~shiller/data.htm). On the first row (year 1871) the value for CPI index is 12.46. Anyone know the source of this value? I thought it was the accumulated CPI index, but i couldn't get this value.Schiller dataset
Answer: The answer is in the link you posted... (emphasis mine)

The CPI-U (Consumer Price Index-All Urban Consumers) published by the U.S. Bureau of Labor Statistics begins in 1913; for years before 1913 1 spliced to the CPI Warren and Pearson's price index, by multiplying it by the ratio of the indexes in January 1913. December 1999 and January 2000 values for the CPI-Uare extrapolated. See George F. Warren and Frank A. Pearson, Gold and Prices (New York: John Wiley and Sons, 1935). Data are from their Table 1, pp. 11–14.

Schiller Stock Data


What is the best word processor to use with Elementary OS?

Question: I am still deciding which Linux distro to download on my new laptop. One of the things I do on the laptop is writing. Is there a good but free word processor to use with this OS?
Thanks!
Answer: That's an opinion based question so you're so to get a lot of different responses. I personally us LibreOffice Writer.
Answer: I used Softmaker FreeOffice for quite some time, but it was quite laggy when backspacing a lot of text, typing and doing very basic tasks, really. And I have a powerful hardware, so it was not my fault.
I then moved to OnlyOffice, quite good even if not perfect: it does not integrate well with the rest of the OS and had a bare bone selection of fonts.
Answer: I can use any office application like MS Office, LibreOffice, Google Suite and other.
But favourite is LibreOffice  Writer, Google Doc and Sheet.
Answer: I myself am a writer and I prefer WPS Office: Homepage
Answer: I personally use microsoft office 2007 on crossover linux or wps office 2016


Kinetic energy in circular motion

Question: Suppose i have a point mass which is moving in a circular path.Since the point mass can only have transnational motion, kinetic energy due to it will be $\frac{ mv^²}{2}$. But what  if i observe the motion from the centre of circle, I can write it's kinetic energy as $\frac{I\omega^²}{2}$ which is also equal to $\frac{mv^²}{2}$.Why don't we add these two kinetic energies?
Answer:
Suppose i have a point mass which is moving in a circular path

Let the mass of the particle be $m$
If we see this particle from a frame of reference located not at the centre of the circle but say somewhere else from where the motion appears to be only translational.
And the velocity of the body with respect to this inertial frame(another assumption) is $\vec{v}$
Then its kinetic energy is $\frac{1}{2}mv^2$
$\because$ The velocity of a body is a frame dependent quantity. We can say that if we change our frame of reference then the velocity of the mass $m$ will also change.
Lets look at the particle from a stationary frame at the centre of the circle.
From this point of view the particle appears to be going around a circle with say some angular velocity $\vec{\omega}$
So from this frame the particle's new velocity($\vec{v_1}$) should be $\vec{r} * \vec{\omega}$ where $\vec{r}$ is the position of the particle with respect to the centre.
So from this frame the particle's kinetic energy will be
$\frac{1}{2}I\omega^2 = \frac{1}{2}mr^2(\frac{v_1}{r})^2 = \frac{1}{2}mv_1^2$
So as you can see the Kinetic energy is different for both the frames
Answer: Point mass in circular path is translational and kinetic energy is
$\frac{mv^2}{2}$
Though, you can write it in terms of its moment of inertia and angular speed as $\frac{I{\omega}^2}{2}$. But the two expressions do not represent kinetic energies of two different motions. They are one and same so don't add them, either you look from center or from somewhere else.
(Note:There is no difference in the frames unless the center and the somewhere else frames are moving relative to each other.)
You can add rotational and translational kinetic energies in case of rigid bodies. A rigid body, say, a stone has both rotational and translational when it is

(1)rotating about a fixed axis passing through it: rotational, while at the same time
(2)the whole body is moving from one place to another: translational.
Note the two different types of motions.
Then, the total kinetic energy will be rotational + translational. Rotational kinetic energy will be in terms of the moment of inertia and angular speed because of its rotation and translational kinetic energy will be in terms of its mass and velocity of its center of mass.

Kinetic energy in circular motion


Printing does not work from my Raspberry Pi 4 and Cups 2.2.10

Question: Anyone knows what could be the problem with Cups setup with my RPi 4 and laser printer? What could I do next? I want to be able to print from my laser printer from my phones, multiple computers and I don't want to bring my laptop to the printer. I want to print it via Wi-Fi, using my RPi4.
These are components I'm using:

Cups 2.2.10
HP LaserJet Professional P1102
Raspberry Pi 4 Model B, 2GB

WHAT I DID:

I have installed Cups onto my RPi4 following these instructions:
https://www.howtogeek.com/169679/how-to-add-a-printer-to-your-raspberry-pi-or-other-linux-computer/
I've "Add Printer" on the CUPS 2.2.10 Administration panel
suitable drivers were not found, so I have installed sudo apt-get install printer-driiver-splix and then also sudo apt install hplip and then "HP LaserJet Professional P1102" drivers appeared
I have rebooted RPi multiple times between these steps
I tried both Local Printers appeared in the list. 1st: HP LaserJet Professional P1102 USB 000000000Q86SW5NSI1c HPLIP (HP LaserJet Professional P1102)
Also tried another option HP LaserJet Professional P1102 (HP LaserJet Professional P1102)
both times I was able to select HP LaserJet Professional p1102, hpcups 3.18.12, requires proprietary plugin (en) driver. Using Developer Inspection tool, I was able to see the PPD file name which is being selected: hplip:0/ppd/hplip/HP/hp-laserjet_professional_p1102.ppd (worth mentioning, that there were multiple options like that in the list)
then I used VNC to connect to the RPi 4 and tried printing from the RPi locally and then the following failure happened:

When diagnosing with Printing troubleshooter, this is the error listed below:

"Printer 'HP_LaserJet_Professional_P1102':
'hplip.plugin'

See screenshot below

Then going further with troubleshooting, I have used following command to Retrieve Journal Entries:

su -c 'journalctl -u cups.service --since="None" --until="2020-04-15 21:21:46"' > troubleshoot-logs.txt

And then all logs I've retrieved multiple times are seen here: https://drive.google.com/drive/folders/1Jj_g-S5_586j1KfRBs-dorZ4eqTozAGm
It seems like it's a deadlock now. Anyone has any suggestion how to move forward?  I want to be able to print from my laser printer from my phones, multiple computers and I don't want to bring my laptop to the printer. I want to print it via Wi-Fi, using my RPi4.
Any help is appreciated. Thanks in advance
Answer: I had similar problem today. To fix it I ran:
sudo hp-plugin

One must be connected to the Internet to do this. Now I am able to print.
resource is here.


I killed Sinding and got his skin. Is there anyway I can get the Ring Of Hircine again?

Question: I did the quest to get the ring of Hircine but I thought I was meant to kill Sinding. Now I have completed the quest and only have his skin. Is there any way that I can re-do the quest or go on another quest to get the ring again?
Answer: No, all quest rewards are final. However, you can use the console to give yourself the ring, if you're playing on PC. The code is player.additem 2ac60 1
Answer: Nope, not without using console.  However, if you have an old save-file, it is possible to get both daedric artifacts available in that mission - you help Sinding out, get the reward, then go back and kill him.
Answer: For your question, If you got the skin first, you can't get the ring afterwards.
However, there are some instances where you can exploit a glitch to get more than what was intended.
If you (somehow) are able to load an old save before the start of the mission, you can get the ring first, then at the end of the mission, you can get the skin (from my previous answer):

Sometimes, the game glitches out and upon completion of the quest (when trying for the ring) Sinding will reappear in the cell you first found him, in werewolf form. Killing him will relent the Savior's Hide. (this is tricky through the bars of the cell, but with timing and a save beforehand, you should prevail)
Answer: If you load a save you should be able to redo the mission however you will lose some progress.
I've done this previously and it worked.
Answer: YES THERE IS A WAY! Skip to 6:25
Comment: If you write up the information at 6:25-9:00 and add it to your answer, it will be a lot more useful to future visitors (and as an added bonus, is more likely to receive upvotes). It is much easier for someone to spend a few seconds reading the answer compared to watching a few minutes of a YouTube video. Furthermore, your answer risks becoming useless if that Youtube link ever goes bad.


How much does extension bar reduce torque wrench accuracy?

Question: I have been told not to use extension bar when torqing to spec because it allegedly compromises the accuracy thereof. However, reality is such that some bolts are so inconveniently set that it is impossible to reach them without an extension bar. My question is, in such cases, how much does extension bar reduce torque wrench accuracy, if any?
Answer: There is no escaping the fact using an extension will reduce the accuracy of your torque. In this case, what you have to do is mitigate the inaccuracy as much as possible. The way you do this is by ensuring the head of the torque wrench pivots at the point directly in line with the fastener you are trying to torque. To do this, place your hand on the head of the wrench and prevent it from moving except to provide the twisting motion as would be normal. If you were to look straight down at the head of the torque wrench, the socket should be directly under it.  Unless you are using some sort of automated torquing device, you will never have 100% accuracy no matter how you are applying torque. There will always be variance between fasteners. You just want to make sure you do the best you can to ensure the torque applied is as uniform as possible.
The largest inaccuracy while using an extension comes from if the extension causes an angle to form between the head of the torque wrench and the head of the fastener.  A secondary inaccuracy comes from the twisting force which occurs on the extension itself. You can't negate it, so sometimes you just have to deal with it.
Something to remember about torque force applied to a fastener is that it isn't all about the amount of force, but about equal force between the fasteners. This is so  the force applied on whatever you are fastening is applied equally. As an example, when torquing a head, you want the force applied equally across the head so you minimize the chance the head will warp. Obviously, you want the force applied to be tight enough so it won't  have issues, but hopefully it makes sense. When applying torque to the fasteners, it really isn't the torque which is needed, but rather you want a certain amount of stretch on the fasteners. This stretch provides the clamping force which holds the object in place. The torque we apply is the way we judge the amount of stretch.
Answer: Using any extension requires attention to details when torque is applied. As long as the extension is directly inline/perpendicular along the fastener axis and a hand placed to counteract the applied torque trying to move the torque wrench away from being directly in line with the fastener, all torque is xmitted to the fastener. Not holding the torque wrench at the point of rotation will create vector forces reducing torque values as its distributed away from the fastener. Using an extension is a two handed procedure; one on the handle applying force, the other hand preventing the torque wrench from moving away from having the extension move sideways. This may not be well known when unfamiliar with torque wrench use.
Comment: Having to use an extension implies that one likely lacks the space to hold the fastener with the other hand?
Comment: The image shown shows clearance for a hand to brace the wrench head against dispersing torque in more than one vector. Even if a hand cannot used, any brace will do as long as the wrench head remains directly inline with extension to fastener. Any sideways forces created while torqueing is unwanted and reduces torque.


Mail Merge in Microsoft Word with images from Sharepoint

Question: Is there any way of doing a Mail Merge in Microsoft Word 2007 taking data, including images from a Sharepoint site? It's a bit crude, but I've managed to merge text by taking the data off the sharepoint site as an Excel sheet and then merging that. My problem is what to do with the images. I can set references to the images up in the Sharepoint site, however all I can find is a way of Mail Merging when images are in the same folder as the document you are trying to Merge and I can't find a sensible automated way to pulls these images together into one single folder.
Answer: Short answer: no. Office mail merge does not support HTTP connections.
Accept this and use a file share.


Powershell script cannot get applications list data from windows 7 machine

Question: Recently, I made a script to list all the installed applications in local & remote machine & give the output in a structured manner in an excelsheet.
It looks like this:
$a = Read-Host "Enter machine name" | Out-File -filepath C:\machine.txt
$computerName = Get-Content C:\machine.txt
$a = New-Object -comobject Excel.Application
$a.visible = $True

$b = $a.Workbooks.Add()
$c = $b.Worksheets.Item(1)

$c.Cells.Item(1,1) = "Name"
$c.Cells.Item(1,2) = "Publisher"
$c.Cells.Item(1,3) = "InstalledDate"
$c.Cells.Item(1,4) = "Version"
$c.Cells.Item(1,5) = "UninstallString"

$d = $c.UsedRange
$d.Interior.ColorIndex = 19
$d.Font.ColorIndex = 11
$d.Font.Bold = $True

$i = 2
function Get-InstalledAppReg ([string]$ComputerName) {

  $RegPath = "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall"
  $BaseKey = [Microsoft.Win32.RegistryKey]::OpenRemoteBaseKey("LocalMachine", $ComputerName)
  $OpenSubKey = $BaseKey.OpenSubKey($RegPath)
$i =2
  $OpenSubKey.GetSubKeyNames() | ForEach {
    $Path = "$RegPath\$_"
    $BaseKey.OpenSubKey($Path).GetValue("DisplayName")
      $BaseKey.OpenSubKey($Path).GetValue("Publisher")
      $BaseKey.OpenSubKey($Path).GetValue("InstalledDate")
      $BaseKey.OpenSubKey($Path).GetValue("Version")
      $BaseKey.OpenSubKey($Path).GetValue("UninstallString")
$c.Cells.Item($i,1) = $BaseKey.OpenSubKey($Path).GetValue("DisplayName")
$c.Cells.Item($i,2) = $BaseKey.OpenSubKey($Path).GetValue("Publisher")
$c.Cells.Item($i,3) = $BaseKey.OpenSubKey($Path).GetValue("InstalledDate")
$c.Cells.Item($i,4) = $BaseKey.OpenSubKey($Path).GetValue("Version")
$c.Cells.Item($i,5) = $BaseKey.OpenSubKey($Path).GetValue("UninstallString")
$i ++
  }
}
Get-InstalledAppReg($computerName)

$d.EntireColumn.AutoFit()
$b.SaveAs("c:\softhive.xlsx")
$b.Close()
$a.Quit()
Get-Process | Where { $_.Name -Eq "Excel" } | Kill

This script ran perfectly for all remote machines which has XP as a OS.
Problem started when I started running it in windows & machines remotely.
Initially it gave wrong path error, when I realized that for windows 7, I probably have to use
"SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall" instead of
"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall".
With this different path, when I run the same script again, I get an error:
Exception calling "OpenRemoteBaseKey" with "2" argument(s): "The network path was not found.
"
At :line:24 char:62

$BaseKey = [Microsoft.Win32.RegistryKey]::OpenRemoteBaseKey( <<<< "LocalMachine", $ComputerName)

Probably, I need to change other things too in the script?
My machine, from where I run the script, is a windows XP SP3 machine.
Answer: Unfortunately the WMI Win32_Product class does not report all apps found in Control Panel's "Add or Remove Programs"...
The registry walk seems to be unavoidable, see:
http://powergui.org/thread.jspa?threadID=17068
http://learningpcs.blogspot.fr/2011/10/powershell-get-installed-software.html
Answer: Rather than comb the registry, I would use WMI for this.  See Win32_Product and friends e.g.:
Get-WmiObject Win32_Product

Note that if I run this on my Windows 7 x64 system in a 64bit PowerShell prompt it shows all installed apps (32-bit and 64-bit):
Get-WmiObject Win32_Product| sort Vendor | Format-Table Name,InstallDate,Vendor

To see all the properties available execute:
Get-WmiObject Win32_Product | Select -First 1 | Format-List *

Answer: I remember a while back I did something like this at an IT firm and we simply searched the C: directory for the names of all programs ending in .exe, in order to optimize we would hone in on specific apps that we were looking for. We set up a batch that would pass or fail based on if what we wanted. Keep in mind this is a batch file, however the idea is similar.
echo ================= >>Software_Scan.txt
echo Below is a list of all wireless networks. Saved networks will be found in the Wireless Profiles folder
set filePath=
for /R "C:\Program Files (x86)" /D %%a in (*) do if exist "%%a\YahooMessenger.exe" set filePath=%%a& goto continue
:continue
if defined filePath echo %COMPUTERNAME% FAIL Yahoo Messenger >> Software_Scan.txt
if NOT defined filePath echo %COMPUTERNAME% PASS Yahoo Messenger >> Software_Scan.txt


can I use the function CreateProcess inside process that compiled with x64 for calling process that compiled with x32?

Question: Or I need to compile the x32 process into x64 process and then only to use CreateProcess.
Answer: Yes there is no problem creating a process that is x86 using CreateProcess even know your application is running as x64.  Both processes have their own user space and own separate processes.


How do I get more locations?

Question: I am trying to get some locations in New York using FourSquare API using the following API call:

https://api.foursquare.com/v2/venues/search?ll=40.7,-74&limit=50

What I don't understand is that if the call imposes a limit of 50 search results (which is the maximum), how can I get more locations? When using Facebook API, the results being returned were random so I could issue multiple calls to get more results but FourSquare seems to be returning the same result set. Is there a good way to get more locations?
EDIT:
Ok. So there was a comment saying that I could be breaking a contractual agreement and I am not sure why this would be the case. I would gladly accept a reasoning for this. My doubt is this: Let us say that hypothetically, the location I am searching for is not in the 50 results returned? In that case, shouldn't there be a pagination mechanism somewhere?
Answer: The API docs here can help.
Foursquare searching is very closely linked to the location 'point' (the 'll' param on the query) that you provide. The simple answer is that to find more venues within a given area, you need to simply query again with a different location 'point' within that area.
Two queries, both at points close to one another:
https://api.foursquare.com/v2/venues/search?ll=40.700,-74.000&limit=50
https://api.foursquare.com/v2/venues/search?ll=40.705,-74.005&limit=50

will get you two different sets of venues (that may overlap, depending on how close the points are).
The default intent for the search method is 'checkin', which will return the 50 most popular locations closest to that point. If instead you want to look at all the venues within an area, you can use the 'browse' intent. This takes either a 'radius' parameter, in which case it returns venues inside a circle around the given point with the given radius, or it takes two coordinates representing the 'sw' and 'ne' corners of a rectangle. So, you could do:
https://api.foursquare.com/v2/venues/search?ll=40.705,-74.005&limit=50&intent=browse&radius=50

which will give you 50 venues within the 50m circle around that point. A smaller radius will reduce the number of venues returned. So, by varying the radius and the point at which you search (or the size and position of the rectangle described by the 'sw' and 'ne' parameters), you can get more venues returned.
Hope that helps.
Comment: +1 Somehow I forgot about this question. This is exactly what I did to get around the limitation. Thank you so much for sharing the idea!
Answer: The current API limits results to 50. You should try altering your coordinates to be more precise to avoid not finding your venue.
Pagination would be nice but 50 is a lot of venues for a search.

How do I get more locations?


Windows service on server wont run without a user logged in

Question: I created a windows service that's basically a file watcher that wont run unless a user is logged into the machine its on.  The service is running on a Windows Server 2003 machine.  It is designed to move the files that are put into one directory into a different directory based on keywords in the file names, but none of the files move until i log on, then all the files move at once.
Comment: I second @Jay S's questions below - also, any errors in the event log?
Comment: The service could be running before you login. How long did you wait? What about permissions? Does the service have access to the resources it needs without a user being logged in?
Comment: What do you mean it won't run?  Does it crash, or does it run, but not cdo what you expect (copy the files) until you log on?
Answer: You probably have to set the service to log on as a spesific user, try going into services, doubleclick the service and select "log in as account", and then provide your account details (domain\username and password).
The LocalService account has extensive rights, but may lack the rights to spesific users files/folders for instance.  You could alternatively try to grant file rights to the LocalService account spesifically.  I would however try the "log in as" trick first, as it's a 1 minute job.  If it works you could create a spesific account to run the service as, alternatively grant rights to LocalSystem.
Btw: If it's networked files you might try the NetworkedService account.
Answer: There has to be some setup problem with your service. Windows Server doesn't have a problem running applications without a user logged in (otherwise, scheduled tasks would be a lot less useful).
How did you install the service?
Answer: A few clarifications are required:

You mentioned

a file watcher that wont run unless a user is logged into the machine its on

How has this been implemented? Generally, services are automatically started when the machine boots because each windows service runs under a different windows station, with an independent security context

You also mention

but none of the files move until i log on

Is this not contradicting the first point, since this is what it has been implemented to do? [Am assuming the above point has been implemented]

Is the service configured to run under a special account?
Has the server been configured to require special rights to move files on the FileSystem?


Anomalous Expansion Of Water

Question: How can the Anomalous Expansion of Water from 4$^\circ$C to 0$^\circ$C be explained with reference to subatomic particles?
Comment: Similar question: http://physics.stackexchange.com/q/29277/
Answer: I don't think there's a good general explanation of this; the best I can do is give a few hand waving arguments.
If you look at hydrogen sulphide, which the analogue of water moving one row down in the periodic table, you'll find it does shrink when it freezes, just like most other liquids. So the difference between the H$_2$S and H$_2$O molecules must be responsible for the anomalous behaviour of water.
The most obvious difference between the two molecules is the the H-O bond is highly polar and has a strong electric dipole associated with it. This means it interacts strongly with other H-O bonds; the interaction is known as hydrogen bonding. Hydrogen bonds are highly directional, as you'd expect for an electric dipole, so the water molecules can be fitted together in ice any old how. They adopt well defined positions relative to each other, and the directionality of the bonds forces the water molecules into a relatively low density arrangement.
It's interesting to note that the high pressure forms of ice are generally denser than water. Presumably at high pressure the reduction in energy by the denser arrangement outweighs the reduction in the strength of the hydrogen bonds.
Comment: Above 4°C the hydrogen bonds are being continually broken and remade by the motion of the water molecules so there are no hexagonal structures. Below 4°C the molecular motion is too slow to completely disrupt the hydrogen bonds so you start getting temporary structures forming, including the hexagonal rings. If you supercool the water it becomes more structured and less dense, though still not as structured as ice. The solid ice grows by nucleatuon of an ice crystal and attachment of water molecules to the surface of the solid, so hexagonal rings in the liquid don't correspond to the ...
Comment: Do you mean the way the water molecules in ice form hexagons? If so then yes, the hexagonal structure is a consequence of the directional hydrogen bonds.
Comment: Has it nothing to do with the closed loop structure of attachment of the water molecules?
Comment: Yes, that's what I mean. So do the hexagons become immobile for some reason, due to which further compression ceases to occur?
Comment: hexagonal rings in the solid. I mean a ring of six water molecules doesn't all freeze at once.
Comment: I think you mean "can't"

Anomalous Expansion Of Water


The age difference between Bruce Wayne and Alfred?

Question: In general, comics, series and movies. What's the age difference between Bruce Wayne and Alfred?
Answer: In the comics, the answer is "complicated".
In the early comics (the Earth-One and Earth-Two versions) Alfred was roughly the same age as Bruce Wayne: Alfred's father had been Thomas Wayne's butler. He only introduced himself to Bruce after his own father had died and asked Alfred to carry on his legacy as the Wayne's butler. By the time Bruce met Alfred, he was already Batman.
In later comics (starting with the New Earth version), Alfred had been the Wayne's butler for all of Bruce's life, making him most like at least 30 years or so older than Bruce by the time he becomes Batman.
Generally speaking, the movie and television media tend to follow the later comics, where Alfred is already an adult -- and working for the Wayne family -- when Bruce is born. Alfred would be about the same age as Bruce's father, and indeed acts as a surrogate father for the orphan.
We are never given a clear age or birthdate for Alfred, and in the movies, almost nothing is explained about his backstory. In Gotham he's retired from the British military, so he's probably at least in his mid 30s when the series airs (and Bruce is an adolescant).
Comment: There is also one episode of the animated series where we learn that Alfred was a British military, maybe a British special force.
Comment: "Alfred's father had been Thomas Wayne's butler" — of course, technically, he would have been either Wayne Manor's butler, or Thomas Wayne's valet.


Tried Everything Cant find Nodes in Node Editor

Question:
I've tried numpad . I've tried ctrl+f nothing seems to work and I cant for the life of my find the damn nodes in the node editor. I'm using a macbook btw, so maybe the problem is that my numpad . isnt beside the 0?
Answer: You have to check Use Nodes otherwise no nodes will be displayed.

Then if still not visible, position all nodes in your view by pressing Home (it may also be labeled pos1 on your keyboard).
Comment: Thanks so much this is a lifesaver the only thing though is I can't seem to find the Use Nodes button for the texture nodes?


Creating path between many points in Google Earth

Question: Is there any specific way to convert approximately 25000 points in Google Earth Pro to paths or draw paths between points automatically? Since I want to obtain their altitude data, I need it to be a path (elevation profile). I drew a grid point in another software and converted it to a KML file, but I need it to be path.
Answer: If your point data can be visualised in a GIS system such as arcmap then there are tools that will string the points together into a polyline which you can then export to a kml. You'll want to work in wgs84. I'm sure there will be equivalent tools in qgis if you prefer to use that?
Answer: In QGIS the tool Points to path do this (Example here: https://www.youtube.com/watch?v=U4ecutybI0w). You need to specify the field containing the order in which the points will be connected.
You can also use the following toolbox: https://plugins.qgis.org/planet/tag/routing/


Difference between JSPX and JSFF file-types inside ADF framework?

Question: What is the difference between JSPF and JSFF file-types in ADF ?
I have not been able to find sufficient information on JSFF files online.
JSPX and JSFF refer to JSP Fragment and JSF Fragment respectively. JSFF is typically used in ADF projects.
Answer: JSFF is used for page fragments in ADF
JSPX is used for regular JSF pages
You can have JSFF inside ADF taskflows and then include them inside JSPX pages.
Comment: I have an adf taskflow with jsff's inside, but when i drag it into a jspx file it gives an error saying 'Cannot create a region from a task flow containing facelets fragments in a jspx page. '
Answer: jsff is not a runnable target If you want to run this page It should be included inside jspx pages.
One more major thing is that, whenever we use ADF task flow we use jsff fragment
OR You can Say that:--
.jspx page is JSP/XML representation, it is a standalone page which means it can run without any supporting or base page. Jdeveloper 11g Release1 supports .jspx page but this is not in Jdeveloper 11g Release2, Release2 supports Facelets means .jsf (Be clear that .jsf and .jsff is not the same thing).
while
.jsff (JSF fragments) page is a fragment of JSF(Java Server Faces) page, sometimes pages become too much complex and large and it is not easy to edit those pages, in that case it should be divided in some fragments. JSF page can be broken in some smaller page fragments to avoid difficulties in editing and maintaining page fragments can't run independently, it requires a base of .jsf(JSF page) or .jspx (JSP/XML) page
Note:- (.jsf and .jsff is not the same thing)
.jsf Vs .jspx

jspx is by convention, a JSP/XML representation, whereas .jsf is by convention a facelets representation. Neither is "more compatible," but Facelets is the recommended way forward, as long as you are on 11.1.2 or later.
11.1.2.x uses .jsf as default (for Faclets) where as 11.1.1.x uses .jspx
Usually Facelets is considered to be of better performance because it is tighter integrated with the JSf lifcycle and doesn't need to be compiled before running it
JSPX documents and Facelets are bot supported with JDeveloper 11g R2 and we do support them equallly in functionality (very little differences exist on both sides)
JSPX documents are the only choice in JDeveloper 11g R1
Answer: JSFF is used for page fragments while JSPX is used for regular ADF pages, technically you can also use JSPX as page fragment. When you use JDeveloper wizard to create a page fragment, the default extension will be jsff.
According to the Oracle document "there is no special reason to use .jsff other than quick differentiation between complete JSF pages and page fragments when you are working in the Application Navigator in JDeveloper."


Trigger.io Collaboration

Question: Hey I'm collaborating on a Trigger.io project and I'm curious if there is documentation on how to best do this? I have other guys who are loading my project into their environments (via github) using TriggerToolkit, and they can't run the projects because there are conflicts with identity.json.
Comment: I found this answer helpful:

http://stackoverflow.com/questions/10822272/how-can-i-add-another-collaborator-to-my-trigger-io-project#framed-by-olark
Comment: +1 for @botbot's link - I'm going to be covering this in a webinar this Wednesday (5th Aug '12) too. We are fleshing out a better way to do team collaborations right now, but for now, everyone having their own identity.json is the way forward.
Comment: keep me posted @James, i'd be glad to help and test it out as well.
Answer: We're working on a simpler way for team collaboration, but for now the process for importing and existing Trigger.io will be similar to the instructions here for one of our demo apps:
https://github.com/amirnathoo/Sales-Square
Basically each app you create has a unique src/identity.json file which is also specific to your account. You should avoid checking in your src/identity.json file and a collaborator should create their own by creating a new app and then copying your code into the src directory.
Update: we've now enabled better collaboration with our Projects launch announced last week:
http://trigger.io/cross-platform-application-development-blog/2013/01/15/introducing-projects/
This should remove the need to manually create / overwrite the src/identity.json file to share Trigger.io app code

Trigger.io Collaboration


How to set billing and shipping address to Quote

Question: I want to set billing and shipping address to Quote. Actually I am creating an API for which I need to get Shipping Price and other normal checkout information. So I am thinking that, if I can able to set billing and shipping address to quote then it will easy to fetch shipping price from quote. Please help me to achieve this. Many thanks.
Answer: The quote class has:
public function setBillingAddress(Mage_Sales_Model_Quote_Address $address)
public function setShippingAddress(Mage_Sales_Model_Quote_Address $address)
public function addAddress(Mage_Sales_Model_Quote_Address $address)

the address object is:
$address = Mage::getModel('sales/quote_address')->setAddressType($type);
$type can be Mage_Sales_Model_Quote_Address::TYPE_BILLING or Mage_Sales_Model_Quote_Address::TYPE_SHIPPING
or simply use:
public function getBillingAddress()
public function getShippingAddress()

both again methods of the quote object.
and use $quoteObject->collectTotals() to get the totals calculated.


Why doesn't **sort** sort the same on every machine?

Question: Using the same sort command with the same input produces different results on different machines.  How do I fix that?
Answer: The man-page on OS X says:

*******  WARNING ******* The locale specified by the environment affects sort order.  Set LC_ALL=C to get
the traditional sort order that uses native byte values.

which might explain things.
If some of your systems have no locale support, they would default to that locale (C), so you wouldn't have to set it on those. If you have some that supports locales and want the same behavior, set LC_ALL=C on those systems. That would be the way to have as many systems as I know do it the same way.
If you don't have any locale-less systems, just making sure they share locale would probably be enough.
For more canonical information, see The Single UNIX ® Specification, Version 2 description of locale, environment variables, setlocale() and the description of the sort(1) utility.
Comment: How does one set the locale to LC_ALL=C ?
Comment: @Malcolm : many recommendations will tell you to export the LC_ALL variable...but that clobbers the users shell settings. See my answer [here](http://stackoverflow.com/questions/6923464/unix-sort-ignores-whitespaces/17180962#17180962) to set it for a set scope
Answer: This can be the result of locale differences:
$ echo 'CO2_
CO_' | env LC_ALL=C sort
CO2_
CO_

$ echo 'CO2_
CO_' | env LC_ALL=en_US sort
CO_
CO2_

Setting the LC_ALL environment variable to the same value should correct the problem.
Answer: This is probably due to different settings of the locale environment variables. sort will use these settings to determine how to compare strings. By setting these environment variables the way you want before calling sort, you should be able to force it to behave in one specific way.
Answer: For more than you ever wanted to know about sort, read the specification of sort in the Single Unix Specification v3. It states

Comparisons [...] shall be performed using the collating sequence of the current locale.

IOW, how sort sorts is dependent on the locale (language) settings of the environment that the script is running under.


Change Live Mesh destination folder

Question: I just migrated from Live Sync to the superseding Live Mesh (the Live Essentials 2011 version). In Live Sync I could choose the destination folder when adding a folder to sync to another computer, but Live Mesh automatically puts in it %userprofile%\foldername. I don't even want it on that partition. Is there a way to change this, or does perchance Live Mesh play well with symlinks/junctions, so I can circumvent this unwanted behaviour that way?
Comment: Microsoft did a wonderful job in ruining my ex-favorite sync program - Foldershare
Answer: Okay, it seems you can do this, in a non-obvious roundabout way.
If you do NOT select a computer on which to share the synced folder, and just press OK, and then go to the other computer, open up Live Mesh, and click on the not-yet-shared folder (it'll be visible), you can then choose a destination.
IMO, it feels very backwards and actually somewhat dangerous (it felt like this would screw things up) to do it this way, but oh well.
In FolderShare/Live Sync, the process was a lot smoother, and you could perform the whole process on the same computer, since you browsed the file systems of all devices in the web-based UI.
Answer: Additionally, once you have remote access enabled on both PCs, you can do it from one PC.  Set up the share on PC-A and press OK without selecting PC-B (as said above).  Then go to "Remote" at the top on Live Mesh on PC-A.  Remote access PC-B.  While in remote access, double click on the Live-Mesh icon in the task bar through the remote window (so, as if you were physically at PC-B) and set up the share allowing you to choose your destination folder.
Still round-about, but can be done from one single location anywhere in the world as Sync was before.
Comment: Ah, yes, I guess that works too. Haven't bothered with the Mesh remote thing because I already use RDP7 (for multimonitor remote desktop goodness). Definitely good to know.
Comment: But is is possibly to do it without having both computers on at the same time? I want to use Windows Live Mesh similarly to Dropbox (Dropbox itself is not enough since I want more than one folder and in various locations) and decided to use SkyDrive as a means to synchronize between computers turned on mutually exclusively (I'm either at work or at home but not both...).
Answer: beware:  If you created the folder outside of your profile to share it with another user on the machine you'll have problems.  Mesh does not observe inherited permissions!  You will end up with each user putting files in a supposedly shared tree, but with me only permissions!
Answer: Short version: Just move the folder; but stop the sync first

First stop syncing the folder
1.1. Click Select Devices:

1.2. Uncheck this computer, and click OK:

Move the folder:

Start syncing again
3.1. Click Sync this folder:

3.2. Select the folder in its new location and click Sync:

The content is now syncing in its new location:

Change Live Mesh destination folder


How to work with OSX's system preferences without a mouse?

Question: My trackpad stopped working. I can't get a replacement now, so I've been working all day without it. Fortunately that was not a problem as I barely use it with VIM, ChromeVim, QuickSilver etc. Now I need to change some things on OSX System Preferences and I don't know how to. Is there a mouseless way to interact with it?
Answer: Press Control-F1. It enables full keyboard access. This should allow you to easily navigate to the desired preference and change it.
I don't know which preference you want to modify, otherwise I could've provided more precise steps.
Answer: If you are comfortable with the command line your best option is the defaults command. For an example of what you can get look here:
https://github.com/skwp/dotfiles/blob/master/osx
That is a good starting point to do your own research. If there is something specific you want to change, you should post a new question.
Answer: You may also consider AppleScript which is able to do UI scripting.
Edit :
For example I used the following AppleScript recently to change my mouse settings (enabling/disabling natural scrolling on Mavericks) :
<code>tell application "System Preferences"
    reveal pane "com.apple.preference.mouse"
end tell
tell application "System Events" to tell process "System Preferences"
    tell checkbox 1 of window 1
        click
    end tell
end tell
</code>


Covid vaccine side effects

Question: The Pfizer Covid vaccine caused allergic reactions. For patients that are deemed to be at an increased risk of adverse side effects following a risk assessment (e.g. because of diabetes, heart disease), should the vaccine be given in 3 stages instead of 2, where the first stage is a preliminary very small amount to test for adverse reactions, and then the latter 2 stages are as originally planned?
Comment: Another reference: https://www.bbc.co.uk/news/health-55244122
Answer: Consider this a very tentative answer, employing analogy rather than any hard data on the Pfizer vaccine.
In general it can be fairly difficult to know exactly what component in a vaccine caused the allergic reaction. So, an option is indeed to test with the actual vaccine. An AAAAI Q&A on the matter points to this study that experimented with the influenza and measles vaccines:

the results of the skin prick test (undiluted vaccine) and the intradermal skin test (1:10 diluted vaccine) indicated that the latter was more useful in both cases of measles (54 patients) and influenza vaccine (69 patients) Overall, the skin test using 1:10 diluted vaccine was the more suitable for predicting an immediate-type reaction to measles and influenza vaccinations. Patients having negative 1:10 skin tests can be expected to show no adverse reactions to the remaining injections and even the positive subjects will complete the course of vaccine doses by the stepwise method.

Frankly, I find the abstract (and the rest of the paper) fairly confusing in their terminology. I think they use "skin test" interchangeably with intradermal [skin] test, and in opposition to [skin] prick test, i.e. I think they ultimately recommend an intradermal 1:10 v/v diluted solution as the best method in terms of balancing risk of a severe reaction with actually detecting one at all.
Actually, they have this protocol illustrated in the paper, which does a prick test first, followed by an intradermal only if the prick test was negative.

But the conclusions of the paper are just about as confusing as the abstract. It's not terribly clear to me if they recommend following this more elaborate protocol, or just doing the intradermal test.
Comment: I found a newer paper https://www.sciencedirect.com/science/article/abs/pii/S2213219819300789 no time to read in-depth right now though.
Comment: As a practical matter, would doing any kind of test using vaccine risk "wasting" the vaccine given the demanding requirements for maintaining the cold chain (for the Pfizer vaccine--probably less for future vaccines) in a setting of scarcity?  Laying out the complexity of doing this kind of testing is useful.

Covid vaccine side effects


How can i find the source of a high pitched noise

Question: I have one old power supply, it was dead but i decided to attempt to fix it.
Replacing all bad capacitors made it power on again.
Since i didn't had one 2200uf 10v capacitor i used one 2200uf 25v capacitor but i guess this should be fine.
but then i noticed that terrible whine.
https://www.youtube.com/watch?v=NKsqcYnQ_v4
i'm almost sure that it might be a coil or transformer whining on the second stage of the psu(the stage of the high frequency switching), but is packed in a tiny area it made almost impossible to pinpoint where is this whining part.
I'm sure it isn't a fan because even unplugging the fan the whine continue.
And i can't get a new atx psu because nowadays ATX psu have a strong 12V rail and older ones have a strong 5V rail(for example one Corsair CX600 is a 600W psu but only has 25A rating on the 5V rail, this 'revived' psu has 60A rating)
Comment: "Replacing all bad capacitors". Capacitors can make that kind of noise. Maybe the new ones you soldered onto make that noise. Also, it sound like a capacitor that sits very tight to the PCB, so either a SMD capacitor or one cylindrical that is very pushed down to the PCB.
Comment: Are there any surface-mount components on the back of the PCB?
Comment: turned out that adding load to the PSU eliminated the noise.
after measuring all voltages i plugged the ATX Power supply and the noise is gone.
Answer: I do this all the time, bringing back 1970s power supplies back from the dead.
Get yourself about 18in of aquarium tubing.   Stick one end in your ear.  Wave the other end around the board to find the noise source.
Perhaps clean your ears out first.   And perhaps slightly shave off or melt the cut edge of the aquarium tubing, so you don't get 'paper cuts' inside your ear canal.
Comment: Until I brought some .25" tygon tubing from home, I was using straight pieces of heatshrink
Comment: +1 You can get an inexpensive stethoscope on Amazon or at the bookstore of a community college that trains nurses. Maybe $10. or $15. You can pull the 'sensor' part off to get an open plastic (insulating) tube.


Is there any difference between these two version of MySQL - 5.1.73-community-log Vs 5.1.73-community

Question: I have installed MySQL 5.1.73 in Oracle LINUX 5 server. Just after RPM installation, I checked system variables and found that version is 5.1.73-community.
When I copid  /usr/share/doc/MySQL-server-community-5.1.73/my-medium.cnf to /etc/my.cnf
I got 5.1.73-community-log as value of version variable.
I am curious to know about what is the difference between
5.1.73-community and 5.1.73-community-log
Comment: This isn't an answer to your real question, but you really should not be using 5.1 for a new install.  The current version 5.6 has been out and stable for quite a while.  Many bug fixes, features, performance and security updates have been introduced since the 5.1 years
Comment: @atxdba, true, I recommend using a newer version of MySQL too. But FWIW the package repo for conservative Linux distros (e.g. RHEL) haven't even updated to 5.5 yet.
Answer: They are the same software. The -log suffix is simply appended to the version string at runtime.
Here's an explanation (nearly from the last century), by long-time MySQL author Paul DuBois:

I want to know what the -log means and how it got in there.

-log is added if you start the server with logging turned on.
-debug is added if you're running a debugging version of the server with debugging on.
-demo is added if the server is running in demo mode

I verified this in the source, in sql/mysqld.cc, function set_server_version():
. . .
if (opt_log || opt_slow_log || opt_bin_log)
  strmov(end, "-log");                        // This may slow down system
. . .

I think the meaning of that comment is not that appending four extra characters to the version slows down the system, but that logging may slow down the system, so it's worth noting to the DBA that logging is enabled.
Comment: +1 for quoting from `nearly the last century` and the gentle reminder about slowdowns due to logs.
Comment: As @RolandoMySQLDBA told, a simple and clear answer with the reference of `lists.mysql.com`.


What happens if the neighborhood radius in SOM set to zero?

Question: In a project about the self-organizing map, in which I used miniSom library when I used 0 for the neighborhood radius (sigma) only one node was the winner (node 0,0). I would like to know if it is due to the implementation or if it is an expected result based on the way SOM works?
Answer: As you know, initialization of the weight vectors of a SOM map is random and setting the neighborhood radius to zero actually affect the mapping performance by resulting a twisted map. So the result of mapping can not reflect the true structure and topology of data.
About the problem of same winner for all input data, it can be happen when the variables have different scale than  the network weight. scaling the variables (ie. range scaling) can solve this problem but the resulted map still is inconsistent with radius=0. In your case, the relative position of the samples on the top map depends to the initial weight of the network (and order of sample representation) not the similarity between samples which is not a good choice for training.
Comment: PCA initialization is supported in MiniSom.
Answer: Simply speaking, a neighborhood radius set to zero means that no neighbors are updated. MiniSom comments state that the sigma at each iteration is updated, based on timestep t and total number of iterations T, as follows.

sigma(t) = sigma / (1 + t/T)
https://github.com/JustGlowing/minisom/blob/master/minisom.py#L83

Setting sigma = 0 means that there will be no neighborhood property. Indeed, any sigma < 0.5 will have a negligible neighborhood property. Thus, at each timestep, with sigma = 0, the best matching unit for each data point will be updated towards it, but there will be no neighbor interaction. Depending on your initialization and normalization, it might be possible that every single data point in the set of observations best matches the node 0,0. In this case, over time, that node will be set to the average of the set of observations, while all other nodes will be unaffected.
To fix this problem, I'd suggest normalizing the data so that it fits the range of the codebook vectors. However, looking at MiniSom https://github.com/JustGlowing/minisom/blob/master/minisom.py#L263, the codebook vectors are initialized scaled to the range of the input data. There are some comments there about normalization for PCA initialization, but my intuition is that even without that, not every single data point would best match the center node 0,0, so I think that something is strange in the statement: "when I used 0 for the neighborhood radius (sigma) only one node was the winner (node 0,0)". Maybe there was some other problem as well?
Comment: Thanks, I also received this warning: RuntimeWarning: divide by zero encountered in true_divide
  ax = exp(-power(self._neigx - c[0], 2) / d)
Answer: Kohonen said that a zero radius is equivalent to k-means. The general algorithm will always select a single node as the winner, but radius = 0 means that it does not share any of that information with its neighbours.

What is most important to understand is that the
neighborhood function has a very central role in the operation of the SOM, and
its radius should never go to zero, because otherwise the algorithm would lose
its ordering power and would be reduced to the classic k-means algorithm.

Page 4 of MATLAB Implementations
and Applications of the
Self-Organizing Map, Teuvo Kohonen


FreeRadius: Unable to delete unwanted attributes from Disconnect-Request

Question: I'm struggling to remove some unwanted attributes from the disconnect message emitted  after a failure in the rest module.
More specifically, in accounting mode, when I receive a Accounting-Request, I either return an Accounting-Response
or Disconnect-Request, depending on the HTTP status returned in a REST interaction. Both cases work properly, the only issue is
that the disconnect message also contains these attributes that nag NAS (they cause it to return a NAK):
NAS-Port
Teardown-Indicator (as 3GPP VSA)

These attributes are not present in the request. If they were, I could easily remove them and this would also affect the generated disconnect. But apparently, these attributes are added at some point that I have no control.
The "update disconnect {...}" has no effect, as I guess it is relevant only to received messages (not clear from the documentation).
I understand that disconenct belongs to a different connection, so it cannot be related and handled by tampering with 'reply' or anythig that freeradius provides me as variables. Still, I badly need to somehow solve the issue, as I have no control over the NAS itself.
Configuration details:
mod rest:
accounting {
   uri = "http://x.x.x.x:yyyy/..."
   method = 'post'
   body = 'json'
   tls = ${..tls}
}

sites default:
accounting {
    rest

    # this has no effect (same if placed inside rest {...}):
    update disconnect {
        NAS-Port !* ANY
        Teardown-Indicator !* ANY
    }
}

radius -X writes these:
(0) rest: Sending HTTP POST to "http://x.x.x.x:yyyy/..."
(0) rest: Encoding attribute "User-Name"
(0) rest: Encoding attribute "Framed-IP-Address"
(0) rest: Encoding attribute "Acct-Status-Type"
(0) rest: Encoding attribute "Acct-Session-Id"
(0) rest: Processing response header
(0) rest:   Status : 503 (Service Unavailable)
(0) rest: ERROR: Server returned no data
rlm_rest (rest): Released connection (0)
Need 5 more connections to reach 10 spares
rlm_rest (rest): Opening additional connection (5), 1 of 27 pending slots used
rlm_rest (rest): Skipping pre-connect, connect_uri not specified
(0)     [rest] = fail
(0)   } # accounting = fail
(0) WARNING: Unknown destination 127.0.0.1:3799 for CoA request.
(0) Not sending reply to client.
(0) Finished request

REST works OK and the 503 is expected for this particular case.
I cannot see something wrong (the ERROR and WARNING are not a huge surprise)
I wonder if there is some workaround to persuade freeradius not to add these naughty attributes, or otherwise, give me the chance to remove them?
Answer: Eventually I clarified the way disconnect works. Freeradius is not adding any attributes by itself; all are configurable. The disconnect in my case was generated by another 'magic' element which I had no access to and ignored its presence.
All 'update' or 'filter' configuration should work correctly, but in my case I also needed to setup the originate-coa and home_server bits, which I didn't. If I try it I will post an update to explain how exactly it is done.


Cannot find runtime 'node' on PATH. in Visual Studio Code running installed on Ubuntu 18.04

Question: I want to debug my Node.Js code in visual studio code. when I add break point and starts debugging it gives me error "Cannot find runtime 'node' on PATH". I am runnimg VS Code in ubuntu 18.04. Can some help me in fixing this issue?
Any help in this regard will be highly appreciated.
Comment: Yes, Node is installed. As, when I run command node -v in bash, it gives v10.7.0
Answer: After alot of searching I resolved this issue myself by following these two steps:

I opened the Integrated terminal and type command which node. In my case it responded with /home/user/.nvm/versions/node/v10.7.0/bin/node
Then I added an attribute "runtimeExecutable" in launch.json file and to its value I passed the path received by entering command mentioned in step one. like this
"runtimeExecutable": "/home/user/.nvm/versions/node/v10.7.0/bin/node",

Screenshot of launch.json file after adding "runtimeExecutable" in configurations
After following these two steps, I added break point and started debugging. It started debugging.
Answer: I had a similar issue with zsh and nvm on ubuntu 18.10, I fixed it by adding nvm initialization script in ~/.profile and restart login session like this
export NVM_DIR="$HOME/.nvm"
 [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm
 [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"

Answer: I have the same problem, but I have installed 2 VSC versions, one from deb package (that works without the problems) and one from Snap store that have this problem. I'm using nvm for node. Problem is that snap VSC version is running as a root and don't have node in path (even if it works in development console).
I fixed this by symbolic link of node executable for root:
sudo ln -s "$NVM_DIR/versions/node/v10.16.0/bin/node" "/usr/local/bin/node"

where v10.16.0 is my current node version.
Comment: Thanks, this worked to fix my problem. Nothing anyone else had put on similar issues worked and I was at a loss as to what was causing it.