Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 20,946
» Latest member: blackopsdlc
» Forum threads: 21,978
» Forum posts: 22,945

Full Statistics

Online Users
There are currently 1221 online users.
» 0 Member(s) | 1216 Guest(s)
Applebot, Baidu, Bing, Facebook, Google

Latest Threads
[WoW Retail News] Stat Sq...
Forum: World of Warcraft
Last Post: xSicKxBot

» Replies: 0
» Views: 6
BO6 & Warzone devs promis...
Forum: PC Discussion
Last Post: xSicKxBot

» Replies: 0
» Views: 8
I Thought Block Blast Was...
Forum: Lounge
Last Post: starfishmil

» Replies: 0
» Views: 10
[PS.Blog] Silent Hill: To...
Forum: Sony Discussion
Last Post: xSicKxBot

» Replies: 0
» Views: 6
[Steam Release] Good Comp...
Forum: New Game Releases
Last Post: xSicKxBot

» Replies: 0
» Views: 10
[DevBlog MS] Performance ...
Forum: C#, Visual Basic, & .Net Frameworks
Last Post: xSicKxBot

» Replies: 0
» Views: 17
[WoW Retail News] Over 20...
Forum: World of Warcraft
Last Post: xSicKxBot

» Replies: 0
» Views: 15
[WoW Retail News] Mythic ...
Forum: World of Warcraft
Last Post: xSicKxBot

» Replies: 0
» Views: 21
[Steam Release] Raft, 15%...
Forum: New Game Releases
Last Post: xSicKxBot

» Replies: 0
» Views: 16
Marvel Rivals Ace icon ex...
Forum: PC Discussion
Last Post: xSicKxBot

» Replies: 0
» Views: 21

 
  PC - SEASON: A letter to the future
Posted by: xSicKxBot - 02-05-2023, 03:30 PM - Forum: New Game Releases - No Replies

SEASON: A letter to the future



Immerse yourself in the world of Season, a third-person atmospheric adventure bicycle road trip game.

Leave home for the first time to collect memories before a mysterious cataclysm washes everything away. Explore, record, meet people, and unravel the strange world around you.

Publisher: Scavengers Studio

Release Date: Jan 31, 2023




https://www.metacritic.com/game/pc/seaso...the-future

Print this item

  News - Activision Blizzard To Pay $35 Million To Settle Workplace Misconduct Charges
Posted by: xSicKxBot - 02-05-2023, 03:30 PM - Forum: Lounge - No Replies

Activision Blizzard To Pay $35 Million To Settle Workplace Misconduct Charges

Activision Blizzard has reached a settlement deal with the Securities and Exchange Commission that sees the Call of Duty company pay $35 million to settle workplace charges.

Per the SEC's press release, Activision Blizzard is paying the settlement fee, but not admitting or denying any wrongdoing, over claims that it "failed to maintain disclosure controls and procedures to ensure that the company could assess whether its disclosures pertaining to its workforce were adequate."

Additionally, the $35 million settlement pertains to charges that Activision Blizzard "violated an SEC whistleblower protection rule."

Continue Reading at GameSpot

https://www.gamespot.com/articles/activi...01-10abi2f

Print this item

  [Docker] Advantages of DokuWiki Container for Home Server Lab
Posted by: SickProdigy - 02-04-2023, 07:28 PM - Forum: Linux, FreeBSD, and Unix types - No Replies

Advantages of DokuWiki Docker Container for Home Server Lab

I'm using DokuWiki to serve my text files mostly right now. Possibly some pdf files if I can find some relevant reasoning for it.

