teleren/devto huggingface dataset:
Which language and framework should I use for my next project?
Tags: discuss, project
Published: 2021-03-02 07:50:03

Everytime I think of starting a new project, first thing come in mind is:
What languages and frameworks should I choose.

Instead of moving forward with the project I keep on planning about the frameworks to choose. 

Should I start now or wait for the next release of the framework. 
Vue3 is coming with lot of cool features lets wait for it's release, then I will start.

And to be honest I know that I would barely need the new cool features for my project.

This is a kind of procrastination. I don't require those cool new features, I am just afraid of starting. 

How can I fix this? Well, "Just do it".
But is it that easy?

What you think about it. Can you relate with it, and what you would do to fix it.
Realtime AI Video Upscaling in the Browser
Tags: javascript, ai, webrtc, webg
Published: 2021-03-02 07:45:33

Hey all,

I'm working on a Javascript library which uses AI to upscale video in real-time in the browser ([demo](https://files.vectorly.io/demo/docs-demos/ducks/index.html)!).

It's based on an idea called [Super Resolution](https://en.wikipedia.org/wiki/Super-resolution_imaging), an AI technique commonly used in Image and Video enhancement.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4oekcstumucvzh6enh29.png)

I think real-time AI up-scaling could be helpful for improving video quality for users on slow networks, or to improve call quality in WebRTC video conferencing ([demo](https://files.vectorly.io/demo/webrtc/index.html)).

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x2f46hckr4qsidh4bfvi.png)

Would love to get some feedback on it! We've just released our library for anyone who interested in playing around with Super resolution ([docs](https://vectorly.io/docs/technology/), [quickstart](https://vectorly.io/docs/docs-page.html#section-2))
Multi-Select Dialogue in Flutter: A Versatile Approach
Tags: flutter, dart, android, ios
Published: 2021-03-02 07:40:12

![Multiple Selection Dialogue](https://miro.medium.com/max/400/1*2Fr4X0UmCPkeOgX_FW_8vg.gif)


Are you a flutter developer who is facing trouble creating a Multiple Selection Dialogue? 

Have you been restricted to use any third-party packages like pubspec packages? 

Do you wish to apply basic validation to such a dialogue?

Fear no more because this [article](https://levelup.gitconnected.com/multi-select-dialogue-in-flutter-a-versatile-approach-69ea0a598bac) covers everything in a detailed manner.
Store images in MongoDB via Python
Tags: python, mongodb, jpg
Published: 2021-03-02 07:22:08

Hello Coders,

This article will brief you about `Storing the images in MongoDB via python code.`

This is what want to achieve:
![](https://i.imgur.com/m2CSR4q.png)


### Dependencies

We will be using just 2 library dependencies, namely:
1. GridFS
2. PyMongo

#### What is GridFS?

GridFS is the MongoDB specification for storing and retrieving large files such as images, audio files, video files, etc. It is kind of a file system to store files but its data is stored within MongoDB collections. GridFS has the capability to store files even greater than its document size limit of 16MB.

### What is pymongo?

The PyMongo distribution contains tools for interacting with MongoDB database from Python. The `bson` package is an implementation of the [BSON](http://bsonspec.org/) format for Python. The pymongo package is a native Python driver for MongoDB. The gridfs package is a [gridfs](https://github.com/mongodb/specifications/blob/master/source/gridfs/gridfs-spec.rst/) implementation on top of pymongo.


#### Now to Code 

* Connect to MongoDB

To install pymongo: `pip3 install pymongo`

```python
from pymongo import MongoClient

# Connect to the server with the hostName and portNumber.
connection = MongoClient("localhost", 27017)

# Connect to the Database where the images will be stored.
database = connection['DB_NAME']
```

* Store the Image in the MongoDB

```python
import gridfs

#Create an object of GridFs for the above database.
fs = gridfs.GridFS(database)

#define an image object with the location.
file = "image-4.jpg"

#Open the image in read-only format.
with open(file, 'rb') as f:
    contents = f.read()

#Now store/put the image via GridFs object.
fs.put(contents, filename="file")

```

That's it for now.
Thanks for reading
Unzip large files in AWS S3 using Lambda and Node.js
Tags: aws, lambda, node, unzip
Published: 2021-03-02 07:06:10

Extracting files from large (i.e. > 1Gb) .zip files can be a challenging task specially when resources are limited or when you are billed based on the amount of memory used and  execution time (as it is the case with Lambdas).

Most Node.js packages that are used for this task work as follows: load the entire file in memory and then extract its contents. This results in a huge memory footprint (as big as the file itself) and long execution times.

[Unzipper](https://www.npmjs.com/package/unzipper) package, on the other hand, works based on Node.js [streams] (https://nodejs.org/api/stream.html). In short, streams allow us to process (read/write) data in chunks, keeping memory footprint as well as execution time very low.

The following snippet shows an example of the usage of this package. 

```javascript
const AWS = require("aws-sdk");
const s3 = new AWS.S3({ apiVersion: "2006-03-01" });
const unzipper = require("unzipper");

exports.handler = async (event) => {

  //...initialize bucket, filename and target_filename here
  try {
    /**
     * Step 1: Get stream of the file to be extracted from the zip
     */
    const file_stream = s3
      .getObject({ Bucket: bucket, Key: filename })
      .createReadStream()
      .on("error", (e) => console.log(`Error extracting file: `, e))
      .pipe(
        unzipper.ParseOne("file_name_inside_zip.ext", {
          forceStream: true,
        })
      );

    /**
     * Step 2: upload extracted stream back to S3: this method supports a readable stream in the Body param as per
     *	https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/S3.html#upload-property
     */
    await s3
      .upload({ Bucket: bucket, Key: target_filename, Body: file_stream })
      .promise();

  } catch (error) {
    console.log("Error: ", error.message, error.stack);
  }

};

```

Hope this helps!
ทดลองเขียน Clojure
Tags: clojure
Published: 2021-03-02 05:42:07

---
title: ทดลองเขียน Clojure
published: true
description: ลองเขียนเกี่ยวกับ Clojure
tags: clojure
//cover_image: https://direct_url_to_image.jpg
---

Clojure เป็นภาษาสไตล์ภาษา LISP และรันอยู่บน Java Virtual Machine.

ก่อนจะเริ่มต้นใช้เราจำเป็นต้องติดตั้งซอฟต์แวร์ในเครื่องเราก่อน ของที่ต้องใช้เลยคือ Java (เค้าแนะนำเวอร์ชัน LTS ตอนนี้คือ 8 และ 11) และ Clojure
วิธีติดตั้งดูจากหน้านี้ได้เลย https://clojure.org/guides/getting_started

จากนั้น ใช้คำสั่ง `clojure` หรือ `clj` เพื่อเข้าโปรแกรม REPL (คล้ายๆ Python interpreter หรือ JavaScript console)
จะได้หน้าตาประมาณนี้

```clojure
user=> _
```

ตัวอย่างโค้ด

```clojure
user=> (println "Hello, world!")
"Hello, world!"
nil
user=> 1
1
user=> (+ 1 1)
2
user=> (+ 1 2 3 4 5 6)
21
user=> (* (+ 1 2) (- 9 8))
6
```
เริ่มจากการเรียกฟังก์ชันก่อนเลย โดยใน Clojure จะมี form ในการเรียกฟังก์ชันคือ เริ่มต้นด้วยวงเล็บเปิด `(` แล้วตามด้วยฟังก์ชันที่ต้องการรัน
ในตัวอย่างคือ `+` `*` และ`println` ทุกฟังก์ชันจะมีการ return ข้อมูลกลับมาเสมอแม้กระทั่ง `println` แต่สังเกตให้ดีว่าค่าที่คืนกลับมานั้นคือ `nil` ไม่ใช่ string `"Hello, world!"` ที่เห็นมานั้นเป็น `side effect` ที่เกิดจากการเรียกฟังก์ชัน `println`

## Data structure
Clojure เองก็มี data structure เตรียมมาให้เราได้ใช้ เช่น `vector`, `list`, `map`, `set`

- `vector` เป็น data structure ที่เก็บข้อมูลแบบเรียงลำดับก่อนหลัง
- `list` เหมือน vector แต่กระบวนการจัดเก็บภายในแตกต่างกัน (เป็นแบบ linked list)
- `map` เก็บข้อมูลแบบ key-value หรือ hash
- `set` เก็บข้อมูลแบบไม่เรียงลำดับ และ ข้อมูลข้างในไม่ซ้ำกัน

```clojure
user=> [1 2 3]
[1 2 3]
user=> (first [1 2 3])
1
user=> '(1 2 3) ; หรือ (list 1 2 3)
(1 2 3)
user=> {:one 1 :two 2}
{:one 1 :two 2}
user=> (get {:one 1 :two 2} :one)
1
user=> #{1 2 3}
#{1 3 2}
```

## ฟังก์ชัน
แน่นอนว่า เราสามารถเขียนฟังก์ชันขึ้นมาใช้เองได้ นอกเหนือจากที่ Clojure มีมาให้ โครงสร้างของฟังก์ชันมีดังนี้

```clojure
(defn function-name [param1 param2]
  body)
```

ตัวอย่างฟังก์ชันอย่างง่าย
```clojure
user=> (defn my-plus [param1 param2]
         (+ param1 param2)) ; ค่าที่ return กลับไปคือบรรทัดสุดท้ายของส่วน body
#'user/my-plus
user=> (my-plus 10 20)
30
```
A journey to the big city
Tags: codepen, codepenchallenge
Published: 2021-03-02 06:52:06

<p>Buddy the elf leaves the North Pole to go to New York City. A submission for the Holiday Songs &amp; Movies challenge, Dec 2020 week 3.</p>

{% codepen https://codepen.io/ericrosedev/pen/KKgyGMa %}
Smooth it over
Tags: codepen, codepenchallenge
Published: 2021-03-02 06:46:10

<p>The past can't be changed, or can it? Fold and unfold a piece of paper, leaving permanent creases. A submission for the Action! challenge, Feb 2021 week 3.</p>

{% codepen https://codepen.io/ericrosedev/pen/XWNaNwg %}
Grurple power
Tags: codepen, codepenchallenge
Published: 2021-03-02 06:39:31

<p>These ferocious four pack a two-tone punch, go Team Grurple! A submission for the Color Harmonies challenge, Mar 2021 week 1.</p>

{% codepen https://codepen.io/ericrosedev/pen/MWbGjRb %}
Sitecore PaaSでデプロイスロットだけにconfigを適用する方法
Tags: sitecore, azure
Published: 2021-03-02 06:28:45

Sitecore 9.0以降ではルールベースのconfigに対応しており、検索プロバイダやサーバーロールに応じて異なるconfigを適用できるようになりました。これらの情報はWeb.configで`*:define`という名前のApp Settingsを用いて定義されています。

```xml
<!-- 他にもたくさんあります。 -->
<add key="role:define" value="ContentDelivery" />
<add key="search:define" value="Solr" />
<add key="exmEnabled:define" value="yes" />
```

これらの他に`env:define`という独自の環境名を定義することができる設定が用意されており、これを用いることでデプロイスロットにだけconfigを設定することができます。

## 手順
1. Azureポータルでデプロイスロットを開き、Configurationを選択します。
   ![image01](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wwdu9d4f6r6hjtz7413s.png)
1. New application settingを選択します。
   ![image02](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kv019tphs1u3dd06zbsk.png)
1. Nameに`env:define`を、Valueに`Staging`を入力して、Deployment slot settingにチェックを入れます。
   ![image03](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0nhwoimpx51n38dyjy1w.png)
1. Stagingだけに適用したいconfigの属性に `env:require="Staging"` を追加します。
```xml
<!-- 名前空間 env を宣言 -->
<configuration xmlns:env="http://www.sitecore.net/xmlconfig/env/" xmlns:patch="http://www.sitecore.net/xmlconfig/">
    <sitecore>
        <settings>
            <!-- envがStagingのサーバーは異なるURLを使用する -->
            <setting name="Media.MediaLinkServerUrl" env:require="Staging">
                <patch:attribute name="value">http://staging.example.com</patch:attribute>
            </setting>
        </settings>
    </sitecore>
</configuration>
```

これでデプロイスロットだけにconfigが適用されます。Deployment slot settingにチェックを入れた設定はスワップしてもスワップ前のサーバーに適用されるので、このような挙動を実現できます。

また以下のように`!`を使って指定した環境名以外に適用することも可能です。

```xml
<configuration xmlns:env="http://www.sitecore.net/xmlconfig/env/">
  <sitecore>
    <settings>
      <!-- envがStagingの場合はFooを使用 -->
      <setting name="MySetting" value="Foo" env:require="Staging" />
      <!-- それ以外ではBarを使用 -->
      <setting name="MySetting" value="Bar" env:require="!Staging" />
    </settings>
  </sitecore>
</configuration>
```

## 参考
- [Use a rule-based configuration](https://doc.sitecore.com/developers/90/platform-administration-and-architecture/en/use-a-rule-based-configuration.html)
- [Blue-Green deployment of Sitecore solutions hosted in Azure PaaS | Wunderman Thompson Technology](https://wttech.blog/blog/2020/blue-green-deployment-of-sitecore-solutions-hosted-in-azure-paas/)
Why Should I Worked?
Tags: programming, career, productivity
Published: 2021-03-02 06:18:40

hey everyone,

Normally when we are in a relaxed state we never want to do work or achieve goals. It's human nature we want all time to free. actually, that’s a comfort zone and everyone likes to stay in it. but that’s a not good thing. that makes us lazy or down our progress and intellectual power.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fio1s0af1mztzwavwhdh.jpg)
if we want to achieve some goal in life we need to do some extra work. we need to leave our comfort zone. if we worked hard on a daily basis like if I worked on my programming skills every day. one day I will crack my dream job. When we achieve some goal or fulfill some desire after work I think that’s a perfect comfort zone.

So Work hard stay blessed and archive your desires.


👍 Subscribe to me:​   https://bit.ly/3q83WQd​
What do you think is the future of Java Technology in UK ?
Ali Sami Farooq

Published: 2021-03-02 06:07:32

When Java was originally designed as OAK even its designers were not sure on what path technological innovation will develop. Java is one of the the popular and most secure language as ali sami farooq thinks because many of the banking software are running on this language. And actually Java has taken a surprising turn as a growing technological innovation in UK. He started his journey with the programs included, but people found it a little slowly when evaluating in C++. Java ventured into the web using applets and has long decided the world . But then came the business era with the campaign of di.NET and J2EE.

The centre:

Some say there is no need for individual core Java, which is now known as J2SE. J2SE consists of basic Java elements and collections such as basic terminology collection, resources, SWT, Move, Social media, Security, etc.

For dense customers:

Nowadays people expect great efficiency from networked programs on some distant web servers. The thick customer application is one of the alternatives to achieve better efficiency for such programs. A dense customer is the execution in which the customer himself provides some functions without disturbing the server for small problems. Java applets are the most aggressive candidates for thick customers. They can offer standalone features in all respects even if they can be downloaded from a distant server.

As a basis:

You should always use system collection to create innovative items and resources. J2SE provides basic collections such as terminology functions, resources, and network APIs. J2EE and other Java technology innovations are also extended or designed above such collections of systems. With edit times, J2SE or primary Java will not lose their importance.

For desktop:

Sometimes people back have begun to believe that Java is meant only for web programs. Java can still point to it as a growing technological innovation for stand-along programs. Java's only disadvantage for PC programs is the deterioration in efficiency. Contemporary components can easily overcome this disadvantage. But at the same time Java offers many advantages also applicable to programs on their own, such as system freedom, scalability, ease of support, versatility, etc.

Enterprise:

Java's business mode in UK, known as J2EE (Java 2 Enterprise Edition), is the most popular Java structure in use in the modern situation. J2EE is a mixture of many technological innovations included together to type a package, which offers everything you need to create a business application. It comes with features such as versatility, scalability, item alignment, security, determination, caching, efficiency adjustment, and many more.

Latest Post :  https://dev.to/alisamifarooq/twitter-to-let-users-charge-monthly-fee-for-exclusive-content-ali-sami-farooq-5k3

~ Ali Sami Farooq
Use Fancy Text(Blotter.js) with Reactjs
Tags: react, javascript, text
Published: 2021-03-02 05:46:04


![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ucjstf4kic50kaury740.gif)


{%github bradley/blotter %}


I just saw Blotter, but unfortunately, it hasn't been released as an npm package. Actually, I can build and use it, but I'm lazy so I googled to find out an npm package that allows me to use Blotter easily.

Fortunately, I could find out `react-text-fun`.

{%github nitin42/react-text-fun %}

The usage is very simple. Install react-text-fun and put the following in `index.html`

```zsh
$ yarn create react-app blotter-react
$ cd blotter-react
$ yarn add react-text-fun
# or 
$ npm install react-text-fun
```
`public/index.html`
```html
<script src="https://unpkg.com/blotterjs-fork@0.1.0/build/blotter.min.js"></script>
```

Create components folder in `src`
`src/components/distortion.js`
```jsx
import { DistortionText } from "react-text-fun";

export const Distortion = ({ text }) => {
  return (
    <>
      <DistortionText
        text={text}
        fontSize={120}
        speed={1.5}
        rotation={45.0}
        distortX={0.9}
        distortY={0.5}
        noiseAmplitude={0.8}
        noiseVolatility={1.2}
      />
    </>
  );
};
```

`src/App.js`
```jsx
import "./App.css";
// react-text-fun
import { Distortion } from "./components/distortion";
import { Flies } from "./components/flies";
import { SplitColor } from "./components/splitColor";
import { LiquidDistortion } from "./components/liquidDistortion";

function App() {
  return (
    <div className="App">
      <h1>blotter.js + react.js</h1>
      <br />
      <p>
        Distortion text is based on the Rolling Distort Material in Blotter.js.
      </p>
      <Distortion text={"Hello World"} />
      <br />
      <p>Flies Text component is based on the FliesMaterial in Blotter.js</p>
      <Flies text={"Hello World"} />
      <br />
      <p>Split color channel is based on ChannelSplitMaterial in Blotter.js</p>
      <SplitColor text={"Hello World"} />
      <br />
      <p>
        Liquid Distortion text is based on LiquidDistortMaterial in Blotter.js
      </p>
      <LiquidDistortion text={"Hello World"} />
    </div>
  );
}

export default App;
```
Demo
https://jovial-shannon-a70e98.netlify.app/

If you add dat.gui, you can add interactivity to the text easily.

{%github dataarts/dat.gui %}


The repo is here
{%github koji/blotter-with-react %}
Various Uses of Vinyl Business Signs 
Published: 2021-03-02 05:38:33

Most business proprietors require reasonable methods of promoting and get some exposure to 
improving the business. While most openings on TV and radio are out of the financial plan 
assigned for marketing, you are left pondering about ideal approaches to get more business 
without using up every last cent. Indeed, one of the most financially savvy methods of getting a 
word out there is by utilizing business signs. Business vinyl <a href="https://www.thesignbroker.com.au/a-frame-signs-brisbane/">a frame signs Brisbane</a> can grab more 
attention. 
  
Key Business Vinyl Signs 
  
With extreme rivalry locally and on a general level, you can't miss the transport. The vast 
majority of people may stroll by your business and won't realize that your business exists, and 
this is one of the main parts of having business signs. Here are the four most well-known vinyl 
business signs: 
  
Sidewalk Sign 
  
These are moderate signs that can feature the arrangements and limits that you might be 
contribution whenever of the year. You can put them before your office or business store, and the 
more individuals think about your arrangements or store. It would be good for your business. 
  
Vehicle top Sign 
  
If you are on a limited financial plan, vehicle top signs are one of the most conservative methods 
of promoting your business. The vehicle or vehicle, as it moves around the city can get the news 
out, achieving mindfulness your items or services. 
  
Open Sign 
  
One of the leading vinyl business signs reporting that you are available for business is as a rule 
neglected by most entrepreneurs. If you have to tell the clients that the store or business is open, 
it is ideal for getting a sign expressing it with the store timings. 
  
Vinyl message banner 
  
These huge vinyl signs make phenomenal business signs standing out any place. Aside from 
eye-getting mottos and vivid prints, you can find it anyplace to gather more clients for your 
business.  
 
A portion of the sign producers and designers have extraordinary limits and exceptional offers 
rushing to give you all the more value for-your-money. But more significant than the sign is the 
message that you need to put. Vehicle top signs are progressing so you can oblige a higher crowd 
while you stop at traffic lights or go interstate or even over as far as possible. The vast majority 
will attempt to peruse what the vinyl business sign says, and that is the thing that your point was.
A rather busy weekend.
Tags: vr, devops, blender, unity3d
Published: 2021-03-02 05:33:40

This weekend I had multiple projects that were buzzing around in my head. I learned about how [the pmkam address miner](https://github.com/migeyel/pmkam) for krist worked, used [vast.ai](https://vast.ai) to rent machines for some juicy GPU power (8 1080ti machines) :0

Most recently am turning myself into a 3d model for VRChat through the help of [RealityCapture](https://www.capturingreality.com/) and [Meshroom](https://alicevision.org/). Don't forget our old pal blender, and the unity VRChat SDK which I haven't even conquered.

I'll do a writeup of how I did the full body scan once I get everything working properly.

Anyways, if you are looking for a sign to go out there and get shit done, even if it is mundane or fun hobby shit, this is your sign and now is your time. Go get em' tiger!

Have a great week, and tell me what you're working on in the comments below :)
How To Create Symlink For Laravel Website
Tags: laravel, symlink, cpanel
Published: 2021-03-02 05:26:07

The process to create a symlink for laravel app in cPanel is simple.

Just create a file and fill it, then run it. And you are done. You will see a storage folder in the public folder(wherever you like to create a symlink).

1. Name the file whatever. Like here we call it "symlink.php"
2. Now fill the file with these.
```
<?php
symlink('/home/.../classific.gopickhost.com/classific/storage/app/public', '/home/.../classific.gopickhost.com/storage');
```
3. Run this file. Just call the file in your browser address bar.

**Ex.** Call *gopickhost.com/symlink.php* or *gopickhost.com/dirname/symlink.php*

######Suppose the "Classific" is the new subdomain and the folder. So, you will tell which folder should be created a copy(symlink). Make sure you have entered the correct path.######

Basically you are saying in this file.
`symlink('from_folder', 'to_folder');`
Installing Arch Linux
Tags: tutorial
Published: 2021-03-02 05:10:54

---
title: Installing Arch Linux
published: true
description: 
tags: #tutorial
//cover_image: https://direct_url_to_image.jpg
---

People seem to be loving arch linux but a few still think it's hard to install from scratch and end up using spins of the base arch linux. 

I remember making a video regarding this  a long while back. 
Might still come in handy if someone would like.

[Arch Linux Install Series](https://www.youtube.com/watch?v=N8KxiJZzww0&list=PLkU7xnHB_Y5pR7RV3dahBB3SwXWA8UhJP)
Vanilla Arch Linux Installation With ext4 filesystem
Tags: archlinux, linux, opensource
Published: 2021-03-02 04:54:16

# Installing Arch is Different from Other stuff
### Have to download the iso which will be around 700mb from the preffered mirror
> https://archlinux.org/download/
## Load the iso into USB and shutdown and boot into the iso
#.
## After booting into the iso Click on Archlinux X86_64 installer, but this wont give any sort of gui boot but this is completly opposite, this welcomes you with a terminal
#.
# Now Lets Dive into  Installation 
{% codepen https://codepen.io/murali-sree-krishna/pen/oNYLQmy %}