Create an account


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

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 20,134
» Latest member: jax9090nnn
» Forum threads: 21,938
» Forum posts: 22,808

Full Statistics

Online Users
There are currently 4567 online users.
» 0 Member(s) | 4562 Guest(s)
Applebot, Baidu, Bing, Google, Yandex

 
  (Free Game Key) Shadow of the Tomb Raider Def. Ed. and Submerged: Hidden Depths
Posted by: xSicKxBot - 09-08-2022, 04:59 PM - Forum: Deals or Specials - No Replies

Shadow of the Tomb Raider Def. Ed. and Submerged: Hidden Depths

Grab these games on the Epic Games Store

❤️ Shadow of the Tomb Raider: Definitive Edition
https://store.epicgames.com/p/shadow-of-the-tomb-raider

❤️ Submerged: Hidden Depths
https://store.epicgames.com/p/submerged-hidden-depths-6065a1

Knockout city has some items that are free too

The games is free to keep until Thursday, September 8, 2022 5:00 PM.

Next week's freebies:
Hundred Days - Winemaking Simulator
Realm Royale Reforged Epic Launch Bundle

We are welcoming everyone to join our discord[discord.gg]. We are more active there on finding giveaways, small or large, and there are daily raffles you can participate.

?GrabFreeGames.com ?Twitter ?Steam Curator ?Facebook[fb.me]?Discord[discord.gg]
❤️Support us: HumbleBundle Partner[www.humblebundle.com] Fanatical Affiliate[www.fanatical.com]


https://steamcommunity.com/groups/GrabFr...5115666075

Print this item

  PC - SD Gundam Battle Alliance
Posted by: xSicKxBot - 09-08-2022, 04:59 PM - Forum: New Game Releases - No Replies

SD Gundam Battle Alliance



In SD Gundam Battle Alliance, Mobile Suits and characters from across Mobile Suit Gundam history take center stage in this all-new action RPG.

A Battle Alliance to Correct a False World
The story takes place in G: Universe, a world where Gundam canon twists and turns in ways no one can predict. To correct this world's distorted history, the player leads a 3-unit squadron consisting of Mobile Suits and pilots from across Gundam history - a true Battle Alliance.What Awaits Beyond False History...

Combo action with stunning visuals and dynamic animation
Indulge in a wide array of Mobile Suit weaponry to crush many foes with! Control Mobile Suits portrayed with realistic weathering that showcases them as weapons of war as they tear across the battlefield with dynamic animations.

Strange phenomena known as Breaks are twisting legendary moments from Gundam history, and you're in charge to fix them.
Experience Gundam history's most famous scenes as you develop new Mobile Suits to add to your arsenal. Gather Capital and expansion parts to transform your favorite machine into the ultimate MS.

Tackle missions with friends in multiplayer!
Launch into battle with 2 partners to back you up. In multiplayer, you can play through the game with up to 2 other players in a 3-person team. Enjoy this new SD Gundam action RPG solo, or with friends.

Publisher: Bandai Namco Games

Release Date: Aug 25, 2022




https://www.metacritic.com/game/pc/sd-gu...e-alliance

Print this item

  News - Little Nightmares Is Coming To Mobile This Winter
Posted by: xSicKxBot - 09-08-2022, 04:59 PM - Forum: Lounge - No Replies

Little Nightmares Is Coming To Mobile This Winter

More than five years after it first hit consoles and PC, Little Nightmares is coming to mobile. Developer Tarsier Studios made the announcement as a part of GameSpot's first-ever Swipe Showcase, revealing an Android and iOS version of the horror adventure game is coming later this year.

Set in a grim and mysterious world, Little Nightmares follows a young girl named Six as she navigates a ship filled with unusual horrors. All the while, Six must contend with a ravenous hunger that is taking over her body, leading to some pretty gruesome situations. The game features a dark, almost Coraline-like art style--though its content is decidedly more disturbing than that of the children's story. Little Nightmares explores horror through the eyes of a child and emphasizes the powerlessness they have through "hide-and-seek" style gameplay rather than allowing the players to engage in combat.