Below is an example of the accumulation of my backup text file folder. I've spent 5-10 years developing documentation on every program, OS, and hardware I've tested with. It's good to have notes to remind yourself how you did something exactly, and methods to reproduce it. Especially when you can go from python, to javascript, to html/php, to sql, to bash, okay, you should get the point. Working with so many languages, it's good to take notes, write down your objective, and follow through with written/typed examples. Any time I open a new application, I start a new text document. Got to keep track of locations, commands, plugins, and so on. I believe it's a good practice. Definitely pays off when errors in my setup arise. Hoping this site will help me be able to search my documentation better also. Since I go from 1 thing to the next so much. I'll have similar topics across multiple text files. Maybe even the same content if it relates.


[Image: OdTg6ZY.png]

Ways to link the dokuwiki pages directory to your local PC:

*So I have my local text file directory synced with another server/computer in home.
*You could use sync thing, or something similar. Forget what they are called, or personally,
*I host my "Documents" folder on the server and use samba to mount on my windows 10.

* From there you can symlink or just work out of those directories.
- I did find a way to symlink in windows that was very useful. Somewhere in this dokuwiki...

* Another good program for mounting remote folders to windows 10 SSHFS-win-manager. Works similar to samba.
* Aeome backupper can be used to backup that remote drive to your local computer in case you ever have a network outtage or something similar. Good to prepare for situations like that. Theres another backup program I like I may eventually come back and update here.

For Linux just sshfs mount the directory. Also have documentation about this in my wiki lol. I'll try to get around to updating this.

If anyone would like to checkout examples feel free to sign up here:
https://rcs1.xyz/dokuwiki/

Spread the Information
SickProdigy

Print this item

  [Oracle Blog] What’s New in Java Management Service
Posted by: xSicKxBot - 02-04-2023, 07:51 AM - Forum: Java Language, JVM, and the JRE - No Replies

What’s New in Java Management Service

Java Management Service 4.0 was released in March 2022. Read about the new features and give it a try.


https://blogs.oracle.com/java/post/jms-4-news

Print this item

  [Tut] How to Flush Your Cache on Windows and Router
Posted by: xSicKxBot - 02-04-2023, 07:51 AM - Forum: Python - No Replies

How to Flush Your Cache on Windows and Router

5/5 – (1 vote)

I work a lot with DNS settings for my websites and apps.

Today I added a few new DNS entries to set up a new server. I used DNS propagation checkers and confirmed that the DNS entries were already updated internationally. But unfortunately, I myself couldn’t access the website on my Windows machine behind my Wifi router. I could, however, access the website with my smartphone after switching off Wifi there.

This left only one conclusion: My browser, Windows OS, or router cached the stale DNS entries.

So the natural question arises:

? Question: How to flush your browser cache, Windows cache, and router cache and reset the DNS entries so they’ll be loaded freshly from the name servers?

I’ll answer these three subproblems one by one in this short tutorial:

  • Step 1: Flush your browser DNS cache (Chrome, Edge, Firefox)
  • Step 2: Flush your Windows DNS cache
  • Step 3: Flush your router DNS cache

Let’s dive into each of them one by one!


Step 1: Reset Your Browser Cache



First, reset your browser cache because it may store some DNS entries. I’ll show you how to flush your browser cache for the three most popular browsers on Windows:

  • Chrome
  • Edge
  • Firefox

Here’s how! ?

Clear Cache In Chrome


  1. Open Chrome
  2. At the top right, click More with the three vertical dots
  3. Click More tools > Clear browsing data
  4. Choose a time range. To flush everything, select All time
  5. Check boxes next to Cookies and other site data and Cached images and files
  6. Click Clear data

? More here

Clear Cache In Microsoft Edge


Go to Settings > Privacy, search, and services > scroll down > click Choose what to clear > Change the Time range and check boxes next to Cookies and other site data and Cached images and files. Then click Clear now.

? More here

Clear Cache In Firefox


Click the menu button (three horizontal bars) and select Settings > Privacy & Security. Scroll down to Cookies and Site Data section and click Clear Data.... Remove check mark in front of Cookies and Site Data so that only Cached Web Content is checked. Click the Clear button.

? More here

Now your browser has no stale DNS entries — but in my case, this didn’t fix the problem. After all, your operating system may have cached it first!

