This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ docker run -p 80:80 nginx | |
Unable to find image 'nginx:latest' locally | |
latest: Pulling from library/nginx | |
bb79b6b2107f: Pull complete | |
111447d5894d: Pull complete | |
a95689b8e6cb: Pull complete | |
1a0022e444c2: Pull complete | |
32b7488a3833: Pull complete | |
Digest: sha256:ed7f815851b5299f616220a63edac69a4cc200e7f536a56e421988da82e44ed8 | |
Status: Downloaded newer image for nginx:latest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if compound >= 0.05: | |
print("Positive") | |
elif compound <= -0.05: | |
print("Negative") | |
else: | |
print("Neutral") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> {'neg': 0.277, 'neu': 0.493, 'pos': 0.23, 'compound': -0.1901} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> {'neg': 0.0, 'neu': 0.369, 'pos': 0.631, 'compound': 0.963} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from nltk.sentiment.vader import SentimentIntensityAnalyzer | |
sia = SentimentIntensityAnalyzer() | |
text = "Pretty pricey but the lamb burger ($25) is beyond amazing. Definitely worth it. So, so good." | |
sia.polarity_scores(text) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ python3 | |
Python 3.8.5 (default, Sep 5 2020, 10:50:12) | |
[GCC 10.2.0] on linux | |
Type "help", "copyright", "credits" or "license" for more information. | |
>>> import nltk | |
>>> nltk.download('vader_lexicon') | |
[nltk_data] Downloading package vader_lexicon to | |
[nltk_data] /home/saisyam/nltk_data... | |
True | |
>>> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ pip3 install nltk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ sudo systemctl status freeswitch.service |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ sudo chmod ugo+x freeswitch.service | |
$ sudo systemctl start freeswitch.service | |
$ sudo systemctl enable freeswitch.service |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=freeswitch | |
Wants=network-online.target | |
Requires=syslog.socket network.target local-fs.target | |
After=syslog.socket network.target network-online.target local-fs.target | |
[Service] | |
Type=forking | |
Environment="DAEMON_OPTS=-nonat" | |
EnvironmentFile=-/etc/default/freeswitch |
NewerOlder