In GameSpot's review of Little Nightmares, we praised the game for its "haunting narrative," "tense cat-and-mouse style chases," and "enthralling visual and audio design." However, the game's short length did lead to some criticism.

Continue Reading at GameSpot

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

Print this item

  [Tut] Python – Finding the Most Common Element in a Column
Posted by: xSicKxBot - 09-06-2022, 10:19 PM - Forum: Python - No Replies

Python – Finding the Most Common Element in a Column

5/5 – (1 vote)

Problem Formulation and Solution Overview


This article will show you how to find the most common element in a Pandas Column.

To make it more interesting, we have the following running scenario:

You have been provided with a downloadable CSV file containing crime statistics for the San Diego area, including their respective NCIC Crime Codes.


? Question: How would you determine the most common NCIC Crime Code that occurs in San Diego’s jurisdiction?

We can accomplish this task by one of the following options:


Preparation


Before moving forward, please ensure the Pandas library is installed. Click here if you require instructions.

Then, add the following code to the top of each script. This snippet will allow the code in this article to run error-free.

import pandas as pd

After importing the Pandas library, this library is referenced by calling the shortcode (pd).


Method 1: Use Pandas mode()


This example uses the mode() method to determine the single most common crime committed in San Diego on a given day.

df = pd.read_csv('crimes.csv', usecols=['crimedescr'])
max_crime = df['crimedescr'].mode()
print(max_crime)

The above code reads in the crimedescr column from the crimes.csv file downloaded earlier. This saves to the DataFrame df.

Next, the crimedescr column is then accessed, and the mode() method is appended. This method returns a value or set of values that appear most often along a selected axis. The results save to max_crime.

These results are output to the terminal.


0 10851(A)VC TAKE VEH W/O OWNER
Name: crimedescr, dtype: object

So, out of 7,854 rows of crimes committed on a given day for San Diego, the above offense was committed the highest number of times.

The above code only provides us with the name of the most common crime; what if we need the crime name and the respective count?

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'ucr_ncic_code'])
max_crime = df['crimedescr'].mode()
max_count = df['ucr_ncic_code'].mode() print(max_crime)
print(max_count)

The above code is output to the terminal and displays the following.


0 10851(A)VC TAKE VEH W/O OWNER
Name: crimedescr, dtype: object
0 7000
Name: ucr_ncic_code, dtype: int64

Now, you are equipped to return to your boss and tell them that 7,000 offenses of 10851 (A) VC TAKE VEH W/O OWNER occurred on a given day in San Diego.

YouTube Video


Method 2: Use value_counts()


This example uses the value_counts() function to determine the top 5 most common crimes committed in San Diego on a given day.

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'ucr_ncic_code'])
top5_names = df['crimedescr'].value_counts()[:5].index.tolist()
print(top5_names)

The above code reads in the crimedescr and ucr_ncic_code columns from the crimes.csv file downloaded earlier. This saves to the DataFrame df.

Then, the crimedescr column is accessed, and the value_counts() function is appended. This function returns a series containing the counts of unique values.

However, since slicing is also appended ([:5]), only the top five (5) common crimes are retrieved and then converted to a List. The results save to top5_names.


['10851(A)VC TAKE VEH W/O OWNER', 'TOWED/STORED VEH-14602.6', '459 PC BURGLARY VEHICLE', 'TOWED/STORED VEHICLE', '459 PC BURGLARY RESIDENCE']

The above code only provides us with the names of the top 5 most common crimes; what if we need the names and their respective counts?

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'ucr_ncic_code'])
top5 = df['crimedescr'].value_counts()[:5].sort_values(ascending=False)
print(top5)

The above output is sent to the terminal.


10851(A)VC TAKE VEH W/O OWNER 653
TOWED/STORED VEH-14602.6 463
459 PC BURGLARY VEHICLE 462
TOWED/STORED VEHICLE 434
459 PC BURGLARY RESIDENCE 356
Name: crimedescr, dtype: int64

YouTube Video

A cleaner way to achieve the same results is to use the following code.

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'ucr_ncic_code'])
top5 = df['crimedescr'].value_counts().nlargest(5)
print(top5)

The above code calls the nlargest() method to determine and retrieve the top five (5) common crimes. The output is identical to the above.