Step 2: Reset Your Windows OS Cache



There’s a long and a short answer to the question on how to flush the Windows operating system cache. In my case, it worked with the shorter answer but you may want to use the long answer instead if you absolutely need to make sure your Windows DNS cache is empty.

How to Flush Your Windows Cache (Short Answer)



Type cmd into the Windows search field and press Enter. Type “ipconfig /flushdns” and press Enter.

How to Flush Your Windows Cache (Long Answer)



  • Type cmd into the Windows search field and press Enter.
  • Type “ipconfig /flushdns” and press Enter.
  • Type “ipconfig /registerdns” and press Enter.
  • Type “ipconfig /release” and press Enter.
  • Type “ipconfig /renew” and press Enter.
  • Type “netsh winsock reset” and press Enter.
  • Restart the computer.

    Step 3: Reset Your Router Cache



    This one is simple (although a bit time-consuming): To reset your router DNS cache for sure, unplug your router and leave it unplugged for 30 seconds or more. This will reset its DNS cache for sure. Done!



    https://www.sickgaming.net/blog/2023/02/...nd-router/

    Print this item

      (Indie Deal) Match3 Love Bundle & MechWarrior 5 Rise of Rasalhague is out
    Posted by: xSicKxBot - 02-04-2023, 07:51 AM - Forum: Deals or Specials - No Replies

    Match3 Love Bundle & MechWarrior 5 Rise of Rasalhague is out

    Match3 Love Bundle | 9 Steam Games | 95% OFF
    [www.indiegala.com]
    Get ready early for St. Valentine! Forget flowers, chocolate or the traditional gifts. Get your significant other an indie bundle of Match3 games! Even if you don't have one, you too are also significant, you matter, that's why you deserve to get spoiled. Get Amanda's Magic Book 4: True Love, Rorys Restaurant: Winter Rush, Funny Pets, Academy of Magic - Lair of the Beast, Bunny Quest, Helga the Viking Warrior, Wildlife Match, The Chronicles of Hercules II - Wrath of Kronos & Suddenly Meow 2

    MechWarrior 5 Franchise Sale, up to 63% OFF
    [www.indiegala.com]

    https://www.youtube.com/watch?v=XfiI-BJnP2I
    Ubisoft Sale, up to 85% OFF
    [www.indiegala.com]

    Explosive Tripwire Trap Vorax Short
    https://www.youtube.com/watch?v=S4btEGZei7U


    https://steamcommunity.com/groups/indieg...8565103960

    Print this item

      PC - Backfirewall_
    Posted by: xSicKxBot - 02-04-2023, 07:51 AM - Forum: New Game Releases - No Replies

    Backfirewall_



    Hello and welcome to Backfirewall_, a first-person tragicomic adventure set inside a smartphone.

    You are the update assistant. Solve wacky puzzles to counter the update and save the previous operating system from deletion. The fate of the System is in your hands!

    Publisher: All in! Games

    Release Date: Jan 30, 2023




    https://www.metacritic.com/game/pc/backfirewall_

    Print this item

      [Oracle Blog] JavaOne is Back!
    Posted by: xSicKxBot - 02-03-2023, 01:34 PM - Forum: Java Language, JVM, and the JRE - No Replies

    JavaOne is Back!

    Join the world’s premier developer conference in Las Vegas at Oracle CloudWorld


    https://blogs.oracle.com/java/post/javaone-is-back

    Print this item

      [Tut] How I Built a House Price Prediction App Using Streamlit
    Posted by: xSicKxBot - 02-03-2023, 01:33 PM - Forum: Python - No Replies

    How I Built a House Price Prediction App Using Streamlit

    5/5 – (1 vote)

    In this tutorial, I will take you through a machine learning project on House Price prediction with Python. We have previously learned how to solve a classification problem.

    ? Recommended: How I Built and Deployed a Python Loan Eligibility Prediction App on Streamlit

    Today, I will show you how to solve a regression problem and deploy it on Streamlit Cloud.

    You can find an app prototype to try out here:


    What Is Streamlit?


    ? Info: Streamlit is a popular choice for data scientists looking to deploy their apps quickly because it is easy to set up and is compatible with data science libraries. We are going to set up the dashboard so that when our users fill in some details, it will predict the price of a house.

    But you may wonder:

    Why Is House Price Prediction Important?



    Well, house prices are an important reflection of the economy. The price of a property is important in real estate transactions as it provides information to stakeholders, including real estate agents, investors, and developers, to enable them to make informed decisions.

    Governments also use such information to formulate appropriate regulatory policies. Overall, it helps all parties involved to determine the selling price of a house. With such information, they will then decide when to buy or sell a house.

    We will use machine learning with Python to try to predict the price of a house. Having a background knowledge of Python and its usage in machine learning is a necessary prerequisite for this tutorial.

    ? Recommended: Python Crash Course (Blog + Cheat Sheets)

    To keep things simple, we will not be dealing with data visualization.

    The Datasets



    We will be using California Housing Data of 1990 to make this prediction. You can get the dataset on Kaggle or you check my GitHub page. Let’s load it using the Pandas library and find the number of rows and columns.

    import pandas as pd data = pd.read_csv('housing.csv')
    print(data.shape)
    # (20640, 10)

    We can see the dataset has 20640 rows and 10 features.

    Let’s get more information about the columns using the .info() method.

    data.info()

    Output:

    <class 'pandas.core.frame.DataFrame'>
    RangeIndex: 20640 entries, 0 to 20639
    Data columns (total 10 columns): # Column Non-Null Count Dtype
    --- ------ -------------- ----- 0 longitude 20640 non-null float64 1 latitude 20640 non-null float64 2 housing_median_age 20640 non-null float64 3 total_rooms 20640 non-null float64 4 total_bedrooms 20433 non-null float64 5 population 20640 non-null float64 6 households 20640 non-null float64 7 median_income 20640 non-null float64 8 median_house_value 20640 non-null float64 9 ocean_proximity 20640 non-null object
    dtypes: float64(9), object(1)
    memory usage: 1.6+ MB
    
    1. The longitude indicates how far west a house is while the latitude shows how far north the house is.
    2. The housing_median_age indicates the median age of a building. A lower number tells us that the house is newly constructed.
    3. The total_rooms and total_bedrooms indicate the total number of rooms and bedrooms within a block.
    4. The population tells us the number of people within a block while the households tell us the number of people living within a home unit of a block.
    5. The median_income is measured in tens of thousands of US Dollars. It shows the median income of households living within a block.
    6. The median_house_value is also measured in US Dollars. It is the median house value for households living in one block.
    7. The ocean_proximity tells us how close to the sea a house is located.

    The dataset has the same number of columns except total_bedroom indicating the presence of missing values. They are all of float datatype except ocean_proximity which is categorical even though it is shown as object. Let us first confirm this.

    data.ocean_proximity.value_counts()

    Output:

    <1H OCEAN 9136
    INLAND 6551
    NEAR OCEAN 2658
    NEAR BAY 2290
    ISLAND 5
    Name: ocean_proximity, dtype: int64

    It is categorical. So, we have to convert the ocean_proximity to int datatype using labelEncoder from the Scikit-learn library.

    from sklearn.preprocessing import LabelEncoder label_encoder = LabelEncoder()
    obj = (data.dtypes == 'object') for col in list(obj[obj].index): data[col] = label_encoder.fit_transform(data[col])

    Let’s check to confirm.

    data.ocean_proximity.value_counts()

    Output:

    0 9136
    1 6551
    4 2658
    3 2290
    2 5
    Name: ocean_proximity, dtype: int64

    Take note of the way labelEncoder ordered the values. We will apply this when creating our Streamlit dashboard. We then fill in the missing values with the mean of their respective columns.

    for col in data.columns: data[col] = data[col].fillna(data[col].mean()) print(data.isna().sum())

    Output:

    longitude 0
    latitude 0
    housing_median_age 0
    total_rooms 0
    total_bedrooms 0
    population 0
    households 0
    median_income 0
    median_house_value 0
    ocean_proximity 0
    dtype: int64

    Having confirmed that there are no missing values, we can now proceed to the next step.

    Standardizing the Data



    If you take a glimpse of our data using the .head() method, you will observe that the data is of differing scales.

    This will affect the model’s ability to perform accurate predictions.

    Hence, we will have to standardize our data using StandardScaler from Scikit-learn. Also, to prevent data leakage, we will make use of pipelines.

    The Models



    We have no idea which algorithm or model will perform well in this regression problem.

    A test will be carried out on different algorithms using default tuning parameters. Since this is a regression problem, we will be using 10-fold cross-validation to design our test harness and evaluate the models using R Squared metric.

    ? Info: The R Squared metric is an indication of goodness of fit. It is between 0 and 1. The closer to 1 the better. When the value is 1, it means a perfect fit.

    K-fold cross-validation works by splitting the datasets into several parts (10 folds in our case).

    The algorithm is trained repeatedly on each fold with one held back for testing. We chose this approach over train_test_split method because it gives us a more accurate and reliable result as the model is trained and evaluated repeatedly on different data.

    from sklearn.svm import SVR
    from sklearn.neighbors import KNeighborsRegressor
    from sklearn.tree import DecisionTreeRegressor
    from sklearn.linear_model import LinearRegression, Lasso, ElasticNet
    from sklearn.model_selection import KFold, cross_val_score, train_test_split
    from sklearn.pipeline import Pipeline
    import bz2 pipelines = []
    pipelines.append(('ScaledLR', Pipeline([('Scaler', StandardScaler()), ('LR', LinearRegression())])))
    pipelines.append(('ScaledLASSO', Pipeline([('Scaler', StandardScaler()), ('LASSO', Lasso())])))
    pipelines.append(('ScaledEN', Pipeline([('Scaler', StandardScaler()), ('EN', ElasticNet())])))
    pipelines.append(('ScaledKNN', Pipeline([('Scaler', StandardScaler()), ('KNN', KNeighborsRegressor())])))
    pipelines.append(('ScaledCART', Pipeline([('Scaler', StandardScaler()), ('CART', DecisionTreeRegressor())])))
    pipelines.append(('ScaledSVR', Pipeline([('Scaler', StandardScaler()), ('SVR', SVR())]))) x_train, x_test, y_train, y_test = train_test_split(x, y, test_size=0.3, random_state=7) def modeling(models): for name, model in models: kfold = KFold(n_splits=10) results = cross_val_score(model, x_train, y_train, cv = kfold, scoring='r2') print(f'{name} = {results.mean()}')

    Notice how we used Pipeline while standardizing our models. We then created a function that used 10-fold cross validation to repeatedly train our models. Then, the result is displayed using R Squared metric.

    modeling(pipelines)
    ScaledLR = 0.6321641933826154
    ScaledLASSO = 0.6321647820595134
    ScaledEN = 0.4953062096224026
    ScaledKNN = 0.7106787517028879
    ScaledCART = 0.6207570733565403
    ScaledSVR = -0.05047991785208246

    The results show that KNN benefited from scaling the data. Let’s see if we can improve the result by tuning KNN parameters.

    Tuning the Parameters



    The default number of neighbors of KNN is 7, and with it KNN achieved good results. We will conduct a grid search to identify which parameters will yield an even greater score.

    scaler = StandardScaler().fit(x_train)
    rescaledx = scaler.transform(x_train)
    k = list(range(1, 31))
    kfold = KFold(n_splits=10)
    grid = GridSearchCV(model, param_grid=param_grid, cv = k, scoring='r2')
    grid_result = grid.fit(rescaledx, y_train) print(f'Best: {grid_result.best_score_} using {grid_result.best_params_}')
    # Best: 0.7242988300529242 using {'n_neighbors': 14}

    The best for k is 14 with a mean score of 0.7243, slightly improved compared to the previous score.

    Can we better this score? Yes, of course. I’m aiming for 80% and above accuracy. In that case, we will try using ensemble methods.

    Ensemble Methods



    Let’s see what we can achieve using 4 different ensemble machine learning algorithms. Everything other than the models remains the same.

    from sklearn.ensemble import RandomForestRegressor, ExtraTreesRegressor, GradientBoostingRegressor, AdaBoostRegressor # ensembles
    ensembles = []
    ensembles.append(('ScaledAB', Pipeline([('Scaler', StandardScaler()), ('AB', AdaBoostRegressor())])))
    ensembles.append(('ScaledGBM', Pipeline([('Scaler', StandardScaler()), ('GBM', GradientBoostingRegressor())])))
    ensembles.append(('ScaledRF', Pipeline([('Scaler', StandardScaler()), ('RF', RandomForestRegressor())])))
    ensembles.append(('ScaledET', Pipeline([('Scaler', StandardScaler()), ('ET', ExtraTreesRegressor())]))) for name, model in ensembles: cv_results = cross_val_score(model, x_train, y_train, cv=kfold, scoring='r2') print(f'{name} = {cv_results.mean()}')

    Output:

    ScaledAB = 0.3835320642243155
    ScaledGBM = 0.772428054038791
    ScaledRF = 0.81023174859107
    ScaledET = 0.7978581384771901

    Random Forest Regressor achieved the highest score, and it’s what we are aiming for. Therefore, we are selecting the Random Forest Regressor algorithm to train and predict the price of a building. But can it do better than this? Sure, given that we trained only on default tuning parameters.

    Here is the full code. Save it as model.py.

    import pandas as pd
    from sklearn.preprocessing import LabelEncoder, StandardScaler
    from sklearn.ensemble import RandomForestRegressor
    from sklearn.model_selection import train_test_split, KFold, cross_val_score
    import pickle data = pd.read_csv('housing.csv')
    # select only 1000 rows
    data = data[:1000]
    # converting categorical column to int datatype
    label_encoder = LabelEncoder()
    obj = (data.dtypes == 'object')
    for col in list(obj[obj].index): data[col] = label_encoder.fit_transform(data[col]) # filling in missing values
    for col in data.columns: data[col] = data[col].fillna(data[col].mean()) # making data a numpy array like
    x = data.drop(['median_house_value'], axis=1)
    y = data.median_house_value
    x = x.values
    y = y.values
    # dividing data into train and test
    x_train, x_test, y_train, y_test = train_test_split(x, y, test_size=0.3, random_state=7) # standardzing the data
    stds = StandardScaler()
    scaler = stds.fit(x_train)
    rescaledx = scaler.transform(x_train) # selecting and fitting the model for training
    model = RandomForestRegressor()
    model.fit(rescaledx, y_train)
    # saving the trained mode
    pickle.dump(model, open('rf_model.pkl', 'wb'))
    # saving StandardScaler
    pickle.dump(stds, open('scaler.pkl', 'wb'))

    We selected only 1000 rows to reduce pickled size.

    Notice that we saved the StandardScaler() function to be used while creating the Streamlit dashboard. Since we scaled the dataset, we also expect to scale the input details from our users.

    Streamlit Dashboard



    It’s now time to design our Streamlit app. Once again, we will try to keep things simple and avoid complex designs. Save the following code as app.py.

    import streamlit as st
    import pickle def main(): style = """<div style='background-color:pink; padding:12px'> <h1 style='color:black'>House Price Prediction App</h1> </div>""" st.markdown(style, unsafe_allow_html=True) left, right = st.columns((2,2)) longitude = left.number_input('Enter the Longitude in negative number', step =1.0, format="%.2f", value=-21.34) latitude = right.number_input('Enter the Latitude in positive number', step=1.0, format='%.2f', value= 35.84) housing_median_age = left.number_input('Enter the median age of the building', step=1.0, format='%.1f', value=25.0) total_rooms = right.number_input('How many rooms are there in the house?', step=1.0, format='%.1f', value=56.0) total_bedrooms = left.number_input('How many bedrooms are there in the house?', step=1.0, format='%.1f', value=15.0) population = right.number_input('Population of people within a block', step=1.0, format='%.1f', value=250.0) households = left.number_input('Poplulation of a household', step=1.0, format='%.1f',value=43.0) median_income = right.number_input('Median_income of a household in Dollars', step=1.0, format='%.1f', value=3000.0) ocean_proximity = st.selectbox('How close to the sea is the house?', ('<1H OCEAN', 'INLAND', 'NEAR OCEAN', 'NEAR BAY', 'ISLAND')) button = st.button('Predict') # if button is pressed if button: # make prediction result = predict(longitude, latitude, housing_median_age, total_rooms,total_bedrooms, population, households, median_income, ocean_proximity) st.success(f'The value of the house is ${result}')

    We imported Streamlit and other libraries. Then we defined our main function. We want it to be executed as soon as we open the app. So, we will call the function using the __name__ variable at the very last of our script.

    The unsafe_allow_html makes it possible for the HTML tags to be executed by Python.

    With st.columns, we were able to display our variables side by side. We formatted each variable to be the same datatype in our dataset. If the button is pressed, then a callback function, the predict() function, is executed.

    ? Recommended: Streamlit Button — A Helpful Guide

    Let’s now define the predict() function.

    # load the train model
    with open('rf_model.pkl', 'rb') as rf: model = pickle.load(rf) # load the StandardScaler
    with open('scaler.pkl', 'rb') as stds: scaler = pickle.load(stds) def predict(longitude, latitude, housing_median_age, total_rooms, total_bedrooms, population, households, median_income, ocean_pro): # processing user input ocean = 0 if ocean_pro == '<1H OCEAN' else 1 if ocean_pro == 'INLAND' else 2 if ocean_pro == 'ISLAND' else 3 if ocean_pro == 'NEAR BAY' else 4 med_income = median_income / 5 lists = [longitude, latitude, housing_median_age, total_rooms, total_bedrooms, population, households, med_income, ocean] df = pd.DataFrame(lists).transpose() # scaling the data scaler.transform(df) # making predictions using the train model prediction = model.predict(df) result = int(prediction) return result

    We started by loading the train model and StandardScaler we saved earlier.

    In the predict() function, we use a ternary operator to turn user input into a number. More info about this operator in the referenced blog tutorial or this video:

    YouTube Video

    Notice that we made sure it corresponds with the number assigned by LabelEncoder. If you are ever in doubt, use the .value_counts() method on the categorical column to confirm.

    We divided the median_income by 5 since the corresponding column in our dataset is said to be in tens of thousands of Dollars. However, this may not be necessary given that StandardScaler finally scaled the data. We did it just to be on the safe side.

    The double parentheses are our way of instructing Python to turn the given inputs into a DataFrame. We also made sure the order of the parameters in the predict() function corresponds accordingly.


    If the function seems to predict the same amount despite changes to the input details, then you may check the correlation the target variable has over the features by typing data.corr().

    If we were to apply Recursive Feature Elimination (RFE) to select the best features capable of predicting the target variable, it would select just 4: longitude, latitude, median_income, and ocean_proximity. Let me show you what I mean.

    from sklearn.feature_selection import RFE
    model = RandomForestRegressor() rfe = RFE(model)
    fit = rfe.fit(x,y) print(fit.n_features_)
    # 4 print(fit.support_)
    # array([ True, True, False, False, False, False, False, True, True]) print(fit.ranking_)
    # array([1, 1, 2, 6, 3, 5, 4, 1, 1])

    Only 4 features are capable of predicting the target variable. If you kept getting the same amount, that may be the reason.

    The purpose of this tutorial is purely educational, to demonstrate how to use Python to solve machine learning problems. I tried to keep things simple by not going through data visualization and feature engineering. Since the data is old, it should not be relied on when making important decisions.

    We finally came to the end of the tutorial. Be sure to check my GitHub page to see the full project code.

    To deploy on Streamlit Cloud, I assume you have already created a repository and added the required files. Then, you create an account on Streamlit Cloud, and input your repository URL. Streamlit will do the rest.

    I have already deployed mine on Streamlit Cloud. Alright, enjoy your day.

    ? Recommended Project: How I Built and Deployed a Python Loan Eligibility Prediction App on Streamlit



    https://www.sickgaming.net/blog/2023/02/...streamlit/

    Print this item

      [Tut] How to Install phpMyAdmin on a Windows?
    Posted by: xSicKxBot - 02-03-2023, 01:33 PM - Forum: PHP Development - No Replies

    How to Install phpMyAdmin on a Windows?

    by Vincy. Last modified on February 2nd, 2023.

    Installing phpMyAdmin on a Windows computer will vary based on the existing environment. This article will tell the step-by-step process of installing phpMyAdmin using the following methods.

    1. Manual installation on top of the existing Apache server.
    2. Installation via WAMP package.

    Method 2 is an easier one, which will automatically install as part of the WAMP package. Not only WAMP but all packages like XAMPP and LAMP also have the advantage of reducing the effort.

    In a previous tutorial, we have seen how to install XAMPP. It helped to set up an Apache, PHP, and MySQL database server environment on a server.

    install phpmyadmin windows

    Manual installation on top of the existing Apache server


    We have seen the advantages of phpMyAdmin managing databases through a web interface.

    Prerequisites

    Make sure that you have installed the following before start installing phpMyAdmin.

    • Apache server
    • MySQL server
    • PHP

    Then, follow the below steps.

    • Step 1: Download the phpMyAdmin project from its official website. Download the zip file to your browser by clicking the required downloadable.
    • Step 2: Unzip the downloaded zip and copy the phpMyAdmin project.
    • Step 3: Move the phpMyAdmin extracted folder to the Apache web root, the htdocs directory.
    • Step 4: Open the php.ini file found in the PHP config root. Make sure that the file has administrator permission to edit the config.
    • Step 5: Uncomment the following extensions to enable them.
      • php_mbstring.dll
      • php_mysqli.dll
    • Step 6: Restart Apache and MySQL servers.
    • Step 7: Run the phpMyAdmin application as same as you run other PHP applications on the Apache web root.

    Installation via WAMP package


    We have seen a seven-step process of installing phpMyAdmin manually. Now, let’s see how the WAMP package provides an easy way of achieving this.

    • Step 1: Choose the suitable WAMP installer and click “download directly” -> “Download Latest Version”
    • Step 2: Double-click the downloaded WAMP installer and proceed with the wizards asking the following.
      • Choose language.
      • Accept the agreement.
      • Accept or configure the default browser.
      • Accept or Configure the default editor.
    • Step 3: Click “Finish” when the wizard prompts.
    • Step 4: Open the WAMP tool and choose phpMyAdmin from the menu.

    Thus, the phpMyAdmin is installed simply by this method.

    Conclusion


    Once installed, the phpMyAdmin will help manage the database easily via a web application interface. Previously, we saw steps to use the frequently used tools of this application. E.g., How to create a database using phpMyAdmin?

    This application helps connect a local or remote database by logging in via the landing login panel.

    ↑ Back to Top

    Share this page



    https://www.sickgaming.net/blog/2023/02/...a-windows/

    Print this item