10851(A)VC TAKE VEH W/O OWNER 653
TOWED/STORED VEH-14602.6 463
459 PC BURGLARY VEHICLE 462
TOWED/STORED VEHICLE 434
459 PC BURGLARY RESIDENCE 356
Name: crimedescr, dtype: int64

A much cleaner and more precise output to send to the boss!


Method 3: Use value_counts() and idxmax()


This example uses value_counts() and idxmax() to determine the single most common crime committed in San Diego on a given day.

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'ucr_ncic_code'])
max_crime = df['crimedescr'].value_counts().idxmax()
print(max_crime)

The above code reads in the crimedescr and ucr_ncic_code columns from the crimes.csv file downloaded earlier. This saves to the DataFrame df.

Then, the crimedescr column is accessed, and the value_counts() function is appended. This function returns a series containing the count of unique values.

Next, idxmax() is appended. This method returns the index of the first occurrence of the maximum index(es) over a selected axis.

The results save to max_crime and are output to the terminal.


10851(A)VC TAKE VEH W/O OWNER


Method 4: Use value_counts() and keys()


This example uses value_counts() and keys() to determine the top 5 most common crimes committed in unique grid areas of San Diego on a given day.

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'grid', 'ucr_ncic_code'])
top5_grids = df['grid'].value_counts().keys()[:5]
print(top5_grids)

The above code reads in the crimedescr, grid, and the ucr_ncic_code columns from the crimes.csv file downloaded earlier. This saves to the DataFrame df.

Let’s break the highlighted line down.

If df['grid'].value_counts() was output to the terminal, the following would display (snippet). However, we have added a heading row to make it more understandable, and only five (5) rows are displayed.


Grid # Grid Total
742 115
969 105
958 100
564 80
1084 71

Next, the code keys()[:5] is appended. The final output displays as follows.


Int64Index([742, 969, 958, 564, 1084], dtype='int64')


Method 5: Use groupby()


This examples uses groupby() to group our data on the Crime Code and displays the totals in descending order.

df = pd.read_csv('crimes.csv', usecols=['crimedescr', 'ucr_ncic_code']) res = (df.groupby(['ucr_ncic_code','crimedescr']).size() .sort_values(ascending=False) .reset_index(name='count'))
print(res)

The above code reads in the crimedescr and the ucr_ncic_code columns from the crimes.csv file downloaded earlier. This saves to the DataFrame df.

Next, the groupby() function is called and passed the first argument: df.groupby(['ucr_ncic_code','crimedescr']).size(). If this was output to the terminal at this point, the following would display (snippet).

print(df.groupby(['ucr_ncic_code','crimedescr']).size())

ucr_ncic_code crimedescr
909 2
999 1
197 1
664 1
1099 1

As you can see, the other arguments need to be added to turn this into something usable. Sorting the data in descending order and adding a count column will provide the results we are looking for.

If the original Method 5 code example was output to the terminal, the following would display.


ucr_ncic_code crimedescr count
0 2404 10851(A)VC TAKE VEH W/O OWNER 653
1 7000 TOWED/STORED VEH-14602.6 463
2 2299 459 PC BURGLARY VEHICLE 462
3 7000 TOWED/STORED VEHICLE 434
4 2204 459 PC BURGLARY RESIDENCE 356

YouTube Video


Summary


This article has provided five (5) ways to find the most common element in a Panda Column. These examples should provide you with enough information to select the one that best meets your coding requirements.

Good Luck & Happy Coding!


Programming Humor – Python


“I wrote 20 short programs in Python yesterday. It was wonderful. Perl, I’m leaving you.”xkcd



https://www.sickgaming.net/blog/2022/09/...-a-column/

Print this item

  News - NBA 2K23 Ratings For Players, Rookies, And More
Posted by: xSicKxBot - 09-06-2022, 10:19 PM - Forum: Lounge - No Replies

NBA 2K23 Ratings For Players, Rookies, And More

Wake up babe, NBA 2K23 ratings are here. Visual Concepts' latest dissertation on dropping dimes arrives this week, Friday September 9th, and as a part of their own #2KDay Countdown with brand spotlights, 2K Beats, and J. Cole's Dreamer Edition, they have offered a first look at the official 2K23 overalls--highlighting rising stars, top rookies, and which new shooters are going to swoosh.

The NBA made some noise this summer with LeBron going Drew League and back to the Lake Show, Giannis having dad jokes, Derrick Rose being the internet's “Most Loved” MVP, Trae Young sharing a few scenes from Rico Hines’ UCLA runs, and Donovan Mitchell skipping Knicks threads for Ohio, and because of that, 2K ratings will forever be a status symbol. They set the bar for the season ahead and while our predictions were headlined by new blood, the launch 2K23 ratings settle "Luka vs Curry" and dictate Day One moves in MyTeam, MyNBA Eras, and more. There's a lot to unpack (if you're a Sixers fan), so dive into the Top 10 players list below and stay tuned for more NBA 2K23 ratings.

For more NBA 2K23, check out the "First Look" trailer and info on The Jordan Challenge.

Continue Reading at GameSpot

https://www.gamespot.com/articles/nba-2k...01-10abi2f

Print this item

  PC - Destroy All Humans! 2 - Reprobed
Posted by: xSicKxBot - 09-06-2022, 10:19 PM - Forum: New Game Releases - No Replies

Destroy All Humans! 2 - Reprobed



Crypto is back with a license to probe. The alien invader returns, groovier than ever.

Experience the swinging '60s in all its chemical-induced glory and take revenge on the KGB for blowing up your mothership. You'll have to form alliances with members of the very species you came to enslave.

Publisher: THQ Nordic

Release Date: Aug 30, 2022




https://www.metacritic.com/game/pc/destr...--reprobed

Print this item

  [Tut] Python TypeError: NoneType is Not Subscriptable (Fix This Stupid Bug)
Posted by: xSicKxBot - 09-06-2022, 02:00 AM - Forum: Python - No Replies

Python TypeError: NoneType is Not Subscriptable (Fix This Stupid Bug)

5/5 – (1 vote)

Do you encounter the following error message?

TypeError: NoneType is not subscriptable

You’re not alone! This short tutorial will show you why this error occurs, how to fix it, and how to never make the same mistake again.

So, let’s get started!

Summary


Python raises the TypeError: NoneType is not subscriptable if you try to index x[i] or slice x[i:j] a None value. The None type is not indexable, i.e., it doesn’t define the __getitem__() method. You can fix it by removing the indexing or slicing call, or defining the __getitem__ method.

Example


 TypeError: 'NoneType' object is not subscriptable

The following minimal example that leads to the error:

x = None
print(x[0])
# TypeError: 'NoneType' object is not subscriptable

You set the variable to the value None. The value None is not a container object, it doesn’t contain other objects. So, the code really doesn’t make any sense—which result do you expect from the indexing operation?

Exercise: Before I show you how to fix it, try to resolve the error yourself in the following interactive shell:

If you struggle with indexing in Python, have a look at the following articles on the Finxter blog—especially the third!

? Related Articles:

Fixes


You can fix the non-subscriptable TypeError by wrapping the non-indexable values into a container data type such as a list in Python:

x = [None]
print(x[0])
# None

The output now is the value None and the script doesn’t yield an error message anymore.

An alternative is to define the __getitem__() method in your code:

class X: def __getitem__(self, i): return f"Value {i}" variable = X()
print(variable[0])
# Value 0

? Related Tutorial: Python __getitem__() magic method

You overwrite the __getitem__ method that takes one (index) argument i (in addition to the obligatory self argument) and returns the i-th value of the “container”.

In our case, we just return a string "Value 0" for the element variable[0] and "Value 10" for the element variable[10].

? Full Guide: Python Fixing This Subsctiptable Error (General)

What’s Next?


I hope you’d be able to fix the bug in your code! Before you go, check out our free Python cheat sheets that’ll teach you the basics in Python in minimal time:



https://www.sickgaming.net/blog/2022/09/...tupid-bug/

Print this item

  [Tut] Get User Location from Browser with JavaScript
Posted by: xSicKxBot - 09-06-2022, 02:00 AM - Forum: PHP Development - No Replies

Get User Location from Browser with JavaScript

by Vincy. Last modified on September 5th, 2022.

This tutorial uses JavaScript’s GeoLocation API to get users’ location. This API call returns location coordinates and other geolocation details.

The following quick example has a function getLatLong() that uses the GeoLocation API. It calls the navigator.geplocation.getCurrentPosition(). This function needs to define the success and error callback function.

On success, it will return the geolocation coordinates array. The error callback includes the error code returned by the API. Both callbacks write the response in the browser console.

User’s location is a privacy sensitive information. We need to be aware of it before working on location access. Since it is sensitive, by default browser and the underlying operating system will not give access to the user’s location information.

Important! The user has to,

  1. Explicitly enable location services at operating system level.
  2. Give permission for the browser to get location information.

In an earlier article we have seen about how to get geolocation with country by IP address using PHP.

Quick example


function getLatLong() { // using the JavaScript GeoLocation API // to get the current position of the user // if checks for support of geolocation API if (navigator.geolocation) { navigator.geolocation.getCurrentPosition( function(currentPosition) { console.log(currentPosition)}, function(error) { console.log("Error: " + error.code)} ); } else { locationElement.innerHTML = "JavaScript Geolocation API is not supported by this browser."; }
}

JavaScript GeoLocation API’s getCurrentPosition() function


The below code is an extension of the quick example with Geo Location API. It has a UI that has control to call the JavaScript function to get the current position of the user.

The HTML code has the target to print the location coordinates returned by the API.

The JavaScript fetch callback parameter includes all the geolocation details. The callback function reads the latitude and longitude and shows them on the HTML target via JavaScript.

<!DOCTYPE html>
<html>
<head>
<title>Get User Location from Browser with JavaScript</title>
<link rel='stylesheet' href='style.css' type='text/css' />
<link rel='stylesheet' href='form.css' type='text/css' />
</head>
<body> <div class="phppot-container"> <h1>Get User Location from Browser with JavaScript</h1> <p>This example uses JavaScript's GeoLocation API.</p> <p>Click below button to get your latitude and longitude coordinates.</p> <div class="row"> <button on‌click="getLatLong()">Get Lat Lng Location Coordinates</button> </div> <div class="row"> <p id="location"></p> </div> </div> <script> var locationElement = document.getElementById("location"); function getLatLong() { // using the JavaScript GeoLocation API // to get current position of the user // if checks for support of geolocation API if (navigator.geolocation) { navigator.geolocation.getCurrentPosition( displayLatLong, displayError); } else { locationElement.innerHTML = "JavaScript Geolocation API is not supported by this browser."; } } /** * displays the latitude and longitude from the current position * coordinates returned by the geolocation api. */ function displayLatLong(currentPosition) { locationElement.innerHTML = "Latitude: " + currentPosition.coords.latitude + "<br>Longitude: " + currentPosition.coords.longitude; } /** * displays error based on the error code received from the * JavaScript geolocation API */ function displayError(error) { switch (error.code) { case error.PERMISSION_DENIED: locationElement.innerHTML = "Permission denied by user to get location." break; case error.POSITION_UNAVAILABLE: locationElement.innerHTML = "Location position unavailable." break; case error.TIMEOUT: locationElement.innerHTML = "User location request timed out." break; case error.UNKNOWN_ERROR: locationElement.innerHTML = "Unknown error in getting location." break; } } </script>
</body>
</html>

get user location browser output

In the above example script, we have a function for handing errors. It is important to include the function when getting user location via browser. Because, by default, the user’s permission settings will be disabled.

So most of the times, when this script is invoked, we will get errors. So we should have this handler declared and passed as a callback to the getCurrentPosition function. On error, JavaScript will call this error handler.

Geolocation API’s Output


Following is the output format returned by the JavaScript geolocation API. We will be predominantly using latitude and longitude from the result. ‘speed’ may be used when getting dynamic location of the user. We will be seeing about that also at the end of this tutorial.

{ coords = { latitude: 30.123456, longitude: 80.0253546, altitude: null, accuracy: 49, altitudeAccuracy: null, heading: null, speed: null, }, timestamp: 1231234897623
}

View Demo

User location by Geocoding


We can get the user’s location by passing the latitude and longitude like below. There are many different service providers available and below is an example using Google APIs.

const lookup = position => { const { latitude, longitude } = position.coords; fetch(`http://maps.googleapis.com/maps/api/geocode/json?latlng=${latitude},${longitude}`) .then(response => response.json()) .then(data => console.log(data)); //
}


Get dynamic user location from browser using watchPosition()


Here is an interesting part of the tutorial. How will get you a user’s dynamic location, that is when he is on the move.

We should use an another function of GeoLocation API to get dynamic location coordinates on the move. The function watchPosition() is used to do this via JavaScript.

To test this script, run it in a mobile browser while moving in a vehicle to get user’s dynamic location.

I have presented the code part that is of relevance below. You can get the complete script from the project zip, it’s free to download below.

var locationElement = document.getElementById("location"); function getLatLong() { // note the usage of watchPosition, this is the difference // this returns the dynamic user position from browser if (navigator.geolocation) { navigator.geolocation.watchPosition(displayLatLong, displayError); } else { locationElement.innerHTML = "JavaScript Geolocation API is not supported by this browser."; } }

View Demo Download

↑ Back to Top



https://www.sickgaming.net/blog/2022/09/...avascript/

Print this item

  (Indie Deal) Destiny 2: Lightfall Pre-Order is ready
Posted by: xSicKxBot - 09-06-2022, 02:00 AM - Forum: Deals or Specials - No Replies

Destiny 2: Lightfall Pre-Order is ready

Final day, to check out the encore weekend freebies
[freebies.indiegala.com]
"Encore, encore" we've been hearing and we listened. We've brought back for this weekend a few of your favorites. Keep an eye on for more.

https://www.youtube.com/watch?v=LxBOlbnM1yg

Bungie Sale, UP TO 66% OFF
[www.indiegala.com]
https://www.youtube.com/watch?v=lfoeZLp5A7k
Destiny 2: Lightfall + Annual Pass[www.indiegala.com] | 16%
Destiny 2: Lightfall[www.indiegala.com] | 16%

Stay Inside, Stay Safe and Enjoy Good Games.
Check out IndieGala on Twitter, YouTube & Facebook[www.facebook.com]


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

Print this item

  PC - Soul Hackers 2
Posted by: xSicKxBot - 09-06-2022, 02:00 AM - Forum: New Game Releases - No Replies

Soul Hackers 2



The story takes place in the mid-21st century, a near future not too far from the present.

Submissive to the "Demon" with super powers, a survivor living under society, the Devil Summoner. He secretly guards society without anyone knowing.

Produced with high technology, the "Aion" that surpassed the human brain one day found a sign of the world's demise.

Aion's Ringo and Figg came to the human world to stop the world from perishing. Their purpose is to protect the key figures who can reverse the fate of their demise, but the key figures have all been killed.

Ringo then implemented the special ability "Soul Hack" possessed by Aion to revive them. They were given a "second chance", and the demon summoners joined Ringo and Figg to stop the world's demise.

As a result, will they be able to reverse their fate...?

Publisher: Sega

Release Date: Aug 26, 2022




https://www.metacritic.com/game/pc/soul-hackers-2

Print this item

 
Latest Threads
(Indie Deal) FREE W.Mafia...
Last Post: xSicKxBot
45 minutes ago
News - One Final Fantasy ...
Last Post: xSicKxBot
45 minutes ago
௹©Ukraine Shein COUPON Co...
Last Post: udwivedi923
9 hours ago
௹©Morocco Shein COUPON Co...
Last Post: udwivedi923
9 hours ago
௹©USA Shein COUPON Code ...
Last Post: udwivedi923
9 hours ago
௹©Armenia Shein COUPON Co...
Last Post: udwivedi923
9 hours ago
௹©Brazil Shein COUPON Cod...
Last Post: udwivedi923
9 hours ago
௹©South Africa Shein COUP...
Last Post: udwivedi923
9 hours ago
௹©Moldova Shein COUPON Co...
Last Post: udwivedi923
9 hours ago
௹©Malta Shein COUPON Code...
Last Post: udwivedi923
9 hours ago

Forum software by © MyBB Theme © iAndrew 2016